Please give a working example of how to use multilingual models with code
- I have paid the 11Labs account
- I have the correct voice id
- Im using latest examples from LiveKit
- ive tried to check all solutions from Issue search results · GitHub
Code:"""LiveKit outbound voice calling agent.Makes AI-powered outbound phone call - Pastebin.com
Log:
Summary
live-call % source .venv/bin/activate && python agent.py --local dev
2026-03-28 13:42:16,175 outbound-caller INFO: === AGENT STARTUP ===
2026-03-28 13:42:16,176 outbound-caller INFO: mode: LOCAL
2026-03-28 13:42:16,176 outbound-caller INFO: LIVEKIT_URL: wss://wefwef-8qbtn8sv.livekit.cloud
2026-03-28 13:42:16,176 outbound-caller INFO: LIVEKIT_API_KEY: set
2026-03-28 13:42:16,176 outbound-caller INFO: LIVEKIT_API_SECRET: set
2026-03-28 13:42:16,176 outbound-caller INFO: OPENAI_API_KEY: set
2026-03-28 13:42:16,176 outbound-caller INFO: DEEPGRAM_API_KEY: set
2026-03-28 13:42:16,176 outbound-caller INFO: ELEVEN_API_KEY: set
2026-03-28 13:42:16,176 outbound-caller INFO: SIP_OUTBOUND_TRUNK_ID: ST_your_trunk_id
2026-03-28 13:42:16,176 outbound-caller INFO: python: 3.12.8 (main, Dec 3 2024, 18:42:41) [Clang 16.0.0 (clang-1600.0.26.4)]
2026-03-28 13:42:16,176 outbound-caller INFO: environment validation passed
2026-03-28 13:42:16,177 outbound-caller INFO: starting worker with agent_name=‘outbound-caller’…
13:42:16.203 DEBUG… asyncio Using selector: KqueueSelector
13:42:16.207 DEV … livekit.agents Watchin
13:42:18.175 DEBUG… asyncio Using selector: KqueueSelector
13:42:18.187 INFO … livekit.agents starting worker {“version”: “1.5.1”, “rtc-version”: “1.1.3”}
13:42:18.189 INFO … livekit.agents starting inference executor
13:42:18.205 INFO … livekit.agents initializing process {“pid”: 4372, “inference”: true}
PyTorch was not found. Models won’t be available and only tokenizers, configuration and file/data utilities can be used.
13:42:23.855 INFO … livekit.agents process initialized {“pid”: 4372, “inference”: true, “elapsed_time”: 5.65}
13:42:23.864 INFO … livekit.agents HTTP server listening on :62579
13:42:24.016 INFO … livekit.agents registered worker
{“agent_name”: “outbound-caller”, “id”: “AW_E9kbKanhLRfv”, “url”: “wss://wefwef-8qbtn8sv.livekit.cloud”, “region”: “EU West B”, “protocol”:
17}
13:42:50.908 INFO … livekit.agents received job request
{“job_id”: “AJ_okHmYFtYSr87”, “dispatch_id”: “sensetive”, “room”: “sensetive”, “room_id”: “RM_ToR6saejvyJK”, “agent_name”:
“outbound-caller”, “resuming”: false, “enable_recording”: false}
13:42:50.953 DEBUG… livekit.agents received assignment
{“agent_name”: “outbound-caller”, “room_id”: “RM_ToR6saejvyJK”, “room”: “playground-t368-1aZA”, “job_id”: “AJ_okHmYFtYSr87”, “dispatch_id”:
“AD_sUg4kJU8GvBY”, “enable_recording”: false}
13:42:50.957 WARNI… livekit.agents no warmed process available for job, waiting for one to be created {“job_id”: “AJ_okHmYFtYSr87”}
13:42:50.977 INFO … livekit.agents initializing process {“pid”: 4512}
2026-03-28 13:42:52,875 outbound-caller INFO: prewarm: loading VAD model…
2026-03-28 13:42:52,875 outbound-caller INFO: prewarm: loading VAD model…
13:42:52.875 INFO … outbound-caller prewarm: loading VAD model… {“pid”: 4512}
2026-03-28 13:42:53,084 outbound-caller INFO: prewarm: VAD model loaded successfully
13:42:53.085 INFO … livekit.agents process initialized {“pid”: 4512, “elapsed_time”: 2.1}
2026-03-28 13:42:53,084 outbound-caller INFO: prewarm: VAD model loaded successfully
13:42:53.084 INFO … outbound-caller prewarm: VAD model loaded successfully {“pid”: 4512}
DEBUG… asyncio Using selector: KqueueSelector {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:53,092 outbound-caller INFO: LOCAL MODE: connecting to room playground-t368-1aZA (LIVEKIT_URL=wss://wefwef-8qbtn8sv.livekit.cloud)
2026-03-28 13:42:53,092 outbound-caller INFO: LOCAL MODE: connecting to room playground-t368-1aZA (LIVEKIT_URL=wss://wefwef-8qbtn8sv.livekit.cloud)
13:42:53.092 INFO … outbound-caller LOCAL MODE: connecting to room playground-t368-1aZA (LIVEKIT_URL=sensetive)
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,168 outbound-caller INFO: LOCAL MODE: connected to room playground-t368-1aZA successfully
2026-03-28 13:42:54,168 outbound-caller INFO: LOCAL MODE: creating OutboundCaller agent…
2026-03-28 13:42:54,169 outbound-caller INFO: OutboundCaller.init: created agent for name=Тестовый пользователь, purpose=тестирование голосового агента локально
2026-03-28 13:42:54,170 outbound-caller INFO: LOCAL MODE: creating AgentSession with STT=deepgram/nova-3, LLM=openai/gpt-4.1-mini, TTS=elevenlabs
2026-03-28 13:42:54,168 outbound-caller INFO: LOCAL MODE: connected to room playground-t368-1aZA successfully
13:42:54.168 INFO … outbound-caller LOCAL MODE: connected to room playground-t368-1aZA successfully {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,168 outbound-caller INFO: LOCAL MODE: creating OutboundCaller agent…
INFO … outbound-caller LOCAL MODE: creating OutboundCaller agent… {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,169 outbound-caller INFO: OutboundCaller.init: created agent for name=Тестовый пользователь, purpose=тестирование голосового агента локально
13:42:54.169 INFO … outbound-caller OutboundCaller.init: created agent for name=Тестовый пользователь, purpose=тестирование голосового агента локально
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,170 outbound-caller INFO: LOCAL MODE: creating AgentSession with STT=deepgram/nova-3, LLM=openai/gpt-4.1-mini, TTS=elevenlabs
13:42:54.170 INFO … outbound-caller LOCAL MODE: creating AgentSession with STT=deepgram/nova-3, LLM=openai/gpt-4.1-mini, TTS=elevenlabs
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,283 outbound-caller INFO: LOCAL MODE: AgentSession created successfully
2026-03-28 13:42:54,283 outbound-caller INFO: LOCAL MODE: starting agent session…
2026-03-28 13:42:54,283 outbound-caller INFO: LOCAL MODE: AgentSession created successfully
13:42:54.283 INFO … outbound-caller LOCAL MODE: AgentSession created successfully {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,283 outbound-caller INFO: LOCAL MODE: starting agent session…
INFO … outbound-caller LOCAL MODE: starting agent session… {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
13:42:54.286 DEBUG… livekit.agents input stream attached
{“participant”: null, “source”: “SOURCE_UNKNOWN”, “accepted_sources”: [“SOURCE_MICROPHONE”], “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”,
“room_id”: “RM_ToR6saejvyJK”}
13:42:54.287 INFO … livekit.agents adaptive interruption detector initialized
{“base_url”: “https://agent-gateway.livekit.cloud/v1”, “detection_interval”: 0.1, “audio_prefix_duration”: 1.0, “max_audio_duration”: 3,
“min_frames”: 2, “threshold”: 0.5, “inference_timeout”: 0.7, “use_proxy”: true, “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,294 outbound-caller INFO: OutboundCaller.on_enter: agent entered, generating initial greeting…
13:42:54.292 DEBUG… livekit.agents http_session(): creating a new httpclient ctx {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,294 outbound-caller INFO: OutboundCaller.on_enter: agent entered, generating initial greeting…
13:42:54.294 INFO … outbound-caller OutboundCaller.on_enter: agent entered, generating initial greeting…
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,556 outbound-caller INFO: LOCAL MODE: agent session started successfully
2026-03-28 13:42:54,556 outbound-caller INFO: LOCAL MODE: starting background audio…
13:42:54.556 DEBUG… livekit.agents using audio io: RoomIO → AgentSession → TranscriptSynchronizer → RoomIO
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
DEBUG… livekit.agents using transcript io: AgentSession → TranscriptSynchronizer → RoomIO
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,556 outbound-caller INFO: LOCAL MODE: agent session started successfully
INFO … outbound-caller LOCAL MODE: agent session started successfully {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,556 outbound-caller INFO: LOCAL MODE: starting background audio…
INFO … outbound-caller LOCAL MODE: starting background audio… {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
13:42:54.586 DEBUG… livekit.agents start reading stream
{“participant”: “identity-s4tL”, “source”: “SOURCE_MICROPHONE”, “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,623 outbound-caller INFO: LOCAL MODE: background audio started
2026-03-28 13:42:54,624 outbound-caller INFO: LOCAL MODE: fully initialized, waiting for participant to join room playground-t368-1aZA…
2026-03-28 13:42:54,623 outbound-caller INFO: LOCAL MODE: background audio started
13:42:54.623 INFO … outbound-caller LOCAL MODE: background audio started {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
2026-03-28 13:42:54,624 outbound-caller INFO: LOCAL MODE: fully initialized, waiting for participant to join room playground-t368-1aZA…
13:42:54.624 INFO … outbound-caller LOCAL MODE: fully initialized, waiting for participant to join room playground-t368-1aZA…
{“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
13:42:56.034 WARNI… livekit.agents failed to synthesize speech: LiveKit Inference TTS returned error: {“type”:“error”,“code”:“BAD_REQUEST”,“data”:“A voice with voice_id
zWSsRd3J6WyZFl12aGMB does not exist.”,“retryable”:false}, retrying in 0.1s
{“tts”: “livekit.agents.inference.tts.TTS”, “attempt”: 1, “streamed”: true, “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”:
“RM_ToR6saejvyJK”}
13:42:56.342 WARNI… livekit.agents failed to synthesize speech: no audio frames were pushed for text: Здравствуйте! Спасибо за внимание, я Богдан из ТонКоин. Могу вкратце
рассказать, как наша платформа поможет вам автоматизировать торговлю криптовалютой и получать пассивный доход. Хотите?, retrying in 2.0s
{“tts”: “livekit.agents.inference.tts.TTS”, “attempt”: 2, “streamed”: true, “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”:
“RM_ToR6saejvyJK”}
13:42:58.349 WARNI… livekit.agents failed to synthesize speech: LiveKit Inference TTS returned error: {“type”:“error”,“code”:“BAD_REQUEST”,“data”:“A voice with voice_id
zWSsRd3J6WyZFl12aGMB does not exist.”,“retryable”:false}, retrying in 2.0s
{“tts”: “livekit.agents.inference.tts.TTS”, “attempt”: 3, “streamed”: true, “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”:
“RM_ToR6saejvyJK”}
13:42:59.352 DEBUG… livekit.agents aec warmup active, disabling interruptions for 3.00s {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
13:42:59.355 DEBUG… livekit.agents resumed false interrupted speech {“timeout”: 2.0, “pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}
13:43:00.568 ERROR… livekit.agents Error in _tts_inference_task
Traceback (most recent call last):
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py”, line 647, in
anext
val = await self._event_aiter.anext()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
StopAsyncIteration
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/utils/log.py", line 17, in
async_fn_logs
return await fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/voice/generation.py", line 324,
in _tts_inference_task
pushed_duration += await _tts_node_inference(input_segment, pushed_duration)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/opentelemetry/util/_decorator.py", line 71, in
async_wrapper
return await func(*args, **kwargs) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/voice/generation.py", line 280,
in _tts_node_inference
async for audio_frame in tts_node:
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/voice/agent.py", line 490, in
tts_node
async for ev in stream:
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py", line 650, in
__anext__
raise exc # noqa: B904
^^^^^^^^^
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py", line 429, in
_traceable_main_task
await self._main_task()
File "/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py", line 480, in
_main_task
raise APIError(f"no audio frames were pushed for text: {self._pushed_text}")
livekit.agents._exceptions.APIError: no audio frames were pushed for text: Здравствуйте! Спасибо за внимание, я Богдан из ТонКоин. Могу
вкратце рассказать, как наша платформа поможет вам автоматизировать торговлю криптовалютой и получать пассивный доход. Хотите?
{"pid": 4512, "job_id": "AJ_okHmYFtYSr87", "room_id": "RM_ToR6saejvyJK"}
Traceback (most recent call last):
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py”, line 647, in anext
val = await self._event_aiter.anext()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
StopAsyncIteration
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/utils/log.py”, line 17, in async_fn_logs
return await fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/voice/generation.py”, line 324, in _tts_inference_task
pushed_duration += await _tts_node_inference(input_segment, pushed_duration)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/opentelemetry/util/_decorator.py”, line 71, in async_wrapper
return await func(*args, **kwargs) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/voice/generation.py”, line 280, in _tts_node_inference
async for audio_frame in tts_node:
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/voice/agent.py”, line 490, in tts_node
async for ev in stream:
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py”, line 650, in anext
raise exc # noqa: B904
^^^^^^^^^
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py”, line 429, in _traceable_main_task
await self._main_task()
File “/Users/dmitrydyachenko/Desktop/auction/live-call/.venv/lib/python3.12/site-packages/livekit/agents/tts/tts.py”, line 480, in _main_task
raise APIError(f"no audio frames were pushed for text: {self._pushed_text}")
livekit.agents._exceptions.APIError: no audio frames were pushed for text: Здравствуйте! Спасибо за внимание, я Богдан из ТонКоин.
13:43:02.353 DEBUG… livekit.agents aec warmup expired, re-enabling interruptions {“pid”: 4512, “job_id”: “AJ_okHmYFtYSr87”, “room_id”: “RM_ToR6saejvyJK”}