← 返回
未分类 中文

Excalidraw Architect

Build or revise architecture diagrams directly in excalidraw.com from natural-language requirements. Use when the user asks to draw, update, clean up, or res...
在 excalidraw.com 直接根据自然语言需求构建或修改架构图。当用户要求绘图、更新、清理或恢复时使用。
energypantry energypantry 来源
未分类 clawhub v1.0.0 1 版本 100000 Key: 无需
★ 0
Stars
📥 411
下载
💾 24
安装
1
版本
#latest

概述

Excalidraw Architect

Overview

Generate structured architecture diagrams in Excalidraw by scripting scene elements (rectangles, text, arrows) through the page runtime API, then iterating quickly based on user feedback.

Workflow

1) Open and verify the Excalidraw tab

Open https://excalidraw.com/ in the browser tool and keep using the same targetId for all edits.

If the user already has a board open, reuse that tab instead of creating a new one.

2) Get Excalidraw runtime API from the page

Use an evaluate action to locate excalidrawAPI from the React fiber tree.

If API lookup fails, refresh once and retry.

Use this lookup logic (or equivalent):

  • find .excalidraw root
  • read __reactFiber$*
  • traverse child/sibling fibers
  • pick node where memoizedProps.excalidrawAPI.updateScene exists

3) Build scene elements from the requested architecture

Translate the user’s request into:

  • container blocks (rectangles)
  • section labels and body text
  • directional arrows between blocks

Prefer clear readable layout:

  • title at top
  • left-to-right data flow unless user requests otherwise
  • enough spacing to avoid overlap

4) Write scene to canvas

Call api.updateScene({ elements, appState }) and then api.scrollToContent(elements, { fitToContent: true }).

When user requests changes, rewrite the scene deterministically (do not partially patch random elements unless user asks for tiny edits).

5) Confirm result

Send a short completion message and mention what changed.

Editing Rules

  • Preserve user’s scope boundaries (example: “only draw to Raw Data Pool”).
  • Keep language concise and business-readable.
  • Prefer complete labels over abbreviations.
  • If text is too dense, split into multiple lines.
  • If user asks for “only one layer”, remove downstream blocks explicitly.

Reusable Resources

scripts/

  • scripts/generate_excalidraw_scene.py: convert a JSON spec into Excalidraw element JSON.

references/

  • references/excalidraw-api-snippets.md: tested API discovery and update snippets for browser evaluate calls.

Use scripts/resources when diagrams are large or need repeatable generation.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-31 18:27 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

design-media

Openai Whisper

steipete
使用 Whisper CLI 进行本地语音转文字(无需 API 密钥)
★ 335 📥 94,641
design-media

UI/UX Pro Max

xobi667
提供 UI/UX 设计智能与实现指导,帮助打造精美界面。适用于 UI 设计、UX 流程、信息架构、视觉风格、设计系统/标记、组件规格、文案/微文案、无障碍及前端 UI(HTML/CSS/JS、React、Next.js、Vue、Svelte
★ 227 📥 48,790
business-ops

LeadsDaddy B2B Lead Finder

energypantry
使用LeadsDaddy(MCP)寻找全球B2B潜在客户,包括进口商、分销商、批发商、餐饮供应商等。
★ 0 📥 466