feat: replace all mermaid diagrams with drawio-style SVGs in gen2D deck
Deploy Slides / build-and-deploy (push) Failing after 59s

This commit is contained in:
2026-05-30 22:14:23 +08:00
parent 1a297e57a9
commit 6014a576ff
8 changed files with 273 additions and 33 deletions
+65
View File
@@ -0,0 +1,65 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 300" font-family="Microsoft YaHei, PingFang SC, Helvetica, Arial, sans-serif">
<defs>
<filter id="shadow" x="-2%" y="-2%" width="104%" height="104%">
<feDropShadow dx="1" dy="1" stdDeviation="2" flood-opacity="0.12"/>
</filter>
<marker id="arrow" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#6c8ebf"/>
</marker>
</defs>
<!-- USER -->
<rect x="40" y="80" width="150" height="120" rx="8" fill="#dae8fc" stroke="#6c8ebf" stroke-width="1.5" filter="url(#shadow)"/>
<rect x="40" y="80" width="150" height="32" rx="8" fill="#6c8ebf"/>
<text x="115" y="102" font-size="13" fill="#fff" text-anchor="middle" font-weight="bold">USER</text>
<text x="55" y="132" font-size="11" fill="#333">🔑 id (base62)</text>
<text x="55" y="150" font-size="11" fill="#333">username</text>
<text x="55" y="168" font-size="11" fill="#333">password_hash</text>
<text x="55" y="186" font-size="10" fill="#888">(bcrypt)</text>
<!-- USER → PROJECT (1:N) -->
<line x1="192" y1="140" x2="248" y2="140" stroke="#6c8ebf" stroke-width="2" marker-end="url(#arrow)"/>
<text x="220" y="132" font-size="10" fill="#6c8ebf" text-anchor="middle">1 : N</text>
<!-- PROJECT -->
<rect x="250" y="60" width="150" height="160" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<rect x="250" y="60" width="150" height="32" rx="8" fill="#82b366"/>
<text x="325" y="82" font-size="13" fill="#fff" text-anchor="middle" font-weight="bold">PROJECT</text>
<text x="265" y="112" font-size="11" fill="#333">🔑 id</text>
<text x="265" y="130" font-size="11" fill="#333">user_id (FK)</text>
<text x="265" y="148" font-size="11" fill="#333">name</text>
<text x="265" y="166" font-size="11" fill="#333">description</text>
<!-- PROJECT → PROJECT_STYLE (1:1) -->
<line x1="402" y1="110" x2="458" y2="110" stroke="#82b366" stroke-width="2" marker-end="url(#arrow)"/>
<text x="430" y="102" font-size="10" fill="#82b366" text-anchor="middle">1 : 1</text>
<!-- PROJECT_STYLE -->
<rect x="460" y="50" width="150" height="120" rx="8" fill="#fff2cc" stroke="#d6b656" stroke-width="1.5" filter="url(#shadow)"/>
<rect x="460" y="50" width="150" height="32" rx="8" fill="#d6b656"/>
<text x="535" y="72" font-size="12" fill="#fff" text-anchor="middle" font-weight="bold">PROJECT_STYLE</text>
<text x="475" y="102" font-size="11" fill="#333">🔑 project_id (FK)</text>
<text x="475" y="120" font-size="11" fill="#333">kv_pairs (JSON)</text>
<text x="475" y="150" font-size="10" fill="#888">artStyle, palette, ...</text>
<!-- PROJECT → TASK (1:N) -->
<line x1="325" y1="222" x2="325" y2="248" stroke="#6c8ebf" stroke-width="2" marker-end="url(#arrow)"/>
<text x="340" y="240" font-size="10" fill="#6c8ebf">1 : N</text>
<!-- TASK -->
<rect x="230" y="250" width="190" height="40" rx="6" fill="#e1d5e7" stroke="#9673a6" stroke-width="1.5" filter="url(#shadow)"/>
<text x="325" y="275" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">TASK</text>
<text x="240" y="275" font-size="10" fill="#888" dx="85">prompt · status · style_override</text>
<!-- TASK → ASSET (1:N) -->
<line x1="422" y1="270" x2="478" y2="270" stroke="#9673a6" stroke-width="2" marker-end="url(#arrow)"/>
<text x="450" y="262" font-size="10" fill="#9673a6" text-anchor="middle">1 : N</text>
<!-- ASSET -->
<rect x="480" y="250" width="190" height="40" rx="6" fill="#f8cecc" stroke="#b85450" stroke-width="1.5" filter="url(#shadow)"/>
<text x="575" y="275" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">ASSET</text>
<text x="490" y="275" font-size="10" fill="#888" dx="85">file_url · metadata</text>
<!-- 七牛云 label -->
<text x="700" y="275" font-size="10" fill="#999">→ 七牛云 Kodo</text>
</svg>

