SkillsReviewed · daymade

Mermaid Tools

Mermaid Tools is a Claude Code skill for developers and documentation writers converting Markdown diagrams into PNGs, but it assumes Chrome is installed at a fixed Linux path. Its Python and Bash helpers extract numbered .mmd files and invoke mermaid-cli with configurable dimensions and scaling. The renderer, browser and runtimes require separate installation.

Researched 16 Nov 2026

In short.

Mermaid Tools is a Claude Code skill for developers and documentation writers exporting Markdown diagrams as PNGs, but its Linux-focused setup and incomplete failure reporting make output checks essential. Bundled Python and Bash scripts extract Mermaid blocks into .mmd files and render them through mermaid-cli and Chrome. The extractor recognizes a narrow fence format, the wrapper also processes older .mmd files in its output directory, and its completion message can overstate success. Rendering, image quality and platform compatibility remain untested.

Researched and written by an AI model and checked by a second AI model. How it works

The scope covers all five supplied files in daymade-docs/mermaid-tools: SKILL.md, references/setup_and_troubleshooting.md, scripts/extract-and-generate.sh, scripts/extract_diagrams.py and scripts/puppeteer-config.json, plus the repository-root LICENSE at the same pinned revision. Other repository resources and separately installed dependency implementations and licences are outside this scope. Nothing was executed; installation, rendering, output quality, security and cross-platform compatibility remain untested.

The overview

Identity

Mermaid Tools lives in daymade-docs/mermaid-tools within the daymade/claude-code-skills repository. It combines assistant instructions with a Python extractor, a Bash rendering wrapper, Puppeteer browser settings and a setup guide. The conversion scripts contain no model API calls.

