agentleFS
xiaoshuai1024xiaoshuai1024/skills/skills/excalidraw/SKILL.md

excalidraw

Skill1 starsChanged 3 months agoMITView on GitHub

Use when the user wants to create or render hand-drawn style diagrams (flowcharts, architecture diagrams, ER diagrams, sequence diagrams, wireframes) as Excalidraw scenes, and export them to SVG/PNG. Triggers on words like "diagram", "flowchart", "draw", "architecture diagram", "excalidraw", or a request to visualize a system or process.

69 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use heartmula, webhook-subscriptions and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • math-incSkill

    heartmula

    Set up and run HeartMuLa, the open-source music generation model family (Suno-like). Generates full songs from lyrics + tags with multilingual support.

    Also in 9 projects that use this

  • Tommy-ywSkill

    webhook-subscriptions

    Create and manage webhook subscriptions for event-driven agent activation, or for direct push notifications (zero LLM cost). Use when the user wants external services to trigger agent runs OR push notifications to chats.

    Also in 5 projects that use this

  • john-data-chenSkill

    touchdesigner-mcp

    Control a running TouchDesigner instance via twozero MCP — create operators, set parameters, wire connections, execute Python, build real-time visuals. 36 native tools.

    Also in 7 projects that use this

  • math-incSkill

    minecraft-modpack-server

    Set up a modded Minecraft server from a CurseForge/Modrinth server pack zip. Covers NeoForge/Forge install, Java version, JVM tuning, firewall, LAN config, backups, and launch scripts.

    Also in 5 projects that use this

  • AlekseiULSkill

    TubeScribe

    YouTube video summarizer with speaker detection, formatted documents, and audio output. Works out of the box with macOS built-in TTS. Optional recommended tools (pandoc, ffmpeg, mlx-audio) enhance quality. Requires internet for YouTube access. No paid APIs or subscriptions. Use when user sends a YouTube URL or asks to summarize/transcribe a YouTube video.

    Also in 3 projects that use this

  • mae616Skill

    p5js

    p5.js(クリエイティブコーディング)のProcessing由来「コードでスケッチ」思想を軸に、setup/drawループ・座標系・インタラクション・パフォーマンス最適化を整理する。p5.js、Processing、クリエイティブコーディング、ジェネラティブアート、インタラクティブ表現、ビジュアルプログラミング、Canvas描画、パーティクル、フラクタル、ノイズ表現に関する相談で必ず使うこと。ユーザーが「コードでアート」「動くビジュアル」「インタラクティブな描画」と言った場合にも適用する。

    Also in 10 projects that use this

  • +5 more from math-inc

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 4 are distinctive, and 3 are very specific to this project.

  • 0

    Common

    Most of the 64 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Create Excalidraw scene JSON files and render them to SVG (and optionally PNG) using the real Excalidraw engine.

    line 8
  2. Distinctive:

    If rendering fails with a playwright/Chromium error, run the installer:

    line 37
  3. Very specific:

    Build the scene JSON: Use references/element-templates.md for copy-paste templates of each element type (rectangle, ellipse, diamond, …

    line 54
  4. Very specific:

    NOT the top-left corner. Excalidraw treats x/y as the text anchor when textAlign="center"/verticalAlign="middle".

    line 67
  5. Very specific:

    Leave seed as null: Do not hardcode seed values.

    line 86
  6. Distinctive:

    Use free-floating text (containerId null) for titles and section labels rather than wrapping everything in boxes.

    line 116
  7. Distinctive:

    No built-in overlap detection: If shapes overlap, the render will show it — review the output SVG and adjust coordinates.

    line 146

“Common” is measured: kept by at least 6 in 10 of the 64 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Excalidraw Diagram Skill

Create Excalidraw scene JSON files and render them to SVG (and optionally PNG) using the real Excalidraw engine. Output is hand-drawn style, vector, and the SVG can be dragged back into excalidraw.com for further editing.

When to use

  • User asks for a diagram, flowchart, architecture sketch, ER diagram, or sequence diagram in a hand-drawn / sketchy style.
  • User says "draw", "visualize", "diagram" and wants an image file out.

When NOT to use

  • The user wants a pixel-perfect / corporate-clean diagram (use a vector tool).
  • The user wants to EDIT interactively right now (point them to excalidraw.com).
  • The diagram needs automatic layout (this skill does NOT auto-layout; you compute coordinates by hand — see Known Limitations).

How it works (read this once)

  1. You write an .excalidraw JSON scene file (elements with x/y/size/style).
  2. scripts/render.py drives headless Chromium, loads the official @excalidraw/excalidraw package, runs the scene through Excalidraw's restore() + convertToExcalidrawElements() (to normalize fields and recompute text metrics), then calls exportToSvg — so the render is the genuine Excalidraw look, not a reimplementation.
  3. It outputs SVG (default) and/or PNG.

First-time setup

If rendering fails with a playwright/Chromium error, run the installer:

bash scripts/install.sh

This installs the playwright Python package and the Chromium binary (~150MB, one-time). It does NOT require npm or node — Excalidraw itself is loaded from the esm.sh CDN at render time (so an internet connection is needed on render).

Creating a diagram

  1. Plan the layout. Decide the shapes and how they connect. Sketch the coordinates on paper first — this skill does not auto-layout, so you are responsible for non-overlapping positions.
  2. Build the scene JSON. Use references/element-templates.md for copy-paste templates of each element type (rectangle, ellipse, diamond, arrow, text). Start from references/examples/flowchart.excalidraw as a working skeleton. Before laying out coordinates from scratch, check references/examples/real-world/ — 16 production diagrams from published articles (timelines, mental models, ladders, pipelines, gates), indexed by diagram type in real-world/index.md. Copy the closest match as your skeleton and edit it; their coordinates, spacing, and arrow routing are field-tested.
  3. ALIGNMENT HARD RULE (do not skip): For any text with a non-null containerId, set x/y to the CENTER of the container (container.x + container.width/2, container.y + container.height/2), NOT the top-left corner. Excalidraw treats x/y as the text anchor when textAlign="center"/verticalAlign="middle". Wrong coordinates = text rendered outside the box. Free-floating text (containerId: null) keeps top-left x/y. Two verification gates:

    # Gate 1 — before rendering: anchors equal container centers
    python3 scripts/check_alignment.py <file.excalidraw>
    
    # Gate 2 — after rendering: text centers equal container centers
    # (--scene filters out free-floating texts; omit it to check everything)
    python3 scripts/render.py <file.excalidraw> --format svg
    python3 scripts/verify_svg_alignment.py <file>.svg --scene <file.excalidraw>

    Gate 2 is the authoritative check: exportToSvg renders each bound-text group's visual center at translate + (rx, ry), so the renderer template repositions labels to (container center - measured/2) before export.

  4. Leave seed as null. Do not hardcode seed values. The render script injects a random seed per element so identical shapes wobble differently — that variation IS the hand-drawn look. Hardcoded seeds make the diagram look stamped and dead.
  5. Write the file with the .excalidraw extension, e.g. login-flow.excalidraw.
  6. Render it:

    python3 scripts/render.py login-flow.excalidraw

    By default this produces login-flow.svg AND login-flow.png next to the input. Options:

    • --format svg or --format png to get only one
    • --output path/stem to control output location (stem, no extension)
    • --scale 3 for higher-resolution PNG (SVG is always vector)
    • --keep-seed to reproduce a previous render exactly
  7. Open the result (the SVG is preferred — crisp, editable). If you want to revise, edit the .excalidraw JSON and re-render. You can also drag the SVG back into excalidraw.com to edit interactively.

Layout tips (since there's no auto-layout)

  • Give each shape ~40-80px of padding around it.
  • Vertical flowcharts: stack shapes 150px apart vertically.
  • Arrows: set points relative to the arrow's own x,y, and bind both ends via startBinding/endBinding so the arrow tracks the shapes.
  • Use free-floating text (containerId null) for titles and section labels rather than wrapping everything in boxes.
  • See examples/flowchart.excalidraw for concrete coordinate values that work.

Element types at a glance

TypeUse for
rectangleprocesses, components, services (rounded via roundness:{type:3})
ellipsestart/end states, external systems
diamonddecisions, conditionals
arrowdirected connections (binds to shapes)
lineundirected structural lines
textlabels inside shapes (containerId) or free-floating titles

Full templates + the binding recipe: references/element-templates.md.

Default colors

Unless the user specifies a palette, use Excalidraw defaults: #1e1e1e strokes; fills green #b2f2bb, blue #a5d8ff, yellow #ffec99, red #ffc9c9, purple #eebefa. See the palette table in element-templates.md.

Known limitations (be honest with the user)

  • No auto-layout. You compute all x/y coordinates. For >10 elements this gets tedious; keep diagrams modest or the user should edit in excalidraw.com.
  • Requires network on render (loads Excalidraw from esm.sh CDN). Offline rendering is not supported by this version.
  • No batch rendering. One file at a time.
  • No built-in overlap detection. If shapes overlap, the render will show it — review the output SVG and adjust coordinates.

Files

PathPurpose
scripts/render.pyThe renderer (run this)
scripts/render_template.htmlBrowser page that loads Excalidraw (don't edit casually)
scripts/install.shOne-time dependency installer
references/element-templates.mdJSON templates for every element type
references/examples/flowchart.excalidrawWorking example scene
references/examples/real-world/16 production diagrams from published articles (index inside)

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.