diagrams
Skill14 starsChanged 31 days agoApache-2.0View on GitHub
How to write diagram code blocks and display math that the figures plugin draws as pictures in the terminal (mermaid, dot/graphviz, d2, svg, LaTeX math). Load before putting a diagram or a formula in a reply, or when asked to draw, chart, or visualize a flow, architecture, state machine, dependency graph, or sequence.
9 other projects use a version of this.
Adopted by
Most recently taken up by
- Zejnilovic/agdtheir own version, first seen Nov 1, 2026
- AlexCiortan/setlisttheir own version, first seen Oct 29, 2026
- conjurer-rich/skillstheir own version, first seen Oct 25, 2026
- nimadorostkar/Claude-Skills-collectiontheir own version, first seen Oct 13, 2026
- roastedbeans/claude-skillstheir own version, first seen Aug 11, 2026
- soujava/agent-skillstheir own version, first seen Jul 13, 2026
Used with
Projects with it also use observability.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
OpenAISkillobservability
Vercel Observability expert guidance — Drains (logs, traces, speed insights, web analytics), Web Analytics, Speed Insights, runtime logs, custom events, OpenTelemetry integration, and monitoring dashboards. Use when instrumenting, debugging, or optimizing application performance and user experience on Vercel.
Also in 3 projects that use this
Other versions9 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 9
- nimadorostkar/Claude-Skills-collection★ 33same name
- soujava/agent-skills★ 10same name
- Zejnilovic/agd★ 5same name
- HartreeWorks/research-skills★ 4same name
- AlexCiortan/setlist★ 2same name
- conjurer-rich/skills★ 1same name
- mmondora/claude-skills★ 1same name
- gologo13/agent-skills★ 0same name
- roastedbeans/claude-skills★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
We split this skill into the rules it gives an agent
3 rules. 0 are common, 1 is distinctive, and 2 are very specific to this project.
0
Common
Most of the 9 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 13
If a block fails, the first line of the renderer's error is shown in red under the reply.
- Very specific: line 41
Write one edge per line. A chained edge with a label, such as A --> B -->|ok| C, is misparsed.
- Very specific: line 43
Keep labels short and quote any label containing punctuation: A["parse (stage 1)"].
“Common” is measured: kept by at least 6 in 10 of the 9 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Diagrams and math that render inline
A fenced block tagged mermaid, dot (or graphviz), d2, or svg in a reply is drawn as a
picture under the reply, and the code stays visible above it. Where the terminal cannot show
images, or the block's renderer is not installed, only the code is shown, so the source should
still read sensibly as text.
If a block fails, the first line of the renderer's error is shown in red under the reply. Fix the source and send the corrected block, rather than explaining the error.
Choosing a language
mermaidfor flowcharts, sequence diagrams, state machines, class and ER diagrams.dotfor graphs with many nodes or edges, such as dependency or call graphs; Graphviz lays them out more cleanly than mermaid does.d2for architecture diagrams with nested containers.svgonly for a figure none of the above can express.
Math
Display math, $$ … $$, \[ … \], or a math block, is typeset with MathJax and drawn under the
reply. Inline $…$ stays plain text, so put a formula that matters on its own as display math.
- amsmath environments such as
alignedandcases, andmathtools,cancel,color,braket, and\boldsymbol, work. - Each formula becomes its own picture, so keep a derivation in one
alignedblock instead of many separate ones. - A
latexblock containing\documentclassis treated as a document and left as code.
Writing mermaid for mmdr
Mermaid blocks are rendered by mmdr, a reimplementation of mermaid.js that does not accept every construct mermaid.js does. mmdc, if installed, takes over only when mmdr reports an error, and mmdr misparses some blocks without one, so write for mmdr:
- Write one edge per line. A chained edge with a label, such as
A --> B -->|ok| C, is misparsed; writeA --> BandB -->|ok| Cinstead. - Keep labels short and quote any label containing punctuation:
A["parse (stage 1)"].
Size
A picture is at most 120 cells wide and 30 rows tall by default. One that would shrink to under 60%
is grown up to the terminal's height, and if it is still small the user sees a note pointing to
/figures. A long chain laid out top to bottom still ends up tiny; prefer flowchart LR for long
chains, and split a diagram of more than about 20 nodes into several.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

