Immutable. This exact content is served forever at /api/v1/blob/4504e147b7a67dfb.
---
name: Documentation & Diagrams
description: Generate C4 architecture diagrams (GitHub-renderable Mermaid) and PowerPoint presentations (PPTX via the native Anthropic pptx skill)
trigger: documentation, c4, c4 diagram, architecture diagram, update docs, powerpoint, pptx, diagram, flowchart, sequence diagram, org chart, timeline, mind map, presentation, slides
metadata:
provenance:
class: cpp-authored
---
# Documentation & Diagrams Skill
When the user asks about creating architecture documentation, C4 models, PowerPoint presentations, or visual content for slides, use the commands below.
- **PowerPoint/PPTX** is generated by the native Anthropic `pptx` skill (install with `npx skills add anthropics/skills@pptx`) - not an MCP server.
- **C4 diagrams** are rendered as GitHub-renderable Mermaid by a zero-dependency Python engine (`scripts/c4-mermaid.py`, issue #411): L1-L3 as `flowchart` with `subgraph` boundaries, L4 as `classDiagram`. Output is `.mmd` files plus an `index.md` that renders inline on GitHub.
## Quick Reference
### Commands
| Command | Purpose |
|---------|---------|
| `/documentation:c4` | Generate C4 architecture diagrams (all 4 levels) |
| `/documentation:pptx` | Guided PowerPoint creation with diagrams |
| `/documentation:help` | Overview of documentation commands |
### C4 Diagram Workflow
1. Analyze project (CLAUDE.md, README, directory structure)
2. Build a C4 model (`docs/architecture/c4-model.json`) for the 4 levels: L1 Context, L2 Container, L3 Component, L4 Code
3. Render with `python3 scripts/c4-mermaid.py --model docs/architecture/c4-model.json --out docs/architecture`
4. The engine writes `c4-*.mmd` per level, `index.md` (renders on GitHub), and `c4-manifest.json`; it fails on invalid edge/relation references (edge-validity QA gate)
> L1-L3 use Mermaid `flowchart` (not the C4 extension, which GitHub does not render); L4 uses `classDiagram`.
### C4 Node Types
| Type | C4 Concept | Color |
|------|-----------|-------|
| `person` | Actor / User | Dark blue (pill) |
| `system` | External System | Grey |
| `system-focus` | System of Interest | Blue |
| `container` | Container | Green |
| `component` | Component | Purple |
| `code` | Code element | Amber |
### PowerPoint Workflow
Use the native Anthropic `pptx` skill (install with `npx skills add anthropics/skills@pptx`), driven by `/documentation:pptx`, to build slide decks from your content.
### C4 / Diagram Concepts
| Type | Best For |
|------|----------|
| `architecture` | System components, services, infrastructure |
| `c4` | C4 model - multi-level architecture with boundaries |
| `flowchart` | Processes, decision trees, workflows |
| `sequence` | API calls, message passing, interactions |
| `orgchart` | Hierarchies, taxonomies, team structure |
| `timeline` | Roadmaps, milestones, project phases |
| `mindmap` | Brainstorming, concept maps, topic exploration |
### Node Types (Colors - non-C4 diagrams)
- `primary` (blue) - Main components
- `secondary` (purple) - Supporting
- `accent` (amber) - Highlights
- `warning` (red) - Critical items
- `success` (green) - Completed/healthy
- `default` (slate) - Standard