/ancplua-skills:c4-diagramfrom ancplua-skills
Generate C4 Container diagrams using C4 model conventions as editable .drawio XML files. Use when the user asks for architecture diagrams, system diagrams, C4 diagrams, container diagrams, or wants to visualize system architecture. Also use proactively when explaining systems with 3+ components where a visual would clarify the architecture.
Ships in ancplua-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Generate C4 Container diagrams following C4 model conventions, exported as editable .drawio XML files that open directly in draw.io (desktop or web).
Explicit triggers:
Proactive triggers:
Skip when:
Identify from the conversation or ask the user:
If the user provides a spec, codebase description, or architecture overview, extract elements automatically and confirm before generating.
Map every element to a C4 category:
| Category | Color | Shape | Description |
|---|---|---|---|
| Person | #08427B (dark blue) | shape=actor + text label | Users, actors, roles |
| Container | #438DD5 (blue) | Rounded rectangle | Applications, services, APIs |
| Database | #438DD5 (blue) | Cylinder | Any data store (SQL, NoSQL, files) |
| Queue/Broker | #438DD5 (blue) | Rounded rectangle with label | Message queues, event buses |
| External System | #999999 (grey) | Rounded rectangle | Third-party services, APIs |
| System Boundary | none (transparent) | Dashed rectangle | Groups internal containers |
Reference: references/element-templates.md for exact draw.io XML templates.
Apply strict layered layout (top to bottom):
Layer 1 (y ~= 20): Person elements (actors)
Layer 2 (y ~= 250): System Boundary containing internal Containers
Layer 3 (y ~= 700+): External Systems
Layout rules:
Minimizing line crossings:
labelBackgroundColor=#ffffff on all edges, and use perpendicular offset (y in mxGeometry) to push labels away from containersFor each connection, specify:
Connection rules:
labelBackgroundColor=#ffffff in connection styles[Protocol] suffix: [REST/JSON], [gRPC], [SQL], [AMQP], [WebSocket]Use the XML structure from references/drawio-template.md as the base.
Build the XML following these rules:
<mxfile> wrapper and <mxGraphModel> with proper dimensionsElement sizing:
Every diagram must include a legend. Place it in the bottom-right corner.
The legend must show:
Reference: references/legend-template.md for the exact XML.
Save to the path requested by the user, or default to ./c4_[system_name].drawio.
Validation checklist:
Follow C4 Container diagram constraints:
mxgraph.c4.* shapes - they require the C4 shape library which is NOT loaded by default in draw.io. Use built-in shapes: shape=actor for persons, shape=cylinder3 for databaseslabelBackgroundColor=#ffffff - naked labels become unreadable when crossing other elementsWhat SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub ancplua/ancplua-skills --plugin ancplua-skills43 skills in this plugin
/agent-log-scanScan agent transcripts and turn antipatterns into config and routine changes, not just an allowlist like fewer-permission-prompts. Use when asked to scan agent logs or session history, "why do my agents keep failing", "what happened across my sessions", to find retry loops, permission thrash, API dead-ends or limit interrupts, or raise autonomy./analyzer-purityKeep Roslyn analyzers, source generators and code fixes pure, loadable and cache-friendly inside every compiler host. Use when creating, changing, reviewing or packaging a netstandard2.0 project with IsRoslynComponent, EnforceExtendedAnalyzerRules or Microsoft.CodeAnalysis references, or when an RS1xxx/RS2xxx diagnostic, a sluggish IDE or a generator that reruns on every keystroke points at one./