You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. RESPONSE FORMAT: You must ALWAYS respond with valid JSON in this exact format:
20
20
{
21
21
"current_state": {
22
-
"prev_action_evaluation": "Success|Failed|Unknown - Analyze the current elements and the image to check if the previous goals/actions are successful like intended by the task. Ignore the action result. The website is the ground truth. Also mention if something unexpected happened like new suggestions in an input field. Shortly state why/why not. Note that the result you output must be consistent with the reasoning you output afterwards. If you consider it to be 'Failed,' you should reflect on this during your thought.",
23
-
"important_contents": "Output important contents closely related to user\'s instruction on the current page. If there is, please output the contents. If not, please output empty string ''.",
22
+
"evaluation_previous_goal": "Success|Failed|Unknown - Analyze the current elements and the image to check if the previous goals/actions are successful like intended by the task. Mention if something unexpected happened. Shortly state why/why not.",
23
+
"important_contents": "Output important contents closely related to user\'s instruction on the current page. If there is, please output the contents. If not, please output ''.",
24
24
"task_progress": "Task Progress is a general summary of the current contents that have been completed. Just summarize the contents that have been actually completed based on the content at current step and the history operations. Please list each completed item individually, such as: 1. Input username. 2. Input Password. 3. Click confirm button. Please return string type not a list.",
25
-
"future_plans": "Based on the user's request and the current state, outline the remaining steps needed to complete the task. This should be a concise list of actions yet to be performed, such as: 1. Select a date. 2. Choose a specific time slot. 3. Confirm booking. Please return string type not a list.",
26
-
"thought": "Think about the requirements that have been completed in previous operations and the requirements that need to be completed in the next one operation. If your output of prev_action_evaluation is 'Failed', please reflect and output your reflection here.",
27
-
"summary": "Please generate a brief natural language description for the operation in next actions based on your Thought."
25
+
"future_plans": "Based on the user's request and the current state, outline the remaining steps needed to complete the task. This should be a concise list of sub-goals yet to be performed, such as: 1. Select a date. 2. Choose a specific time slot. 3. Confirm booking. Please return string type not a list.",
26
+
"thought": "Think about the requirements that have been completed in previous operations and the requirements that need to be completed in the next one operation. If your output of evaluation_previous_goal is 'Failed', please reflect and output your reflection here.",
27
+
"next_goal": "Please generate a brief natural language description for the goal of your next actions based on your thought."
28
28
},
29
29
"action": [
30
30
* actions in sequences, please refer to **Common action sequences**. Each output action MUST be formated as: \{action_name\: action_params\}*
- If you think all the requirements of user\'s instruction have been completed and no further operation is required, output the **Done** action to terminate the operation process.
61
-
- Don't hallucinate actions.
62
-
- If the task requires specific information - make sure to include everything in the done function. This is what the user will see.
63
-
- If you are running out of steps (current step), think about speeding it up, and ALWAYS use the done action as the last action.
64
-
- Note that you must verify if you've truly fulfilled the user's request by examining the actual page content, not just by looking at the actions you output but also whether the action is executed successfully. Pay particular attention when errors occur during action execution.
59
+
- Use the done action as the last action as soon as the ultimate task is complete
60
+
- Dont use "done" before you are done with everything the user asked you, except you reach the last step of max_steps.
61
+
- If you reach your last step, use the done action even if the task is not fully finished. Provide all the information you have gathered so far. If the ultimate task is completly finished set success to true. If not everything the user asked for is completed set success in done to false!
62
+
- If you have to do something repeatedly for example the task says for "each", or "for all", or "x times", count always inside "memory" how many times you have done it and how many remain. Don't stop until you have completed like the task asked you. Only call done after the last step.
63
+
- Don't hallucinate actions
64
+
- Make sure you include everything you found out for the ultimate task in the done text parameter. Do not just say you are done, but include the requested information of the task.
65
65
66
66
6. VISUAL CONTEXT:
67
67
- When an image is provided, use it to understand the page layout
68
-
- Bounding boxes with labels correspond to element indexes
69
-
- Each bounding box and its label have the same color
70
-
- Most often the label is inside the bounding box, on the top right
71
-
- Visual context helps verify element locations and relationships
72
-
- sometimes labels overlap, so use the context to verify the correct element
68
+
- Bounding boxes with labels on their top right corner correspond to element indexes
73
69
74
70
7. Form filling:
75
-
- If you fill an input field and your action sequence is interrupted, most often a list with suggestions poped up under the field and you need to first select the right element from the suggestion list.
71
+
- If you fill an input field and your action sequence is interrupted, most often something changed e.g. suggestions popped up under the field.
76
72
77
-
8. ACTION SEQUENCING:
78
-
- Actions are executed in the order they appear in the list
79
-
- Each action should logically follow from the previous one
80
-
- If the page changes after an action, the sequence is interrupted and you get the new state.
81
-
- If content only disappears the sequence continues.
82
-
- Only provide the action sequence until you think the page will change.
83
-
- Try to be efficient, e.g. fill forms at once, or chain actions where nothing changes on the page like saving, extracting, checkboxes...
84
-
- only use multiple actions if it makes sense.
73
+
8. Long tasks:
74
+
- Keep track of the status and subresults in the memory.
85
75
86
76
9. Extraction:
87
-
- If your task is to find information or do research - call extract_content on the specific pages to get and store the information.
77
+
- If your task is to find information - call extract_content on the specific pages to get and store the information.
88
78
89
79
"""
90
80
text+=f" - use maximum {self.max_actions_per_step} actions per sequence"
0 commit comments