From de0124a7e06d54127cd72da1ee30c68a87c9aa30 Mon Sep 17 00:00:00 2001 From: Monesh Ram <31161039+WhoisMonesh@users.noreply.github.com> Date: Sat, 21 Feb 2026 17:14:58 +0530 Subject: [PATCH] fix(vertex_ai): conditionally add 'audio' only for TTS models in get_supported_openai_params --- .../vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/litellm/llms/vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py b/litellm/llms/vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py index 5aeb5be4c78..0cf9071107f 100644 --- a/litellm/llms/vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py +++ b/litellm/llms/vertex_ai/gemini/vertex_and_google_ai_studio_gemini.py @@ -271,7 +271,6 @@ class VertexGeminiConfig(VertexAIBaseConfig, BaseConfig): "modalities", "parallel_tool_calls", "web_search_options", - "audio", ] # Add penalty parameters only for non-preview models @@ -281,6 +280,8 @@ class VertexGeminiConfig(VertexAIBaseConfig, BaseConfig): if supports_reasoning(model): supported_params.append("reasoning_effort") supported_params.append("thinking") + if "tts" in model: + supported_params.append("audio") return supported_params def map_tool_choice_values(