After

Width:  |  Height:  |  Size: 3.9 KiB

+64
View File
@@ -0,0 +1,64 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 700 420" font-family="Microsoft YaHei, PingFang SC, Helvetica, Arial, sans-serif">
<defs>
<filter id="shadow" x="-2%" y="-2%" width="104%" height="104%">
<feDropShadow dx="1" dy="1" stdDeviation="2" flood-opacity="0.12"/>
</filter>
<marker id="arrow" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#6c8ebf"/>
</marker>
<marker id="arrow-gray" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#999"/>
</marker>
<marker id="arrow-green" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#82b366"/>
</marker>
</defs>
<!-- User -->
<rect x="280" y="15" width="140" height="45" rx="8" fill="#dae8fc" stroke="#6c8ebf" stroke-width="1.5" filter="url(#shadow)"/>
<text x="350" y="43" font-size="14" fill="#333" text-anchor="middle" font-weight="bold">User</text>
<!-- Arrow: User → nginx -->
<line x1="350" y1="62" x2="350" y2="95" stroke="#6c8ebf" stroke-width="2" marker-end="url(#arrow)"/>
<text x="365" y="83" font-size="10" fill="#6c8ebf">HTTP</text>
<!-- Docker Compose 外框 -->
<rect x="80" y="100" width="540" height="170" rx="10" fill="none" stroke="#82b366" stroke-width="2" stroke-dasharray="8,4"/>
<text x="100" y="125" font-size="12" fill="#82b366" font-weight="bold">Docker Compose</text>
<!-- nginx 容器 -->
<rect x="110" y="140" width="200" height="60" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<text x="210" y="167" font-size="13" fill="#333" text-anchor="middle" font-weight="bold">nginx 容器</text>
<text x="210" y="187" font-size="10" fill="#666" text-anchor="middle">静态资源 + 反向代理</text>
<!-- Arrow: nginx → app -->
<line x1="312" y1="170" x2="370" y2="170" stroke="#82b366" stroke-width="2" marker-end="url(#arrow-green)"/>
<text x="340" y="162" font-size="10" fill="#82b366" text-anchor="middle">proxy_pass</text>
<!-- app 容器 -->
<rect x="373" y="140" width="200" height="60" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<text x="473" y="167" font-size="13" fill="#333" text-anchor="middle" font-weight="bold">app 容器</text>
<text x="473" y="187" font-size="10" fill="#666" text-anchor="middle">Go 二进制 + SQLite</text>
<!-- Port label -->
<text x="210" y="230" font-size="10" fill="#666" text-anchor="middle">暴露 8080 端口</text>
<!-- Arrow: app → 外部服务 -->
<line x1="473" y1="202" x2="473" y2="295" stroke="#999" stroke-width="2" stroke-dasharray="6,3" marker-end="url(#arrow-gray)"/>
<!-- 外部服务外框 -->
<rect x="140" y="300" width="420" height="100" rx="10" fill="#f5f5f5" stroke="#999" stroke-width="1" stroke-dasharray="6,3"/>
<text x="160" y="325" font-size="11" fill="#333" font-weight="bold">外部服务</text>
<!-- 七牛云 Kodo -->
<rect x="160" y="340" width="120" height="40" rx="6" fill="#fff2cc" stroke="#d6b656" stroke-width="1"/>
<text x="220" y="365" font-size="11" fill="#333" text-anchor="middle">七牛云 Kodo</text>
<!-- DeepSeek LLM -->
<rect x="295" y="340" width="120" height="40" rx="6" fill="#fff2cc" stroke="#d6b656" stroke-width="1"/>
<text x="355" y="365" font-size="11" fill="#333" text-anchor="middle">DeepSeek LLM</text>
<!-- Stability AI -->
<rect x="430" y="340" width="120" height="40" rx="6" fill="#fff2cc" stroke="#d6b656" stroke-width="1"/>
<text x="490" y="365" font-size="11" fill="#333" text-anchor="middle">Stability AI</text>
</svg>

