You are an expert AI software architect creating a production-grade AGENTS.md.
Your output must be style-locked to the owner workflow below, not a generic template. If repository facts conflict with the style rules, keep the style rules and adapt only factual project details.
Analyze this repository and generate a complete AGENTS.md for AI coding agents that preserves:
- Node package manager preference
- Git workflow and commit style
- Mandatory post-task checklist (typecheck + GitOps + stage/commit/push)
- Operational constraints and quality bar
- Always use
pnpmfor package and script commands. - Never start the dev server locally.
- Do not run build or lint unless explicitly requested.
- Always type-check after any code change and fix all TypeScript errors.
- Run:
pnpm exec tsc --noEmitand resolve all errors. - Execute post-task GitOps checklist from
.github/gitops.mdbefore handoff. - Stage, commit, and push every completed task.
- Commit format must enforce:
git commit -m "feat: <6–7 word summary>"as canonical example.
- Use git CLI only.
- Never use
git commit -a. - Stage explicitly with
git add <file>. - Include commit type guidance:
feat,fix,docs,style,refactor,perf,test. - Keep commit summaries short (~6–7 words).
- Push after commit.
- When asked to create a PR, target
devby default. - Ensure clean typecheck first.
- Build only when PR creation is explicitly requested.
- Use project PR template if present (ex:
.github/pr-template.md). - Use a concise title/body grounded in branch commits.
- If repository references Linear workflow, require MCP-based Linear operations and context lookup first.
- Use this prompt's owner rules as default policy baseline in every generated output.
- If some project facts are missing, keep owner rules intact and fill unknowns conservatively (state "verify in repo" where needed).
Read and infer from relevant files (only those that exist), including:
package.json, lockfiles, workspace filesREADME.md- ts/js config, framework config, lint/format config
- infra/deploy config (
Dockerfile, Firebase/Vercel/etc.) - env examples and runtime configuration
.github/*workflows/templates/checklists (especially gitops docs)
Inspect real folder structure (not assumptions).
Determine:
- app type and domain purpose
- frontend/backend stack
- auth and authorization model
- data/database access patterns
- state management and API organization
- service integrations and initialization points
Capture:
- secret handling rules
- service account/API key boundaries
- auth checks before data writes
- risky areas agents must not break
Generate a practical, concise, agent-focused document. Prefer prescriptive language ("Always", "Never", "Do not") for guardrails.
# AGENTS.md- Intro line describing this as main guidance for AI agents in this repo
## Overview## Golden Rules## Linear MCP (Mandatory)(only if project uses Linear; otherwise state "Not used in this repo")## Always After Changes (Mandatory)## Development Constraints## Tech Stack## Architecture## Code Style## Git Workflow## Pull Request Guidelines (On Request Only)## Project Structure## Core Features## Development Patterns## Testing & Debugging## Environment Variables## Performance
- Use clean markdown headings and short bullets.
- Keep instructions explicit and executable.
- Avoid vague wording and generic filler.
- Use repository-specific facts; do not invent tools or workflows.
- Include concrete commands (
pnpm ...,git ...) where relevant. - Ensure all mandatory owner rules are represented clearly.
- Make the final output look like a ready-to-use repo
AGENTS.md, not a meta prompt.
- Output only the final markdown content for
AGENTS.md. - Do not output analysis, reasoning, or preface text.