Spaces:
Running
Running
change from HfApiModel to InferenceClientModel
Browse files
app.py
CHANGED
@@ -1,13 +1,15 @@
|
|
1 |
import gradio as gr
|
2 |
import random
|
3 |
-
from smolagents import GradioUI, CodeAgent, HfApiModel
|
|
|
4 |
|
5 |
# Import our custom tools from their modules
|
6 |
from tools import DuckDuckGoSearchTool, WeatherInfoTool, HubStatsTool
|
7 |
from retriever import load_guest_dataset
|
8 |
|
9 |
# Initialize the Hugging Face model
|
10 |
-
model = HfApiModel()
|
|
|
11 |
|
12 |
# Initialize the web search tool
|
13 |
search_tool = DuckDuckGoSearchTool()
|
|
|
1 |
import gradio as gr
|
2 |
import random
|
3 |
+
#from smolagents import GradioUI, CodeAgent, HfApiModel
|
4 |
+
from smolagents import GradioUI, CodeAgent, InferenceClientModel
|
5 |
|
6 |
# Import our custom tools from their modules
|
7 |
from tools import DuckDuckGoSearchTool, WeatherInfoTool, HubStatsTool
|
8 |
from retriever import load_guest_dataset
|
9 |
|
10 |
# Initialize the Hugging Face model
|
11 |
+
#model = HfApiModel()
|
12 |
+
model = InferenceClientModel()
|
13 |
|
14 |
# Initialize the web search tool
|
15 |
search_tool = DuckDuckGoSearchTool()
|