-
Notifications
You must be signed in to change notification settings - Fork 511
How to reduce http call latency to tts service
szhaomsft edited this page Dec 26, 2019
·
4 revisions
TTS service latency is decided by the synthesis time and network.
For synthesis time, usually the longer text will take longer time to synthesize. Using streaming mode format will be helpful for long text. If you have long text, it is also useful to send the text sentence by sentence to service to reduce latency.
For network latency, HTTP connection usually takes time. When possible, try following steps:
- Try to establish connection before posting actual content (using a warm up request).
- Reuse the HTTP connection For example, in C#, reuse HttpClient object for each request. Don't create a new one.
Now, it is recommended to use speech SDK to call TTS service. It has a lot of samples in different languages to call TTS from service or client. See more https://github.com/Azure-Samples/cognitive-services-speech-sdk
- Azure TTS: Empower every person and every organization on the planet to have a delightful digital voice!
- Azure Custom Voice: Build your one-of-a-kind Custom Voice and close to human Neural TTS in cloud and edge!