cortex-ai
CLAUDE.md1 starsChanged 6 months agoMITView on GitHub
Stack: <STACK> Status: <STATUS> Replace the three placeholders above after cloning. Everything below is ready to use. What this project does: [One sentence. What problem does it solve for whom?] What it does NOT do: [Explicit scope boundary — prevents feature creep] Primary consumers: [Who uses this? Internal team / external users / downstream systems] [Add project-specific architecture notes here — key modules, data flow, critical paths] Language / runtime: [e.g., Python 3.12, Node 20, TypeScript strict] Package management: [e.g.,…
In this repository4 other files it gives its agents.
- adr-writerSkill
- commit-styleSkill
- data-contractsSkill
- sql-reviewSkill
The file
We split this CLAUDE.md into the rules it gives an agent
9 rules. About 0 are common, 2 are distinctive, and 7 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
7
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
- Very specific: line 22
Plan before coding: Use /plan for anything non-trivial.
- Very specific: line 24
For vague requests, invoke
@product-managerfirst: No implementation starts without testable acceptance criteria. - Very specific: line 25
ADR for architectural decisions: If a decision is hard to reverse, or future engineers will wonder why it was made, use /adr.
- Distinctive: line 69
Use these agents proactively.
- Very specific: line 120
Run just init for first-time setup (installs deps, pre-commit hooks, builds Graphify graph)
- Very specific: line 121
Run just format before committing — also runs automatically via pre-commit hooks
- Very specific: line 122
Run just lint to check all linters without auto-fixing
- Very specific: line 123
Run just health to invoke tech-debt-hunter and generate a codebase health report
- Distinctive: line 135
Read before editing: Always read a file before modifying it.
≈ “Common” is an estimate: at least 1 in 5 of the 26,980 CLAUDE.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
Project: <PROJECT_NAME>
Stack:
<STACK>Status:<STATUS>
Replace the three placeholders above after cloning. Everything below is ready to use.
Project Identity
What this project does: [One sentence. What problem does it solve for whom?]
What it does NOT do: [Explicit scope boundary — prevents feature creep]
Primary consumers: [Who uses this? Internal team / external users / downstream systems]
Critical Rules
- Plan before coding. Use
/planfor anything non-trivial. Coding without a plan produces code that solves the wrong problem correctly. - For complex tasks, invoke
@tech-leadfirst. It decomposes the task, identifies required agents, and parallelizes independent work. Don't route multi-domain problems to a single agent. - For vague requests, invoke
@product-managerfirst. No implementation starts without testable acceptance criteria. - ADR for architectural decisions. If a decision is hard to reverse, or future engineers will wonder why it was made, use
/adr. The code does not explain the tradeoffs. - No redundant comments. Comments explain WHY — constraints, workarounds, non-obvious invariants. Comments that restate what the code does are noise and will be flagged in review.
- Tests before merging. New behavior requires tests. Refactoring requires existing tests. No exceptions.
- English in code, commits, and comments. This codebase is public-facing. All identifiers, commit messages, and inline comments must be in English.
Architecture
- Full diagram:
docs/architecture.md - Knowledge graph (read before broad searches):
graphify-out/GRAPH_REPORT.md - Decision log:
docs/adr/ - Current session state:
CONTEXT.md
[Add project-specific architecture notes here — key modules, data flow, critical paths]
Conventions
Language / runtime: [e.g., Python 3.12, Node 20, TypeScript strict] Package management: [e.g., pip + uv, npm, poetry] Formatting: [e.g., ruff + black for Python, prettier for TS/JSON/YAML] Linting: [e.g., ruff, eslint]
Branch naming:
feat/<ticket>-<short-description>fix/<ticket>-<description>hotfix/<ticket>-<description>(production only)docs/<description>
Commit style: Conventional Commits — see .claude/skills/commit-style/SKILL.md
PR requirements:
- Self-reviewed before requesting review
- No 🔴 BLOCKER issues from
code-reviewer - Tests added for new behavior
- CHANGELOG.md updated if user-facing change
- ADR created if architectural decision was made
Active Subagents
Use these agents proactively. They are specialized and will produce better output than asking the general Claude session.
Leadership Layer (start here for complex work)
| Task | Agent | Command |
| Complex multi-domain tasks — decompose + delegate | tech-lead | /plan |
| Vague requests — clarify requirements + acceptance criteria | product-manager | — |
Execution Layer
| Task | Agent | Command |
| Feature design, system decomposition | architect | /plan |
| Code review, PR quality gate | code-reviewer | /review, /ship |
| Bug investigation | debugger | /debug |
| Code structure improvement | refactor | /refactor |
| Writing tests | test-writer | — |
| Data pipelines, SQL, dbt | data-engineer | — |
| ML experiments, model design | ml-engineer | — |
| React, TypeScript, UI | frontend | — |
| APIs, services, auth | backend | — |
| Security review | security-auditor | — |
| Performance investigation | performance | — |
| Documentation | docs-writer | — |
| CI/CD, Docker, IaC, observability | devops | — |
Quality & Meta Layer
| Task | Agent | Command |
| Full codebase debt audit | tech-debt-hunter | /audit |
| Pre-release validation + release notes | release-manager | /release |
| Technology research + comparison | research-analyst | /research |
| Rewrite or improve underperforming agents | prompt-engineer | — |
Second Brain
Obsidian vault: ~/vault/projects/<project-name>/
- Session logs: synced by
/sync-vault - Decision copies:
decisions/(mirrorsdocs/adr/)
Setup guide: docs/obsidian-vault-setup.md
Local Development
- Run
just initfor first-time setup (installs deps, pre-commit hooks, builds Graphify graph) - Run
just formatbefore committing — also runs automatically via pre-commit hooks - Run
just lintto check all linters without auto-fixing - Run
just healthto invoketech-debt-hunterand generate a codebase health report - Pre-commit hooks enforce: formatting (ruff/prettier/sqlfluff), no secrets (gitleaks), Conventional Commits (commitlint), markdown consistency (markdownlint)
Tool Usage Rules
- Before broad file searches → read
graphify-out/GRAPH_REPORT.mdfor architecture context. - For "where is X defined?" →
graphify query "X"is faster and smarter than grep. - For cross-module relationships →
graphify path "ModuleA" "ModuleB"orgraphify explain "concept". - After modifying source files → run
graphify update .to keep the graph current. - For SQL questions → apply the
sql-reviewskill before proposing changes. - Read before editing. Always read a file before modifying it. Never assume structure.
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.