After

Width:  |  Height:  |  Size: 3.7 KiB

+63
View File
@@ -0,0 +1,63 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 960 180" font-family="Microsoft YaHei, PingFang SC, Helvetica, Arial, sans-serif">
<defs>
<filter id="shadow" x="-2%" y="-2%" width="104%" height="104%">
<feDropShadow dx="1" dy="1" stdDeviation="2" flood-opacity="0.12"/>
</filter>
<marker id="arrow-blue" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#6c8ebf"/>
</marker>
<marker id="arrow-red" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#b85450"/>
</marker>
<marker id="arrow-green" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#82b366"/>
</marker>
</defs>
<!-- 用户输入 -->
<rect x="20" y="55" width="100" height="50" rx="8" fill="#dae8fc" stroke="#6c8ebf" stroke-width="1.5" filter="url(#shadow)"/>
<text x="70" y="85" font-size="13" fill="#333" text-anchor="middle" font-weight="bold">用户输入</text>
<!-- Arrow: 用户输入 → PromptOptimizer -->
<line x1="122" y1="80" x2="155" y2="80" stroke="#6c8ebf" stroke-width="2" marker-end="url(#arrow-blue)"/>
<!-- PromptOptimizer -->
<rect x="158" y="45" width="140" height="70" rx="8" fill="#f8cecc" stroke="#b85450" stroke-width="1.5" filter="url(#shadow)"/>
<text x="228" y="73" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">Prompt</text>
<text x="228" y="91" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">Optimizer</text>
<!-- Arrow: → AssetGenerator -->
<line x1="300" y1="80" x2="333" y2="80" stroke="#b85450" stroke-width="2" marker-end="url(#arrow-red)"/>
<!-- AssetGenerator -->
<rect x="336" y="45" width="140" height="70" rx="8" fill="#f8cecc" stroke="#b85450" stroke-width="1.5" filter="url(#shadow)"/>
<text x="406" y="73" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">Asset</text>
<text x="406" y="91" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">Generator</text>
<!-- Arrow: → 质检 -->
<line x1="478" y1="80" x2="511" y2="80" stroke="#b85450" stroke-width="2" marker-end="url(#arrow-red)"/>
<!-- 质检(菱形) -->
<polygon points="570,30 630,80 570,130 510,80" fill="#fff2cc" stroke="#d6b656" stroke-width="1.5" filter="url(#shadow)"/>
<text x="570" y="84" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">质检</text>
<!-- Arrow: 通过 → FormatAdapter -->
<line x1="632" y1="80" x2="665" y2="80" stroke="#82b366" stroke-width="2" marker-end="url(#arrow-green)"/>
<text x="648" y="72" font-size="10" fill="#82b366" text-anchor="middle">通过</text>
<!-- FormatAdapter -->
<rect x="668" y="45" width="140" height="70" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<text x="738" y="73" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">Format</text>
<text x="738" y="91" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">Adapter</text>
<!-- Arrow: → 输出 -->
<line x1="810" y1="80" x2="843" y2="80" stroke="#82b366" stroke-width="2" marker-end="url(#arrow-green)"/>
<!-- 输出 -->
<rect x="846" y="55" width="90" height="50" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<text x="891" y="85" font-size="13" fill="#333" text-anchor="middle" font-weight="bold">输出</text>
<!-- 不通过 → 回退到 PromptOptimizer -->
<path d="M 570,132 L 570,160 L 228,160 L 228,117" fill="none" stroke="#b85450" stroke-width="2" stroke-dasharray="6,3" marker-end="url(#arrow-red)"/>
<text x="400" y="153" font-size="10" fill="#b85450" text-anchor="middle">不通过(重试≥3走降级)</text>
</svg>

After

Width:  |  Height:  |  Size: 3.8 KiB

