https://livekit.io logo
Join Slack
Powered by
# ask-ai
  • f

    flaky-scooter-85113

    11/03/2025, 6:28 PM
    Can you suggest reasons why
    Copy code
    await roomService.moveParticipant('transfer-room-yS9Y-UrNT', 'contact-REDACTED-room-yS9Y-UrNT', 'room-yS9Y-UrNT');
    gave error:
    Copy code
    Error moving participant "contact-REDACTED-room-yS9Y-UrNT" from "transfer-room-yS9Y-UrNT" to "room-yS9Y-UrNT" Not Found: no handler for path "/twirp/livekit.RoomService/MoveParticipant"
        at TwirpRpc.request (file:///app/node_modules/.pnpm/livekit-server-sdk@2.14.0/node_modules/livekit-server-sdk/dist/TwirpRPC.js:59:13)
        at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
        at async RoomServiceClient.moveParticipant (file:///app/node_modules/.pnpm/livekit-server-sdk@2.14.0/node_modules/livekit-server-sdk/dist/RoomServiceClient.js:162:5)
        at async Object.execute (file:///app/dist/tools/contact-warm-transfer.js:152:33)
        at async file:///app/node_modules/.pnpm/@livekit+agents@1.0.15_@livekit+rtc-node@0.13.20_zod@3.25.76/node_modules/@livekit/agents/dist/voice/generation.js:584:16 {
      status: 404,
      code: 'bad_route',
      metadata: {
        twirp_invalid_route: 'POST /twirp/livekit.RoomService/MoveParticipant'
      }
    }
    And ultimately, any suggestions for resolution.
    t
    • 2
    • 6
  • m

    many-forest-60185

    11/03/2025, 6:30 PM
    How would I listen to when a call is hung up by the user / agent? I want to do an action when the call is finished.
    t
    • 2
    • 2
  • i

    important-apartment-79699

    11/03/2025, 6:44 PM
    What is this error? I am getting suddenly? I've changed my keys and still seeing this>>
    t
    • 2
    • 2
  • i

    important-apartment-79699

    11/03/2025, 6:44 PM
    2025-11-03 123914,122 - ERROR livekit.agents - AgentSession is closing due to unrecoverable error Traceback (most recent call last): File "/Users/melvinramos/.pyenv/versions/3.12.9/envs/sales-receptionist/lib/python3.12/site-packages/livekit/agents/stt/stt.py", line 289, in _main_task return await self._run() ^^^^^^^^^^^^^^^^^ File "/Users/melvinramos/.pyenv/versions/3.12.9/envs/sales-receptionist/lib/python3.12/site-packages/livekit/agents/inference/stt.py", line 416, in _run ws = await self._connect_ws() ^^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/melvinramos/.pyenv/versions/3.12.9/envs/sales-receptionist/lib/python3.12/site-packages/livekit/agents/inference/stt.py", line 469, in _connect_ws ws = await asyncio.wait_for( ^^^^^^^^^^^^^^^^^^^^^^^ File "/Users/melvinramos/.pyenv/versions/3.12.9/lib/python3.12/asyncio/tasks.py", line 520, in wait_for return await fut ^^^^^^^^^ File "/Users/melvinramos/.pyenv/versions/3.12.9/envs/sales-receptionist/lib/python3.12/site-packages/aiohttp/client.py", line 1100, in _ws_connect raise WSServerHandshakeError( aiohttp.client_exceptions.WSServerHandshakeError: 401, message='Invalid response status', url='wss://agent-gateway.livekit.cloud/v1/stt'
    t
    • 2
    • 4
  • m

    many-forest-60185

    11/03/2025, 6:44 PM
    Is there any way I can get the call SID from Twilio when I dispatch the agent to join the session? Where can I grab the Twilio SID?
    t
    • 2
    • 4
  • w

    wonderful-wolf-51568

    11/03/2025, 6:50 PM
    I want to make my Agent State aware, so i have a state(e.g. greeting_completed, identity_asked, users_intent,...) and i want this to inject into the LLM, so that it knows the current state (like a Statemachine). How and where should i inject this state?
    t
    • 2
    • 2
  • m

    many-forest-60185

    11/03/2025, 6:51 PM
    How would I temporarily mute the agent and unmute?
    t
    • 2
    • 2
  • b

    breezy-island-88598

    11/03/2025, 7:19 PM
    what are the best settings in terms of turn detection & interruptions for building telephony agents with livekit
    t
    • 2
    • 2
  • w

    white-room-9349

    11/03/2025, 7:24 PM
    How can we access conversation history of just 1 agent amongst other 3-4 agents?
    t
    • 2
    • 2
  • h

    hundreds-breakfast-89028

    11/03/2025, 7:29 PM
    in quick start demo: uv run agent.py console ... 2025-11-04 032432,396 - INFO livekit.agents - job runner initialized {"tid": 597387, "elapsed_time": 0.0} 2025-11-04 032432,777 - DEBUG livekit.agents - http_session(): creating a new httpclient ctx 2025-11-04 032432,779 - DEBUG livekit.agents - using audio io:
    ChatCLI
    ->
    AgentSession
    ->
    TranscriptSynchronizer
    ->
    ChatCLI
    2025-11-04 032432,779 - DEBUG livekit.agents - using transcript io:
    AgentSession
    ->
    TranscriptSynchronizer
    ->
    ChatCLI
    2025-11-04 032433,004 - ERROR livekit.agents - AgentSession is closing due to unrecoverable error Traceback (most recent call last): File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/stt/stt.py", line 289, in _main_task return await self._run() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/inference/stt.py", line 416, in _run ws = await self._connect_ws() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/inference/stt.py", line 469, in _connect_ws ws = await asyncio.wait_for( File "/Users/steven/.pyenv/versions/3.10.16/lib/python3.10/asyncio/tasks.py", line 445, in wait_for return fut.result() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/aiohttp/client.py", line 1494, in send return self._coro.send(arg) File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/aiohttp/client.py", line 1093, in _ws_connect raise WSServerHandshakeError( aiohttp.client_exceptions.WSServerHandshakeError: 401, message='Invalid response status', url='wss://agent-gateway.livekit.cloud/v1/stt' 2025-11-04 032433,007 - ERROR asyncio - Task exception was never retrieved future: <Task finished name='Task-37' coro=<ConnectionPool.prewarm.<locals>._prewarm_impl() done, defined at /Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/utils/connection_pool.py:165> exception=WSServerHandshakeError(RequestInfo(url=URL('wss://agent-gateway.livekit.cloud/v1/tts'), method='GET', headers=<CIMultiDictProxy('Host': 'agent-gateway.livekit.cloud', 'Authorization': 'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpbmZlcmVuY2UiOnsicGVyZm9ybSI6dHJ1ZX0sInN1YiI6ImFnZW50IiwiaXNzIjoiQVBJd0hkbTg3VXlRN2U3IiwibmJmIjoxNzYyMTk3ODcyLCJleHAiOjE3NjIxOTg0NzJ9.DtFY3QvAXD3HB1CLNVwS6FKEgml_ND5g22aLEBE6Rj0', 'Upgrade': 'websocket', 'Connection': 'Upgrade', 'Sec-WebSocket-Version': '13', 'Sec-WebSocket-Key': '3+89v+WXrYAyajzFnwsX+g==', 'Accept': '*/*', 'Accept-Encoding': 'gzip, deflate', 'User-Agent': 'Python/3.10 aiohttp/3.13.2')>, real_url=URL('wss://agent-gateway.livekit.cloud/v1/tts')), (), status=401, message='Invalid response status', headers=<CIMultiDictProxy('Content-Length': '54', 'Content-Type': 'text/plain; charset=utf-8', 'Date': 'Mon, 03 Nov 2025 192432 GMT', 'Vary': 'Origin')>)> Traceback (most recent call last): File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/utils/connection_pool.py", line 168, in _prewarm_impl conn = await self._connect(timeout=self._connect_timeout) File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/utils/connection_pool.py", line 62, in _connect connection = await self._connect_cb(timeout) File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/inference/tts.py", line 290, in _connect_ws ws = await asyncio.wait_for( File "/Users/steven/.pyenv/versions/3.10.16/lib/python3.10/asyncio/tasks.py", line 445, in wait_for return fut.result() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/aiohttp/client.py", line 1494, in send return self._coro.send(arg) File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/aiohttp/client.py", line 1093, in _ws_connect raise WSServerHandshakeError( aiohttp.client_exceptions.WSServerHandshakeError: 401, message='Invalid response status', url='wss://agent-gateway.livekit.cloud/v1/tts' 2025-11-04 032433,010 - ERROR livekit.agents - Error in _stt_task Traceback (most recent call last): File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/stt/stt.py", line 408, 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/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/utils/log.py", line 16, in async_fn_logs return await fn(*args, **kwargs) File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/voice/audio_recognition.py", line 578, in _stt_task async for ev in node: File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/voice/agent.py", line 376, in stt_node async for event in stream: File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/stt/stt.py", line 411, in anext raise exc # noqa: B904 File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/stt/stt.py", line 289, in _main_task return await self._run() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/inference/stt.py", line 416, in _run ws = await self._connect_ws() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/livekit/agents/inference/stt.py", line 469, in _connect_ws ws = await asyncio.wait_for( File "/Users/steven/.pyenv/versions/3.10.16/lib/python3.10/asyncio/tasks.py", line 445, in wait_for return fut.result() File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/aiohttp/client.py", line 1494, in send return self._coro.send(arg) File "/Users/steven/wrkspc/onglai/lk/livekit-voice-agent/.venv/lib/python3.10/site-packages/aiohttp/client.py", line 1093, in _ws_connect raise WSServerHandshakeError( aiohttp.client_exceptions.WSServerHandshakeError: 401, message='Invalid response status', url='wss://agent-gateway.livekit.cloud/v1/stt' 2025-11-04 032433,014 - DEBUG livekit.agents - session closed {"reason": "error", "error": "type='stt_error' timestamp=1762197873.004409 label='livekit.agents.inference.stt.STT' error=WSServerHandshakeError(RequestInfo(url=URL('wss://agent-gateway.livekit.cloud/v1/stt'), method='GET', headers=<CIMultiDictProxy('Host': 'agent-gateway.livekit.cloud', 'Authorization': 'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpbmZlcmVuY2UiOnsicGVyZm9ybSI6dHJ1ZX0sInN1YiI6ImFnZW50IiwiaXNzIjoiQVBJd0hkbTg3VXlRN2U3IiwibmJmIjoxNzYyMTk3ODcyLCJleHAiOjE3NjIxOTg0NzJ9.DtFY3QvAXD3HB1CLNVwS6FKEgml_ND5g22aLEBE6Rj0', 'Upgrade': 'websocket', 'Connection': 'Upgrade', 'Sec-WebSocket-Version': '13', 'Sec-WebSocket-Key': 'gFAPVOEdHBkqhMVTa5skvA==', 'Accept': '*/*', 'Accept-Encoding': 'gzip, deflate', 'User-Agent': 'Python/3.10 aiohttp/3.13.2')>, real_url=URL('wss://agent-gateway.livekit.cloud/v1/stt')), (), status=401, message='Invalid response status', headers=<CIMultiDictProxy('Content-Length': '54', 'Content-Type': 'text/plain; charset=utf-8', 'Date': 'Mon, 03 Nov 2025 192432 GMT', 'Vary': 'Origin')>) recoverable=False"}
    t
    • 2
    • 18
  • b

    blue-branch-38615

    11/03/2025, 7:38 PM
    I am having an issue with the hyperparameters of my turn-detection / VAD model. The behavior is as follows: the agent replies too quickly / when an answer is not necessary (i.e. when the user says "one moment", "alright", etc.). Sometimes the user is halfway through the sentence and it does not catch that: the agent will reply and cause the rest of the user's words to be a separate speech chunk / transcript item. I suspect this issue can be resolved by fixing the turn-taking/VAD parameters, but I'm not sure which ones are relevant to change and in what direction / magnitude they should be changed. Here are my current parameters that are not default: min_endpointing_delay=0.3, min_silence_duration=0.5, prefix_padding_duration=0.1, activation_threshold=0.6.
    t
    • 2
    • 4
  • i

    important-rainbow-47551

    11/03/2025, 7:39 PM
    how to set multi agent handoff with multiple python file explain detaily
    t
    • 2
    • 2
  • f

    future-glass-56154

    11/03/2025, 7:44 PM
    When should you await a session.say and when should you not?
    t
    • 2
    • 2
  • m

    modern-stone-67508

    11/03/2025, 7:50 PM
    RuntimeError: inference of lk_end_of_utterance_multilingual failed: no inference executor
    t
    • 2
    • 2
  • a

    agreeable-dream-41746

    11/03/2025, 7:51 PM
    lets say i have 2 agents; agent 1 hands off to agent 2 and then it hands off back to agent 1; how can i have it such that only when agent 2 hands off to agent 1; then agent 1 has a new function tool available to it; is it even possible?
    t
    e
    • 3
    • 14
  • e

    early-window-29567

    11/03/2025, 8:25 PM
    How can I set the instruction in the on_enter this is what i have
    Copy code
    def __init__(self, chat_ctx=None) -> None:
            super().__init__(
                chat_ctx=chat_ctx,
                instructions="You are a helpful teaching assistant."
            )
            self.current_lesson = 0
            self.covered_lessons = []
            self.completed_lessons = []
        
        async def on_enter(self) -> None:
            """Initialize from session state when agent becomes active"""
            state: SessionState = self.session.userdata
            
            # Build dynamic instructions
            video_data = state.video_data
            language_code = state.language or 'en'
            self.instructions = get_intro_agent_instructions(video_data, language_code)
    but am getting an error AttributeError: property 'instructions' of 'IntroAgent' object has no setter {"room": "voice_assistant_room_1104", "pid": 59594, "job_id": "AJ_YDBkFsUGKGWM"}
    t
    • 2
    • 10
  • f

    fast-dentist-39499

    11/03/2025, 9:02 PM
    is it possible to preprocess audio with something like RNNoise before using it inside realtime models?
    t
    • 2
    • 8
  • f

    faint-microphone-96685

    11/03/2025, 9:49 PM
    How can I change agent language to latvian? I need a Full speech to speech solution.
    t
    • 2
    • 6
  • s

    steep-shampoo-86436

    11/03/2025, 10:47 PM
    for agent deployed to livekit, what is the maximim concurent meetings ?
    t
    • 2
    • 2
  • e

    elegant-coat-98622

    11/03/2025, 11:05 PM
    list all language supported by MultilingualModel
    t
    • 2
    • 6
  • m

    many-forest-60185

    11/04/2025, 12:27 AM
    What are your suggestions for being able to grab the user’s transcription from the STT node and getting the output from the LLM in as real time as possible? We want to do some processing real-time on that information.
    t
    • 2
    • 4
  • m

    many-forest-60185

    11/04/2025, 12:49 AM
    How can I have a ~2 second delay once the call is answered by a user before generate_reply starts?
    t
    • 2
    • 2
  • m

    many-forest-60185

    11/04/2025, 12:54 AM
    How do you advise “resetting” an agent on a call?
    t
    • 2
    • 2
  • h

    happy-diamond-58115

    11/04/2025, 2:25 AM
    https://docs.livekit.io/home/server/webhooks Why does my webhook endpoint never receive
    room_finished
    event?
    t
    • 2
    • 2
  • a

    aloof-smartphone-88022

    11/04/2025, 2:27 AM
    The agent should join the web call and remain silent, simply listening to the conversation. It should only respond when its name is mentioned, and once it has spoken, it should return to listening mode.
    t
    • 2
    • 2
  • n

    numerous-vr-95901

    11/04/2025, 3:15 AM
    I’m not receiving participant connected events when running through LiveKit cloud but I receive these events when I run via the console. What might be the cause?
    t
    • 2
    • 3
  • a

    adorable-engine-68435

    11/04/2025, 3:33 AM
    Hi, how do you create low latency pipeline agent on your main page demo?
    t
    • 2
    • 3
  • f

    future-shampoo-29056

    11/04/2025, 3:42 AM
    how can i make the agent play a prerecord file ( Please wait a minute) when the LLm take more than 5 seconds to answer
    t
    • 2
    • 11
  • h

    happy-diamond-58115

    11/04/2025, 3:51 AM
    How do I implement rate limiting? My SIP trunk provider cannot handle more than 13 channels (13 concurrent calls)
    t
    • 2
    • 8
  • a

    adorable-engine-68435

    11/04/2025, 3:51 AM
    Can we add multi/parallel language model, i.e for fast and quick reply, we want to use nano model, and we do longer or complex task on large reasoning model? How to do that? I want to reduce the STT-LLM-TTS pipeline latency on generating reply, doing task, and etc...
    👀 1
    t
    • 2
    • 4