browser-automation-skills
简介
browser-automation-skills
原始描述
Browser automation skills for AI models — navigate, screenshot, interact, scrape, debug, test, and record browser sessions. Controls local Google Chrome via...
通过你的 Agent 添加
安装目录:browser-context/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。
点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。
或者手动安装
包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可;
目录名不用换,也不要把包直接解压到 skills 根目录。
技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。
技能正文
name: browser-context
description: Background knowledge about browser automation tools and capabilities. Provides reference for how to control the browser, available primitives, interaction patterns, and error handling. 浏览器控制参考、浏览器工具文档、浏览器自动化能力、browser_subagent使用方法。
user-invocable: false
Browser Automation Reference
You have access to browser automation that controls the local Google Chrome browser.
Backend Detection
Detect which backend is available and use it:
Backend A: Antigravity (browser_subagent)
If you have the browser_subagent tool available, use it directly.
See api-reference.md for full details.
Backend B: Playwright CLI (scripts/browser.py)
If you have terminal/command execution access but no browser_subagent, use the CLI adapter:
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py navigate <url>
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py screenshot [url] [--output path.png] [--full]
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py dom
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py text
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py click <x> <y>
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py type <text>
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py key <key_name>
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py scroll <direction> [amount]
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py resize <width> <height>
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py network
python ${CLAUDE_SKILL_DIR}/../scripts/browser.py console
Tool Mapping
Action
Antigravity (browser_subagent)
Playwright CLI (browser.py)
Navigate
open_browser_url
browser.py navigate <url>
Screenshot
capture_browser_screenshot
browser.py screenshot
Read DOM
browser_get_dom
browser.py dom
Read text
read_browser_page
browser.py text
Click
click_browser_pixel x y
browser.py click <x> <y>
Type
(via browser_press_key)
browser.py type <text>
Key press
browser_press_key
browser.py key <key>
Scroll
browser_scroll
browser.py scroll <dir> [amt]
Resize
browser_resize_window
browser.py resize <w> <h>
Network
browser_list_network_requests
browser.py network
Console
capture_browser_console_logs
browser.py console
Lock input
(automatic in Antigravity)
browser.py lock
Unlock input
(automatic in Antigravity)
browser.py unlock
Core Pattern: Observe → Act → Verify
- Get DOM / screenshot to understand current state
- Perform action (click, type, scroll)
- Screenshot to verify the result
Key Rules
- Use pixel coordinates for clicking (from DOM data), not CSS selectors
- Always verify via screenshot after actions
- For Antigravity: pass
ReusedSubagentId to continue multi-step flows
- For CLI: the browser session persists automatically between calls
- For CLI: use
browser.py lock before interactive sequences to prevent user interference, and browser.py unlock after
| Action | Antigravity (browser_subagent) |
Playwright CLI (browser.py) |
|---|---|---|
| Navigate | open_browser_url |
browser.py navigate <url> |
| Screenshot | capture_browser_screenshot |
browser.py screenshot |
| Read DOM | browser_get_dom |
browser.py dom |
| Read text | read_browser_page |
browser.py text |
| Click | click_browser_pixel x y |
browser.py click <x> <y> |
| Type | (via browser_press_key) | browser.py type <text> |
| Key press | browser_press_key |
browser.py key <key> |
| Scroll | browser_scroll |
browser.py scroll <dir> [amt] |
| Resize | browser_resize_window |
browser.py resize <w> <h> |
| Network | browser_list_network_requests |
browser.py network |
| Console | capture_browser_console_logs |
browser.py console |
| Lock input | (automatic in Antigravity) | browser.py lock |
| Unlock input | (automatic in Antigravity) | browser.py unlock |
- Get DOM / screenshot to understand current state
- Perform action (click, type, scroll)
- Screenshot to verify the result
Key Rules
- Use pixel coordinates for clicking (from DOM data), not CSS selectors
- Always verify via screenshot after actions
- For Antigravity: pass
ReusedSubagentId to continue multi-step flows
- For CLI: the browser session persists automatically between calls
- For CLI: use
browser.py lock before interactive sequences to prevent user interference, and browser.py unlock after
ReusedSubagentId to continue multi-step flowsbrowser.py lock before interactive sequences to prevent user interference, and browser.py unlock after正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。