Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -3,7 +3,7 @@ import gradio as gr
|
|
| 3 |
import requests
|
| 4 |
import inspect
|
| 5 |
import pandas as pd
|
| 6 |
-
from smolagents import CodeAgent, OpenAIServerModel, DuckDuckGoSearchTool, WikipediaSearchTool
|
| 7 |
from smolagents.agents import PromptTemplates
|
| 8 |
|
| 9 |
GEMINI_API_KEY = os.environ.get("GEMINI_API_KEY")
|
|
@@ -111,7 +111,7 @@ DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
|
|
| 111 |
# ----- THIS IS WERE YOU CAN BUILD WHAT YOU WANT ------
|
| 112 |
class BasicAgent:
|
| 113 |
def __init__(self):
|
| 114 |
-
self.agent =
|
| 115 |
tools = [DuckDuckGoSearchTool(), WikipediaSearchTool()],
|
| 116 |
model = model,
|
| 117 |
add_base_tools=True,
|
|
|
|
| 3 |
import requests
|
| 4 |
import inspect
|
| 5 |
import pandas as pd
|
| 6 |
+
from smolagents import CodeAgent, OpenAIServerModel, DuckDuckGoSearchTool, WikipediaSearchTool, MultiStepAgent
|
| 7 |
from smolagents.agents import PromptTemplates
|
| 8 |
|
| 9 |
GEMINI_API_KEY = os.environ.get("GEMINI_API_KEY")
|
|
|
|
| 111 |
# ----- THIS IS WERE YOU CAN BUILD WHAT YOU WANT ------
|
| 112 |
class BasicAgent:
|
| 113 |
def __init__(self):
|
| 114 |
+
self.agent = MultiStepAgent(
|
| 115 |
tools = [DuckDuckGoSearchTool(), WikipediaSearchTool()],
|
| 116 |
model = model,
|
| 117 |
add_base_tools=True,
|