[Bug Fix] - /vertex_ai/ was not detected as llm_api_route on pass through but vertex-ai was (#8186)

* fix mapped_pass_through_routes

* fix route checks

* update test_is_llm_api_route
This commit is contained in:
Ishaan Jaff 2025-02-01 17:26:08 -08:00 committed by GitHub
parent 4e9c2d5b21
commit c0f3100934
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 16 additions and 18 deletions

View file

@ -180,23 +180,10 @@ class RouteChecks:
if RouteChecks._is_azure_openai_route(route=route):
return True
# Pass through Bedrock, VertexAI, and Cohere Routes
if "/bedrock/" in route:
return True
if "/vertex-ai/" in route:
return True
if "/gemini/" in route:
return True
if "/cohere/" in route:
return True
if "/langfuse/" in route:
return True
if "/anthropic/" in route:
return True
if "/azure/" in route:
return True
if "/openai/" in route:
return True
for _llm_passthrough_route in LiteLLMRoutes.mapped_pass_through_routes.value:
if _llm_passthrough_route in route:
return True
return False
@staticmethod