Revert "[Ui] add together AI, Mistral, PerplexityAI, OpenRouter models on Admin UI "

This commit is contained in:
Ishaan Jaff 2024-07-20 19:04:22 -07:00 committed by GitHub
parent 28bb2919b6
commit 9a545c1ff8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 26 deletions

View file

@ -79,10 +79,7 @@ def set_client(litellm_router_instance: LitellmRouter, model: dict):
default_api_key = None default_api_key = None
if custom_llm_provider in litellm.openai_compatible_providers: if custom_llm_provider in litellm.openai_compatible_providers:
_, custom_llm_provider, api_key, api_base = litellm.get_llm_provider( _, custom_llm_provider, api_key, api_base = litellm.get_llm_provider(
model=model_name, model=model_name
custom_llm_provider=custom_llm_provider,
api_key=litellm_params.get("api_key"),
api_base=litellm_params.get("api_base"),
) )
default_api_base = api_base default_api_base = api_base
default_api_key = api_key default_api_key = api_key

View file

@ -137,26 +137,18 @@ interface ProviderSettings {
} }
enum Providers { enum Providers {
Anthropic = "Anthropic", OpenAI = "OpenAI",
Anyscale = "Anyscale",
Azure = "Azure", Azure = "Azure",
Azure_AI_Studio = "Azure AI Studio", Azure_AI_Studio = "Azure AI Studio",
Bedrock = "Amazon Bedrock", Anthropic = "Anthropic",
Codestral = "Codestral API (MistralAI)",
Databricks = "Databricks",
Google_AI_Studio = "Google AI Studio", Google_AI_Studio = "Google AI Studio",
Groq = "Groq", Bedrock = "Amazon Bedrock",
MistralAI = "MistralAI", OpenAI_Compatible = "OpenAI-Compatible Endpoints (Groq, Together AI, Mistral AI, etc.)",
Ollama = "Ollama",
OpenAI = "OpenAI",
OpenAI_Compatible = "OpenAI-Compatible Endpoints (vLLM etc.)",
OpenRouter = "OpenRouter",
PerplexityAI = "PerplexityAI",
TogetherAI = "TogetherAI",
Vertex_AI = "Vertex AI (Anthropic, Gemini, etc.)", Vertex_AI = "Vertex AI (Anthropic, Gemini, etc.)",
Databricks = "Databricks",
Ollama = "Ollama",
} }
const provider_map: Record<string, string> = { const provider_map: Record<string, string> = {
OpenAI: "openai", OpenAI: "openai",
Azure: "azure", Azure: "azure",
@ -166,13 +158,6 @@ const provider_map: Record<string, string> = {
Bedrock: "bedrock", Bedrock: "bedrock",
OpenAI_Compatible: "openai", OpenAI_Compatible: "openai",
Vertex_AI: "vertex_ai", Vertex_AI: "vertex_ai",
TogetherAI: "together_ai",
MistralAI: "mistral",
Codestral: "codestral",
PerplexityAI:"perplexity",
OpenRouter: "openrouter",
Anyscale: "anyscale",
Groq: "groq",
Databricks: "databricks", Databricks: "databricks",
Ollama: "ollama", Ollama: "ollama",
@ -1739,7 +1724,7 @@ const ModelDashboard: React.FC<ModelDashboardProps> = ({
tooltip="Actual model name used for making litellm.completion() call." tooltip="Actual model name used for making litellm.completion() call."
className="mb-0" 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) ? (
<TextInput placeholder={getPlaceholder(selectedProvider.toString())} /> <TextInput placeholder={getPlaceholder(selectedProvider.toString())} />
) : providerModels.length > 0 ? ( ) : providerModels.length > 0 ? (
<MultiSelect value={providerModels}> <MultiSelect value={providerModels}>