一键导入
browser-switch
Choose between agent-browser and Playwright CLI for browser automation tasks.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Choose between agent-browser and Playwright CLI for browser automation tasks.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | browser-switch |
| description | Choose between agent-browser and Playwright CLI for browser automation tasks. |
Choose between agent-browser (Rust) and Playwright CLI (Node.js) for browser automation.
Need max speed & token efficiency? → agent-browser Need cross-browser or debugging? → Playwright CLI Complex component frameworks (e.g. Gradio, MUI, Ant Design)? → Playwright CLI
| Feature | agent-browser | Playwright CLI |
|---|---|---|
| Language | Rust | Node.js |
| Browser | Chrome only | Chrome, Firefox, Safari |
| Token Usage | ~5.5K chars | ~31K chars |
| Speed | ~100ms/action | ~200-300ms |
| Maturity | New (Vercel) | Mature (Microsoft) |
| Custom components | May miss some | Better snapshot coverage |
agent-browser open example.com
agent-browser snapshot -i
agent-browser click @e2
agent-browser fill @e3 "test@example.com"
playwright-cli open https://example.com
playwright-cli snapshot
playwright-cli click e2
playwright-cli fill e3 "test@example.com"
Use agent-browser unless you specifically need:
If agent-browser snapshot -i doesn't show the element:
agent-browser click "#my-button"agent-browser find text "Submit" clickagent-browser eval "document.querySelector('.my-class').click()"agent-browser may lose tab state when navigating away and back. Use CSS selectors for tab switching:
agent-browser click "[role=tab]:nth-child(2)"
Or fall back to Playwright CLI for reliable tab persistence.
Apps built with Gradio, MUI, Ant Design, or other component libraries often use custom elements and deep nesting that agent-browser's accessibility tree doesn't fully capture. Common symptoms:
- text: "..." with no interactable refsTry Playwright CLI when agent-browser struggles with these patterns.