Design diagrams that people actually understand. Picks the right diagram type, applies layout and clarity discipline, styles hand-drawn whiteboard looks, and enforces accessibility. Use when an agent needs to create a flowchart, chart, architecture diagram, or sketch for a human reader.
./install.sh diagram-craftname: diagram_craft description: Design diagrams that people actually understand. Picks the right diagram type, applies layout and clarity discipline, styles hand-drawn whiteboard looks, and enforces accessibility. Use when an agent needs to create a flowchart, chart, architecture diagram, or sketch for a human reader.
AI-generated diagrams usually fail on judgment, not tools: wrong chart type, cluttered layout, color-only encoding, legends nobody reads. This skill gives agents the design judgment to make diagrams humans get at a glance. Covers data charts and concept diagrams, both polished and hand-drawn styles.
Before drawing anything, ask: would a numbered list or a table say this better? If yes, do not make a diagram. Draw a diagram only when it shows something a list flattens: branching decisions, flows, relationships, hierarchy, or shape comparisons. A linear sequence with no branches is a list, not a diagram.
Match the diagram to what the reader needs to answer. For charts of data:
| Question the reader has | Use this | Avoid | |---|---|---| | How do these categories compare? | Horizontal bar chart, sorted by value | Pie chart, 3D bars | | How has this changed over time? | Line chart, time on x-axis | Bars for many time points | | What is the distribution? | Histogram or box plot | Pie chart | | What is the relationship between two variables? | Scatter plot | Line chart (implies time) | | What is the part-to-whole breakdown? | Stacked bar or waffle chart | Pie chart, unless 2-3 slices max | | What is the geographic pattern? | Choropleth map | Bars by region name | | What is the ranking? | Horizontal bar chart, sorted | Vertical bars, radar charts |
For concepts and systems:
| What you are showing | Use this | |---|---| | Decision path through a process | Flowchart | | Message flow over time | Sequence diagram | | Object or service lifecycle | State diagram | | Component relationships | Flowchart with subgraphs | | Hierarchical concepts | Mindmap or tree | | Phases or timeline | Gantt chart | | Entity relationships | ER diagram |
Pie charts are almost always the wrong choice: people compare angles and areas badly. Two exceptions: exactly 2-3 slices where one dominates, or a convention the audience expects (financial reporting). Never use 3D effects on charts. They distort values and lie about the data.
Write down every node and label before touching any tool. One diagram shows one concept. Cap sizes: flowcharts around 12 nodes max, sequence diagrams around 8 participants, mindmaps around 15 branches. If you are over the cap, split into two diagrams instead of shrinking text.
Match the style to the message. For working drafts, brainstorming, or inviting feedback, use a hand-drawn whiteboard style (Excalidraw, free and browser-based): the rough look signals "this is open for discussion" and stops pixel-perfect fiddling. For shipped docs and presentations, use clean rendered diagrams (Mermaid in docs, Graphviz for generated output, PlantUML for rich UML). Never ship a polished diagram that is still under debate, and never ship a sketch as a final deliverable.
Run every diagram through this before it ships:
references/palettes.md is designed to stay distinguishable under common color vision deficiencies; its yellow needs darkening for white backgrounds.Every diagram delivery includes:
If the diagram will not render in the target environment (Mermaid version, dark mode), say so and pick a different format instead of shipping broken code.
bin/lint_diagram.py on Mermaid sources before shipping. Fix every error, justify every warning.publisher key 2e43c913833850e6d80f939677e3de76e806d47785c0f1caaca90f9d18c98e1e
No ratings yet — be the first to rate it.