diagramlisted
Install: claude install-skill vanducng/skills
# vd:diagram
Turn natural-language descriptions into reviewable diagram images and version-controlled diagram artifacts. Two render paths:
- **PNG** (default): refines the prompt with `claude-haiku-4-5`, then generates the image. Default image provider is **codex** (`gpt-image-2` via your ChatGPT subscription — cost-optimized, no per-image API spend), with automatic fallback to OpenRouter `gpt-5.4-image-2` when codex is unavailable. Force the API path with `--provider openrouter`.
- **SVG** (`--format svg`): the LLM emits the SVG markup directly. Cheaper, crisper labels, hand-editable.
Use `--versioned` when the diagram belongs in docs, ADRs, specs, or PR review. It writes a stable folder under `docs/diagrams/<slug>/` with:
- `diagram.spec.yaml` — reviewable source intent (type, preset, engine, description, latest variant)
- `manifest.json` — deterministic metadata for automation
- `v1.svg`, `v2.svg`, ... or `v1.png`, `v2.png`, ... — rendered variants
## Quick Start
```bash
# Auto-detect type, default PNG
~/.claude/skills/.venv/bin/python3 $HOME/skills/skills/diagram/scripts/generate.py \
"system architecture for an OAuth signup flow with FastAPI backend"
# Explicit type, SVG output
~/.claude/skills/.venv/bin/python3 $HOME/skills/skills/diagram/scripts/generate.py \
--type sequence --format svg \
"user logs in: User → App → Auth Provider → callback"
# Version-controlled workflow artifact for docs/diagrams/
~/.claude/skills/.venv/bin/python3 $HOME/skills/skills/dia