Sketchy README

The full upstream README, mirrored for reference. Install config, tool schemas, adoption signals and our own overview live on the Sketchy listing page.

Sketchy

Sketchy lets your AI assistant draw while it explains: clean, hand-drawn, interactive diagrams, pictures, molecules and maps rendered right next to the answer. It works in the Claude chat as a skill, including the Claude app on your phone, and as an MCP server in Claude Code, Codex, Cursor, VS Code and other MCP clients.

The AI decides what to draw and label. Sketchy decides where: a part library with named anchor points, automatic layout and ready-made shapes. The AI never computes coordinates (except on the small canvas of a free-hand picture), so drawings come out precise and consistent every time.

Sketchy in a chat: the answer to "How does a language model pick the next word?" comes with an interactive drawing, its toolbar and five steps to click through

What it can draw

Systems, step by step

Ask "What happens when I open a web page?" and the AI draws the whole path, then walks you through it. Each step lights up what matters in red and fades the rest: its lines glow, or on request beat, shake or redraw themselves, or a circle, a short underline, a highlighter stroke or a pointing arrow marks it. Photos and pictures without lines get a red frame. A step can also zoom the camera onto its part when the AI asks for it. Use the buttons or the arrow keys.

The life of a web request, from the browser through CDN, load balancer and services to cache, database and queue

Step 5 of the walkthrough: the orders service, cache and database glow red while the rest fades

Concepts from computer science and machine learning

Sketchy is not limited to hardware. Structure, flow, comparison and metaphor patterns cover any topic, from transformers to TCP.

How an LLM picks the next word: tokenizer, embeddings, a transformer block with self-attention and MLP, and sampling

Pictures that move

When boxes and arrows would hide the idea, the AI draws the thing itself: atoms, forces, orbits, a wing, the water cycle. A draw block has its own small canvas with circles, curves, shapes, arcs and text, ready-made objects (person, car, tree, cloud, sun, gear, drop and more) and icons. Sliders move shapes, as one piece or along a path, by hand or step by step, so a packet travels through the network and a droplet goes round the water cycle.

A droplet travels the water cycle: up from the sea, through the cloud, as rain onto the mountain and down the river back to the sea

Geometry and physics get helpers that would be fiddly by hand: angle with the right-angle square, measure for dimension lines, brace, axes and grid.

A right triangle with a right-angle mark and dimension lines: a = 3, b = 4, c = 5The water cycle as a ready-made cycle: evaporation, condensation, precipitation, collection

Stages: real things that change step by step

For cooking, experiments, repairs or a day in a life, the AI puts real things on a stage and only says how they relate: the pan is on the stove, the eggs are in the bowl, the bowl is over the pan. Sketchy places and scales everything at about its real size. Each step changes the stage: things glide to new places, fill up, heat up, crack, melt or get chopped, a tilted bowl pours, and steam, bubbles, flames and stirring keep moving. Recipe cards tick off ingredients and scale with a servings slider.

Boiling water on a stage: a beaker on a tripod over a Bunsen burner, the thermometer glowing redScrambled eggs: a recipe card with ticked-off ingredients above a stove, the bowl pouring eggs into the pan

Packs bring the things and cards for each field: a workshop with tools, materials and a kit card that ticks off parts per step, a lab with glassware, burners and equation cards, a body with organs and cells, inference with a language-model walk from tokens to the next word, and trading with candlestick charts, trade plans and order books.

Hang a shelf: a kit card with tools and parts next to a brick wall with the drill in itHow a model picks the next word: tokens, embeddings and three layers with attention arcs glowing red
A trade plan on paper: eight candles, a planned entry, a stop with the red 1R risk box and a target with the green 2R reward box

Ready-made shapes

For the classic explanation shapes the AI only names the contents and Sketchy draws the rest: timeline, cycle, pyramid, funnel, venn, matrix and mindmap.

The web in five moments: a timeline from 1989 to 2007

Molecules and maps

Chemistry gets structural formulas from a SMILES string, rings, double bonds and hydrogens included. Geography and history get maps of any region, with countries to colour, places by latitude and longitude, and routes between them (Natural Earth outlines). In the viewer, hovering names a country, a click flies to it, the wheel or a pinch zooms, and steps fly the map to what they mark. Timelines open their small print on hover or click, and long ones scroll sideways. Both work from the keyboard, and exported files show everything without scripts.

Structural formula of caffeineMap of western Europe: a dashed night-train route from Berlin to Paris, Germany and France coloured

Processes, screens and themes

Flowcharts rank their steps along the arrows and can run in swimlanes, so a business process shows who does what. Screens show phone, tablet, browser and desktop apps from a list of widgets, in a clean, iOS, Material or wireframe look, light or dark, with pages, modals and taps that animate step by step. Every drawing can switch from paper to whiteboard, blueprint (on faint graph paper) or chalk; the viewer's buttons follow the theme.

An online order as a flowchart in two swimlanes

Two iOS phone screens, sign-up and welcome, joined by a tap arrowA request path drawn in the blueprint theme

Packs

Sketchy's building blocks come in packs: general (the fallback), circuit, data, science, geo, process, ui, stage, kitchen, workshop, lab, inference, trading and body. It stays one tool: the AI writes a block and Sketchy finds the pack behind it; a scene that is just help <pack> returns that pack's docs. You can add your own packs as JSON files with symbols in Sketchy's draw language, no code involved:

Terminal
npx -y @ddkbs/sketchy pack init road-signs

See docs/packs.md for every block and how to write a pack.

Your own code

Ask "Explain my repo". The AI reads the code and draws modules, folders and data flow. Click a box to open the file in VS Code, Cursor, Windsurf or Zed; hover to see what it does.

Architecture of a repository with nested folders

Circuits from Arduino and ESP32 sketches

Ask "How is my sketch wired?". The AI reads pinMode, digitalWrite and friends, places real parts (50 boards, sensors, displays and modules from wokwi-elements) and connects pins by name. Sketchy routes the wires and places the callouts.

ESP32 with PIR sensor, DHT22, buzzer and status LEDArduino Uno driving an LED through a resistor

Labeled photos

The AI finds a freely licensed photo (Wikimedia Commons, Openverse), and a vision model running on your computer (Florence-2) locates the parts and printed text to label. Attribution is always shown.

Photo of an Arduino Uno with labeled parts

Your own pictures work too: share a photo or screenshot and ask about it. The AI puts it under a drawing and marks it up by hand, circling the part that matters with free pen loops, pointing with arrows and stepping through what to look at, each step showing its own marks. In Claude chat this uses the uploaded file; elsewhere the AI passes a file path or a URL.

Comparisons and metaphors

SQL vs. NoSQL side by sideCPU caches explained as a kitchen

Interactive, exportable

  • Hover any box, pin or wire for details.
  • Step through walkthroughs with the buttons or arrow keys; new parts are drawn on like a pen and old ones fade; drag the sliders of a picture to move it yourself.
  • Draw on the sketch with a red pen, a highlighter and notes, then Send to AI with a question: the AI gets the marked-up drawing and which parts you marked.
  • Click a code node to open the file, or a photo credit to open its source.
  • Export as SVG or PNG, fonts included, or as an Excalidraw file to keep editing on excalidraw.com: your system's save dialog asks where to put the file. Drawings with steps can be saved step by step as PNG, SVG or HTML, one file each, ready for slides.
  • Fullscreen where the host supports it.

Drawing mode: the CDN is circled in red pen with a note, and a question is ready to send to the AI

Install

Where do you work? Sketchy comes two ways, and both can be installed side by side:

  • In the chat (Claude on web, desktop and the iPhone and Android apps): the skill. Nothing to install locally.
  • While coding (Claude Code in the desktop app or terminal, Codex, Cursor, VS Code): the extension, which adds photo labeling, SVG, PNG and Excalidraw export and click-to-open files.

Claude chat (web, desktop and mobile)

The skill draws right in the chat, with no server:

  1. Download sketchy-skill-<version>.zip from the latest release.
  2. In Claude, open Settings → Capabilities → Skills and upload the zip.
  3. Ask for a drawing in any chat.

On your phone: skills belong to your Claude account, so once uploaded the skill also works in the Claude app on iPhone and Android. Ask a question on the go and the drawing appears in the chat, with steps you can tap through. Nothing to install on the phone.

