Browser automation with AI
Skills used in this guide (3)
通过 CDP 直接控制浏览器进行网页交互:自动化、抓取、测试、截图与站点/应用作业。
npx skills add browser-use/browser-use -g对网站或 Web 应用做 QA 测试并返回 1-5 质量分(5=完美,1=损坏)及证据。当用户想测试、QA、评估或“检查好坏”某个站点、页面、流程或应用——包括本地开发服务器(如“qa 测试 localhost:5173”、“结账能用吗”、“给这个落地页打分”)。驱动真实的 Browser Use 云端浏览器,自动打通本地隧道。
npx skills add browser-use/browser-use -g为 Convex 应用添加周期性调度任务(crons)。
npx skills add get-convex/agent-skills -g
Browser-automation pain is "brittle scripts, break on any change". The point of AI: give a clear goal and a done-criteria, let it walk and self-verify, not hardcode XPath and maintain forever.
Who this is for / not for
For:
- Auto fill forms / scrape / walk flows
- Pages change often, hate maintaining scripts
- Repeat ops on a schedule
Not for:
- Bypass captcha / login风控 (compliance risk)
- Hammer a site (polite scraping)
- Payments etc. high-risk (human review)
Before you start
- Goal: what to finish, what "done" means.
- Env: a client that can run a browser.
- (Opt) cadence: need schedule?
Steps
1. Install the skill
browser-use is a browser-automation skill. Copy its folder into your client's skills directory (same as any Agent Skill):
| Client | Directory |
|---|---|
| Claude Code | ~/.claude/skills/ |
| Codex | ~/.codex/skills/ |
| Cursor | ~/.cursor/skills/ |
| Trae | ~/.trae/skills/ |
| CodeBuddy | ~/.codebuddy/skills/ |
| Tongyi Lingma | ~/.lingma/skills/ |
2. Goal + done-criteria
Log in, go to backend, export yesterday's 50 pending orders to downloads/orders.csv.
Done = file exists and row count = 50. On captcha, stop and error, don't push.3. Verify with qa
Key flows → qa auto-verifies page behavior, avoids silent failure:
Open checkout, verify "submit" is disabled when stock = 0, give result.4. Schedule with convex-crons
Recurring → convex-crons schedules, throttle so you're not a nuisance.
Pitfalls
| Pit | Symptom | Fix |
|---|---|---|
| No done-criteria | Wanders | Define success first |
| Push风控 | Banned | Stop on captcha |
| High freq | Blocked | Rate-limit + gap |
| Brittle script | Breaks | Let AI self-verify |
| High-risk op | Loss | Human review payments |
FAQ
No scripting?
Yes — give goal, AI walks it.
Pages change?
AI self-verifies (qa), steadier than XPath.
Schedule?
Yes, convex-crons sets cadence.
Get banned?
Throttle, stop on captcha, skip风控.
Auto-pay?
No — high-risk, keep human review.
Related guides
Continue across these scenes:
相关源码
- browser-use/browser-use · browser-use source
- browser-use/browser-use · qa source
- get-convex/agent-skills · convex-crons source
- Agent Skill open format spec
一句话结论
结论:浏览器自动化给清目标和"完成标准",让 AI 自校验(qa)、遇验证码就停,别写死 XPath 也别碰风控。