architecture
Skill1 starsChanged 3 months agoMITView on GitHub
Scan a codebase and produce a structured architecture-map.md — stack, directory structure, database schema, API routes, auth flow, external integrations, and the 5-10 most critical files. Use when joining an unfamiliar repo or when re-loading context on your own project after months of absence (e.g., interview prep).
136 other projects use a version of this.
Adopted by
Most recently taken up by
- thistleknot/skillstheir own version, first seen Nov 8, 2026
- lklimek/claudiustheir own version, first seen Nov 8, 2026
- nisarth/claude-skills-storetheir own version, first seen Nov 8, 2026
- DnsQueen/orcinus-skillstheir own version, first seen Nov 8, 2026
- denormans/claude-code-workflowtheir own version, first seen Nov 8, 2026
- xiaoyangtx996/Searching-skilltheir own version, first seen Nov 8, 2026
Used with
Projects with it also use intelligent-routing, bash-linux and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
SKB3002Skillintelligent-routing
Automatic agent selection and intelligent task routing. Analyzes user requests and automatically selects the best specialist agent(s) without requiring explicit user mentions.
Also in 6 projects that use this
xenitV1Skillbash-linux
Bash/Linux terminal patterns. Critical commands, piping, error handling, scripting. Use when working on macOS or Linux systems.
Also in 8 projects that use this
xenitV1Skillred-team-tactics
Red team tactics principles based on MITRE ATT&CK. Attack phases, detection evasion, reporting.
Also in 8 projects that use this
SKB3002Skillnextjs-react-expert
React and Next.js performance optimization from Vercel Engineering. Use when building React components, optimizing performance, eliminating waterfalls, reducing bundle size, reviewing code for performance issues, or implementing server/client-side optimizations.
Also in 3 projects that use this
- +8 more from xenitV1
Other versions136 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 136
- anthropics/knowledge-work-plugins★ 35ksame name
- iOfficeAI/AionUi★ 34ksame name
- vudovn/ag-kit★ 8.2ksame name
- vudovn/antigravity-kit★ 8.2ksame name
- nativewind/nativewind★ 8.1ksame name
- PaulWoitaschek/Voice★ 3.3ksame name
- wellwelwel/poku★ 1.2ksame name
- Alwurts/simple-ai★ 755same name
- patrickjaja/claude-desktop-extra★ 734same name
- ktnyt/cclsp★ 673same name
126 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository17 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- code-reviewSkill
- commandsSkill
- conventionsSkill
- debugSkill
- decisionSkill
- explainSkill
- isolateSkill
- issueSkill
- journeysSkill
- onboardSkill
- quick-workSkill
- safe-commitSkill
- safe-pushSkill
- scaffoldSkill
- todoSkill
- workSkill
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 3 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 118 edited versions we read keep these.
3
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
Run, in parallel where possible:
- Very specific: line 107
Read imports across src/ to find third-party services:
- Very specific: line 133
Write the file in this exact format.
- Distinctive: line 224
Don't fabricate. If you couldn't detect something from the code, mark it as TBD.
- Distinctive: line 225
Don't write a 30-page wall of text.
- Very specific: line 226
Don't overwrite an existing architecture-map.md without warning.
- Very specific: line 227
Don't try to interpret WHY decisions were made — that's /decision's job.
- Very specific: line 228
Don't add Co-Authored-By: Claude to the file.
“Common” is measured: kept by at least 6 in 10 of the 118 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
/architecture-map — Codebase architecture cheat sheet
You are Claude. The user wants a structured map of an entire codebase so they can re-load context fast or hand it to someone else (interviewer, new team member).
This is the "30,000-foot view" deliverable, complementing /conventions (which captures style patterns) — together they give you both what the code looks like (conventions) and what the code does (architecture).
Argument (optional): $ARGUMENTS may be an output path like .claude/architecture-map.md. If empty, default to .claude/architecture-map.md.
Phase 1 — Detect project shape
Run, in parallel where possible:
# Project root identification
test -f package.json && echo "node project"
test -f Cargo.toml && echo "rust project"
test -f pyproject.toml && echo "python project"
test -f go.mod && echo "go project"
# Directory tree (depth 3, skip noise)
tree -L 3 -I 'node_modules|.next|.git|.swc|dist|build|target|__pycache__|.venv' . 2>/dev/null | head -60
# Stack signal
test -f package.json && cat package.json | jq '{name, version, dependencies: (.dependencies // {}), scripts: (.scripts // {})}'
test -f tsconfig.json && cat tsconfig.json | jq '.compilerOptions | {target, module, strict, paths}'Phase 2 — Detect tech stack details
Based on what's in the dependencies (or equivalent), enrich:
| Signal in deps | Infer |
next | Framework: Next.js + likely TypeScript |
@supabase/supabase-js | DB: Supabase (Postgres + Auth + Storage) |
prisma, @prisma/client | ORM: Prisma + likely Postgres |
drizzle-orm | ORM: Drizzle |
@nestjs/common | Framework: NestJS |
express, fastify, hono | Backend framework |
react-native, expo | Mobile: React Native |
react-hook-form + zod | Forms with validation |
posthog-js, @posthog/node | Analytics: PostHog |
@lemonsqueezy/lemonsqueezy.js | Payments: Lemon Squeezy |
resend | Email: Resend |
bullmq | Queues: BullMQ + Redis |
vitest, jest | Testing |
Be honest about uncertainty: if you can't tell from deps alone, mark it as "TBD — verify by reading [file]".
Phase 3 — Detect database schema
In order, check for:
- Prisma:
schema.prisma→ read models - Drizzle:
**/schema.tswithpgTable/mysqlTable→ read tables - Supabase migrations:
supabase/migrations/*.sql→ read all in chronological order - Raw SQL migrations:
migrations/*.sql,db/migrations/, etc. - ORM-less: skip and mark "no schema definition found"
For each table/model, capture:
- Name
- Columns (primary key, FKs, important columns only — not exhaustive)
- Foreign key relationships
- RLS policies (if Supabase)
- Indexes (composite ones especially)
Phase 4 — Detect API surface
Find HTTP route definitions:
# Next.js App Router
find src/app -name "route.ts" -o -name "route.tsx" 2>/dev/null | head -20
# Express/Fastify
grep -rn "app\.\(get\|post\|put\|delete\|patch\)" src/ 2>/dev/null | head -20
# NestJS controllers
grep -rln "@Controller(" src/ 2>/dev/null | head -10For each route found, capture the HTTP verb, path, and a 1-line description of what it does (from comments, function name, or inferring from code).
Phase 5 — Detect auth pattern
Look for:
grep -rn "createServerClient\|createBrowserClient\|signInWithPassword\|signInWithOAuth" src/ 2>/dev/null | head -10
grep -rn "JsonWebToken\|jsonwebtoken\|jwt\." src/ 2>/dev/null | head -10
grep -rn "passport\|@nestjs/passport" src/ 2>/dev/null | head -10Identify the pattern:
- Supabase Auth (PKCE? OAuth providers?)
- NextAuth / Auth.js
- Custom JWT
- Passport (Express/Nest)
- None / public
Phase 6 — Detect external integrations
Read imports across src/ to find third-party services:
grep -rh "^import.*from \"[^@.]" src/ 2>/dev/null | sed 's/.*from "\([^"]*\)".*/\1/' | sort -u | head -30Filter to known service integrations (Lemon Squeezy, Stripe, Resend, PostHog, Telegram, Twilio, AWS, GCP, etc.). For each, note where it's used (which file).
Phase 7 — Identify 5-10 critical files
These are files the user will reference often when explaining the system. Pick based on:
- Auth handler (most often
lib/auth.tsorapp/auth/route.ts) - Payment webhook handler (often
app/api/webhooks/[provider]/route.ts) - Core business logic (often
lib/calculations.ts,services/, or a domain-specific name) - Database client wrapper (often
lib/db.tsorlib/supabase.ts) - Email/notification dispatchers
- Main layout / providers tree (
app/layout.tsx) - Main config file (next.config, vercel.json, etc.)
For each, provide:
- Path
- 1-sentence description
- Why it's critical (what would break if you got it wrong)
Phase 8 — Build the output
Write the file in this exact format. Use <placeholder> only where info is genuinely uncertain — never fabricate.
# Architecture map — <project name>
*Generated by `/architecture-map` on <date>. Re-run when the codebase changes substantially.*
## 1. Elevator pitch (2 sentences)
<inferred from package.json description, README, and code structure — be conservative>
## 2. Tech stack
| Capa | Tecnología | Versión | Source of truth |
|---|---|---|---|
| <as detected> | <as detected> | <from package.json> | <file where it lives> |
## 3. Directory structure
\`\`\`
<tree output>
\`\`\`
### Carpetas clave
- `<dir>` → <what lives here>
- ...
## 4. Database
### Tables
- **`<table>`** — <one-line purpose>
- Columns: <key cols>
- FKs: <relationships>
- Indexes: <composite ones>
- RLS: <yes/no, brief>
### Schema decisions worth noting
- <inferred patterns>
## 5. API surface
| Method | Path | Purpose |
|---|---|---|
| <as found> | <as found> | <as inferred> |
## 6. Auth
**Pattern:** <detected pattern>
**Flow (high level):** <inferred steps>
**Critical file:** <path>
## 7. External integrations
| Service | Used in | Purpose |
|---|---|---|
| <as detected> | <file path> | <purpose> |
## 8. Los 5-10 archivos críticos
| # | Path | Por qué importa |
|---|---|---|
| 1 | <path> | <reason> |
| ... | ... | ... |
## 9. ⚠️ Cosas que NO pude verificar desde el código
> Estos huecos requieren tu memoria o experiencia con el proyecto. Llenalos manualmente.
- <list items where you marked TBD>
- ...
## 10. Cosas que sugiero releer ANTES de una entrevista o handoff
- <list of files that would benefit from deeper familiarity>
- ...Phase 9 — Save + hand off
Save to the path provided in $ARGUMENTS or default .claude/architecture-map.md.
Output:
"Architecture map saved to
<path>. Reviewed:<N>files,<M>tables,<K>API routes detected.Honest gaps (marked in section 9):
<X>items where the code didn't tell me enough — you'll need to fill those from memory.Want me to also run
/conventionsso you have both the architecture (what the code DOES) and the conventions (what it LOOKS LIKE)?"
What NOT to do
- Don't fabricate. If you couldn't detect something from the code, mark it as TBD.
- Don't write a 30-page wall of text. Keep each section tight — this is a cheat sheet, not documentation.
- Don't overwrite an existing
architecture-map.mdwithout warning. If it exists, ask "overwrite, or save as architecture-map.v2.md?" - Don't try to interpret WHY decisions were made — that's
/decision's job. This command only captures WHAT exists. - Don't add
Co-Authored-By: Claudeto the file.
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.

