HumanMessage ---------------------------------------- SYSTEM_PROMPT_FOR_PLANNER ========================= === GLOBAL INSTRUCTIONS === - **Environment:** macOS 15+. - Content-safety override – If any user task includes violent, illicit, politically sensitive, hateful, self-harm, or otherwise harmful content, you must not comply with the request. Instead, you must output exactly with the phrase “REFUSE TO MAKE PLAN”.(all in capital and no other words) - The plan should be a step goal level plan, not an action level plan. - **Output Format for Single-turn Non-repetitive Tasks:** Strictly JSON in English, no harmful language: { "iteration_info": { "current_iteration": i, "total_iterations": times you need to repeat, }, "search_summary": "Concise summary of the most relevant search findings (empty string if none).", "selected_skills": ["skill-name-1", "skill-name-2"], "natural_language_plan": "High-level plan in natural language (no step IDs, no low-level actions).", "step_by_step_plan": [ { "step_id": "Step 1", "description": "[Goal Description]", "important_search_info": "[Relevant search info for this step or empty string]" }, { "step_id": "Step 2", "description": "[Goal Description]", "important_search_info": "[Relevant search info for this step or empty string]" }, { "step_id": "Step N", "description": "[Goal Description]", "important_search_info": "[Relevant search info for this step or empty string]" } ] } - **Output Format for Multi-turn Repetitive Tasks:** Same JSON structure as above, but with total_iterations > 1. In the first turn (initial task), set current_iteration=1 and output the plan for the FIRST instance/item only. In subsequent turns, the human message will specify the previous completed iteration (e.g., "Continue: previous iteration X completed, summary: [brief what was done], original task: [reminder]"), then set current_iteration = previous + 1 and output the plan ONLY for that specific next instance/item. - **IMPORTANT STEP ID FORMAT**: Each step in `step_by_step_plan` must have `step_id` as "Step X" starting from 1 (reset per iteration). - **IMPORTANT DESCRIPTION CONTENT**: Descriptions must be concise, high-level goals in English, no low-level details (e.g., no keystrokes, clicks). Focus on achieving the step's goal for the CURRENT iteration's specific item/instance. - **SEARCH INFO FIELDS**: If no search was used or no relevant findings, set `search_summary` and each `important_search_info` to an empty string. - **SKILL SELECTION**: Always include `selected_skills` as a list of skill names from the Skills Catalog. If none apply or no skills are provided, output an empty list []. If the user message provides "Preselected skills", you MUST use that list exactly and do not add or remove skills. - **NATURAL LANGUAGE PLAN**: Include `natural_language_plan` as a concise, high-level description of the overall plan. Do NOT include step IDs, numbering like "Step 1", or low-level actions (clicks, keystrokes). Prefer 2-6 short sentences or bullets describing the main objectives. === SKILLS CATALOG === (No skills provided.) === MULTI-TURN REPETITIVE TASK HANDLING === - **Detect Repetition:** If the task involves repeating similar actions for multiple distinct items (e.g., "download 5 images: url1,url2,..."; "send message to 3 people: Alice, Bob, Charlie"), calculate total_iterations = number of items/instances. - **First Turn (Initial Message):** - Determine total_iterations N. - Output iteration_info with current_iteration=1, total_iterations=N. - step_by_step_plan: ONLY for the 1st item/instance (e.g., download url1 only; make it specific to that item). - **Subsequent Turns (Continuation Messages):** - Human will provide: "Summary of previous: [brief, e.g., 'Downloaded image1 from url1']; The information stored previous tasks; Previous task you planned that completed; Original task." - Parse this to identify the next item/instance (X+1). - Output iteration_info: current_iteration = X+1, total_iterations = same N. - step_by_step_plan: ONLY for the (X+1)th specific item/instance (independent, no reference to others). - You should give the full information stored to the agent if the information stored does help in next iteration. - Avoid give the previous completed plan you generated.(e.g. the previous plan download the first image, your next plan should not include download the first image again) - **Non-repetitive Tasks:** Always total_iterations=1, current_iteration=1, full plan in one output. - **Independence:** Each iteration's plan is fully standalone; do not assume state from previous iterations. === ROLE & RESPONSIBILITIES === - **Role:** Planner for macOS GUI Agent in multi-turn sessions. - **Responsibilities:** 1. Analyze task (initial or continuation) and output JSON plan for current iteration only. 2. For repetitions, enforce one iteration per turn to enable sequential execution and feedback. 3. If the previous tasks were completed successfully, the new plan should not involve redoing previous completed plans. === SPECIFIC PLANNING GUIDELINES === - Prioritize AppleScript/terminal for speed in repetitive actions if suitable. === IMPORTANT REMINDERS === - Specify apps in descriptions (e.g., "In Safari, download the specific image"). - No "verify/check" in descriptions. - For coding: Use VS Code/Copilot/Cursor. - Sometimes the screenshot of the completion of the previous subtask will mislead the performance of the agent in executing the next subtask. Give instructions to remove the completion status to avoid ambiguity.(e.g. close the tab showing the completed status) --- *Respond strictly with the JSON output.* Now, here is the task you need to break down: "继续在当前东方财富2条件单新建页面:填写测试参数但绝对不要提交。填写内容:代码510300,方向买入,数量100,有效期当日;触发价=当前价下调0.30%,委托价=触发价上调0.10%。禁止点击任何包含提交/确认/下单/买入/卖出字样的按钮。填写完成后停止并输出 READY_FOR_CONFIRMATION。" Please follow the guidelines and provide the required JSON output. ============================================================ RESPONSE { "iteration_info": { "current_iteration": 1, "total_iterations": 1 }, "search_summary": "", "selected_skills": [], "natural_language_plan": "Fill in the conditional order creation form in the East Money application with test parameters for stock code 510300. Set the direction to buy, quantity to 100, and validity to same day. Calculate the trigger price as 0.30% below the current price, and the order price as 0.10% above the trigger price. Do not click any submit, confirm, order, buy, or sell buttons. After completing all fields, output the text 'READY_FOR_CONFIRMATION'.", "step_by_step_plan": [ { "step_id": "Step 1", "description": "Enter stock code 510300 in the code input field", "important_search_info": "" }, { "step_id": "Step 2", "description": "Ensure the trading direction is set to Buy", "important_search_info": "" }, { "step_id": "Step 3", "description": "Enter quantity 100 in the quantity field", "important_search_info": "" }, { "step_id": "Step 4", "description": "Set the validity period to Same Day", "important_search_info": "" }, { "step_id": "Step 5", "description": "Read the current stock price and calculate the trigger price as current price multiplied by 0.997", "important_search_info": "" }, { "step_id": "Step 6", "description": "Enter the calculated trigger price in the trigger price field", "important_search_info": "" }, { "step_id": "Step 7", "description": "Calculate the order price as trigger price multiplied by 1.001 and enter it in the order price field", "important_search_info": "" }, { "step_id": "Step 8", "description": "Output the text 'READY_FOR_CONFIRMATION' to indicate completion without submission", "important_search_info": "" } ] } ============================================================