Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -162,8 +162,8 @@ def get_model_client(service, api_key):
|
|
162 |
return OpenAIChatCompletionClient(model="gpt-4o-2024-08-06", api_key=api_key)
|
163 |
elif service == "Anthropic-claude-3-sonnet-20240229":
|
164 |
return AnthropicChatCompletionClient(model="claude-3-sonnet-20240229", api_key=api_key)
|
165 |
-
elif service == "Google-gemini-
|
166 |
-
return OpenAIChatCompletionClient(model="gemini-
|
167 |
elif service == "Ollama-llama3.2":
|
168 |
return OllamaChatCompletionClient(model="llama3.2")
|
169 |
elif service == "Azure AI Foundry":
|
@@ -1254,11 +1254,11 @@ with gr.Blocks(
|
|
1254 |
"Azure AI Foundry",
|
1255 |
"OpenAI-gpt-4o-2024-08-06",
|
1256 |
"Anthropic-claude-3-sonnet-20240229",
|
1257 |
-
"Google-gemini-
|
1258 |
"Ollama-llama3.2",
|
1259 |
],
|
1260 |
label="Model",
|
1261 |
-
value="Google-gemini-
|
1262 |
)
|
1263 |
api_key = gr.Textbox(label="Model Provider API Key", type="password", placeholder="Not required for Ollama or Azure AI Foundry (use GITHUB_TOKEN env var)")
|
1264 |
serpapi_key = gr.Textbox(label="SerpApi Key (For Research Agent)", type="password", placeholder="Enter your SerpApi key (optional)")
|
|
|
162 |
return OpenAIChatCompletionClient(model="gpt-4o-2024-08-06", api_key=api_key)
|
163 |
elif service == "Anthropic-claude-3-sonnet-20240229":
|
164 |
return AnthropicChatCompletionClient(model="claude-3-sonnet-20240229", api_key=api_key)
|
165 |
+
elif service == "Google-gemini-2.0-flash":
|
166 |
+
return OpenAIChatCompletionClient(model="gemini-2.0-flash", api_key=api_key)
|
167 |
elif service == "Ollama-llama3.2":
|
168 |
return OllamaChatCompletionClient(model="llama3.2")
|
169 |
elif service == "Azure AI Foundry":
|
|
|
1254 |
"Azure AI Foundry",
|
1255 |
"OpenAI-gpt-4o-2024-08-06",
|
1256 |
"Anthropic-claude-3-sonnet-20240229",
|
1257 |
+
"Google-gemini-2.0-flash",
|
1258 |
"Ollama-llama3.2",
|
1259 |
],
|
1260 |
label="Model",
|
1261 |
+
value="Google-gemini-2.0-flash"
|
1262 |
)
|
1263 |
api_key = gr.Textbox(label="Model Provider API Key", type="password", placeholder="Not required for Ollama or Azure AI Foundry (use GITHUB_TOKEN env var)")
|
1264 |
serpapi_key = gr.Textbox(label="SerpApi Key (For Research Agent)", type="password", placeholder="Enter your SerpApi key (optional)")
|