Claude writes the scene, and the chat's inline visualization loads Sketchy's browser bundle from jsDelivr, which serves it from this repository's cdn branch. The skill follows the current minor version, so it picks up fixes without being uploaded again. To run exactly the code you reviewed, use sketchy-skill-<version>-pinned.zip instead: it loads the bundle from a fixed commit of the cdn branch and checks it with a Subresource Integrity hash, so the browser refuses any other file. It does not pick up fixes; upload the next pinned zip to update. Photo labeling and opening files from a drawing need your computer, so they stay in the desktop extension.

Claude desktop app (Code tab)

  1. Download the .mcpb file for your platform from the latest release (macOS on Apple Silicon, Windows or Linux).
  2. Double-click it (or drag it into Settings → Extensions) and confirm.
  3. Optional: in the extension settings choose your editor and where Sketchy stores its data.
  4. Open the Code tab and start a session. Drawings appear inline next to Claude's answer.

The Chat tab does not display views from locally installed extensions; use the skill above there.

The photo-labeling model is not part of the download. The first time the AI labels a photo, Sketchy asks you to pick a model size:

ModelDownloadMemoryNotes
Small~280 MB~1 GBRecommended. Printed text, distinct parts
Medium~830 MB~2.5 GBBetter grounding of small parts
Large~3.1 GB~4.5 GBMost precise

Claude Code in the terminal

Sketchy is on npm as @ddkbs/sketchy. With Node.js 20 or newer, register it once for all your projects:

Terminal
claude mcp add sketchy --scope user -- npx -y @ddkbs/sketchy

Run claude mcp list to check that it is connected. npx downloads the server on first start and picks up new versions on its own.

Codex

With Node.js 20 or newer, register Sketchy once for the Codex CLI and IDE extension:

bash
codex mcp add sketchy -- npx -y @ddkbs/sketchy

Run codex mcp list to check that it is enabled, then start a new session. To add it by hand, put this into ~/.codex/config.toml:

toml
[mcp_servers.sketchy]
command = "npx"
args = ["-y", "@ddkbs/sketchy"]

Where Codex cannot show MCP Apps inline, Sketchy saves each drawing as an interactive HTML file, as described under Other MCP clients.

Cursor and VS Code

Both show Sketchy's drawings inline in the agent chat. With Node.js installed, click Add to Cursor or Add to VS Code and confirm.

To add it by hand, put this into ~/.cursor/mcp.json (Cursor, all projects) or your VS Code MCP settings:

config.json
{
  "mcpServers": {
    "sketchy": {
      "command": "npx",
      "args": ["-y", "@ddkbs/sketchy"],
      "env": { "SKETCHY_EDITOR": "cursor" }
    }
  }
}

SKETCHY_EDITOR decides which editor opens when you click a box in a drawing; leave it out for VS Code.

Other MCP clients

Sketchy is a standard MCP server and works in any client that supports MCP Apps. Start it with npx -y @ddkbs/sketchy, as above.

Clients without MCP Apps (OpenCode, for example) cannot show drawings inline. There Sketchy saves each drawing as an interactive HTML file in ~/.sketchy/exports/, tells the AI where it is, and asks it to explain the diagram fully in text. Set SKETCHY_OPEN=1 to open the file in your browser right away.

The npm package leaves out the photo-labeling runtime (about 470 MB) so it starts quickly. Sketchy installs it with npm into its data folder the first time you pick a model; the desktop extension ships it.

Try it

  • "What happens when I open a web page? Walk me through it."

  • "How does an LLM pick the next word?"

  • "How do I hang a shelf on a brick wall?"

  • "Why does phenolphthalein turn pink?"

  • "How do I make scrambled eggs for four?"

  • "Draw a trade plan with entry, stop and target."

  • "Explain the architecture of /path/to/my/repo, then walk me through one request."

  • "How is this sketch wired?" followed by your .ino file

  • "Show me a photo of a Raspberry Pi and label the ports."

  • "Compare TCP and UDP."

  • "Explain CPU caches with an everyday metaphor."

  • "Why can a plane fly?"

  • "Show me the structure of caffeine."

  • "Draw the route of the Silk Road on a map."

  • "Prove the Pythagorean theorem with a picture."

The same patterns are available as prompts: explain-structure, explain-flow, compare, metaphor, explain-repo and explain-circuit.

How it works

Code
The AI describes the scene (extension: tools like sketch, place_part, label;
                            skill: the same scene as JSON in an inline widget)
          ↓
Scene: nodes, groups, parts, wires, labels, photos, figures, steps
       (coordinates only inside free-hand pictures)
          ↓
Layout engine (elkjs): positions, orthogonal routing, collision-free callouts
          ↓
Viewer: hand-drawn rendering with rough.js, hover, steps, export

Every feature fills the same scene, and a single viewer renders it. The visual style lives in the renderer, so every drawing looks consistent no matter what the AI asks for. The extension runs layout in its server process and shows the viewer as an MCP App; the skill runs the same code in the browser from a bundle on jsDelivr.

Tools
ToolPurpose
sketchDraw a whole scene in one call, in the compact line syntax
edit_sketchChange the last drawing by sending only what changes
search_partsElectronic part types and their pins
find_image, locate, choose_modelPhoto search, local grounding, model setup

A scene is a few short lines: browser Browser @globe, browser -> server HTTPS, step Request: The browser asks | browser browser->server. Pictures, templates, molecules and maps are blocks inside the same scene (draw atom 100x100, cycle c, molecule caf <SMILES>, map eu <region>). Setting SKETCHY_FORMAT=json restores the JSON sketch tool and the incremental tools of earlier versions (add_node, add_edge, place_part, label, render, …).

Follow-ups

Ask the AI to change a drawing ("add the cache and the call back to the router") and it sends only the changes with edit_sketch, or the whole scene again with the same ids. Sketchy keeps the order and places of everything the earlier drawing already showed and fits the new parts in around them, so before and after stay comparable, also when a back-edge closes a cycle.

After every drawing Sketchy checks what a reader would see: text that overlaps, shapes that leave their canvas, at the start and in every step. It tells the AI, which fixes those spots before you look.

Token usage

Does a drawing cost more than a text answer? We asked Claude Sonnet to explain five topics (DNS, git branches, transformers, the TLS handshake, an Arduino button circuit), in plain text and with Sketchy, and read the exact usage Claude Code reports. Version 0.1.6 introduced the compact scene format; the JSON column is the format before it.

Average per answer, fresh conversationPlain textSketchy, JSON (≤ 0.1.5)Sketchy, compact (0.1.6)
Output tokens (what Claude writes)9621,168686 (−29% vs. text)
Tool definitions–~4,100~500
Cost on Sonnet list prices~$0.034~$0.059~$0.043

Over a whole session the compact format is cheaper than plain text. Six questions in a row, each variant in its own session, mean of two runs:

Answers in the sessionPlain textSketchy, JSONSketchy, compact
1$0.04$0.07$0.05
3$0.21$0.27$0.20
6$0.61$0.75$0.58
  • Claude writes less for a drawing than for text. Layout and drawing happen in Sketchy and cost no tokens.
  • Every answer stays in the history. Shorter answers keep it small, so each follow-up question costs less than after a text answer.
  • A tool call adds a turn that re-sends the context, mostly from the cache at a tenth of the price; this is why the very first answer still costs a little more than text.

Measured on November 2, 2026 in Claude Code with an empty project. Run it yourself with npm run build && node scripts/token-benchmark.mjs.

Configuration

VariableDefaultDescription
SKETCHY_EDITORvscodeEditor for file links: vscode, cursor, windsurf, vscode-insiders, zed
SKETCHY_PHOTOSonoff disables photo search and labeling
SKETCHY_DATA_DIR~/.sketchyModels, cached photos and the local SQLite database
SKETCHY_EXPORT_DIR~/DownloadsFolder the save dialog opens in, and where exports go when no dialog is available
SKETCHY_FORMATcompactjson restores the JSON scene tools of earlier versions
SKETCHY_OPENoff1 opens drawings in the browser in clients without MCP Apps

Development

Requires Node.js 20 or later.

Terminal
npm install
npm run build      # part catalog, server and viewer
npm test
npm run preview    # viewer with sample scenes at http://localhost:5173/preview.html
npm run screenshots  # retake the README images (add names to retake only those)
npm run pack       # .mcpb bundle for the current platform
npm run build:skill  # chat skill zip
npm run build:web    # browser bundle that the skill loads

See CONTRIBUTING.md for the project layout.

License

MIT © ddkbs. Sketchy builds on open-source work listed in THIRD_PARTY_NOTICES.md.