Google plugin: the model does not stay silent after a tool returns `None` on Vertex AI
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 25/100
Direzione di ricerca
Start with the Gemini-only scheduling: SILENT condition in livekit-plugins/livekit-plugins-google/livekit/plugins/google/utils.py (around lines 81-83) and realtime/realtime_api.py (around lines 729-745). The goal is to send scheduling on Vertex AI for a NON_BLOCKING tool that returns None. Run the linked repro_vertex_silent.py gist to confirm the model stays silent. A pull request (#7664) is already open for this, so check it before starting.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Bug Description
In LiveKit, a tool that returns None needs no reply. On Vertex AI, the model replies to it, even when the tool is NON_BLOCKING.
What I observed
I ran 10 trials for each cell on 2026-10-08, with Vertex AI in us-central1.
| Model on Vertex AI | BLOCKING |
NON_BLOCKING |
|---|---|---|
gemini-3.8-live |
replied 10/10 | replied 10/10 |
gemini-live-2.5-flash-native-audio |
replied 10/10 | replied 10/10 |
What the plugin sends
The plugin keeps the model silent with scheduling: SILENT, but only on the Gemini API (utils.py, realtime_api.py):
| API | tool_behavior |
scheduling for a tool that returns None |
|---|---|---|
| Gemini API | NON_BLOCKING |
SILENT |
| Gemini API | BLOCKING, or not set |
not sent |
| Vertex AI | any | not sent |
On Vertex AI, the plugin logs "pass tool_behavior=NON_BLOCKING to keep it silent" even for NON_BLOCKING tools.
Vertex AI supports scheduling now
The plugin skips Vertex AI because of #3784 (2025-11). In that issue, gemini-live-2.5-flash-preview-native-audio-09-2025 on Vertex AI rejected scheduling with 1007 Unknown name "scheduling". #3793 fixed it with the comment "vertexai currently doesn't support the scheduling parameter". #6785 then added scheduling: SILENT only on the Gemini API.
The model from #3784 is no longer available on Vertex AI. The Vertex AI documentation now lists scheduling (Asynchronous function calling). When the NON_BLOCKING tool response included scheduling: SILENT, both models above accepted it and stayed silent in 10 of 10 trials, and no session ended with an error.
Expected Behavior
On Vertex AI, the plugin sends scheduling: SILENT for a NON_BLOCKING tool that returns None, as on the Gemini API, and the model stays silent.
Reproduction Steps
1. Create `google.realtime.RealtimeModel(vertexai=True, model="gemini-3.8-live", tool_behavior=types.Behavior.NON_BLOCKING)`.
2. Give the agent a function tool that returns `None`.
3. Send a user message that makes the model call the tool.
4. The tool returns `None`. The plugin logs "a tool result wants no reply, but Gemini will answer it anyway; pass tool_behavior=NON_BLOCKING to keep it silent", and the model replies.
I used this script for the repeated trials in the description: `repro_vertex_silent.py` in https://gist.github.com/pokutuna/ff5a12222f44632d9fd8f5d7c722364f
Run it with: `uv run repro_vertex_silent.py`
Each API needs its own credentials. The script skips an API without them:
Gemini API: `GOOGLE_API_KEY`
Vertex AI: `GOOGLE_CLOUD_PROJECT` and Application Default Credentials
Operating System
macOS 26
Models Used
Google RealtimeModel on Vertex AI: gemini-3.8-live, gemini-live-2.5-flash-native-audio
Package Versions
livekit-agents==1.8.5
livekit-plugins-google==1.8.5
google-genai==2.28.0
Session/Room/Call IDs
(None. I ran the script locally, without LiveKit Cloud. Each session has one user turn.)
Proposed Solution
Send `scheduling` on Vertex AI too, in the same way as on the Gemini API.
I can open a pull request for this.
Additional Context
What the proposed change affects
The proposed change only removes the Vertex AI condition from the plugin. Nothing changes on the Gemini API.
| Case on Vertex AI | Now | With the change |
|---|---|---|
NON_BLOCKING tool returns None |
no scheduling, the model replies |
scheduling: SILENT, the model stays silent |
NON_BLOCKING tool returns a value |
no scheduling |
no change |
BLOCKING, or tool_behavior not set |
no scheduling |
no change |
the user sets tool_response_scheduling |
dropped, with a warning | sent |
gemini-3.8-live uses NON_BLOCKING by default, so with the default settings its tools that return None become silent. On Vertex AI, I tested only SILENT, not the other tool_response_scheduling values.
Notes
- In each trial, the user gives one answer as text, and the model calls a tool. The tool returns
Noneafter 5 seconds, and the script watches for speech from the model for 15 seconds. The delay keeps out speech that some models make while aNON_BLOCKINGtool runs. - Not tested: Vertex AI regions other than us-central1, and audio input.
- A separate problem: the plugin also sends
scheduling: SILENTtogemini-3.8-live-extended-thinking(Gemini API), because 3.8 models useNON_BLOCKINGby default. This model does not supportscheduling(model page), so the server closed the session with 1007 "Function response scheduling is not supported for this model." in 10 of 10 trials. The same script shows this whenGOOGLE_API_KEYis set. - Related: #7302
Screenshots and Recordings
(None)
- Lingua principale
- Python
- Stelle
- 14.6k
- Fork
- 3.9k
- Merge medio
- 2g 23h
- PR unite (30g)
- 177
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di livekit/agents
-
Assistant markup is stripped from chat history when expressive mode is offForse già presa @ShivamSharma43 l’ha presa 6 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
docs: openai.LLM vs openai.responses.LLM for HTTP OpenAI-compat hostsForse di nuovo libera @AbarnaaSree l’ha presa 46 giorni fa e non c’è nessuna pull request aperta. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
livekit/agents#7022 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Tool argument errors put the argument values in the log message body, outside `lk.pii.*`Forse già presa @Li-john1021 l’ha presa oggi. Aperta
Difficoltà 3/5 Mezza giornata Idoneità per principianti 25/100
livekit/agents#7801 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Google Realtime (Vertex AI): update_instructions() appends a model turn instead of replacing the system instructionForse già presa @Li-john1021 l’ha presa oggi. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 25/100
livekit/agents#7785 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
elevenlabs: text-to-dialogue (v3/v4) alignment timestamps are chunk-relative, breaking synced transcriptsForse già presa @satheeshk50 l’ha presa 1 giorno fa. Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 58/100
livekit/agents#7773 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di livekit/agents
Issue simili
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
Deltares/imod-python#1940 ·
I maintainer di solito rispondono entro 1 giorno
-
effort: low prio: low ready
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
digitalfabrik/integreat-cms#4621 ·
I maintainer di solito rispondono entro 5 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
ioos/compliance-checker#1375 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno