loom-diagramming

loom-diagramming is a skill for Claude Code, Codex from cosmix/loom. It costs 26 tokens per session (2,175 once invoked), scanned A, original, MIT.

A guide for creating technical diagrams with Mermaid, a text format that turns code into diagrams. It covers architecture, interactions over time, data models, workflows, and lifecycle changes in documentation stored with the code.

In plain words
What is it for?
Use it to create sequence diagrams, flowcharts, state diagrams, entity-relationship diagrams, class diagrams, or layered C4 architecture diagrams.
Why use it?
It helps choose a diagram type that matches the question and avoid syntax mistakes. Keeping diagrams beside the code makes them easier to update when the system changes.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to create sequence diagrams, flowcharts, state diagrams, entity-relationship diagrams, class diagrams, or layered C4 architecture diagrams.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/cosmix/loom/loom-diagramming
View source ↗ cosmix/loom
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add cosmix/loom --skill loom-diagramming
Clone the repo
git clone --depth 1 https://github.com/cosmix/loom

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for loom-diagramming

README.md
[![agentmods](https://agentmods.dev/badge/skills/cosmix/loom/loom-diagramming/github.svg)](https://agentmods.dev/skills/cosmix/loom/loom-diagramming)
Your own site
<a href="https://agentmods.dev/skills/cosmix/loom/loom-diagramming"><img src="https://agentmods.dev/badge/skills/cosmix/loom/loom-diagramming/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for loom-diagramming

Your own site · 80×15
<a href="https://agentmods.dev/skills/cosmix/loom/loom-diagramming"><img src="https://agentmods.dev/badge/skills/cosmix/loom/loom-diagramming.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,175 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00026 $0.02175
Opus 5 $0.00013 $0.01087
Sonnet 5 $0.00005 $0.00435
Haiku 4.5 $0.00003 $0.00217

Measured 6d ago against content hash fe0ea6677d51, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

loom-diagramming scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

- **Quote labels with special characters.** Parentheses `()`, `{}`, `[]`, `#`, `:`, `;`, and quotes inside a label break parsing — wrap the text: `A["fetch(url)"]`, `B["step: parse"]`. For literal special chars inside a
skills/loom-diagramming/SKILL.md · 232 lines

How it starts

The opening of the file, as written. The whole thing — 232 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Diagramming

Overview

Create maintainable technical diagrams in Mermaid (renders in GitHub, GitLab, and most doc tools). Diagrams live in version control next to code — they must stay in sync or they mislead. This skill covers type selection, syntax, and the parsing footguns that waste the most time.

Choose the diagram type

Type Use when Not when
Sequence Interactions over time across participants Showing static structure
Flowchart Decision logic, process/pipeline steps Timing between services (use sequence)
State An entity's lifecycle + transitions/guards Data flow or call order
ERD Data model, tables, cardinality Runtime behavior
Class OO structure, interfaces, inheritance Deployment or infra
C4 (Context) System boundary + external actors/systems Internal code detail
C4 (Container) Deployable units + their tech + data stores Class-level detail

Rule of thumb: structure → flowchart/C4/class/ERD; behavior over time → sequence; lifecycle → state. For architecture, prefer C4's layered zoom (Context → Container → Component) over one sprawling diagram.

Gotchas (Mermaid parsing footguns)

These cause silent render failures or garbled output far more often than logic errors.

  • end is reserved in flowcharts. A lowercase node id end breaks the parser. Use End, END, or quote it: id["end"]. Same care with subgraph/click/class as bare ids.
  • Quote labels with special characters. Parentheses (), {}, [], #, :, ;, and quotes inside a label break parsing — wrap the text: A["fetch(url)"], B["step: parse"]. For literal special chars inside a quoted label, use HTML entities: #quot; won't work — use &quot;, &amp;, &#35; (for #).
  • Line breaks: <br/> inside a label, not \n: A["Line one<br/>Line two"].
  • Edge labels with special chars must be quoted: A -->|"retry (max 3)"| B.
  • Leading o/x on an edge become arrowheads. A---oB renders a circle end, A---xB a cross. Add a space (A --- oB is still risky) or rename the node so an edge doesn't touch a bare o/x.
  • Subgraph direction: set direction LR inside the subgraph; note that edges crossing subgraph boundaries can override a subgraph's internal direction.
  • Comments are %% on their own line. Semicolons are optional line terminators.
  • C4 diagrams (C4Context/C4Container) have limited, sometimes experimental layout control and lag other Mermaid features — verify they render in your target tool before committing to them; a plain flowchart with subgraphs is a robust fallback.
  • Don't build the giant diagram. Past ~15-20 nodes it's unreadable and un-reviewable. Split by concern or zoom level. One diagram, one idea.

Read the full file on GitHub · 232 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago Changed · -20 tokens per session fe0ea6677d51
  2. 9d ago First seen · 232 lines · 46 tokens per session scan A c9a2663cb7d0

Subscribe to this mod's changes

loom-diagramming is a skill published in the GitHub repository cosmix/loom (54 stars, last pushed yesterday), licensed MIT. It adds 26 tokens to every session and 2,175 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

eval-graphics

Turn an eval study's numbers into on-brand, publish-ready figures using the Newsjack chart room (the eval design system), then validate them with Playwright. For producing the charts in a published eval/data study.

elvisun/newsjack · 47 tokens

drawio-logical-diagrams

Creates professional logical flow diagrams and logical system architecture diagrams using draw.io XML format (.drawio files). Use when creating: (1) logical flow diagrams showing data/process flow between system components, (2) logical architecture diagrams representing system structure without cloud provider…

giuseppe-trisciuoglio/developer-kit · 133 tokens

aws-drawio-architecture-diagrams

Creates professional AWS architecture diagrams in draw.io XML format (.drawio files) using official AWS Architecture Icons (aws4 library). Use when the user asks for AWS diagrams, VPC layouts, multi-tier architectures, serverless designs, network topology, or draw.io exports involving Lambda, EC2, RDS, or other AWS…

giuseppe-trisciuoglio/developer-kit · 76 tokens

aksel-builder

Expert builder for Aksel, the Nav / @navikt design system — React components, design tokens, layout primitives, theming (light/dark), icons, CSS, the Tailwind preset, version migrations, Figma-to-code. Triggers — Aksel, "using/with aksel", Nav/Navikt, "designsystemet", "design system", @navikt/ds- (e.g.…

navikt/copilot · 181 tokens

aksel-spacing

Lag responsive layouts med Aksel Design System (v8+) - spacing tokens, layout primitives (Box, HStack, VStack, HGrid, Page, Bleed) og ResponsiveProp.

navikt/copilot · 41 tokens

web-design-reviewer

Visuell inspeksjon av nettsider for å identifisere og fikse designproblemer. Trigges av forespørsler som "sjekk designet", "gå gjennom UI-en", "fiks layouten", "finn designfeil". Finner problemer med responsivt design, tilgjengelighet, visuell konsistens og layout, og fikser dem i kildekoden.

navikt/copilot · 89 tokens