Skip to content
Back to skills

Diagram

ASecurity

Use to create or update the project's Mermaid .mmd diagrams when the user asks for diagrams, when shape finalizes work that changes the structure, when survey drafts the missing diagrams of an existing codebase, or when a change makes an existing diagram wrong (services, infrastructure, data flow or module boundaries added, removed or rewired).

  • 2 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added November 26, 2026
ai-agentsnodeapidatabase

Works with

  • api

Security analysis

A100/100

Scanned November 26, 2026

npx -y skills add odhyp/skills --skill diagram --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Diagram?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Diagram
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/odhyp-diagram/badge)](https://www.skillsdirectory.com/skills/odhyp-diagram)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: diagram
description: Use to create or update the project's Mermaid .mmd diagrams when the user asks for diagrams, when shape finalizes work that changes the structure, when survey drafts the missing diagrams of an existing codebase, or when a change makes an existing diagram wrong (services, infrastructure, data flow or module boundaries added, removed or rewired).
---

Read the odhyp block in `CLAUDE.md` for the diagrams folder. No odhyp block: stop and say to run `/odhyp:setup`. Edit only `.mmd` files in that folder; start a new one from `${CLAUDE_PLUGIN_ROOT}/templates/diagram.mmd`.

The folder starts empty. Create a diagram only when the user asks or `shape` or `survey` calls for one; otherwise update only diagrams that already exist. A diagram drawn from `shape` shows the agreed design; one drawn from `survey` shows the code as it is.

## Files

Stable names, one concern each. Create a file only when the project has something to show in it:

| File | Shows |
|---|---|
| `infrastructure.mmd` | Hosts, services, databases, queues, external APIs, and how they connect |
| `architecture.mmd` | Modules or packages and their dependencies |
| `data-flow.mmd` | How the main data moves from input to storage to output |

Add another file only for a view none of these covers, named for it (`auth-flow.mmd`).

## Writing a diagram

- Line 1 is a header comment saying what the diagram covers: `%% Architecture: modules under src/ and their imports`.
- Plain Mermaid (`flowchart`, `sequenceDiagram`, `erDiagram`, …), no HTML, no styling beyond `classDef`.
- Node labels use the names in the code (module, service, table), so a reader can grep for them.
- When updating, change only what the change touched; keep node IDs stable so diffs stay small.

**Done when** every service, module or flow the change added, removed or rewired appears correctly, and nothing that no longer exists remains.

Report which files changed and what changed in each.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.