multi-agents-browser: Instructions file for Claude Code

CLAUDE.md

multi-agents-browser CLAUDE.md is an instructions file for Claude Code from zzhan111/multi-agents-browser. It costs 2,205 tokens per session, scanned A, original, MIT.

Project instructions for MultiAgentsBrowser, a browser automation project whose current command and MCP name are ma-browser.

In plain words
What is it for?
Maintaining the browser automation code, navigation recording, portable element selectors, trace export, and the legacy deployment and environment conventions.
Why use it?
They preserve compatibility with the old bb-browser names while explaining the newer naming and completed browser-tracing work.

Instructions file for Claude Code

Written for Claude Code: the file is CLAUDE.md. Also seen: mentions CLAUDE.md; built for openclaw.

This is zzhan111/multi-agents-browser's own configuration. It tells Claude Code how to work on multi-agents-browser itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything multi-agents-browser configures →

Reuse

Borrowing it

Nothing to install: this file belongs to zzhan111/multi-agents-browser. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/zzhan111/multi-agents-browser/main/CLAUDE.md
Clone the repo
git clone --depth 1 https://github.com/zzhan111/multi-agents-browser

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for multi-agents-browser CLAUDE.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/zzhan111/multi-agents-browser/claude-md/github.svg)](https://agentmods.dev/instructions/zzhan111/multi-agents-browser/claude-md)
Your own site
<a href="https://agentmods.dev/instructions/zzhan111/multi-agents-browser/claude-md"><img src="https://agentmods.dev/badge/instructions/zzhan111/multi-agents-browser/claude-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for multi-agents-browser CLAUDE.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/zzhan111/multi-agents-browser/claude-md"><img src="https://agentmods.dev/badge/instructions/zzhan111/multi-agents-browser/claude-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 2,205 This file is loaded in full into every session.
When invoked 2,205 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.02205 $0.02205
Opus 5.5 $0.00882 $0.00882
Sonnet 5.5 $0.00441 $0.00441
Haiku 4.5 $0.00220 $0.00220

Measured 3d ago against content hash ba7553448831, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

multi-agents-browser CLAUDE.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

CLAUDE.md · 145 lines

How it starts

The opening of the file, as written. The whole thing — 145 lines — stays where its author put it; the contents beside it link to each section on GitHub.

CLAUDE.md

经验见 learnings.md

项目改名 → MultiAgentsBrowser / ma-browser(2026-06-10)

本项目由 bb-browser(fork 自 epiral/bb-browser)改名为 MultiAgentsBrowser,CLI/MCP 名 ma-browser,迁到独立仓库 github.com/zzhan111/multi-agents-browser(保留 epiral credit,见 README/LICENSE)。本地工作目录仍是 Z:\Apps\bb-browser。

作为历史兼容层有意保留、改动代码时勿动:

  • BB_* 环境变量(BB_BROWSER_HOME / BB_SESSION_* / BB_TRACE_CAPACITY 等)
  • ~/.bb-browser 数据目录、x-bb-* HTTP 头、bbTabId 协议字段
  • Z:\Apps\bb-browser-tray 部署目录名(exe 已改 ma-browser-tray.exe)
  • epiral/bb-sites 社区适配器仓库链接、CHANGELOG.md(带 legacy 注的历史条目)

新增改动应使用 ma-browser 命名。运维链路细节见用户记忆 project-rename-ma-browser / bb-chain-guard / deployment-after-commit。

Trace Export — 已完成改进(2026-05-18)

以下原 roadmap 项已全部实现,记录于此供历史回溯。当前如需新增改进,请在文末"后续待改进项"追加。

✅ P1: 导航事件录制

  • trace-inject.ts 监听 popstate 和 hashchange,捕获 SPA 内导航
  • cdp-connection.ts 在 Page.frameNavigated(仅主框架)时发出 navigation trace 事件
  • tab-state.ts 的 addTraceNavigation 按 URL 去重,避免 CDP redirect 链产生重复
  • 导出脚本中渲染为 page.goto(url);与 activeTab.url 相同的首条 navigation 会被跳过避免双重 goto

✅ P1: 选择器可移植性

ExportDialog 提供三个模式:

  • Auto:ref → cssSelector → xpath(保留 ma-browser ref 优先级)
  • CSS:cssSelector → xpath,便于在标准 Playwright/Selenium 环境运行
  • XPath:仅用 xpath,跨 DOM 变化更稳定

JS/Playwright 在 XPath 模式下使用 xpath=... 前缀;Python 切换到 By.XPATH。

✅ P2: 步骤间等待机制

ExportDialog 新增"智能等待"开关(默认开启):

  • JS / Playwright:在 click/fill/select/check 前插入 page.waitForSelector(sel) 或 locator(sel).waitFor()
  • Python:插入 wait.until(EC.presence_of_element_located((by, sel)))

✅ P2: 字符串转义

esc() 替换为 q(str) → 返回 JSON.stringify(str),自动处理换行、制表符、Unicode、引号、反斜杠。生成的字符串字面量从单引号迁移到双引号。

✅ P3: Ring Buffer 上限

TRACE_CAPACITY 通过 BB_TRACE_CAPACITY 环境变量配置(默认 1000,最小 100)。缓冲首次写满时打印一次性 warning 到 daemon stderr:

[ma-browser] trace buffer full for tab <shortId> (cap=1000); oldest events will be discarded. Set BB_TRACE_CAPACITY to raise the limit.

后续待改进项

Read the full file on GitHub · 145 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago Changed · +2 lines · +11 tokens per session ba7553448831
  2. 12d ago Changed · +6 lines · +141 tokens per session 91d89d65fe3e
  3. 2mo ago First seen · 137 lines · 2,053 tokens per session scan A ffdf8dc3655f

Subscribe to this mod's changes

multi-agents-browser CLAUDE.md is an instructions file published in the GitHub repository zzhan111/multi-agents-browser (1 stars, last pushed 4d ago), licensed MIT. It adds 2,205 tokens to every session, about $0.0088 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

multi-agents-browser CLAUDE.md compared with instructions from other repositories

multi-agents-browser CLAUDE.md next to 6 instructions from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
multi-agents-browser CLAUDE.mdzzhan111/multi-agents-browserInstructions file14d agoMITA2,205Claude Code
vscode buildNext.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA9,719GitHub Copilot
vscode oss-third-party-notices.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA5,516GitHub Copilot
next.js AGENTS.mdvercel/next.jsInstructions file143kyesterdayMITA7,461Codex, OpenCode
langchain AGENTS.mdlangchain-ai/langchainInstructions file149ktodayMITA4,680Codex, OpenCode
vscode copilot-instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA3,093GitHub Copilot
vscode model-prompts.instructions.mdmicrosoft/vscodeInstructions file195ktodayMITA2,022GitHub Copilot