[BidiGenerateContent] Model freezes after serverContent.interrupted — no audio output after barge-in
@thorwebdev is already working on this.
Since Jun 9, 2026.
Assessment
This issue has not been assessed yet.
Description
Environment
- Model:
gemini-3.1-flash-live-preview - Voice:
Leda - Transport: Raw WebSocket v1beta
wss://generativelanguage.googleapis.com/ws/.../BidiGenerateContent - Audio pipeline: Twilio MediaStreams (mulaw 8kHz) → PCM16 16kHz → Gemini → PCM16 24kHz → mulaw 8kHz
- Platform: Node.js (
wslibrary, raw WebSocket, no SDK)
Bug Description
When the caller interrupts the model (barge-in) and serverContent.interrupted fires, the model sometimes fails to resume generating audio after the interruption. The caller finishes speaking and waits for a response, but the model produces no audio output. The WebSocket remains open, no error is returned.
Normal barge-in behavior:
- Model is speaking
- Caller talks over the model →
serverContent.interruptedfires - Model stops speaking (correct)
- Caller finishes their turn
- Model should respond with audio → but sometimes it never does
The model enters a state where it has acknowledged the interruption (stopped its own audio) but never starts generating a new response. The caller is left in silence.
Impact
This is particularly damaging on phone calls because:
- The caller spoke (they're engaged and waiting for a response)
- Silence after someone speaks is unnatural and causes callers to hang up
- These are live sales conversations — losing them means losing business
Workarounds Implemented
- Post-interruption nudge timer (4 seconds): After every
serverContent.interruptedevent, we start a 4-second timer. If the model hasn't produced audio within 4 seconds, we injectrealtimeInput.text: "Your previous response was interrupted. Respond now with a SHORT reply."This recovers the model in some cases. - Dead call watchdog (10 seconds): If mutual silence persists for 10 seconds (including after nudge attempts), we kill the call.
Expected Behavior
After serverContent.interrupted fires and the caller finishes speaking, the model should process the caller's speech and generate an audio response — the same as it would for any turn transition. Interruption should not put the model into a permanently silent state.
Questions for the Team
- Is there a known state machine issue where
interruptedprevents the model from starting a new generation? - Does
activityHandling: 'START_OF_ACTIVITY_INTERRUPTS'interact poorly with certain conversation patterns? - Is there a recommended way to "reset" the model's turn state after an interruption?
- Would switching to manual VAD (
activityHandling: 'NO_INTERRUPTIONS') during model output and back to auto afterward help avoid this?
Related Issues
- google-gemini/gemini-live-api-examples#54 (audio output freeze — may be same root cause)
- google-gemini/gemini-live-api-examples#53 (our previous report — 13 issues)
- Dominant language
- JavaScript
- Stars
- 582
- Forks
- 205
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from google-gemini/gemini-live-api-examples
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
-
`gemini-3.1-flash-live-preview`: the model repeats the same sentence 2–4 times inside one generation (~7 s of silence between each) before releasing the toolCallMay be free again @ashishgit4 claimed this 68 days ago, and no pull request is open. Open
Difficulty 5/5 Over a week Newbie friendliness 35/100
google-gemini/gemini-live-api-examples#46 · 4 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
All issues in google-gemini/gemini-live-api-examples
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
[Windows] Hidden title bar: a maximized window restored from minimized on a secondary monitor gets the primary monitor's work area as its client areaPossibly taken @lijy91 claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 67/100
libnativeapi/nativeapi#53 · 1 reaction ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
KilledByAPixel/LittleJS#188 ·
-
[workshop-sync] workshop/06-install-gh-aw.md: outdated version example and gh aw init file listOpendocumentation
Difficulty 1/5 Under an hour Newbie friendliness 86/100
githubnext/gh-aw-workshop#6053 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
JuliusBrussee/caveman#1567 ·
Maintainers usually reply within 1 day