mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-13 23:11:40 +00:00
fix(api_route): expose provider info helper
This commit is contained in:
parent
6f46550c18
commit
ef4e641a0a
2 changed files with 2 additions and 2 deletions
|
|
@ -853,7 +853,7 @@ def _get_openai_compatible_provider_info(
|
|||
(
|
||||
api_base,
|
||||
dynamic_api_key,
|
||||
) = litellm.APIRouteChatConfig()._get_openai_compatible_provider_info(api_base, api_key)
|
||||
) = litellm.APIRouteChatConfig().get_openai_compatible_provider_info(api_base, api_key)
|
||||
elif custom_llm_provider == "wandb":
|
||||
api_base = api_base or get_secret("WANDB_API_BASE") or "https://api.inference.wandb.ai/v1"
|
||||
dynamic_api_key = api_key or get_secret_str("WANDB_API_KEY")
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ class APIRouteChatConfig(OpenAIGPTConfig):
|
|||
def custom_llm_provider(self) -> str | None:
|
||||
return "api_route"
|
||||
|
||||
def _get_openai_compatible_provider_info(
|
||||
def get_openai_compatible_provider_info(
|
||||
self, api_base: str | None, api_key: str | None
|
||||
) -> tuple[str | None, str | None]:
|
||||
resolved_api_base: Final = api_base or get_secret_str("API_ROUTE_BASE_URL") or "https://global.api-route.com/v1"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue