← 返回 Skills 市场
zengiai

handdraw-flowchart

作者 zengiai · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ 安全检测通过
31
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install handdraw-flowchart
功能描述
Create hand-drawn workflow diagrams from natural-language process descriptions by generating strictly validated Mermaid flowchart, sequenceDiagram, or classD...
使用说明 (SKILL.md)

Handdraw Flowchart

Workflow

  1. Convert the user's natural-language process into one supported Mermaid diagram:

    • flowchart TD or flowchart LR for business processes, decision trees, and state transitions.
    • sequenceDiagram for actor/system interactions over time.
    • classDiagram for domain objects, DTOs, entities, interfaces, and relationships.
  2. Generate raw Mermaid only. Do not wrap it in Markdown fences when writing .mmd files.

  3. Read references/mermaid-generation-rules.md before producing non-trivial Mermaid, especially for sequence or class diagrams.

  4. Save the Mermaid source as \x3Cname>.mmd.

  5. Run the renderer script. It performs strict Mermaid parsing before conversion:

    cd \x3Cskill-directory>
    npm install
    node scripts/render-mermaid-handdraw.mjs --input /path/to/\x3Cname>.mmd --out-dir /path/to/output --name \x3Cname>
    

The script writes:

  • \x3Cname>.mmd: normalized Mermaid source
  • \x3Cname>.excalidraw: editable Excalidraw scene
  • \x3Cname>.png: rendered PNG

Conversion Contract

  • Treat flowchart as the primary hand-drawn path. It converts to native Excalidraw elements and gives the best editable sketch-style result.
  • Treat sequenceDiagram as supported but still verify output visually when the diagram is complex.
  • Treat classDiagram as supported with possible image fallback inside the Excalidraw scene. If the script reports image-fallback, the PNG is valid, but editability is limited.
  • Reject unsupported Mermaid diagram types instead of silently producing a lower-quality result.
  • Do not claim success until the renderer has completed without validation or export errors.

Strict Validation Rules

  • Run node scripts/render-mermaid-handdraw.mjs --input \x3Cfile> --validate-only after generating Mermaid if you need a fast syntax gate.
  • If validation fails, edit the Mermaid source and rerun. Do not bypass validation.
  • Prefer simple Mermaid syntax over clever syntax. Avoid custom CSS, HTML labels, Markdown tables inside labels, YAML frontmatter, and experimental Mermaid shape declarations.
  • Keep node IDs stable and ASCII where practical. Put user-facing Chinese text in labels, not IDs.

Rendering Notes

  • The script uses browser execution because Excalidraw export utilities require DOM/canvas APIs.
  • If Playwright has no bundled browser, the script tries common local Chrome/Chromium executable paths and honors CHROME_PATH.
  • For reproducible results, keep the versions pinned in package.json unless there is a specific reason to upgrade and retest the renderer.
安全使用建议
This looks safe to use for generating diagrams. Before installing, be comfortable with running npm install and a local Node/Playwright renderer, and choose a dedicated output directory for generated files.
功能分析
Type: OpenClaw Skill Name: handdraw-flowchart Version: 1.0.0 The skill bundle is a legitimate tool for converting natural-language process descriptions into hand-drawn style diagrams using Mermaid and Excalidraw. It utilizes Playwright to launch a headless browser for rendering and esbuild to dynamically bundle the necessary conversion libraries (mermaid, @excalidraw/excalidraw) at runtime. The script `scripts/render-mermaid-handdraw.mjs` includes security best practices such as enforcing Mermaid's 'strict' security level and sanitizing output filenames to prevent path traversal. While the skill requires significant permissions (filesystem access and browser execution), these capabilities are strictly aligned with its stated purpose, and no evidence of malicious intent, data exfiltration, or prompt injection was found.
能力标签
crypto
能力评估
Purpose & Capability
The SKILL.md, package metadata, and visible script behavior consistently support the stated purpose of validating Mermaid and exporting diagram files.
Instruction Scope
The workflow asks the agent to create files and run a local renderer, which is expected for this skill and constrained by validation rules and supported diagram types.
Install Mechanism
There is no automatic install spec, but the user-directed workflow requires npm install of pinned third-party packages from package.json/package-lock.json.
Credentials
The skill requires Node/npm and launches Playwright or a local Chrome/Chromium executable, which is proportionate for image export but worth noticing.
Persistence & Privilege
No credentials, background service, persistent memory, or privilege escalation are declared or evident; persistence is limited to generated .mmd, .excalidraw, and .png output files.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install handdraw-flowchart
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /handdraw-flowchart 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.0.0
Initial release of handdraw-flowchart. - Generates hand-drawn style workflow diagrams from natural-language process descriptions. - Converts strictly validated Mermaid (flowchart, sequenceDiagram, classDiagram) into Excalidraw scenes and exports PNG images. - Script ensures Mermaid syntax validity and supports rejection of unsupported diagram types. - Supports editable diagrams with best quality for flowcharts; sequence and class diagrams are supported with caveats. - Provides stepwise workflow and strict validation rules for consistent and reliable outputs.
元数据
Slug handdraw-flowchart
版本 1.0.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 1
常见问题

handdraw-flowchart 是什么?

Create hand-drawn workflow diagrams from natural-language process descriptions by generating strictly validated Mermaid flowchart, sequenceDiagram, or classD... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 31 次。

如何安装 handdraw-flowchart?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install handdraw-flowchart」即可一键安装,无需额外配置。

handdraw-flowchart 是免费的吗?

是的,handdraw-flowchart 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

handdraw-flowchart 支持哪些平台?

handdraw-flowchart 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 handdraw-flowchart?

由 zengiai(@zengiai)开发并维护,当前版本 v1.0.0。

💬 留言讨论