langchain-ai/mermaid-diagrams
Embed Mermaid diagrams in generated wiki pages. Use whenever documenting a runtime or request flow, a call sequence, a state machine or lifecycle, a data model or entity relationships, or non-trivial control flow, since these are clearer as a diagram than as prose. Also use when an update run touches a page that already contains a mermaid fence, or a page that contains a text fence a previous run degraded.
npx skills add https://github.com/langchain-ai/openwiki --skill mermaid-diagrams
Diagrams are part of high-quality wiki generation, not decoration. Where a flow,
lifecycle, or data model is easier to grasp visually, embed a Mermaid diagram in
a fenced `mermaid block on the most relevant page.
sequenceDiagram for runtime and request flows across components (auth flows, request lifecycles, agent tool loops).stateDiagram-v2 for lifecycles and state machines (job states, connection states, run phases).erDiagram for the data model: entities and their relationships.flowchart TD for branching control flow and decision logic.These rules prevent the most common render breakages. When in doubt, rephrase the label.
flowchart, wrap any label containing parentheses, brackets, or other punctuation in double quotes: A["calls foo(bar)"].flowchart, never use the bare word end as a node id, and never start a node id with o or x followed by a dash (both are edge-marker syntax); rename the node.sequenceDiagram, participant names with spaces or punctuation need an alias: participant AS as Auth Service.note, end, loop, alt, opt, par, and, else, activate, deactivate, class, state, click, link. For example a notification participant must be Notifier, not Note (which collides with the note keyword).erDiagram, entity and attribute names must be single identifier-like tokens; put human phrasing in the relationship label.`mermaid fence, and delete the comment.Take langchain-ai/mermaid-diagrams from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.