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
Copy file name to clipboardExpand all lines: src/core/prompts/tools/browser-action.ts
+8-1Lines changed: 8 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -15,19 +15,26 @@ Parameters:
15
15
* launch: Launch a new Puppeteer-controlled browser instance at the specified URL. This **must always be the first action**.
16
16
- Use with the \`url\` parameter to provide the URL.
17
17
- Ensure the URL is valid and includes the appropriate protocol (e.g. http://localhost:3000/page, file:///path/to/file.html, etc.)
18
+
* hover: Move the cursor to a specific x,y coordinate.
19
+
- Use with the \`coordinate\` parameter to specify the location.
20
+
- Always move to the center of an element (icon, button, link, etc.) based on coordinates derived from a screenshot.
18
21
* click: Click at a specific x,y coordinate.
19
22
- Use with the \`coordinate\` parameter to specify the location.
20
23
- Always click in the center of an element (icon, button, link, etc.) based on coordinates derived from a screenshot.
21
24
* type: Type a string of text on the keyboard. You might use this after clicking on a text field to input text.
22
25
- Use with the \`text\` parameter to provide the string to type.
26
+
* resize: Resize the viewport to a specific w,h size.
27
+
- Use with the \`size\` parameter to specify the new size.
23
28
* scroll_down: Scroll down the page by one page height.
24
29
* scroll_up: Scroll up the page by one page height.
25
30
* close: Close the Puppeteer-controlled browser instance. This **must always be the final browser action**.
26
31
- Example: \`<action>close</action>\`
27
32
- url: (optional) Use this for providing the URL for the \`launch\` action.
28
33
* Example: <url>https://example.com</url>
29
-
- coordinate: (optional) The X and Y coordinates for the \`click\` action. Coordinates should be within the **${args.browserViewportSize}** resolution.
34
+
- coordinate: (optional) The X and Y coordinates for the \`click\` and \`hover\` actions. Coordinates should be within the **${args.browserViewportSize}** resolution.
30
35
* Example: <coordinate>450,300</coordinate>
36
+
- size: (optional) The width and height for the \`resize\` action.
37
+
* Example: <size>1280,720</size>
31
38
- text: (optional) Use this for providing the text for the \`type\` action.
0 commit comments