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
Merge remote-tracking branch 'upstream/litellm_internal_staging' into litellm_staging_03_23_2026
Chesarsebe16072f238
diff --cc model_prices_and_context_window.jsonindex 1a0c872d177,2d13c5cd00f..c8ed58ff3ea--- a/model_prices_and_context_window.json+++ b/model_prices_and_context_window.json@@@ -14615,6 -15342,21 +15342,21 @@@"supports_multimodal": true,"uses_embed_content": true},+ "vertex_ai/gemini-embedding-2": {+ "input_cost_per_audio_per_second": 0.00016,+ "input_cost_per_image": 0.00012,+ "input_cost_per_token": 2e-07,+ "input_cost_per_video_per_second": 0.00079,+ "litellm_provider": "vertex_ai",+ "max_input_tokens": 8192,+ "max_tokens": 8192,+ "mode": "embedding",+ "output_cost_per_token": 0,+ "output_vector_size": 3072,- "source": "https://cloud.google.com/vertex-ai/generative-ai/pricing",++ "source": "https://ai.google.dev/gemini-api/docs/embeddings#multimodal",+ "supports_multimodal": true,+ "uses_embed_content": true+ },"gemini-flash-experimental": {"input_cost_per_character": 0,"input_cost_per_token": 0,@@@ -37400,85 -39370,50 +39388,131 @@@}]},+ "zai.glm-5": {+ "input_cost_per_token": 1e-06,+ "output_cost_per_token": 3.2e-06,+ "litellm_provider": "bedrock_converse",+ "max_input_tokens": 200000,+ "max_output_tokens": 128000,+ "max_tokens": 128000,+ "mode": "chat",+ "supports_function_calling": true,+ "supports_reasoning": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "source": "https://aws.amazon.com/bedrock/pricing/"+ },+ "bedrock/us-east-1/zai.glm-5": {+ "input_cost_per_token": 1e-06,+ "output_cost_per_token": 3.2e-06,+ "litellm_provider": "bedrock",+ "max_input_tokens": 200000,+ "max_output_tokens": 128000,+ "max_tokens": 128000,+ "mode": "chat",+ "supports_function_calling": true,+ "supports_reasoning": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "source": "https://aws.amazon.com/bedrock/pricing/"+ },+ "bedrock/us-west-2/zai.glm-5": {+ "input_cost_per_token": 1e-06,+ "output_cost_per_token": 3.2e-06,+ "litellm_provider": "bedrock",+ "max_input_tokens": 200000,+ "max_output_tokens": 128000,+ "max_tokens": 128000,+ "mode": "chat",+ "supports_function_calling": true,+ "supports_reasoning": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "source": "https://aws.amazon.com/bedrock/pricing/"+ },+ "minimax.minimax-m2.5": {+ "input_cost_per_token": 3e-07,+ "output_cost_per_token": 1.2e-06,+ "litellm_provider": "bedrock_converse",+ "max_input_tokens": 1000000,+ "max_output_tokens": 8192,+ "max_tokens": 8192,+ "mode": "chat",+ "supports_function_calling": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "source": "https://aws.amazon.com/bedrock/pricing/"+ },+ "bedrock/us-east-1/minimax.minimax-m2.5": {+ "input_cost_per_token": 3e-07,+ "output_cost_per_token": 1.2e-06,+ "litellm_provider": "bedrock",+ "max_input_tokens": 1000000,+ "max_output_tokens": 8192,+ "max_tokens": 8192,+ "mode": "chat",+ "supports_function_calling": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "source": "https://aws.amazon.com/bedrock/pricing/"+ },+ "bedrock/us-west-2/minimax.minimax-m2.5": {+ "input_cost_per_token": 3e-07,+ "output_cost_per_token": 1.2e-06,+ "litellm_provider": "bedrock",+ "max_input_tokens": 1000000,+ "max_output_tokens": 8192,+ "max_tokens": 8192,+ "mode": "chat",+ "supports_function_calling": true,+ "supports_system_messages": true,+ "supports_tool_choice": true,+ "source": "https://aws.amazon.com/bedrock/pricing/"++ },+ "bedrock/us-gov-east-1/anthropic.claude-haiku-4-5-20251001-v1:0": {+ "cache_creation_input_token_cost": 1.5e-06,+ "cache_read_input_token_cost": 1.2e-07,+ "input_cost_per_token": 1.2e-06,+ "litellm_provider": "bedrock",+ "max_input_tokens": 200000,+ "max_output_tokens": 64000,+ "max_tokens": 64000,+ "mode": "chat",+ "output_cost_per_token": 6e-06,+ "source": "https://aws.amazon.com/about-aws/whats-new/2025/10/claude-4-5-haiku-anthropic-amazon-bedrock",+ "supports_assistant_prefill": true,+ "supports_computer_use": true,+ "supports_function_calling": true,+ "supports_prompt_caching": true,+ "supports_reasoning": true,+ "supports_response_schema": true,+ "supports_tool_choice": true,+ "supports_vision": true,+ "tool_use_system_prompt_tokens": 346,+ "supports_native_structured_output": true,+ "supports_pdf_input": true+ },+ "bedrock/us-gov-west-1/anthropic.claude-haiku-4-5-20251001-v1:0": {+ "cache_creation_input_token_cost": 1.5e-06,+ "cache_read_input_token_cost": 1.2e-07,+ "input_cost_per_token": 1.2e-06,+ "litellm_provider": "bedrock",+ "max_input_tokens": 200000,+ "max_output_tokens": 64000,+ "max_tokens": 64000,+ "mode": "chat",+ "output_cost_per_token": 6e-06,+ "source": "https://aws.amazon.com/about-aws/whats-new/2025/10/claude-4-5-haiku-anthropic-amazon-bedrock",+ "supports_assistant_prefill": true,+ "supports_computer_use": true,+ "supports_function_calling": true,+ "supports_prompt_caching": true,+ "supports_reasoning": true,+ "supports_response_schema": true,+ "supports_tool_choice": true,+ "supports_vision": true,+ "tool_use_system_prompt_tokens": 346,+ "supports_native_structured_output": true,+ "supports_pdf_input": true}}diff --cc tests/test_litellm/llms/vertex_ai/multimodal_embeddings/test_vertex_ai_multimodal_embedding_transformation.pyindex 5bb49a4fb78,1c2fbc70d82..6b605aed0ca--- a/tests/test_litellm/llms/vertex_ai/multimodal_embeddings/test_vertex_ai_multimodal_embedding_transformation.py+++ b/tests/test_litellm/llms/vertex_ai/multimodal_embeddings/test_vertex_ai_multimodal_embedding_transformation.py@@@ -134,36 -144,6 +144,38 @@@ class TestVertexMultimodalEmbedding),]result = self.config.process_openai_embedding_input(input_data)- assert result == expected_output, f"Expected {expected_output}, but got {result}"+ assert (+ result == expected_output+ ), f"Expected {expected_output}, but got {result}"++ def test_dimensions_parameter_forwarded_as_dimension(self):+ """Test that the dimensions parameter is forwarded as dimension+ in the request body parameters field.++ Fixes: https://github.com/BerriAI/litellm/issues/24392+ """+ optional_params = {}+ optional_params = self.config.map_openai_params(+ non_default_params={"dimensions": 128},+ optional_params=optional_params,+ model="multimodalembedding",+ drop_params=False,+ )+ request = self.config.transform_embedding_request(+ model="multimodalembedding",+ input="Hello world",+ optional_params=optional_params,+ headers={},+ )+ assert "parameters" in request, "Request should contain 'parameters' field"+ assert request["parameters"]["dimension"] == 128++ def test_no_parameters_field_when_dimensions_not_set(self):+ """Test that no parameters field is added when dimensions is not set."""+ request = self.config.transform_embedding_request(+ model="multimodalembedding",+ input="Hello world",+ optional_params={},+ headers={},+ )+ assert "parameters" not in request