browser-controller
AGENTS.md9 starsChanged 12 days agoMITView on GitHub
MCP clients connect to a local daemon that validates calls and routes them over authenticated WebSockets to the paired extension. Keep schemas under mcp-server/src/tools/, registration in mcp-server/src/tools/registry.ts, and browser behavior in matching handlers. Preserve timeouts and tab ownership. Pairing grants trusted clients powerful, unsandboxed browser control. Never commit secrets/private configuration; report vulnerabilities through SECURITY.md. Vault fill never clicks Submit, though site handlers may submit on input. Use ES modules, two spaces, semicolons, and nearby naming. Keep tools and handlers focused;…
- Deletes or force-pushes
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 31,774 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository3 other files it gives its agents.
- agent-config/AGENTS.mdAGENTS.md
- .cursor/rules/project.mdcCursor rule
- llms.txtllms.txt
The file
We split this AGENTS.md into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 33
Use scoped Conventional Commits, e.g.
≈ “Common” is an estimate: at least 1 in 5 of the 40,246 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Repository Guidelines
Project Structure
mcp-server/src/holds the TypeScript MCP server, daemon/bridge, tools, and credential vault.extension/is Chrome MV3: background modules wire events;dispatch/routes calls,lib/holds shared state, handlers implement browser behavior.tests/has Vitest suites and Chrome mocks;scripts/has daemon, pairing, and smoke utilities;scripts/pages/has fixtures.agent-config/,specs/,docs/, anddeploy/contain editor setup, feature designs, project/audit docs, and supervisor examples.
Architecture and Security
MCP clients connect to a local daemon that validates calls and routes them over authenticated WebSockets to the paired extension. Keep schemas under mcp-server/src/tools/, registration in mcp-server/src/tools/registry.ts, and browser behavior in matching handlers. Preserve timeouts and tab ownership. Pairing grants trusted clients powerful, unsandboxed browser control. Never commit secrets/private configuration; report vulnerabilities through SECURITY.md. Vault fill never clicks Submit, though site handlers may submit on input.
Build, Test, and Development
npm ciinstalls locked dependencies (Node.js 22.18+, 24.11+, or 26+);npm run devwatches TypeScript;npm run buildcompiles tomcp-server/dist/.npm testruns Vitest; focus one withnpm test -- tests/v3-mock.test.ts.- CI runs
npm run lint,npm run typecheck,npm run build,npm run test:coverage,npm run security:audit,npm run context:lint,npm run context:measure, andnpm run arch:checkon the declared minimum and latest Node 22, 24, and 26 releases. Run the same set before calling a change done. npm run smoke:real-chromerequires a built server and enrolled extension; it restarts the daemon and uses the normal Chrome profile.- Code-graph indexes are machine-local output:
.codebase-memory/andgraphify-out/stay uncommitted, and a clone that still tracks the former clears it once withrm -rf .codebase-memorybefore pulling past8777e78. The tool rebuilds the index on the next run. - A release is an annotated tag
vX.Y.Zon the commit that sets that version, with notes read from the tagged tree'sCHANGELOG.mdsection, never from the working tree.
Style and Testing
Use ES modules, two spaces, semicolons, and nearby naming. Keep tools and handlers focused; Vitest files end in *.test.ts. Add regressions for protocol, tab ownership, timeouts, and credential redaction; prefer isolated tests. Use real-Chrome smoke checks when needed. docs/lessons.md holds the four engineering laws this codebase learned from shipped defects — read it before adding a parallel config table, an alias, or a comment that claims behavior the code does not have.
Spec Kit, Evidence, and Agent Workflow
Spec Kit is configured under .specify/; Codex skills are under .agents/skills/. Use $speckit-specify, $speckit-plan, $speckit-tasks, and $speckit-implement; the workflow pauses for spec and plan review. Root constitution.md is proposed pending gates A–D and token tests; .specify/memory/constitution.md mirrors that proposal and is not adopted policy. Check the mirror's source fingerprint against the root file before relying on it. Requirements define intended behavior; source shows current implementation; tests/runtime cover exercised paths. Treat Graphify and codebase-memory as maps; verify claims against source, configuration, and tests. Scope delegated work; findings are evidence, not approval; independently review behavior/security changes.
Commits and Pull Requests
Use scoped Conventional Commits, e.g. refactor(vault): ... or docs(audit): .... PRs describe behavior, scope, and checks; note protocol/security changes, include UI screenshots, and link issues. Open an issue before larger changes, as README.md requests.
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.

