Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,16 +1,15 @@
|
|
| 1 |
-
from smolagents import CodeAgent, InferenceClientModel
|
| 2 |
-
from tools.party_menu import suggest_menu
|
| 3 |
-
from tools.party_song import suggest_party_music
|
| 4 |
-
from tools.party_time import estimate_preparation_time
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
| 16 |
-
GradioUI(agent).launch()
|
|
|
|
| 1 |
+
from smolagents import CodeAgent, InferenceClientModel
|
| 2 |
+
from tools.party_menu import suggest_menu
|
| 3 |
+
from tools.party_song import suggest_party_music
|
| 4 |
+
from tools.party_time import estimate_preparation_time
|
| 5 |
+
|
| 6 |
+
model = InferenceClientModel(model_id="Qwen/Qwen2.5-Coder-7B-Instruct")
|
| 7 |
+
|
| 8 |
+
agent = CodeAgent(
|
| 9 |
+
model=model,
|
| 10 |
+
tools=[FinalAnswerTool(), suggest_menu, suggest_party_music, estimate_preparation_time],
|
| 11 |
+
)
|
| 12 |
+
|
| 13 |
+
if __name__ == "__main__":
|
| 14 |
+
from Gradio_UI import GradioUI
|
| 15 |
+
GradioUI(agent).launch()
|
|
|