The original source folder is [https://github.com/daymade/claude-code-skills/tree/main/daymade-docs/mermaid-tools]. The supplied source version is commit 5f0395309c5e82376f25c3b7295c343dd0eb9b7b. SKILL.md declares the name mermaid-tools and sets disable-model-invocation to true; invocation behavior in a specific Claude Code version is not established.

Assessment

The useful feature is a repeatable path from a Markdown document to editable Mermaid source files and PNG images. Naming, rendering options and basic file checks are already connected, reducing the scripting needed for documents containing several diagrams.

Adoption needs care. Chrome has a hard-coded Linux location, extraction errors can leave a successful process status, and failed PNG validation does not prevent the final success banner. These are findings from the supplied code; no successful installation or rendering results are established.

Users

It fits developers and technical writers who already keep Mermaid diagrams in Markdown and need image exports for documentation or presentations. Retaining .mmd files also gives experienced users an intermediate format they can inspect or render separately.

Beginners should expect command-line installation and browser troubleshooting. The supplied files provide no graphical editor, diagram authoring interface or automatic repair of invalid Mermaid syntax.

Capabilities

The extractor finds Mermaid blocks, assigns sequence numbers, derives filenames from nearby descriptions or headings, and writes one .mmd file per match. The wrapper renders PNGs into a chosen directory; the default directory is diagrams beside the Markdown file.

MERMAID_WIDTH, MERMAID_HEIGHT and MERMAID_SCALE control base rendering settings, defaulting to 1200, 800 and 2. Filename keywords change the dimensions passed to mermaid-cli: timeline or gantt doubles width and halves height; architecture, system or caching doubles both; monitoring, workflow, sequence or api doubles width. These parameters do not establish the actual dimensions or visual quality of an unobserved output.

Using it

Requirements

The documented environment is WSL2 Ubuntu. Required components include Bash, Python 3, Node.js and npm for installing @mermaid-js/mermaid-cli, the mmdc command on PATH, and Chrome at /usr/bin/google-chrome-stable. The Python extractor uses standard-library modules and reads UTF-8 text.

The wrapper expects its extractor and puppeteer-config.json beside it. It also calls file, stat with -c, sort with -V, ls and awk. The identify command is optional for printed image dimensions: failure falls back to unknown. Supported runtime versions, operating-system releases and resource requirements are unspecified.

Mechanism

Python reads the document and uses a regular expression to capture Mermaid fences. It examines up to 20 preceding lines for recognized descriptions, then headings, to choose a filename. Context-derived names start with a sequence number; fallback names use the form diagram-01.

Bash then gathers every .mmd file in the output directory, applies version sorting, chooses dimensions from filename keywords, and invokes mmdc with the browser configuration and scale. PNG checks require a nonempty file identified as PNG by the file command. Optional dimension reporting adds information but does not verify layout or diagram meaning.

Setup

Obtain the complete skill folder so the instructions, scripts and browser configuration remain together. The guide proposes npm install -g @mermaid-js/mermaid-cli and Chrome installation through an Ubuntu apt repository, followed by checks using mmdc --version, google-chrome-stable --version and python3 --version. These checks were not executed.

The documented invocation starts in the skill's scripts directory and uses ./extract-and-generate.sh with a Markdown path and optional output-directory path. The wrapper resolves companion files from its own location; absolute input and output paths avoid working-directory ambiguity. The installation guide provides no version pins, and compatibility of its apt instructions with a particular current Ubuntu release is unknown.

Example

An illustrative design.md document could contain a level-two heading named Workflow, followed by an ordinary lowercase mermaid fence containing flowchart TD and a connection such as A[Draft] --> B[Review]. From the scripts directory, the corresponding command would be ./extract-and-generate.sh "/absolute/path/design.md" "/absolute/path/rendered-diagrams".

The naming logic would assign 01-workflow.mmd to that block. If rendering succeeds, the wrapper would create 01-workflow.png. The workflow filename selects twice the base width and the base height, with scale passed separately to mermaid-cli. This example is inferred from the code and was not run.

Assessment & evidence

Limitations

Extraction is based on a narrow regular expression, not a Markdown parser. Tilde fences, differently capitalized language labels and opening fences with trailing spaces fall outside its explicit pattern. Repeated identical diagram bodies can use the first occurrence's context because each body is searched for again from the document's beginning.

The output directory is not cleared. Existing .mmd files are also rendered, and matching output names can be overwritten. Mixed fallback and context-derived filenames do not guarantee rendering in source-document order.

Python catches read and individual write errors without returning a failing process status. The Bash set -e setting can stop rendering at a failed mmdc call before its intended continuation branch. Conversely, PNG validation failures only print messages, allowing the final success banner to appear despite failed validation.

The browser configuration includes --no-sandbox and --disable-setuid-sandbox, reducing browser isolation. This is a material consideration for untrusted input. No security assessment or evidence of safe handling of hostile diagrams is supplied.

Reasoning

Its strongest fit is repeated export of known Markdown documents in a controlled Linux environment. Editable intermediates, contextual filenames and centralized rendering settings offer practical value when a document has several diagrams.

Its fit is weaker for unattended publishing or varied Markdown sources. Narrow extraction, reused output directories and incomplete error propagation mean process completion alone cannot establish that every expected diagram produced a usable image.

Alternatives

For an existing .mmd file, direct use of mermaid-cli is the lower-level alternative visible in the wrapper. It avoids this extractor's fence recognition and naming rules while leaving browser configuration and rendering options to the caller.

For extraction without image rendering, the supplied Python script accepts a Markdown path and output-directory path independently. That avoids invoking Chrome but retains the extractor's limitations. Other skills, editors and hosted renderers were not assessed.

Evidence

The supplied evidence contains SKILL.md, the setup and troubleshooting guide, the Bash wrapper, the Python extractor, Puppeteer settings and the repository-root licence. Together they establish the documented workflow and the implementation details described here.

No generated PNGs, execution logs, benchmarks or platform test results are included. Statements about control flow and filenames come from source inspection; successful installation, rendering quality, performance and compatibility remain untested.

Access & freshness

Costs

The MIT licence grants permission to use and redistribute the covered software without charge. Total operating cost is unknown: the supplied materials contain no Claude Code pricing, setup-cost estimate, runtime measurements or storage measurements.

The scripts invoke local Python, mermaid-cli and Chrome commands and contain no model API calls or payment integration. That does not establish the cost or terms of the surrounding assistant environment or separately installed dependencies.

Rights

The supplied repository-root MIT licence names Copyright (c) 2025 daymade. It permits use, copying, modification, publication, distribution, sublicensing and sale, provided the copyright and permission notice accompany copies or substantial portions. It also disclaims warranties and liability.

The notice is available at [https://raw.githubusercontent.com/daymade/claude-code-skills/5f0395309c5e82376f25c3b7295c343dd0eb9b7b/LICENSE]. Separate dependency licences and rights to diagrams supplied by a user are not established by this notice.

Freshness

The source snapshot is pinned to commit 5f0395309c5e82376f25c3b7295c343dd0eb9b7b and was captured on 16 November 2026 at 05:45 UTC. These findings apply to that snapshot; whether later revisions changed the behavior is unknown.

The supplied files do not identify a release version, supported dependency-version matrix or tested Ubuntu release. The unpinned renderer and browser installation instructions leave current dependency compatibility unknown.

Actions

Before adoption, confirm the target system's Chrome path and dependency compatibility, and review the sandbox-disabling browser settings. Use a fresh output directory for each export, compare expected diagram counts with both .mmd and PNG counts, and inspect the resulting images.

For automation, make extraction and PNG-validation failures return explicit failure statuses. Decide whether rendering should stop on the first error or continue, then reconcile that decision with set -e. Treat the final banner as a message, not proof that every diagram rendered correctly.

Evidence for this report

LICENSEnotice · checked 2026-11-16
daymade-docs/mermaid-tools/SKILL.mdselected · checked 2026-11-16