From 9a545c1ff8bb32c61e5c0fb55e655a655687cebe Mon Sep 17 00:00:00 2001 From: Ishaan Jaff Date: Sat, 20 Jul 2024 19:04:22 -0700 Subject: [PATCH] Revert "[Ui] add together AI, Mistral, PerplexityAI, OpenRouter models on Admin UI " --- .../client_initalization_utils.py | 5 +--- .../src/components/model_dashboard.tsx | 29 +++++-------------- 2 files changed, 8 insertions(+), 26 deletions(-) diff --git a/litellm/router_utils/client_initalization_utils.py b/litellm/router_utils/client_initalization_utils.py index 513457fb8..073a87901 100644 --- a/litellm/router_utils/client_initalization_utils.py +++ b/litellm/router_utils/client_initalization_utils.py @@ -79,10 +79,7 @@ def set_client(litellm_router_instance: LitellmRouter, model: dict): default_api_key = None if custom_llm_provider in litellm.openai_compatible_providers: _, custom_llm_provider, api_key, api_base = litellm.get_llm_provider( - model=model_name, - custom_llm_provider=custom_llm_provider, - api_key=litellm_params.get("api_key"), - api_base=litellm_params.get("api_base"), + model=model_name ) default_api_base = api_base default_api_key = api_key diff --git a/ui/litellm-dashboard/src/components/model_dashboard.tsx b/ui/litellm-dashboard/src/components/model_dashboard.tsx index 904f8a9cb..27608f0ae 100644 --- a/ui/litellm-dashboard/src/components/model_dashboard.tsx +++ b/ui/litellm-dashboard/src/components/model_dashboard.tsx @@ -137,26 +137,18 @@ interface ProviderSettings { } enum Providers { - Anthropic = "Anthropic", - Anyscale = "Anyscale", + OpenAI = "OpenAI", Azure = "Azure", Azure_AI_Studio = "Azure AI Studio", - Bedrock = "Amazon Bedrock", - Codestral = "Codestral API (MistralAI)", - Databricks = "Databricks", + Anthropic = "Anthropic", Google_AI_Studio = "Google AI Studio", - Groq = "Groq", - MistralAI = "MistralAI", - Ollama = "Ollama", - OpenAI = "OpenAI", - OpenAI_Compatible = "OpenAI-Compatible Endpoints (vLLM etc.)", - OpenRouter = "OpenRouter", - PerplexityAI = "PerplexityAI", - TogetherAI = "TogetherAI", + Bedrock = "Amazon Bedrock", + OpenAI_Compatible = "OpenAI-Compatible Endpoints (Groq, Together AI, Mistral AI, etc.)", Vertex_AI = "Vertex AI (Anthropic, Gemini, etc.)", + Databricks = "Databricks", + Ollama = "Ollama", } - const provider_map: Record = { OpenAI: "openai", Azure: "azure", @@ -166,13 +158,6 @@ const provider_map: Record = { Bedrock: "bedrock", OpenAI_Compatible: "openai", Vertex_AI: "vertex_ai", - TogetherAI: "together_ai", - MistralAI: "mistral", - Codestral: "codestral", - PerplexityAI:"perplexity", - OpenRouter: "openrouter", - Anyscale: "anyscale", - Groq: "groq", Databricks: "databricks", Ollama: "ollama", @@ -1739,7 +1724,7 @@ const ModelDashboard: React.FC = ({ tooltip="Actual model name used for making litellm.completion() call." className="mb-0" > - { (selectedProvider === Providers.Azure) || (selectedProvider === Providers.OpenAI_Compatible) || (selectedProvider === Providers.Ollama) || (selectedProvider === Providers.TogetherAI) ? ( + { (selectedProvider === Providers.Azure) || (selectedProvider === Providers.OpenAI_Compatible) || (selectedProvider === Providers.Ollama) ? ( ) : providerModels.length > 0 ? (