ascii-diagram
Agent skill fromSethGammon/Citadel
Generate perfectly aligned ASCII diagrams — architecture, flow, sequence, box-and-arrow. Uses a programmatic character-grid approach so alignment is guaranteed by math, not token prediction. Includes post-render verification.
How to install ascii-diagram
install ascii-diagram
# install the Citadel pack with the skills CLI
npx skills add SethGammon/Citadel# or add only this skill to Claude Code: copy the folder
skills/ascii-diagram/
# into
~/.claude/skills/ascii-diagram/ (all projects)
.claude/skills/ascii-diagram/ (one project)
1# /ascii-diagram — Perfectly Aligned ASCII Diagrams23## Orientation45**Use when:**6- The user wants any kind of text/ASCII diagram: architecture, flow, sequence,7 box-and-arrow, tree, table, org chart, network topology8- A diagram needs to be embedded in markdown, code comments, or plain text9- Visual alignment matters1011**Do NOT use when:**12- The user wants an image (suggest Mermaid, PlantUML, or an image tool instead)13- The diagram is trivial (a single box or a one-line arrow)1415**What this skill needs:**16- A description of what to diagram17- Optional: preferred style (single-line `+--+`, double-line `╔══╗`, rounded `╭──╮`, heavy `┏━━┓`)18- Optional: target width constraint1920## Protocol2122### Step 1: PLAN THE LAYOUT2324Before writing ANY characters, plan the diagram structurally:25261. **Identify elements**: List every box/node and its label text272. **Identify connections**: List every arrow/line between elements, with optional labels283. **Choose layout direction**: left-to-right, top-to-bottom, or mixed294. **Calculate dimensions**:30 - Each box width = max label line length + 4 (2 padding + 2 border)31 - Each box height = label line count + 2 (top + bottom border)32 - Gutters between boxes: minimum 3 characters for arrows (` → `)33 - For vertical arrows: minimum 1 row gap3435Write this plan out explicitly before proceeding. Example:3637```38Elements:39 A: "Client" → width=10, height=340 B: "Server" → width=10, height=341 C: "Database" → width=12, height=342Layout: left-to-right43…
Excerpt shown under the repository's MIT license.
