-
Notifications
You must be signed in to change notification settings - Fork 110
Expand file tree
/
Copy pathplan_act.yaml
More file actions
93 lines (89 loc) · 4.53 KB
/
plan_act.yaml
File metadata and controls
93 lines (89 loc) · 4.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
_target_: tapeagents.agent.Agent
name : gaia_agent
max_iterations: 2
llms:
default: ${llm}
tools_description: |
- WebSearch - Performs a search in the web, wikipedia or youtube
- VideoReader - Opens video from a youtube URL. Can access the video content, thumbnail, subtitles and audio.
- Browser - Browser tool that can load web pages and interact with their content.
- CodeExecutor - Executes the python code snippet
known_actions:
- _target_: hydra.utils.get_class
path: tapeagents.tools.web_search.SearchAction
- _target_: hydra.utils.get_class
path: tapeagents.steps.WatchVideoAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.code_executor.PythonCodeAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.browser.ClickBIDAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.browser.GoBackAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.browser.GoForwardAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.browser.OpenUrlAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.simple_browser.PageDownAction
- _target_: hydra.utils.get_class
path: tapeagents.tools.simple_browser.PageUpAction
templates:
system_prompt: |
You are an expert AI Agent trained to assist users with complex information processing tasks.
Your role is to understand user queries and respond in a helpful and accurate manner.
Keep your replies concise and direct. Prioritize clarity and avoid over-elaboration.
Do not express emotions or opinions about user questions.
allowed_tools: |
You have access to the following tools:
{tools_description}
thought_format: |
Important! Respond with the plain text, do not include any JSON or code.
Do not output anything besides what I asked in this message.
allowed_steps: |
You have access to the following tools:
{tools_description}
You are allowed to produce ONLY steps with the following JSON schemas:
{allowed_steps}
Do not reproduce the schema when producing steps; use it as a reference.
format: >
Output only a single JSON dict.
Do not repeat the last thought again.
If the last action does not change the observation, do not repeat it!
DO NOT OUTPUT ANYTHING BESIDES THE JSON! DO NOT PLACE ANY COMMENTS INSIDE THE JSON.
It will break the system that processes the output.
nodes:
- _target_: tapeagents.nodes.StandardNode
name: plan
system_prompt: ${agent.templates.system_prompt}
guidance: |
Write a concise multi-step plan explaining which steps should be performed to find the answer for the given task.
Remember that you can use web search, browser, python code execution and access the youtube videos to reach your goals.
Be specific about how each step should be performed. Only describe the intended actions here, do not perform them yet.
Consider that next steps may depend on results of previous steps, so include conditional branching using "if" statements where needed.
${agent.templates.thought_format}
steps_prompt: ${agent.templates.allowed_tools}
- _target_: tapeagents.nodes.StandardNode
name: facts_survey
system_prompt: ${agent.templates.system_prompt}
guidance: |
Before we begin executing the plan, please answer the following pre-survey.
Here is the pre-survey:
1. Please list any specific facts or figures that are GIVEN in the request itself. It is possible that there are none.
2. Please list any facts that may need to be looked up, and WHERE SPECIFICALLY they might be found. In some cases, authoritative sources are mentioned in the request itself.
3. Please list any facts that may need to be derived (e.g., via logical deduction, simulation, or computation)
4. Please list any facts that are recalled from memory, hunches, well-reasoned guesses, etc.
When answering this survey, keep in mind that "facts" will typically be specific names, dates, statistics, etc.
${agent.templates.thought_format}
steps_prompt: ${agent.templates.allowed_tools}
- _target_: tapeagents.nodes.StandardNode
name: act
system_prompt: ${agent.templates.system_prompt}
guidance: Then produce single function call for the next step. If the answer is ready, call GaiaAnswer.
steps_prompt: ${agent.templates.allowed_steps}
steps:
- tapeagents.steps.ReasoningThought
- agentlab.benchmarks.gaia.ExtractedFacts
- agentlab.benchmarks.gaia.GaiaAnswer
use_known_actions: true
use_function_calls: true
next_node: act