From 83cbcfee2868a1cb8fb6d904d4de10d9b795cf24 Mon Sep 17 00:00:00 2001 From: Shuchang Zheng Date: Wed, 7 Aug 2024 23:46:04 -0700 Subject: [PATCH] move 'need_verification-code' to the bottom of the structured json (#690) --- skyvern/forge/prompts/skyvern/extract-action.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/skyvern/forge/prompts/skyvern/extract-action.j2 b/skyvern/forge/prompts/skyvern/extract-action.j2 index 818d05d8..639db8f2 100644 --- a/skyvern/forge/prompts/skyvern/extract-action.j2 +++ b/skyvern/forge/prompts/skyvern/extract-action.j2 @@ -9,7 +9,6 @@ If you see a popup in the page screenshot, prioritize actions on the popup. Reply in JSON format with the following keys: { -{% if verification_code_check %} "need_verification_code": bool, // Whether a verification code is needed to proceed.{% endif %} "user_goal_achieved": str, // A string that describes if user goal has been completed with reasoning. "action_plan": str, // A string that describes the plan of actions you're going to take. Be specific and to the point. Use this as a quick summary of the actions you're going to take, and what order you're going to take them in, and how that moves you towards your overall goal. Output "COMPLETE" action in the "actions" if user goal has been achieved. "actions": array // An array of actions. Here's the format of each action: @@ -34,7 +33,8 @@ Reply in JSON format with the following keys: "confidence_float": float // The confidence of the error. Pick a number between 0.0 and 1.0. 0.0 means no confidence, 1.0 means full confidence }] {% endif %} - }], + }],{% if verification_code_check %} + "need_verification_code": bool, // Whether a verification code is needed to proceed.{% endif %} } {% if action_history %} Consider the action history from the last step and the screenshot together, if actions from the last step don't yield positive impact, try other actions or other action combinations.