browser-replay
它能做什么
这项技能将已录制的浏览器轨迹重放到同一页面或已变更的版本上。适合希望在更新后确认某个流程仍然正常的测试人员和开发者。
适用场景
- ✓当你希望在部署后重新检查某个界面流程时。
- ✓当你需要复现早前录制会话中的错误时。
- ✓当你希望对比同一流程两次运行的差异时。
技能链接
https://github.com/ruvnet/ruflo/blob/main/plugins/ruflo-browser/skills/browser-replay/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请把上周的结账会话在预发布站点上重放一遍,并告诉我在哪里失败。”
每周 5 个新技能,1 分钟读完。
工作原理
智能体加载已录制的步骤,打开一个新的浏览器,按顺序重复每个操作;遇到选择器变化时,通过搜索相似元素进行处理。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
Browser Replay
Re-drive a recorded session trajectory. Used for regression testing, deterministic re-runs, and as the verification path that browser-record plus browser-selectors actually produces something replayable.
This skill is the load-bearing assumption of the v0.2.0 architecture. ADR-0001 Verification §4 requires ≥80% replay success across 10 distinct sites of varying drift profiles before the proposal moves from
Proposed→Accepted. If you find replay unreliable, capture the failure modes infindings.mdand report them up the ADR.
When to use
- Regression-testing a UI flow after a deploy.
- Reproducing a bug captured in a prior session.
- Comparing two runs of the same flow for
browser-screenshot-diff. - Forking a session (
/ruflo-browser fork) and replaying the parent before mutating.
Steps
- Locate the source session:
npx -y ruvector@0.2.27 rvf status <session-id>.rvf - Load the trajectory:
Each line isRead .../trajectory.ndjson{ts, action, args, selector, result}. - Open a fresh browser via
mcp__plugin_ruflo-core_ruflo__browser_open(target URL = original or--urloverride). - For each trajectory step, dispatch the matching MCP tool (
browser_click,browser_fill,browser_eval, etc.) with the recorded args. - On selector miss, do not fail immediately — query the
browser-selectorsnamespace for an embedding-similar selector for the same<host>:<intent>and retry once:npx -y @claude-flow/cli@latest memory search --namespace browser-selectors \ --query "<host> <intent>" --limit 5 - Record a new trajectory for the replay run (allocate a fresh RVF container, lineage-tracked via
rvf derive). - Verdict: tally matched-step / total-step ratio. Default tolerance threshold is 0.85 (configurable via
--tolerance). Verdict goes intofindings.md.
Caveats
- Browserbase explicitly does not offer replay (rrweb session replay was deprecated). We're betting on selector-embedding recovery; expect noise on heavily drifted sites.
- Network nondeterminism (timing, content variation) can produce false-fail verdicts. Use
--mutateto inject expected variation or pin to a fixture. - For visual diff, chain into
browser-screenshot-diffagainst the parent session id. - If selector recovery requires more than one retry per step, log it. That's the signal that the site needs a re-record, not a replay.
常见问题
如果某个选择器不再匹配怎么办?
这项技能说明,它不会立即失败,而是尝试通过相似元素进行恢复。
我可以对更改后的网址进行重放吗?
可以。这项技能允许覆盖网址,以便对变体进行重放。
重放可靠吗?
这项技能说明,重放方法仍在验证中,所以请记录你发现的失败情况。
详情
作者的原始描述
Replay a recorded session trajectory against the same URL or a mutated variant; uses browser-selectors embedding similarity to recover from DOM drift
repo: ruvnet/ruflo
热度
- GitHub 星标
- 81k
- 排名
- #1581
- 许可证
- MIT
- 更新时间
- 2026/11/2
评论
- …
同一仓库的更多技能
agent-adaptive-coordinator
81k帮你的智能体在工作量变化时拆分和重新平衡一组 AI 智能体,并选择适合任务的分工方式。
agent-agent
81k教你的智能体把一个大目标拆成有顺序的行动计划,并在情况变化时重新规划。
agent-agentic-payments
81k帮你的智能体管理 AI 购物的消费授权,包括消费上限、时间窗口、商户规则和签名审批。
agent-analyze-code-quality
81k帮你的智能体检查代码质量,找出代码异味、技术债务和重构建议,且不改动文件。