
Mermaid Diagram CLI
Create, edit and render Mermaid diagrams from the command line via a stateful project file.
- Repository
- HKUDS/CLI-Anything
- Stars
- 58,084
- Licence
- Apache-2.0
- Files
- 1 file
What it does
This skill teaches an AI agent to use a command-line tool called cli-anything-mermaid, which builds Mermaid diagrams (flowcharts, sequence diagrams and similar) without opening the Mermaid Live Editor website. The agent can create a project file, set the diagram text, undo or redo edits, and export the result as SVG or PNG through the mermaid.ink rendering service. It can also generate a shareable Mermaid Live Editor link.
Great for
- Developers who want diagrams generated from code or text inside an automated workflow
- Technical writers who need architecture or sequence diagrams rendered as images for documents
- Users who prefer scripted, repeatable diagram generation over a GUI
Skip it if
- Users who need diagrams kept private: rendering and sharing send diagram source to the external mermaid.ink service and Mermaid Live Editor, so confidential architecture or data should not be sent there
- Offline or air-gapped environments, because rendering depends on a cloud service
- Anyone needing a full visual diagram editor with drag-and-drop, since this is text and command based
Try asking
- “Create a flowchart of our login process and export it as an SVG”
- “Turn this sequence description into a sequence diagram and render it to PNG”
- “Generate an editable Mermaid Live link for this diagram so my team can edit it”
- “Undo the last change to the diagram and show me the current Mermaid source”
Install in 3 steps
- 1
Download the skill
The ZIP contains the 1 original files, the Apache-2.0 licence and an attribution note.
skills.zip - 2
Add it to your agent
Claude Code (all projects)
mkdir -p ~/.claude/skills && unzip skills.zip -d ~/.claude/skills/Claude Code / Agent SDK (this project only)
mkdir -p .claude/skills && unzip skills.zip -d .claude/skills/Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.
- 3
Ask for the task
No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.
Get better results
- Ask the agent to use the --json flag so output is structured and easier to check
- Use absolute file paths, as the skill recommends, and confirm rendered files exist afterwards
- Do not include secrets, personal data or confidential system names in diagram text, since it is sent to a third-party renderer
What's inside
- SKILL.md
Redistributed unmodified from HKUDS/CLI-Anything under the Apache-2.0 licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.