steep-balloon-41261
12/11/2025, 8:05 PMtall-airline-16756
12/11/2025, 8:05 PMtall-airline-16756
12/11/2025, 8:06 PMmodels/gemini-2.5-flash-preview-native-audio-dialog. I’ll help you troubleshoot.
What to check and next steps:
• Use a supported model ID (no models/ prefix). For example: gemini-2.5-flash-native-audio-preview-09-2025.
• Ensure your plugin call passes only the model ID (not API version or path).
• Confirm your Google/Vertex credentials or GOOGLE_API_KEY are set correctly.
• Verify your Google project has access to preview/experimental native-audio models (those often require approval).
• Make sure you’re using a LiveKit Google plugin version that supports the target Gemini model (livekit-agents[google] compatibility).
Can you share: 1) the exact model string you’re sending in code (redact keys), and 2) which plugin version and authentication method you’re using?
With that I can suggest the precise code change or config fix.
Sources: Gemini Live API plugin | LiveKit docsagreeable-forest-33528
12/11/2025, 8:08 PMtall-airline-16756
12/11/2025, 8:09 PMlivekit-plugins-google~=1.3.3 and an API key. That’s fine. The error is coming from an invalid/unsupported model identifier.
Please confirm two things so I can give the exact fix:
1. The exact model string you are sending in code (redact the API key). Is it prefixed with models/ or an API version?
2. Are you initializing the Realtime model with google.realtime.RealtimeModel (code snippet if possible)?
If you’re using a wrong model string, switch to: gemini-2.5-flash-native-audio-preview-09-2025
If you share the model string and the short snippet where you set model=..., I’ll provide the exact code change.
Sources: Gemini Live API plugin | LiveKit docstall-airline-16756
12/11/2025, 8:11 PMcreate_instance code. The key issue is the default model string and its format.
What to change
• Replace the default model:
◦ Current default: "gemini-live-2.5-flash-preview"
◦ Use this supported Realtime model instead: "gemini-2.5-flash-native-audio-preview-09-2025"
• Ensure you pass only the model ID (no models/ prefix, no API version).
Minimal code change
if "model" not in filtered_config:
filtered_config["model"] = "gemini-2.5-flash-native-audio-preview-09-2025"
Other checks (your code mostly covers these)
• Keep voice only when Modality.AUDIO is present (your removal/default logic is correct).
• Ensure GOOGLE_API_KEY or api_key is set (you said you use API key).
• Confirm the Google project has access to the native-audio preview model and billing is enabled.
If you update the default model and still get 1008, paste the exact model value that ends up in filtered_config (I’ll point out any remaining format/access issues). Would you like a suggested unit-test/snippet to validate the final config before creating the model?tall-airline-16756
12/11/2025, 8:20 PMgemini-2.5-flash-native-audio-preview-09-2025 supports the TEXT modality.
You can set it by passing modalities=[Modality.TEXT] (or ["TEXT"]) when creating the google.realtime.RealtimeModel. If you use TEXT-only, keep voice out of the config (your code already removes it for TEXT-only), and use a separate TTS provider if you need synthesized audio output.
Sources: Gemini Live API plugin | LiveKit docstall-airline-16756
12/11/2025, 9:08 PMvoice parameter while the request was TEXT-only. The Gemini Realtime model rejects voice settings on non-audio frames: "Cannot extract voices from a non-audio request."
What to do
• Confirm the final config passed into google.realtime.RealtimeModel does not include "voice" when modalities are TEXT-only.
• Add a quick runtime check/log right before creating the model to show modalities and whether voice is present.
Suggested quick check (add somewhere before return google.realtime.RealtimeModel(**filtered_config)):
logger.info(f"Final Google Realtime config: modalities={filtered_config.get('modalities')}, voice_present={'voice' in filtered_config}")
If you see modalities contains only Modality.TEXT (or "TEXT") but voice_present is True, your earlier removal logic isn't being applied — ensure the modality conversion and TTS-flag logic run before you set/remove voice.
If the config looks correct (no voice with TEXT-only) but you still get 1007, paste the exact logged output for filtered_config (with api_key removed) and I’ll point out the remaining mismatch.