From forge
Lock architecture before building. Queries memory bank for past decisions, produces a locked architecture doc with data flow, API contracts, edge cases, and test strategy. Called by /think for feature and epic tasks. Use when planning architecture, designing systems, or before building features — triggered by 'plan the architecture', 'design the system', 'how should we structure'.
How this skill is triggered — by the user, by Claude, or both
Slash command
/forge:architectThis skill is limited to the following tools:
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Never write implementation code — architecture only. You produce a locked architecture document that /build consumes directly. All decisions, no code.
Never write implementation code — architecture only. You produce a locked architecture document that /build consumes directly. All decisions, no code.
Shared protocols apply. See
skills/shared/rules.mdfor evidence-before-claims, scope discipline, artifact integrity.
Run /memory-recall with the current task context. If relevant entries found, treat as constraints/prior art and note anti-patterns to avoid. If nothing relevant, proceed silently.
Check ls .forge/brainstorm/*.md 2>/dev/null | head -1. If found, extract selected approach, rejected alternatives, constraints, and trade-offs to avoid re-exploring rejected paths. If absent, proceed.
Before designing, understand what exists: project structure, existing patterns (naming, architecture, tests), APIs, data models, config files, tech stack, and dependencies.
Write a structured architecture document. This is the contract /build must follow.
Produced by FORGE /architect. Changes require re-running /architect.
[1-2 sentences: what and why]
[How data moves. Text diagrams if helpful.] Input -> [Step 1] -> [Step 2] -> Output
| Component | Responsibility | Creates/Modifies |
|---|
[New packages, services, or infrastructure required]
[Auth, data handling, input validation, OWASP relevance]
[What was explicitly decided NOT to build now, and why]
Create directory and save: mkdir -p .forge/architecture then write to .forge/architecture/[task-name-slugified].md.
Verify the file was written:
head -5 .forge/architecture/[task-name-slugified].md
Output must include the file path and ## Status: LOCKED line. Show evidence before claiming completion. Present the full doc to the user:
FORGE /architect -> Architecture locked.
Key decisions: [list top 3]
Files to create/modify: [count] | Test coverage: [summary]
Ready for /build. Override any decision? (or say "build" to proceed)
Wait for user approval. If they request changes, update the doc and re-present.
Run /memory-remember to store key architectural decisions. After storing, confirm: FORGE /architect — Decisions stored to memory bank: [list decisions].
See
skills/shared/compliance-telemetry.mdfor the full protocol. Log violations viascripts/compliance-log.sh.
| rule_key | severity | trigger |
|---|---|---|
implementation-in-arch | major | Implementation code written during architecture phase |
memory-not-checked | minor | Memory bank not checked before designing |
missing-edge-case-handling | major | Edge cases missing handling strategies |
missing-api-errors | major | APIs missing defined error cases |
Telemetry: bash scripts/telemetry.sh architect completed then bash scripts/telemetry.sh phase-transition architect
Error handling: If memory recall fails, proceed without and note "No prior decisions found." If codebase scanning fails, ask the user to narrow scope. Never produce an architecture doc based on assumptions when evidence is unavailable.
See
skills/shared/workflow-routing.mdfor the full routing table. After /architect, the next step is/build.
Guides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.
npx claudepluginhub bakirp/forge --plugin forge