Reference
AI Coding Assistants Integration
Every scaffolded project ships with AGENTS.md and CLAUDE.md — project-aware context files that keep Cursor, Claude Code, and Copilot on-convention from the first prompt.
Why it matters
AI assistants produce dramatically better code when they know your stack, folder rules, and boilerplate patterns. CEM generates both context files with your exact choices baked in (ORM, validator, auth delivery, etc.) — so the assistant never has to guess.
AGENTS.md
A concise, high-level rulebook placed in the project root:
- Records chosen stack parts (e.g. Mongoose + Zod + Cookies).
- Enforces the modular folder layout under
src/app/modules/. - Enforces the
<name>.middleware.tsnaming convention. - Documents every helper command for adding/removing modules, middlewares, and env vars.
CLAUDE.md
A deeper reference customised to your exact scaffold choices — the assistant can copy directly from these patterns:
- Controller boilerplate — full pattern using
catchAsyncandsendResponse. - Model boilerplate — Mongoose schema types, Prisma client singleton, or Drizzle schema tables depending on your ORM.
- Validation boilerplate — Zod or Joi syntax, matched to your choice.
- Route boilerplate — includes automatic router wiring and optional role-based
auth()guards.
Where they live
my-api/
├── AGENTS.md # concise rules for any AI agent
├── CLAUDE.md # deep boilerplate context
└── ...