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
refactor(router): move model info discovery provider set into openai_like module
Devin AI2b8e17d581fc
diff --git a/litellm/llms/openai_like/model_info.py b/litellm/llms/openai_like/model_info.pyindex 22091622baa..cfe01e513fc 100644--- a/litellm/llms/openai_like/model_info.py+++ b/litellm/llms/openai_like/model_info.py@@ -14,6 +14,7 @@ from litellm.utils import _add_path_to_api_base # pyright: ignore[reportPrivateMODEL_INFO_REFRESH_SECONDS: Final = 300MODEL_INFO_REFRESH_CONCURRENCY: Final = 8+MODEL_INFO_DISCOVERY_PROVIDERS: Final = frozenset({"hosted_vllm", "openai", "text-completion-openai", "openai_like"})_EMPTY_LIMITS: Final[Mapping[str, int]] = MappingProxyType({})diff --git a/litellm/router.py b/litellm/router.pyindex 8a5ceba44db..fc1b5d5ba2b 100644--- a/litellm/router.py+++ b/litellm/router.py@@ -112,6 +112,7 @@ from litellm.llms.base_llm.vector_store.transformation import (from litellm.llms.custom_httpx.http_handler import AsyncHTTPHandler, get_async_httpx_clientfrom litellm.llms.openai_like.json_loader import JSONProviderRegistryfrom litellm.llms.openai_like.model_info import (+ MODEL_INFO_DISCOVERY_PROVIDERS,MODEL_INFO_REFRESH_CONCURRENCY,MODEL_INFO_REFRESH_SECONDS,get_openai_compatible_model_info,@@ -10357,7 +10358,7 @@ class Router:))model, provider, dynamic_api_key, api_base = litellm.get_llm_provider(model=params.model, litellm_params=params)- if provider not in ("hosted_vllm", "openai", "text-completion-openai", "openai_like"):+ if provider not in MODEL_INFO_DISCOVERY_PROVIDERS:returnif api_base is None or "*" in model or params.get("use_clientside_credentials"):return