By bitsmuggler
Analyze your codebase to generate C4 architecture models in Structurizr DSL for system context, container, component, and deployment diagrams. Validate via Docker CLI and export renders to PlantUML, Mermaid, PNG, or SVG images.
npx claudepluginhub bitsmuggler/c4-skillA Claude Code plugin that analyses software architecture and generates C4 model using the Structurizr DSL.
workspace.dsl files following C4 model conventionsc4-skill/
├── .claude-plugin/
│ └── plugin.json # Plugin metadata
├── commands/
│ └── c4.md # /c4 slash command
├── skills/
│ └── c4-architecture/
│ ├── SKILL.md # Skill definition
│ ├── references/
│ │ └── structurizr-dsl-reference.md # Full DSL syntax reference
│ ├── examples/
│ │ └── example-workspace.dsl # Sample bookstore workspace
│ └── scripts/
│ └── export-diagrams.sh # Structurizr vNext export wrapper
├── .gitignore
└── README.md
git clone git@github.com:bitsmuggler/c4-skill.git ~/.claude/c4-skill
mkdir -p ~/.claude/commands
ln -s ~/.claude/c4-skill/commands/c4.md ~/.claude/commands/c4.md
docker pull structurizr/structurizr
docker pull plantuml/plantuml
Restart Claude Code (or open a new VS Code window). The /c4 command is now available globally across all projects.
/c4
Invoke the /c4 command to analyse the current project and generate a C4 model.
After generating the workspace.dsl, Claude will ask if you want to render diagram images. If you say yes, it exports to PlantUML and renders to PNG - all via Docker.
You can also run the export script manually:
bash skills/c4-architecture/scripts/export-diagrams.sh workspace.dsl plantuml/c4plantuml ./diagrams
| Level | View | Description |
|---|---|---|
| 0 | System Landscape | All systems in the enterprise |
| 1 | System Context | One system + its interactions |
| 2 | Container | Internal structure of a system |
| 3 | Component | Internal structure of a container |
| - | Deployment | Infrastructure mapping |
| - | Dynamic | Behavioural/sequence flows |
Generate architecture documentation using C4 model Mermaid diagrams. Use when asked to create architecture diagrams, document system architecture, visualize software structure.
Share bugs, ideas, or general feedback.
Interactive C4 architecture diagrams (Simon Brown's model). Slash commands: /c4m:auto, /c4m:design, /c4m:code, /c4m:prose, /c4m:review, /c4m:update. Negotiable format (Mermaid / Structurizr / PlantUML) and destination (filesystem or MCP — Notion, Linear, Drive).
Generate architecture diagrams and technical design documents
Diagrams-as-code tools for visualizing code, data, and systems using Mermaid and PlantUML
Codebase visualization — generates architecture, data flow, dependency, call chain, community detection, and class diagrams via Mermaid Chart MCP
Turn complex codebases into clear, navigable architecture diagrams