The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]
Python ai-gatewayanthropicazure-openaibedrockgatewaylangchainlitellmllmllm-gatewayllmopsmcp-gatewayopenaiopenai-proxyrustrust-aivertex-ai
fix(vertex): shallow copy parameters before mutating in _build_vertex_schema_for_gemini_2
Chesars08d81f5d7c72
diff --git a/litellm/llms/vertex_ai/common_utils.py b/litellm/llms/vertex_ai/common_utils.pyindex 20fe1f2b41b..b9cbb52e57a 100644--- a/litellm/llms/vertex_ai/common_utils.py+++ b/litellm/llms/vertex_ai/common_utils.py@@ -530,6 +530,7 @@ def _build_vertex_schema_for_gemini_2(parameters: dict) -> dict:"""valid_schema_fields = set(get_type_hints(Schema).keys())+ parameters = dict(parameters) # shallow copy to avoid mutating caller's dictdefs = parameters.pop("$defs", {})unpack_defs(parameters, defs)