diagram

diagram is a skill for Claude Code, Codex from AgentSystemLabs/launch-pad. It costs 97 tokens per session (1,519 once invoked), scanned A, original, MIT.

A skill for displaying Mermaid diagrams—text descriptions of flows, systems, and relationships—in Mission Control's interactive viewer.

In plain words
What is it for?
Use it for flowcharts, sequence diagrams, architecture sketches, state machines, entity-relationship diagrams, and similar visuals.
Why use it?
It keeps diagrams readable and lets the viewer apply its own light or dark theme instead of leaving raw diagram text in the terminal.

Skill for Claude CodeCodex

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.

agentmods
npx agentmods add skills/agentsystemlabs/launch-pad/diagram
Any agent
npx skills add AgentSystemLabs/launch-pad --skill diagram
Clone the repo
git clone --depth 1 https://github.com/AgentSystemLabs/launch-pad

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/agentsystemlabs/launch-pad/diagram.svg)](https://agentmods.dev/skills/agentsystemlabs/launch-pad/diagram)
Your own site
<a href="https://agentmods.dev/skills/agentsystemlabs/launch-pad/diagram"><img src="https://agentmods.dev/badge/skills/agentsystemlabs/launch-pad/diagram.svg" alt="Measured on agentmods" height="20"></a>
Per session 97 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,519 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
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 $0.00097 $0.01519
Opus 5 $0.00048 $0.00759
Sonnet 5 $0.00019 $0.00304
Haiku 4.5 $0.00010 $0.00152

Measured 5d ago against content hash ed4e6c1a17c4, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

diagram 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 5d 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.

curl -sS -X POST "$MC_API_URL/api/diagram?taskId=$MC_TASK_ID" \
.agents/skills/diagram/SKILL.md · 137 lines

How it starts

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

Mission Control agent sessions receive env vars automatically:

  • MC_API_URL — loopback API base (e.g. http://127.0.0.1:54321)
  • MC_API_TOKEN — bearer token for that API
  • MC_TASK_ID — the active task/session id
  • MC_THEME — Mission Control UI theme: dark or light

Do not print Mermaid to the user and stop. POST it to Mission Control so the app opens an interactive viewer modal. The viewer applies Mission Control theme colors automatically — your job is to avoid fighting that styling.

When to use

  • User asks for a diagram, flowchart, sequence diagram, architecture map, or state chart
  • You are explaining a multi-step system and a diagram would land faster than prose
  • You already drafted Mermaid and would otherwise paste it in the terminal

Skip when Mission Control env vars are missing (plain shell outside MC) — fall back to inline Mermaid in markdown.

API contract

POST $MC_API_URL/api/diagram?taskId=$MC_TASK_ID
Authorization: Bearer $MC_API_TOKEN
Content-Type: application/json

{
  "source": "<mermaid source>",
  "title": "Optional title shown in the modal",
  "format": "mermaid",
  "theme": "dark"
}

theme is optional metadata — pass "$MC_THEME" when set so Mission Control knows which UI theme was active. The viewer still re-renders using the live app theme; you do not need to bake colors into source for MC.

Success (200): { "ok": true, "id": "<uuid>" } — Mission Control opens the viewer automatically.

Common errors:

  • 400 — missing/invalid body, empty source, or taskId query param missing
  • 401 — bad or missing bearer token
  • 404 — unknown taskId

Theme rules (critical)

Mission Control runs in dark mode by default. Diagrams fail when agents embed colors that disappear on dark backgrounds (dark gray boxes, faint borders, #111 fills).

  1. Do not override Mermaid theme in source. Never use %%{init: {'theme':'dark'}}%%, %%{init: {'theme':'base', 'themeVariables': ...}}%%, YAML frontmatter theme blocks, or classDef / style with hardcoded hex/rgb fills.
  2. Use plain Mermaid syntax. Let Mission Control's viewer apply accent, surface, text, and border tokens from the active UI theme.
  3. Read $MC_THEME. When it is dark, avoid near-black node/participant fills. When it is light, avoid near-white fills on white backgrounds.
  4. Sequence diagrams: use default participant boxes — do not set actor background colors inline. Example:

Read the full file on GitHub · 137 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. 5d ago First seen · 137 lines · 97 tokens per session scan A ed4e6c1a17c4

Subscribe to this mod's changes

diagram is a skill published in the GitHub repository AgentSystemLabs/launch-pad (22 stars, last pushed 1mo ago), licensed MIT. It adds 97 tokens to every session and 1,519 once invoked, about $0.0005 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.