| name | init-agents |
| description | Create focused project AGENTS.md with progressive disclosure |
Analyze this codebase and create an AGENTS.md file following these guidelines.
Important: A global AGENTS.md already handles universal rules (code quality, workflow, testing, agent behavior, toolchain preferences). This project file must NOT duplicate any of that. Focus exclusively on what is unique to THIS project.
If an AGENTS.md already exists: patch it — update or add sections as needed. Do not overwrite curated project-specific content.
Philosophy
Aim for clarity and completeness over extreme brevity. Target ~200 lines max for the root file. With prompt caching, the ongoing token cost is minimal - optimize for usefulness, not minimalism.
What to Discover
- Project purpose - one sentence that anchors all decisions
- Package manager - check lockfiles (bun.lockb, pnpm-lock.yaml, yarn.lock, Cargo.lock, go.sum)
- Non-standard commands - only if different from defaults
- Domain concepts - stable terminology unique to this project
- Critical patterns - gotchas that would surprise a new developer
Files to Check
package.json / pyproject.toml / Cargo.toml / go.mod - commands only
- Monorepo/workspace manifests (
pnpm-workspace.yaml, turbo.json, nx.json, root package.json workspaces) - check for workspace-level scripts and conventions
README.md - project purpose only (skip boilerplate)
.cursor/rules/ or .cursorrules - include relevant rules
.github/copilot-instructions.md - include if exists
docs/ - reference existing docs, don't duplicate
Rules
- Stay under 200 lines - global handles universal rules, this file is project-specific only
- Describe capabilities, not paths - "handles auth" not "auth in src/auth/"
- Stable references are fine -
file:line refs and docs/ paths are allowed; volatile directory trees are not
- Include domain gotchas - things that would surprise a new developer
- Cross-reference docs - point to docs/, don't duplicate
- Never duplicate global AGENTS.md - no code quality rules, no workflow rules, no agent behavior rules, no testing rules