agent-browser
使用AI代理自动化网页浏览
也可从以下获取: vercel-labs,inferencesh,inference-sh-9,inference-sh-8,inf-sh,inference-sh-0
自动化网页交互操作,如表单填写、数据提取和测试,无需手动控制浏览器。该技能为AI代理提供浏览器自动化功能,通过简单的元素引用系统,无需复杂的CSS选择器或XPath查询。
下载技能 ZIP
在 Claude 中上传
前往 设置 → 功能 → 技能 → 上传技能
开启并开始使用
测试它
正在使用“agent-browser”。 Open https://example.com and show me interactive elements
预期结果:
Session created: abc123
Interactive elements:
@e1 [a] 'Home' href='/'
@e2 [input type='text'] placeholder='Search'
@e3 [button] 'Submit'
Screenshot saved to: /tmp/screenshot.png
正在使用“agent-browser”。 Click the search button and wait for results
预期结果:
Action completed: clicked @e3
Waiting for page load...
Snapshot updated: 5 new elements found
Current URL: https://example.com/search?q=test
正在使用“agent-browser”。 Extract all headlines from the page
预期结果:
Executing JavaScript: document.querySelectorAll('h2').map(h => h.textContent)
Result: ['Introduction', 'Features', 'Pricing', 'Contact']
Screenshot saved
安全审计
安全All 606 static findings are false positives. The skill contains only documentation (markdown files) and template shell scripts. The external_commands findings are code examples in markdown showing users how to use the infsh CLI tool. The network findings are example URLs in documentation. The filesystem findings are example file paths. The skill itself does not execute any commands - it provides documentation for a third-party CLI tool (inference.sh). Users execute the commands themselves, not the skill.
风险因素
质量评分
你能构建什么
自动化表单测试
QA工程师可以跨多个浏览器自动化表单提交流程,测试验证逻辑和错误处理,无需手动点击
从Web应用提取数据
研究人员可以从需要登录的Web应用程序中提取结构化数据,通过已认证的会话导航来抓取报告或仪表板数据
回归测试
开发者可以创建可复现的浏览器自动化脚本来验证关键用户流程,如代码更改后的结账流程或账户注册流程
试试这些提示
打开 https://example.com 并显示页面上的所有交互式元素
在登录表单中填写用户名 'user@example.com' 和密码 'secret123',然后点击提交按钮
导航到 https://example.com/data 并执行JavaScript将所有产品名称和价格提取为结构化格式
打开启用视频录制的浏览器会话,导航通过结账流程,并保存视频用于调试
最佳实践
- 页面导航后务必重新获取快照以获取新的元素引用,因为@e引用在DOM更改后会失效
- 使用环境变量存储敏感凭据,而不是在自动化脚本中硬编码
- 完成后关闭浏览器会话以释放资源并获取录制的视频
- 开发期间启用视频录制,生产环境运行时禁用以提高性能
避免
- 点击链接或提交表单后不要重复使用元素引用——始终调用snapshot获取新的引用
- 避免长时间不活动——会话可能会超时并丢失状态
- 切勿在自动化脚本中提交凭据或API密钥
- 不要尝试在元素可见之前就与其交互