Skip to content

Commit 3c56f52

Browse files
committed
perf: update gaia rollout modular prompt
1 parent 2b995cf commit 3c56f52

File tree

1 file changed

+13
-14
lines changed

1 file changed

+13
-14
lines changed

openmanus_rl/environments/prompts/tool_use.py

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
parameters: {{"param1": "value1", "param2": "value2"}}
2323
</tool_call>
2424
25-
Now it's your turn to take an action. You should first reason step-by-step about the current situation. This reasoning process MUST be enclosed within <think> </think> tags.
25+
Now it's your turn to take an action. You should first reason step-by-step about the current situation. This reasoning process MUST be enclosed within <plan> </plan> tags.
2626
Once you've finished your reasoning, you should either use a tool or provide your final answer within <answer> </answer> tags.
2727
"""
2828
TOOL_USE_TEMPLATE_LAST_STEP = """
@@ -52,30 +52,29 @@
5252
5353
You should first recall relevant past experiences and reason from our conversation history, then MUST summarize within <memory_recall> </memory_recall> tags like this:
5454
55-
<memory_analysis>
56-
[Recall relevant past experiences and reason from our conversation history]
57-
- Please summarize the most relavent memory for this step.
58-
- Please explain why this memory is helpful for the next reflection and planning.
59-
</memory_analysis>
55+
<memory>
56+
Look at the past observations and actions from our conversation history.
57+
- Please retrieve the most relavent memory for this step including the relevant observation and action in a RAG style along with the step number.
58+
- These memory should be helpful milestones to solve this task.git reset --soft HEAD~1
59+
</memory>
6060
6161
After that, you should reflect on the last action and its outcome, then MUST summarize within <reflection> </reflection> tags like this:
6262
6363
<reflection>
64-
[Reflect on the last action and its outcome]
65-
- What did my last action accomplish?
66-
- Was it successful or did it encounter issues?
67-
- How does this outcome affect my plan?
64+
Reflect on the last action and its outcome
65+
- Did I complete the task goal?
66+
- Was last action successful or did it encounter issues?
6867
- Am I making progress toward the task goal?
68+
- If the action did not go as expected and did not result in progress, provide constructive feedback to guide the next planning step.
6969
</reflection>
7070
71-
Given from the analysis from the memory analysis and reflection, if we get the final answer, we should provide it within <answer> </answer> tags.
72-
If we don't get the final answer, you should plan the next step based on memory and reflection, then MUST summarize within <plan> </think> tags like this:
71+
Given from the analysis from the memory and reflection, if we get the final answer, we should provide it within <answer> </answer> tags.
72+
If we don't get the final answer, you should plan the next step based on memory and reflection, then MUST summarize within <plan> </plan> tags like this:
7373
7474
<plan>
75-
[Plan the next step based on memory and reflection]
75+
Plan the next step based on memory and reflection
7676
- Given what I've learned, what should I do next?
7777
- Please explain why this plan is helpful for the next action?
78-
- How does this action fit into my overall strategy?
7978
- What do I expect this action to achieve?
8079
</plan>
8180

0 commit comments

Comments
 (0)