Excalidraw
Skill này làm gì
Vẽ sơ đồ theo phong cách vẽ tay trên một canvas Excalidraw cục bộ mà bạn có thể theo dõi và chỉnh sửa. Skill dành cho người muốn biến một ý tưởng hoặc bản phác thô thành sơ đồ rõ ràng.
Khi nào nên dùng
- ✓Khi bạn muốn biến một ý tưởng thành sơ đồ vẽ tay trên bảng trắng.
- ✓Khi bạn muốn đọc một bản phác thô trên canvas như dữ liệu có cấu trúc.
- ✓Khi bạn cần chuyển một biểu đồ Mermaid thành bản vẽ Excalidraw có thể chỉnh sửa.
Liên kết skill
https://github.com/danielmiessler/LifeOS/blob/main/LifeOS/install/skills/Excalidraw/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Phác thảo một sơ đồ đơn giản về luồng đăng nhập của ứng dụng tôi trên bảng trắng.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Skill vẽ sơ đồ trên canvas cục bộ trong lúc làm việc, để bạn có thể xem và chỉnh sửa. Trước khi chia sẻ sơ đồ, skill kiểm tra chữ có dễ đọc ở cả nền sáng và nền tối không.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Excalidraw
Drives a live Excalidraw canvas from the command line via the community mcp-excalidraw-server package (MIT), version-pinned through Tools/Canvas.ts. The canvas runs locally; the user watches the diagram draw itself at the canvas URL and can hand-edit the moment the model stops. Two directions: model → canvas (sketch ideas) and canvas → model (describe reads a human's rough canvas back as structured data).
Ideal State
- Every diagram left behind is readable by the person it is for: no truncated or overlapping text, label style set at creation, and
Tools/ContrastCheck.tsexiting 0 against the real ground, which holds in light and dark themes alike. - What leaves the machine is the form that renders correctly: a link from
Tools/Share.tsfor a scene without images, the exported.excalidrawfile (or a PNG flattened from it) for a scene carrying screenshots, and never a local canvas screenshot as final art. - The canvas is driven only through
Tools/Canvas.ts, so the pinned package version and port hold, and the skill registers no MCP server. - A human's canvas is read back faithfully and nothing they drew is lost: risky changes are snapshotted first, and the detached server is stopped when the drawing work is done unless the user keeps using it.
Intent Routing
| Intent | Trigger | File |
|---|---|---|
| SketchDiagram | "sketch a diagram", "draw this", "put this on a canvas" | Intents/SketchDiagram.md |
| RefineDiagram | "refine the diagram", "read my canvas", "organize my whiteboard", edit an existing .excalidraw |
Intents/RefineDiagram.md |
| File | Read when |
|---|---|
References/Cheatsheet.md |
writing element JSON or using a command the intents do not show: full command list, element format, palette and sizing, layout anti-patterns, quality checklist, error recovery, raw REST API |
Data & Config
User customizations live at <configRoot>/LIFEOS/USER/CUSTOMIZATIONS/SKILLS/Excalidraw/ (configRoot is $CLAUDE_CONFIG_DIR when set, else ~/.claude). When the directory exists, its PREFERENCES.md (default export directory, preferred palette, canvas port override) applies; when it is absent, the defaults stand.
Quick Reference
- Tool:
bun ~/.claude/skills/Excalidraw/Tools/Canvas.ts <command> [...]— pinsmcp-excalidraw-server@2.0.0and port3579; all commands pass through. - Canvas URL:
http://127.0.0.1:3579— the user opens this to watch live and hand-edit. Any canvas-touching command auto-starts the server. - Contrast gate:
bun ~/.claude/skills/Excalidraw/Tools/ContrastCheck.ts [--bg <hex>]— deterministic WCAG check of every text element against its effective background; MUST exit 0 before any diagram is declared done. - Embed an image:
bun ~/.claude/skills/Excalidraw/Tools/AddImage.ts <image> --x N --y N [--w N --h N]or--replace <shapeId>to fit a screenshot inside an existing box. Registers the bytes as a data-URL file and adds animageelement; the file travels inside the exported.excalidraw. Use for real screenshots as diagram nodes (e.g. a dashboard capture as the "Agents Dashboard" node). - Black-canvas share:
bun ~/.claude/skills/Excalidraw/Tools/Share.ts <scene.excalidraw> [--bg <hex>]— uploads to excalidraw.com with the canvas background baked in (default#111114). Use it, never the CLIshare(which hardcodes a white canvas). The shared-link editor does not reliably honor the file'sviewBackgroundColoralone, so a non-white scene also carries a backdrop rectangle (Gotchas). - Exit codes: 0 ok, 1 error, 2 usage, 3 canvas unreachable, 4 browser tab required.
- Files: exported
.excalidrawfiles open at excalidraw.com (File → Open) or in the Excalidraw VS Code extension. A.excalidraw.mdexport targets the Obsidian plugin's native format.
Gotchas
- Label styling is set at CREATION, deterministically — the export/share expansion gives each bound label its shape's
strokeColorand the shape'sfontSizeprop (default 16). So: putfontSize: 20on labeled shapes, choose stroke colors that read on the fill, and give solid-color focal boxes a PALE fill with a saturated stroke (never saturated fill + dark stroke, which makes the label invisible). No post-add patching, no free-text label workaround — free labels detach from shapes and were retracted after live use (2026-08-26). The viewer's dark mode inverts the whole canvas, so colored text on colored fill can vanish even when a light-
Câu hỏi thường gặp
Tôi có thể sửa sơ đồ sau đó không?
Có. Bạn có thể chỉnh sửa canvas bằng tay ngay khi nét vẽ dừng lại.
Làm sao tôi chia sẻ sơ đồ?
Skill có thể tạo liên kết chia sẻ, hoặc xuất file .excalidraw hay PNG cho các cảnh có hình ảnh.
Nó có đọc được bản phác của tôi không?
Có. Nó có thể đọc một canvas bạn vẽ thô và trả về dưới dạng dữ liệu có cấu trúc.
Chi tiết
Mô tả gốc của tác giả
Sketches ideas as hand-drawn Excalidraw diagrams on a live local canvas via the pinned mcp-excalidraw-server CLI, with mermaid conversion, file I/O, and share links. USE WHEN excalidraw, whiteboard, canvas, sketch a diagram, draw this on a canvas, hand-drawn diagram, draw my idea, architecture sketch, live canvas, put this on the whiteboard, read my canvas, organize my whiteboard, .excalidraw file, mermaid to excalidraw. NOT FOR polished images (Art), web UI (Webdesign), video (HyperFrames).
repo: danielmiessler/LifeOS
Độ phổ biến
- Sao GitHub
- 20k
- Vị trí xếp hạng
- #10423
- Giấy phép
- MIT
- Cập nhật
- 28/10/2026
Bình luận
- …
Thêm skill từ kho mã này
LifeOS
20kGiúp agent của bạn thiết lập LifeOS, một hệ thống cá nhân ánh xạ trạng thái hiện tại tới trạng thái lý tưởng qua một cuộc phỏng vấn và một bảng điều khiển.
AnnualReports
20kGiúp agent của bạn tìm và so sánh báo cáo an ninh mạng thường niên từ các nhà cung cấp lớn, như xu hướng vi phạm và ransomware, có nguồn cho mọi số liệu.
ApertureOscillation
20kDạy agent của bạn kiểm tra một câu hỏi thiết kế ở phạm vi hẹp và phạm vi rộng, rồi chỉ ra chỗ hai câu trả lời mâu thuẫn trước khi bạn xây dựng.
Aphorisms
20kCho phép agent của bạn tìm, ghép và theo dõi các câu trích dẫn có ghi tác giả từ một bộ sưu tập được chọn lọc, tránh những câu vừa được dùng trong bản tin.
Skill tương tự
canvas
394kCho phép agent của bạn hiện một widget trực quan được lưu trữ trên bảng Mac đã kết nối, rồi ẩn bảng hoặc chuyển nó sang trang khác.
control-ui
394kGiúp agent của bạn sắp xếp và khắc phục sự cố Control UI của OpenClaw, gồm các phiên, bảng điều khiển và Gateway đã kết nối.
diagram-maker
394kGiúp agent của bạn vẽ sơ đồ rõ ràng dạng SVG, HTML hoặc Excalidraw có thể sửa, cho quy trình, kiến trúc hệ thống và bản phác bảng trắng.