Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -29,21 +29,29 @@ final_answer = FinalAnswer()
|
|
| 29 |
with open(os.path.join(CURRENT_DIR, "prompts.yaml"), 'r') as stream:
|
| 30 |
prompt_templates = yaml.safe_load(stream)
|
| 31 |
|
| 32 |
-
agent = CodeAgent(
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
executor_type='local',
|
| 44 |
executor_kwargs={},
|
| 45 |
max_print_outputs_length=None,
|
| 46 |
-
prompt_templates=prompt_templates
|
| 47 |
)
|
|
|
|
| 48 |
if __name__ == "__main__":
|
| 49 |
-
GradioUI(
|
|
|
|
| 29 |
with open(os.path.join(CURRENT_DIR, "prompts.yaml"), 'r') as stream:
|
| 30 |
prompt_templates = yaml.safe_load(stream)
|
| 31 |
|
| 32 |
+
# agent = CodeAgent(
|
| 33 |
+
# model=model,
|
| 34 |
+
# tools=[web_search, visit_webpage, suggest_menu, catering_service_tool, superhero_party_theme_generator],
|
| 35 |
+
# managed_agents=[],
|
| 36 |
+
# class='CodeAgent',
|
| 37 |
+
# max_steps=10,
|
| 38 |
+
# verbosity_level=2,
|
| 39 |
+
# grammar=None,
|
| 40 |
+
# planning_interval=None,
|
| 41 |
+
# name=None,
|
| 42 |
+
# description=None,
|
| 43 |
+
# executor_type='local',
|
| 44 |
+
# executor_kwargs={},
|
| 45 |
+
# max_print_outputs_length=None,
|
| 46 |
+
# prompt_templates=prompt_templates
|
| 47 |
+
# )
|
| 48 |
+
codeAgent_Party = CodeAgent(model=InferenceClientModel(), max_steps=10, verbosity_level=2,
|
| 49 |
+
tools = [final_answer, web_search, visit_webpage, suggest_menu, catering_service_tool, superhero_party_theme_generator],
|
| 50 |
executor_type='local',
|
| 51 |
executor_kwargs={},
|
| 52 |
max_print_outputs_length=None,
|
| 53 |
+
prompt_templates=prompt_templates,
|
| 54 |
)
|
| 55 |
+
|
| 56 |
if __name__ == "__main__":
|
| 57 |
+
GradioUI(codeAgent_Party).launch()
|