/minimalist-entrepreneur:draw-diagramfrom minimalist-entrepreneur
画图路由器——根据图的类型选择最合适的画图工具。序列图/流程图用 mermaid(嵌 markdown,不渲染);模块关系图/架构图默认用 fireworks-tech-graph(手动坐标、可控、文本化几何校验);简单图可用 d2,d2 自动布局调整两轮仍不合格就切 fireworks。当需要画任何图时使用。
Ships in minimalist-entrepreneur. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
先判断图的类型,再选工具。选型错了的代价(自动布局洗牌、反复截图烧 token)远大于多花 10 秒判断。
| 图的类型 | 工具 | 理由 |
|---|---|---|
| 序列图、时序交互、状态机、简单流程图 | mermaid,直接嵌 markdown,不单独渲染 | 语义即布局,几乎没有排版自由度,也就不存在布局翻车 |
| 模块关系图、架构图(容器框 + 色块模块 + 带标签的边) | 默认 fireworks-tech-graph;图很简单(≤6 模块、无嵌套容器)可用 d2 | 见下「为什么架构图默认 fireworks」 |
| 数据图表(柱状/折线/散点) | 不用本 skill,用绘图库 | — |
升级规则:选了 d2 但自动布局连续调整 2 轮仍不合格(边穿框、标签压字、跨容器边绕远路),立即切 fireworks,不要继续跟布局引擎搏斗。预估"模块多、关系杂、有嵌套容器"时跳过 d2 直接 fireworks。
check 命令输出碰撞/截断/交叉的文本报告(精确到元素 ID),迭代不用把截图读回模型;d2 只能渲染成图亲眼看,每张截图几千 tokenskills/fireworks-tech-graph/,输入格式见 schemas/diagram-v1.schema.json,风格见 references/style-*.md(教程文档推荐 Style 1 或 4,浅色)python3 skills/fireworks-tech-graph/scripts/fireworks.py validate|render|check|export-html <输入.json>validate → render → check 拿文本报告修几何问题 → export-html(可缩放拖拽的离线查看版)font-family: ... 整串替换为 font-family: 'Noto Sans CJK SC', sans-serif(本机已装该字体与 cairosvg):
sed "s/font-family: [^;\"]*/font-family: 'Noto Sans CJK SC', sans-serif/g" in.svg > in-cjk.svg
python3 -c "import cairosvg; cairosvg.svg2png(url='in-cjk.svg', write_to='out.png', scale=2.0)"
skills/d2-diagrams/SKILL.md,二进制在 bin/d2(v0.7.1,ELK 引擎;TALA 未装)What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub linjiaqin12138/skills --plugin minimalist-entrepreneur29 skills in this plugin
/clone-from-scratch-tutor把一个开源仓库做成可断点续作的从零实现教程。当用户给出仓库地址,并要求手搓、从零实现、按里程碑学习作者的设计时使用。只想要代码导读、跑起来或一次架构介绍时不用。/company-valuesHelp define company values and culture for a minimalist business. Use when someone is setting up their company culture, preparing to hire, or wanting to codify what their company stands for./concept-writer当需要把一个概念落成可链接的概念页或深读页,或教程里的背景卡片装不下这个概念时使用。正文覆盖本次用点及其依赖、讲到够用;「去学」仅供深入。Other plugins' skills for the same job