diagram

diagram is a skill for Claude Code, Codex from HybridAIOne/hybridclaw. It costs 36 tokens per session (1,521 once invoked), scanned A, original, MIT.

A tool for creating and checking diagrams from text-based files. It supports formats such as Mermaid, PlantUML, Graphviz DOT, and Excalidraw JSON.

In plain words
What is it for?
Use it to create or revise flowcharts, sequences, states, database relationships, class diagrams, dependency graphs, and editable sketches.
Why use it?
It turns structured descriptions into diagrams and checks them for errors before rendering, which makes diagrams easier to update and validate.

Skill for Claude CodeCodex

Written for Claude Code and Codex: disable-model-invocation in frontmatter, but also agents/openai.yaml present.

Good fit Use it to create or revise flowcharts, sequences, states, database relationships, class diagrams, dependency graphs, and editable sketches.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/hybridaione/hybridclaw/diagram
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 HybridAIOne/hybridclaw --skill diagram
Clone the repo
git clone --depth 1 https://github.com/HybridAIOne/hybridclaw

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 diagram

README.md
[![agentmods](https://agentmods.dev/badge/skills/hybridaione/hybridclaw/diagram/github.svg)](https://agentmods.dev/skills/hybridaione/hybridclaw/diagram)
Your own site
<a href="https://agentmods.dev/skills/hybridaione/hybridclaw/diagram"><img src="https://agentmods.dev/badge/skills/hybridaione/hybridclaw/diagram/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 diagram

Your own site · 80×15
<a href="https://agentmods.dev/skills/hybridaione/hybridclaw/diagram"><img src="https://agentmods.dev/badge/skills/hybridaione/hybridclaw/diagram.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 36 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,521 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. 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.00036 $0.01521
Opus 5 $0.00018 $0.00760
Sonnet 5 $0.00007 $0.00304
Haiku 4.5 $0.00004 $0.00152

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

Security

Grade A, and why

diagram scanned grade A with 0 findings 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 13d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/diagram/SKILL.md · 132 lines

How it starts

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

Diagram

Use this skill when the user wants a rendered static diagram, a validated diagram source artifact, or a revision to an existing diagram source.

Default to Mermaid unless the user asks for another format or the shape is a better fit for another adapter:

  • Mermaid: sequence, flowchart, state, ER, class, gantt, git-graph, mindmap, and pie diagrams.
  • PlantUML: UML sequence/component/activity/deployment diagrams when the user already uses PlantUML or asks for it.
  • Graphviz DOT: topology, dependency graphs, and layouts where rank/direction control matters.
  • Excalidraw JSON: hand-drawn-style editable sketches when the user asks for an editable canvas.

Tool Surface

Use the runtime tools directly:

  • diagram_create: create source, validate it, save source, and optionally render.
  • diagram_update: update existing source or source artifact, validate it, save a new source artifact, and optionally render.
  • diagram_validate: validate source only; do not render.

The tool output includes these fields:

{
  "success": true,
  "valid": true,
  "source": "...",
  "source_artifact_ref": "/workspace/.generated-diagrams/skills/diagram/diagram-...",
  "rendered_artifact_ref": "/workspace/.generated-diagrams/skills/diagram/diagram-...",
  "type": "flowchart",
  "format": "mermaid",
  "artifacts": [],
  "runtime_events": [],
  "warnings": []
}

On validation failure, success and valid are false and errors plus suggested_fix may be present. When render_to is "none", rendered_artifact_ref is null. Invalid source is still saved with source_artifact_valid: false so the operator can inspect or repair it.

Default Workflow

  1. Pick the diagram type before writing syntax. If uncertain, set type to auto, but prefer an explicit type when the user request clearly names one.
  2. For Mermaid, read references/mermaid-types.md when you need grammar examples or when the diagram type is not obvious.
  3. Draft complete source yourself when the user needs a specific diagram. Do not rely on the tool's generated starter unless the request is generic.
  4. Call diagram_validate before rendering when you wrote or revised source manually.
  5. If validation fails, use the returned errors and suggested_fix, revise once, then validate again. Make at most 2 fix-up attempts before surfacing the failure with the invalid source artifact. The runtime also caps automatic pre-render fix-up at 2 attempts.
  6. Call diagram_create or diagram_update with render_to set to svg by default. Use png or pdf only when requested and the adapter can render that target.
  7. Return the source artifact and rendered artifact paths to the user.

Read the full file on GitHub · 132 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

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. 13d ago First seen · 132 lines · 36 tokens per session scan A 589271ab384b

Subscribe to this mod's changes

diagram is a skill published in the GitHub repository HybridAIOne/hybridclaw (132 stars, last pushed yesterday), licensed MIT. It adds 36 tokens to every session and 1,521 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.