big-controller-60015
06/26/2025, 9:09 AM2025-06-26 13:13:33,262 - WARNING livekit.agents - failed to synthesize speech, retrying in 0.1s
Traceback (most recent call last):
File "/home/mohammedusamaahmed/usama1/Voice-Agents/newLivekitVersion/1_0_21_newLivekitVersionVenv/lib/python3.10/site-packages/livekit/agents/tts/tts.py", line 311, in _main_task
await self._run(output_emitter)
File "/home/mohammedusamaahmed/usama1/Voice-Agents/newLivekitVersion/1_0_21_newLivekitVersionVenv/lib/python3.10/site-packages/livekit/plugins/elevenlabs/tts.py", line 335, in _run
raise APITimeoutError() from None
livekit.agents._exceptions.APITimeoutError: Request timed out. (body=None, retryable=True) {"tts": "livekit.plugins.elevenlabs.tts.TTS", "attempt": 1, "streamed": true, "pid": 959026, "job_id": "AJ_wGUeVFe6TJfj"}
when can i get this error, how can i avoid this?tall-airline-16756
06/26/2025, 9:09 AMtall-airline-16756
06/26/2025, 9:09 AMAPITimeoutError
, occurs when an API request to synthesize speech times out. This typically happens if the text-to-speech service does not respond within the expected time frame.
To avoid this error, you can try the following:
• Ensure that the network connection is stable and has low latency.
• Check if the text-to-speech service is operational and not experiencing downtime.
• Increase the timeout settings, if configurable, to allow more time for the service to respond.
• Retry the request, as the error is marked as retryable in the logs.
If the issue persists, please let us know so we can assist further.
Sources: GitHub::livekit::agents | tests/test_tts.py