keynobi
AGENTS.md201 starsChanged 7 months agoMITView on GitHub
Keynobi is a macOS companion app for Android development: Gradle builds, logcat, devices, UI hierarchy, and an MCP server for AI clients. Tauri 2 (Rust, tokio) backend, SolidJS + TypeScript + Vite frontend, ts-rs for IPC types, rmcp for MCP. Each reference doc ends with Known Gaps: rules the code does not meet yet. Do not copy a known gap into new code. Run the checks for what you changed; all must pass. Update the reference doc that owns what…
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 35,266 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.
- .claude/CLAUDE.mdCLAUDE.md
- .cursor/rules/karpathy-guidelines.mdcCursor rule
- keynobiSkill
The file
We split this AGENTS.md into the rules it gives an agent
5 rules. About 0 are common, 4 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈4
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
- could be automatic: a setting could enforce it
- Distinctive: line 41
Do not mention external documents or tool names in code, comments, or branch names.
- Distinctive: line 45
Run the checks for what you changed.
- Distinctive: line 55
Update the reference doc that owns what you changed (see Where to Look).
- Very specific: line 62
Never commit docs/ (local planning files), secrets, or machine-specific paths.
- Distinctive: line 63
Do not bump versions, tag, or run release scripts unless asked.
≈ “Common” is an estimate: at least 1 in 5 of the 45,344 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
AGENTS.md
Keynobi is a macOS companion app for Android development: Gradle builds, logcat, devices, UI hierarchy, and an MCP server for AI clients. Tauri 2 (Rust, tokio) backend, SolidJS + TypeScript + Vite frontend, ts-rs for IPC types, rmcp for MCP.
Commands
npm ci # install
npm run tauri dev # run the app (first Rust build takes minutes)
npm run dev:web # frontend only, against the mock backend
npm run generate:bindings # after changing Rust models; commit src/bindings/Where to Look
| Task | Read |
| Any change | references/BEST_PRACTICES.md, references/CODE_PATTERN.md |
| Build, logcat, devices, layout, settings | references/DOMAIN_PATTERNS.md |
| MCP tools, prompts, resources | references/MCP_SERVER.md |
| UI components, styling, accessibility | references/DESIGN_SYSTEM.md |
| User-visible behavior, shortcuts | references/USER_MANUAL.md |
Each reference doc ends with Known Gaps: rules the code does not meet yet. Do not copy a known gap into new code.
Key Rules
- Layering: components → stores/services →
src/lib/tauri-api.ts→ Tauri commands → Rust services. Onlytauri-api.tscallsinvoke; commands validate and delegate. - IPC contract: a command change updates the Rust handler,
generate_handler!inlib.rs, thetauri-api.tswrapper, and the mock backend together. After changing Rust models, runnpm run generate:bindingsandnpm run generate:ipc-fixtures; import IPC types from@/bindingsand never edit generated files. - One implementation per behavior: Tauri commands and MCP tools call the same service function. Never copy logic into
mcp_server.rs. - Process model:
keynobi --mcpattaches to the running app when it can (the app serves the session on its own state) and otherwise runs standalone with its own state, which the GUI does not see. Seereferences/MCP_SERVER.md§ Modes. - Untrusted input: validate identifiers with
utils/validation.rsand paths withutils/path.rs(canonicalized, never rawstarts_with). Arguments toadb shellare re-parsed by the device shell. - Rust: no
unwrap()in production code; new commands returnResult<T, AppError>; never hold a Mutex across.await; every growing collection has a named cap. - Frontend: register shortcuts with
registerKeyAndAction()inApp.tsx; build UI from@/components/uiprimitives and theme tokens. - User data: tests must never read or write
~/.keynobi. Unit tests get a temp data directory automatically (cfg(test)insettings_manager); integration tests must calltests/common::isolate_data_dir()first. CI fails if a test creates~/.keynobi.
Code Style
- Match the surrounding code. Formatting is enforced by Prettier and
rustfmt. - Comment only when the code cannot explain itself; keep comments short.
- Do not mention external documents or tool names in code, comments, or branch names.
Before You Finish
Run the checks for what you changed; all must pass.
npm run lint && npm run format:check && npm run typescript:check && npm test
npm run test:ds # design system, shared styles, or tokens
npm run test:e2e # user flows or IPC
cd src-tauri && cargo fmt --check && cargo clippy --all-targets -- -D warnings && cargo test --lib --tests
cd src-tauri && cargo clippy --features telemetry -- -D warnings && cargo test --lib --tests --features telemetry # telemetry codeUpdate the reference doc that owns what you changed (see Where to Look). Remove a Known Gaps entry when you fix it; add one when you knowingly leave a rule unmet.
Git and PRs
- Branches:
<type>/<short-kebab-slug>, for examplefix/logcat-reconnect. - Commits and PR titles: Conventional Commits,
type(scope): summary. Types:feat,fix,docs,refactor,test,ci,chore,style,perf. The changelog is generated from them. - Fill in
.github/pull_request_template.md. Keep PRs to one concern. - Never commit
docs/(local planning files), secrets, or machine-specific paths. - Do not bump versions, tag, or run release scripts unless asked.
Security
Report vulnerabilities privately (see SECURITY.md), never in a public issue or PR.
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.