+70
View File
@@ -0,0 +1,70 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 880 160" font-family="Microsoft YaHei, PingFang SC, Helvetica, Arial, sans-serif">
<defs>
<filter id="shadow" x="-2%" y="-2%" width="104%" height="104%">
<feDropShadow dx="1" dy="1" stdDeviation="2" flood-opacity="0.12"/>
</filter>
<marker id="arrow-blue" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#6c8ebf"/>
</marker>
<marker id="arrow-green" viewBox="0 0 10 10" refX="10" refY="5" markerWidth="8" markerHeight="8" orient="auto-start-reverse">
<path d="M 0 0 L 10 5 L 0 10 z" fill="#82b366"/>
</marker>
</defs>
<!-- 用户描述 -->
<rect x="20" y="55" width="100" height="50" rx="8" fill="#dae8fc" stroke="#6c8ebf" stroke-width="1.5" filter="url(#shadow)"/>
<text x="70" y="75" font-size="11" fill="#333" text-anchor="middle" font-weight="bold">用户</text>
<text x="70" y="91" font-size="11" fill="#333" text-anchor="middle">描述</text>
<!-- Arrow -->
<line x1="122" y1="80" x2="148" y2="80" stroke="#6c8ebf" stroke-width="2" marker-end="url(#arrow-blue)"/>
<!-- 风格合并 -->
<rect x="150" y="40" width="120" height="80" rx="8" fill="#fff2cc" stroke="#d6b656" stroke-width="1.5" filter="url(#shadow)"/>
<text x="210" y="75" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">风格合并</text>
<text x="210" y="93" font-size="10" fill="#666" text-anchor="middle">merge()</text>
<!-- 工程风格 input -->
<line x1="210" y1="38" x2="210" y2="10" stroke="#d6b656" stroke-width="1.5"/>
<rect x="155" y="-15" width="110" height="25" rx="4" fill="#f5f5f5" stroke="#d6b656" stroke-width="1"/>
<text x="210" y="2" font-size="10" fill="#333" text-anchor="middle">工程风格</text>
<!-- 任务覆盖 input -->
<line x1="210" y1="122" x2="210" y2="148" stroke="#d6b656" stroke-width="1.5"/>
<rect x="155" y="148" width="110" height="25" rx="4" fill="#f5f5f5" stroke="#d6b656" stroke-width="1"/>
<text x="210" y="165" font-size="10" fill="#333" text-anchor="middle">任务覆盖</text>
<!-- Arrow -->
<line x1="272" y1="80" x2="298" y2="80" stroke="#d6b656" stroke-width="2" marker-end="url(#arrow-blue)"/>
<!-- 三段式组装 -->
<rect x="300" y="40" width="120" height="80" rx="8" fill="#e1d5e7" stroke="#9673a6" stroke-width="1.5" filter="url(#shadow)"/>
<text x="360" y="68" font-size="11" fill="#333" text-anchor="middle" font-weight="bold">三段式</text>
<text x="360" y="84" font-size="11" fill="#333" text-anchor="middle" font-weight="bold">组装</text>
<text x="360" y="102" font-size="9" fill="#888" text-anchor="middle">描述+风格+规格</text>
<!-- Arrow -->
<line x1="422" y1="80" x2="448" y2="80" stroke="#9673a6" stroke-width="2" marker-end="url(#arrow-blue)"/>
<!-- LLM 优化 -->
<rect x="450" y="40" width="120" height="80" rx="8" fill="#f8cecc" stroke="#b85450" stroke-width="1.5" filter="url(#shadow)"/>
<text x="510" y="68" font-size="11" fill="#333" text-anchor="middle" font-weight="bold">LLM 优化</text>
<text x="510" y="84" font-size="10" fill="#666" text-anchor="middle">DeepSeek</text>
<text x="510" y="102" font-size="9" fill="#b85450" text-anchor="middle">无Key回退模板</text>
<!-- Arrow -->
<line x1="572" y1="80" x2="598" y2="80" stroke="#b85450" stroke-width="2" marker-end="url(#arrow-blue)"/>
<!-- 最终提示词 -->
<rect x="600" y="55" width="120" height="50" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<text x="660" y="75" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">最终</text>
<text x="660" y="91" font-size="12" fill="#333" text-anchor="middle" font-weight="bold">提示词</text>
<!-- Arrow to AssetGenerator -->
<line x1="722" y1="80" x2="748" y2="80" stroke="#82b366" stroke-width="2" marker-end="url(#arrow-green)"/>
<!-- AssetGenerator -->
<rect x="750" y="55" width="110" height="50" rx="8" fill="#d5e8d4" stroke="#82b366" stroke-width="1.5" filter="url(#shadow)"/>
<text x="805" y="75" font-size="11" fill="#333" text-anchor="middle" font-weight="bold">Asset</text>
<text x="805" y="91" font-size="11" fill="#333" text-anchor="middle" font-weight="bold">Generator</text>
</svg>

After

Width:  |  Height:  |  Size: 4.2 KiB