steep-balloon-41261
12/26/2025, 4:12 PMtall-airline-16756
12/26/2025, 4:12 PMtall-airline-16756
12/26/2025, 4:13 PMdiscard_audio_if_uninterruptible=True (Python) or discardAudioIfUninterruptible: true (TypeScript) when creating the AgentSession alongside allow_interruptions=False. Example:
Python
session = AgentSession(
llm=google.realtime.RealtimeModel(...),
allow_interruptions=False,
discard_audio_if_uninterruptible=True,
# ...
)
TypeScript
const session = new voice.AgentSession({
llm: new google.realtime.RealtimeModel(...),
allowInterruptions: false,
discardAudioIfUninterruptible: true,
// ...
});
Would you like a snippet adapted to your existing session code or help confirming this setting is applied in your environment?
Sources: Turns overview | LiveKit docstall-airline-16756
12/26/2025, 4:18 PMpreemptive_generation is disabled for realtime models (it can interfere with streaming).
• SDK/server version mismatch: Older SDKs or server versions can show instability for longer streams.
Immediate steps to try
1. Enable observability/insights and watch jitter, packet loss, and audio buffer levels.
2. Check client console logs for buffer underflow or WebRTC warnings.
3. Test with controlled network conditions (high/low bandwidth, simulated packet loss) to reproduce.
4. Try shorter TTS outputs to confirm length dependency.
5. Ensure you’re on the latest agent and client SDK versions and that preemptive_generation is off.
If you’d like, I can dig deeper — please share:
• Agent SDK version and client SDK + platform (e.g., @livekit/agents vX.Y, Chrome on desktop)
• Typical audio duration when pauses occur (seconds)
• Whether audio resumes after the pause or stops entirely
• Any client/server logs showing warnings/errors
Which of those details can you provide so I can help pinpoint the cause?
Sources: Managing Video Quality During Network Congestion | OpenAI and LiveKit partner to turn Advanced Voice into an API | Agent speech and audio | LiveKit docs | examples/voice_agents | livekit/livekit_composite | DeepWiki | Text and transcriptions | LiveKit docs