.agents/skills/mermaid/SKILL.md
Rules and validation for Mermaid diagrams. Use when creating or editing Mermaid diagrams in documentation.
npx skillsauth add haowjy/pokemon-amber mermaidInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
After writing or editing any Mermaid block, validate with the co-located script: scripts/check-mermaid.sh <file>.
Any node label with (), [], <>, <br/>, ,, or emoji must be wrapped in ["..."]. Same idea for edge labels — use |"..."|.
| Context | Needs quotes? | Example |
|---------|--------------|---------|
| Simple text only | No | A[Hello World] |
| Contains () | Yes | A["Config (optional)"] |
| Contains [] | Yes | A["items list"] (avoid [] entirely) |
| Contains <br/> | Yes | A["Line 1<br/>Line 2"] |
| Contains emoji | Yes | A["Done ✓"] |
| Contains " | Escape | A["Say 'hello'"] |
| Edge with specials | Yes | A -->\|"data (raw)"\| B |
flowchart LR
A["Turn 1: user"] -->|"StreamEvents (Delta, Block)"| B["blocks list"]
C["UI Panels (Thread, Tool)"]
<br/> for line breaksNot \n. In flowchart labels, quote the label when using <br/>.
flowchart LR
A["Turn 1<br/>user message"] --> B["Next step"]
sequenceDiagram
Note over A,B: First line<br/>Second line
end keywordLowercase end as a node label breaks flowcharts and sequence diagrams. Capitalize it or wrap in quotes:
flowchart LR
A["end of process"] --> B["End"]
Use built-in themes (default, dark, neutral, forest, base) rather than styling every node. classDef and style are fine for intentional emphasis (error paths, highlights), but avoid overriding the theme's defaults — hardcoded fills break in dark mode.
For rect grouping in sequence diagrams, use near-transparent fills:
rect rgba(128, 128, 128, 0.08)
Note over A,B: Phase label
end
o and x after links: A---oB creates a circle-end edge, A---xB a cross-end. Add a space if your node ID starts with o or x: A--- oNode.#59; for literal semicolons.The validation script lives at scripts/check-mermaid.sh within this skill directory. It extracts each ```mermaid block, validates it with mmdc, and reports file + line number for failures.
# Validate specific file
scripts/check-mermaid.sh path/to/file.md
# Validate all .md files recursively from cwd
scripts/check-mermaid.sh
# Validate a directory
scripts/check-mermaid.sh docs/features/
data-ai
Team composition for writing workflows — which agents to spawn, how many, what focus areas to assign, and how to scale effort. Use when composing critic panels, dispatching researchers, staffing draft/revise loops, or setting up brainstorm fan-outs.
testing
What fiction readers actually want, framed as four composable reward channels (transportation, aesthetic, social simulation, flow), and the specific documented ways alignment training damages each one. Grounded in reader-psychology research and empirical NLP findings. Load when drafting prose, critiquing a draft, deciding whether to show or tell, diagnosing why a passage feels flat, or reasoning about why a scene is or isn't working.
testing
Logging and referencing writing issues — craft problems, tics, inconsistencies, and structural concerns found during analysis, critique, or review. Use when an agent identifies something worth tracking beyond a single critique report: repeated tics across chapters, inconsistencies that affect multiple scenes, structural problems that need the author's attention, or patterns that should be fixed in revision.
development
Shared artifact convention between orchestrators — what goes where in `$MERIDIAN_FS_DIR/` and `$MERIDIAN_WORK_DIR/`, how artifacts flow between phases, and what each directory means. Use whenever work artifacts, style files, knowledge entries, drafts, or critique reports are being created, referenced, or discussed.