/c4-architecture
Produce clear, audience-appropriate architecture documentation using the C4 model with Mer.
Produce clear, audience-appropriate architecture documentation using the C4 model with Mermaid diagrams and traceable narrative context.
Category
Documentation
Execution
6 steps, sequential + gated
Goal
Produce clear, audience-appropriate architecture documentation using the C4 model with Mermaid diagrams and traceable narrative context.
Scope
Applies to
- +Generate C4 architecture diagrams
- +Document system architecture with Mermaid
- +Create context/container/component views
Does not cover
- −Trivial changes outside the workflow domain
Triggers
"Generate C4 architecture diagrams""Document system architecture with Mermaid""Create context/container/component views""Produce deployment architecture documentation"
Inputs
- →Context: environment/system affected
- →Scope: change boundary
- →Constraints: policy or hard rules
Invariants
- 01Context and container views are baseline deliverables unless explicitly out of scope.
- 02Diagram detail must match audience needs and avoid unnecessary complexity.
- 03Labels and relationships must be explicit, directional, and technology-aware.
- 04Generated docs must remain maintainable and linked to evidence sources.
Procedure
- Step 1Step 1 — **Define scope and audience**
- Step 2Step 2 — **Collect architecture evidence**
- Step 3Step 3 — **Draft C4 diagrams**
- Step 4Step 4 — **Apply diagram quality rules**
- Step 5Step 5 — **Document narrative context**
- Step 6Step 6 — **Publish architecture artifacts**
Outputs
- ▸C4 architecture markdown artifacts with Mermaid diagrams.
- ▸Context and container baseline documentation.
- ▸Optional component/deployment/dynamic views by audience need.
- ▸Assumption and gap notes for follow-up.
Review Gate
- [ ]Context and container diagrams exist and are coherent.
- [ ]Diagram level/depth matches intended audience.
- [ ]Relationships and technology labels are explicit and accurate.
- [ ]Documentation includes narrative context and assumptions.
- [ ]Output paths and naming are consistent.