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
add test_chat_completion_with_no_tags
Ishaan Jafff592aeaa3842
diff --git a/litellm/proxy/example_config_yaml/otel_test_config.yaml b/litellm/proxy/example_config_yaml/otel_test_config.yamlindex 7d8f6d4fe95..54d9286c9f1 100644--- a/litellm/proxy/example_config_yaml/otel_test_config.yaml+++ b/litellm/proxy/example_config_yaml/otel_test_config.yaml@@ -4,6 +4,17 @@ model_list:model: openai/fakeapi_key: fake-keyapi_base: https://exampleopenaiendpoint-production.up.railway.app/+ tags: ["teamA"]+ model_info:+ id: "teama"+ - model_name: fake-openai-endpoint+ litellm_params:+ model: openai/fake+ api_key: fake-key+ api_base: https://exampleopenaiendpoint-production.up.railway.app/+ tags: ["teamB"]+ model_info:+ id: "teamb"- model_name: rerank-english-v3.0litellm_params:model: cohere/rerank-english-v3.0diff --git a/litellm/proxy/proxy_config.yaml b/litellm/proxy/proxy_config.yamlindex 5f9f99d57df..1afac20cdae 100644--- a/litellm/proxy/proxy_config.yaml+++ b/litellm/proxy/proxy_config.yaml@@ -1,15 +1,21 @@model_list:- - model_name: gpt-4+ - model_name: fake-openai-endpointlitellm_params:model: openai/fakeapi_key: fake-keyapi_base: https://exampleopenaiendpoint-production.up.railway.app/- tags: ["teamA"] # 👈 Key Change- - model_name: gpt-4+ tags: ["teamA"]+ model_info:+ id: "teama"+ - model_name: fake-openai-endpointlitellm_params:- model: openai/gpt-4o- api_key: os.environ/OPENAI_API_KEY- tags: ["teamB"] # 👈 Key Change+ model: openai/fake+ api_key: fake-key+ api_base: https://exampleopenaiendpoint-production.up.railway.app/+ tags: ["teamB"]+ model_info:+ id: "teamb"+router_settings:enable_tag_filtering: True # 👈 Key Changediff --git a/tests/otel_tests/test_team_tag_routing.py b/tests/otel_tests/test_team_tag_routing.pyindex 56bf361a815..390e7dce655 100644--- a/tests/otel_tests/test_team_tag_routing.py+++ b/tests/otel_tests/test_team_tag_routing.py@@ -119,3 +119,14 @@ async def test_team_tag_routing():print(response_b)print(headers)assert headers["x-litellm-model-id"] == "teamb", "Model ID should be teamB"+++async def test_chat_completion_with_no_tags():+ async with aiohttp.ClientSession() as session:+ key = LITELLM_MASTER_KEY+ response, headers = await chat_completion(session, key)+ headers = dict(headers)+ print(response)+ print(headers)+ assert response is not None