browser-harness
Skill1 starsChanged 4 days agoApache-2.0View on GitHub
验收前端页面:准备服务和登录态,通过 agent-browser 交互、采集证据并清理资源。
10 other projects use a version of this.
Adopted by
Most recently taken up by
- davidondrej/cloudroom-coretheir own version, first seen Nov 1, 2026
- davidondrej/cloudroomtheir own version, first seen Nov 1, 2026
- davidondrej/skillstheir own version, first seen Oct 29, 2026
- edgardoperrelli-maker/claude-skillstheir own version, first seen Oct 25, 2026
- browser-use/browser-harnesstheir own version, first seen Oct 8, 2026
- attentiondotnet/davidondrej-skillstheir own version, first seen Jul 7, 2026
Used with
Projects with it also use adr-verbatim, file-tree and 8 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
davidondrejSkilladr-verbatim
Record concise ADRs that preserve the user''s decisions without conversational noise. Use for "adr-verbatim", "new ADR", "document that as an ADR", "record this decision", or supplied ADR wording.
Also in 3 projects that use this
davidondrejSkillfile-tree
Manually-invoked skill that prints a nice file tree of the current topic in a code block. Use when the user says "file-tree" or "file tree".
Also in 3 projects that use this
matyasstochSkilldistribute-skill-to-all-agents
Distribute a newly-created agent skill across all 4 canonical skill folders on a local machine so Claude Code, Codex/OpenAI Agents, Pi Agent, and Hermes all see it. Use whenever the user says "give this skill to all agents", "distribute this skill", "sync skills across agents", or after creating a new skill that should be globally available. Covers the .claude/skills symlink and the ~/.pi/agent/skills (NOT ~/.pi/skills) trap.
Also in 3 projects that use this
attentiondotnetSkillsetup-help
Walk the user through setting up anything step by step. Use when the user asks for help setting up, configuring, installing, or getting something working — "help me set up X", "walk me through this", "setup-help". Differentiator: gives one current step at a time, then always lists every remaining setup step after each response.
Also in 4 projects that use this
matyasstochSkilleffective-agent-skills
How to write effective agent skills — what to do, what not to do, anatomy, progressive disclosure, design patterns, anti-patterns, testing, security. Read this whenever a skill (Claude Skill, Agent Skill, SKILL.md) is being created, edited, reviewed, or debugged. Use when the user says "create a skill", "new skill", "update this skill", "improve a skill", "why isn't my skill triggering", or anything else involving authoring or editing SKILL.md files.
Also in 3 projects that use this
maragudkSkilldecisions
Guide for recording significant architectural and design decisions in docs/decisions.md. Use this skill when clearly significant architectural decisions are made (database choices, frameworks, core design patterns) or when explicitly asked to document a decision. Be conservative - only suggest for major decisions, not minor implementation details.
Also in 3 projects that use this
- +2 more from davidondrej
Other versions10 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 10
- browser-use/browser-harness★ 19ksame name
- davidondrej/skills★ 4.3ksame name
- davidondrej/cloudroom★ 1.5ksame name
- davidondrej/cloudroom-core★ 1.5ksame name
- matyasstoch/david-skills★ 59same name
- itgoyo/hermes-skills★ 53same name
- attentiondotnet/davidondrej-skills★ 11same name
- Roentek/Claude_Code_Boilerplate_Framework★ 4same name
- Synthenova/skills★ 1same name
- edgardoperrelli-maker/claude-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository13 other files it gives its agents.
- agent-conductSkill
- asset-validationSkill
- awesome-presentationSkill
- changelog-writingSkill
- debian-testvmSkill
- feature-deliverySkill
- herdrSkill
- persistent-ssh-opsSkill
- provision-xray-hy2-nodeSkill
- public-acceptanceSkill
- repo-knowledge-graphSkill
- tddSkill
- trigger-build-workflowSkill
The file
Files
Browser Harness
为 URL、HTML 文件或项目目录准备验收环境,通过 agent-browser 完成浏览器交互和截图、控制台、网络采证。项目测试由项目自身执行,本技能提供实际 APP_URL。
执行者与交接
父 Agent 默认通过当前宿主自带的 subagent 工具委派浏览器验收:Codex 用官方 subagent 并指定 gpt-6.1-sol / medium,Claude Code 用 Agent 工具新建 subagent 并指定 sonnet。不用 Herdr 启动替代 Agent。派发前读取 子 Agent 交接与复验,按其中的宿主参数传入完整验收要求与资源归属。已受委派的验收 Agent 直接执行下方流程,不再派发。
父 Agent 负责验收标准、业务修复与最终确认;子 Agent 负责环境准备、浏览器交互、采证和自有资源清理。宿主没有 subagent 工具或指定模型不可用时报告具体阻塞,由父 Agent 承接已授权验收,不静默换模型、换宿主或改用其他执行载体。用户明确要求父 Agent 直接操作时遵从用户。
浏览器配置
默认使用 自带 Chromium + 无头模式,交互验收和采证共用同一命名 session/profile。遵循 agent-browser 原生配置,不另设浏览器配置层;日常验收不连接 Convorel 的 ChatGPT 浏览器,也不复用其 CDP、session 或 profile。
login 为人工登录显式添加 --headed,登录后关闭本任务会话,再以无头模式继续验收,持久化 profile 保留。若旧配置仍有 "headed": true,本次任务设置 AGENT_BROWSER_HEADED=false;浏览器路径必须显式指向已安装的自带 Chromium(工具管理的浏览器缓存),不依赖自动发现、也不回退到系统 Chrome。配置优先级、已有配置迁移和模式切换见 平台与运行时。
默认流程
- 固定任务根目录与 target;按实际加载的本
SKILL.md所在目录定位 dispatcher。 - 未准备环境时运行
prepare取得APP_URL;已交接成功 prepare 结果或既有服务 URL 时核实并复用,不重复 prepare。需要登录时读 登录态与 profile。 - 按 交互与证据 检查关键页面和失败路径;项目测试也使用同一个
APP_URL。 - 验收通过或必要失败诊断完成后,默认 cleanup 本任务拥有清理权且无实际依赖的服务,并关闭本次浏览器和验证进程;借用服务不执行其 target 的 cleanup。中间产物和一次性验收数据按 任务资源生命周期 回收,先保留交付所需的最小证据。已有用户远程走查或保留服务要求时才进入 远程与保留分支,不额外询问是否走查。
- 报告实际
APP_URL、关键页面结果、console/network 错误、证据目录和清理动作;说明服务、浏览器、验证进程是否释放。保留资源时写明原因、PID 和端口。
既有流程需要或用户要求独立验收报告时,默认交付 REPORT.html,生成前读取 HTML 验收报告规范;既有 JSON 采证结果保持原契约。
以下命令展示尚未准备环境、且已确认 target 没有其他所有者服务的项目分支;已有服务按交接复用,URL target 无本地服务需要 cleanup。
# BROWSER_HARNESS_SKILL_DIR = 实际加载本 SKILL.md 的目录
BH_DIR="$BROWSER_HARNESS_SKILL_DIR/scripts"
export AGENT_BROWSER_SESSION="<task-session>"
export BH_DEFAULT_PROFILE="$AGENT_BROWSER_SESSION"
export AGENT_BROWSER_HEADED=false
# 先核实工具管理的 Chromium 实际路径;不填系统 Chrome 或 Convorel 浏览器路径
export AGENT_BROWSER_EXECUTABLE_PATH="<已核实的自带 Chromium 可执行文件绝对路径>"
export AGENT_BROWSER_PROFILE="$(bun "$BH_DIR/bh.ts" profile-dir "$BH_DEFAULT_PROFILE")"
# TARGET = 用户目标 URL、HTML 绝对路径或项目绝对路径
# 在任务/项目根运行;失败时停止依赖动作,并清理本任务已创建的资源
if BH_PREPARE_ENV="$(bun "$BH_DIR/bh.ts" prepare "$TARGET")"; then
eval "$BH_PREPARE_ENV"
else
BH_PREPARE_STATUS=$?
bun "$BH_DIR/bh.ts" cleanup "$TARGET"
exit "$BH_PREPARE_STATUS" # 仅结束当前命令批次;Agent 按失败原因修复后重试
fi
bun "$BH_DIR/bh.ts" collect-evidence "$APP_URL"
bun "$BH_DIR/bh.ts" cleanup "$TARGET"
agent-browser close每次 shell 调用的变量不会自动延续,cwd 也可能变化;在同一批解析并消费结果,或显式重载任务私有环境文件。目录定位、跨批次、自定义启动和 macOS 故障读 平台与运行时。下文及引用中的 bh 均指 bun "$BH_DIR/bh.ts"。
必要约束
- 先用赋值命令检查 prepare 的退出码,仅成功后 eval 其 stdout;失败即清理本任务资源,不消费残留 APP_URL、不继续采证。不要将命令替换直接嵌入 eval,它会掩盖 prepare 失败。项目 target 同时输出
DEV_SERVER_PID/DEV_SERVER_LOG;不得从日志猜端口或自行拼 URL。 - 项目 journey/testing-suite 通过其现有参数或环境变量消费
APP_URL,例如bun run test:journey -- --app-url "$APP_URL";不在本技能重新实现测试。 collect-evidence默认重新打开 URL。交互后要保留瞬时状态,须在同一 profile 已打开目标页时使用--reuse-page,此时 URL 只作元数据。artifact_errors非空的文件是 fallback 占位,不能作为有效证据判通过;open失败退出 3 且无证据目录。从 stdout 的evidence_dir取精确目录,不猜“最新”目录。请求 body 按requestId单条读取。cleanup使用与 prepare/share/publish 相同的 target;HTML target 归一到所在目录。它回收 tunnel 和 dev server,浏览器须另行关闭。- 项目
prepare会停止该 target 状态文件中已有的存活服务,cleanup也按 target 清理,不按 Agent 隔离。执行前核实所有权和保留要求;借用服务只使用交接 URL,不对其项目 target 执行 prepare/cleanup。需要重建自有服务时,先确认旧执行者已停且无人依赖,再操作。 - 整个交互与采证流程使用同一命名 session 和 profile。跨命令保留
AGENT_BROWSER_SESSION/AGENT_BROWSER_PROFILE或逐次传参;遗漏 profile 可能使 agent-browser 重启到空白页。不要操作共享默认 session。 - 清理边界是本任务创建的精确 PID、target、profile;保留用户既有服务和登录态。核对 PID、父进程与 profile,不用宽泛
pgrep -f杀进程。close 后只从外部查精确 PID/CDP 端口,不再用 snapshot/open 探测,以免重启浏览器。 - 验收失败时,子 Agent 返回复现步骤、原始证据及资源状态;负责开发的父 Agent 修复业务/环境问题,再按交接规则续接复验,直到通过或遇到真实阻塞。子 Agent 不擅自修改业务代码、测试预期或 mock;父 Agent 直接执行时仍负责修复与复验。不要修改诊断或证据来伪造通过。
- 不自动全局安装或升级 Bun、agent-browser、浏览器或项目依赖;缺失时报告准确前置,并依据已有安装授权与项目包管理约定执行。
按需分支
- 登录、多账号、profile 复用:登录态。
- 点击/填写/截图、网络深挖、证据结构:交互采证。
- 用户要求远程走查、保留服务或启动并发布:远程流程。创建公网仍须用户授权,已有授权不重复问;加载 public-acceptance,复用同一 tunnel。启动获得地址立即交付,不把探活作为启动条件。
- 依赖、dispatcher 定位、自定义服务、macOS、清理故障:平台排障。
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

