一键导入
generate-mermaid-flowchart
Use when rendering Mermaid syntax into diagram image files for docs or articles (mermaid, flowchart, diagram, PNG, SVG, visualization).
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when rendering Mermaid syntax into diagram image files for docs or articles (mermaid, flowchart, diagram, PNG, SVG, visualization).
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Use when generating AI cover images or illustrations via OpenRouter API (AI image, OpenRouter, cover image, WeChat, text-to-image, Gemini, image generation).
Use when an approved delivery slice or plan exists and the next step is execution, or when debugging, TDD, E2E acceptance, parallel task coordination, or isolated workspace setup is needed (approved slice, approved plan, coordinated execution, implementation execution, worktree, isolated workspace, branch isolation, plan execution, TDD, test first, failing test, bugfix, regression proof, E2E, end-to-end, acceptance test, test suite, acceptance gate, parallel agents, subagent, independent task, coordinator, debugging, root cause, unexpected behavior, verification failure).
Use when drafting or revising technical design, API endpoint contracts, or advancing a service from evidence into design and implementation readiness (technical design, backend design, platform design, module boundary, API design, endpoint contract, validation, error code, service delivery, design closure, implementation readiness).
Use when researching a topic, discovering or clarifying requirements, tracing evidence, or investigating a technical spike (research, investigation, topic research, technology evaluation, domain analysis, findings report, requirements discovery, elicitation, requirements document, feature definition, use case analysis, requirement clarification, scope definition, acceptance, functional boundary, evidence trace, traceability, data mapping, reference mapping, technical spike, evidence gap, option comparison).
Use when splitting scope into executable implementation slices, or when strengthening test and acceptance coverage (implementation breakdown, delivery slices, task decomposition, test breakdown, acceptance, integration test, verification planning).
Use when renaming, moving, archiving, or cleaning up docs (archive, move, rename documents).
| name | generate-mermaid-flowchart |
| description | Use when rendering Mermaid syntax into diagram image files for docs or articles (mermaid, flowchart, diagram, PNG, SVG, visualization). |
| argument-hint | Mermaid code or description of the diagram to generate, e.g.: delivery lifecycle flowchart, service architecture diagram |
| user-invocable | true |
Render Mermaid diagrams into PNG or SVG images using the local Mermaid CLI (mmdc).
generate-ai-image instead.@mermaid-js/mermaid-cli installed globally: npm install -g @mermaid-js/mermaid-cli.Define the diagram. Write or receive the Mermaid syntax. If the user provides a description instead of code, draft the Mermaid code first. Use <br/> for line breaks inside node labels (not \n).
Save the Mermaid source. Write the Mermaid code to a .mmd file in the target output directory (e.g., assets/diagrams/).
Render the image. Run the appropriate script:
.github/skills/generate-mermaid-flowchart/scripts/render-mermaid.ps1 -InputFile <path.mmd> -OutputFile <path.png> -Format png.github/skills/generate-mermaid-flowchart/scripts/render-mermaid.sh <path.mmd> <path.png> pngVerify the output. Confirm the output image file exists and is non-empty.
Update references. Replace inline Mermaid code blocks or text-art diagrams in the target document with .
| Script | Platform | Purpose |
|---|---|---|
scripts/render-mermaid.ps1 | Windows (PowerShell) | Render .mmd to PNG/SVG via mmdc |
scripts/render-mermaid.sh | Linux / macOS (Bash) | Render .mmd to PNG/SVG via mmdc |
| Parameter | Required | Default | Description |
|---|---|---|---|
InputFile | Yes | — | Path to .mmd file containing Mermaid syntax |
OutputFile | No | <InputFile basename>.<format> | Output image file path |
Format | No | png | Output format: png or svg |
assets/diagrams/ or alongside the document using them..mmd source file next to the output image for future regeneration.delivery-lifecycle.mmd, service-architecture.mmd.flowchart / graph — process flows, decision trees, lifecycle diagramssequenceDiagram — API call sequences, interaction flowsclassDiagram — entity relationships, data modelsstateDiagram — state machineserDiagram — database entity relationshipsgantt — timeline and schedulingpie — proportional datamindmap — concept maps