How to set buffer size to start processing in Streaming TTS with min_buffer_size
How to set buffer size to start processing in Streaming TTS with min_buffer_size
How to set buffer size to start processing in Streaming TTS with min_buffer_size
The min_buffer_size parameter sets the minimum number of characters that must accumulate in the buffer before the TTS engine begins converting text into audio.
We buffer incoming text until it reaches this threshold before processing and chunking begins.
This parameter is available only in the WebSocket Streaming API. It is not supported in the REST API.
This helps balance latency with natural sentence completion during real-time TTS streaming.
30 to 20050min_buffer_size, the text is automatically processed and streamed as audio.A flush command forces the TTS engine to immediately process the current buffer — even if it hasn’t reached the min_buffer_size.
Suppose min_buffer_size = 50, and you send an 80-character sentence in two parts:
To process the remaining 20 characters, send a flush message.