big-controller-60015
09/19/2025, 7:56 AMtall-airline-16756
09/19/2025, 7:56 AMtall-airline-16756
09/19/2025, 7:56 AMinterrupted flag in the ChatMessage object, which gets set whenever an interruption happens.
• The agent_speech_interrupted event, which is triggered when the agent is interrupted while speaking.
• The agent_state_changed event, where the state changes from "speaking" to "listening" once an interruption occurs.
• The PlaybackFinishedEvent, where the interrupted field will be True if the playback was interrupted.
On top of that, you can customize how interruptions behave by adjusting the AgentSession parameters to fit your needs:
• allow_interruptions: Set this to False if you want to disable interruptions (by default, it’s True).
• min_interruption_duration: This sets the minimum speech duration in seconds required to trigger an interruption (default is 0.5 seconds).
• min_interruption_words: This defines the minimum number of transcribed words needed to consider it an interruption (default is 0).
And if you want to take manual control, you can always call the session.interrupt() method to immediately stop any ongoing or queued speech.
Sources: livekit-agents/livekit/agents/voice/agent_session.py | Turn detection and interruptions | LiveKit Docs | VoicePipelineAgent | LiveKit Docs | VoicePipelineAgent | LiveKit Docsbig-controller-60015
09/19/2025, 10:31 AMtall-airline-16756
09/19/2025, 10:32 AM