faint-arm-51818
11/04/2025, 1:34 PMtall-airline-16756
11/04/2025, 1:34 PMtall-airline-16756
11/04/2025, 1:35 PMsession.interrupt() to stop the current and queued speeches. You can force it to ignore allow_interruptions if needed. Docs
• Interrupt a specific utterance: keep the SpeechHandle returned by `say()`/`generate_reply()` and call its interrupt/cancel method. You can also check session.current_speech to access the active handle. Guide
• Let users interrupt by speaking: by default, the agent stops when user speech is detected (turn detection). Details
If you’d like, I can share a minimal code snippet (Python or Node) for your setup.
Sources: Agent Session & Client Integration | livekit/livekit_composite | DeepWiki | Agent speech and audio | LiveKit docs | Turn detection and interruptions | LiveKit Docs | How to detect when an agent has finished speakingfaint-arm-51818
11/04/2025, 1:36 PMallow_interruptions?tall-airline-16756
11/04/2025, 1:36 PMallow_interruptions=False.
• Use a forced session interrupt: call session.interrupt() in “force” mode to stop the current and queued speeches regardless of allow_interruptions. Details
• Alternatively, interrupt via your orchestration layer with a forced interrupt (equivalent behavior): it cancels preemptive generation, stops current/queued/background speeches, and updates context.
If you want a code snippet, tell me your language (Python or Node).faint-arm-51818
11/04/2025, 1:37 PMtall-airline-16756
11/04/2025, 1:38 PMSpeechHandle for that utterance:
• If you kept the handle from `say()`/`generate_reply()`, call its interrupt method (or cancel) to stop only that speech. You can also check handle.interrupted or await handle.done().
• If you don’t have the handle, use session.current_speech to get the active one and interrupt it there.
For a global stop (affects current and queued speeches), use session.interrupt(). To override allow_interruptions, call the interrupt in forced mode.
Would you like a short code snippet in Python or Node? See: Agent speech and audio, Turn detection and interruptions.
Sources: Agent Session & Client Integration | livekit/livekit_composite | DeepWiki | Turn detection and interruptions | LiveKit Docs | Agent speech and audio | LiveKit docs