Skip to main content
Glama
ymo6

Illustrator Figure MCP

by ymo6

Illustrator Figure MCP

Rebuild scientific figures as editable Adobe Illustrator artwork, and prove the result is structurally correct.

macOS only (Illustrator is macOS/Windows; this uses osascriptdo javascript). Requires Adobe Illustrator and Claude Code.

Why this exists

Plenty of MCP servers can draw in Illustrator. They give a model hands but no eyes: nothing checks whether the thing it just drew is right. So the model draws, reports success, and the figure has a label overflowing its box, an arrow ending in the middle of an unrelated rectangle, and three "aligned" panels that are 3pt out.

The valuable part is not the drawing. It is the validate-and-repair loop, on two channels that check different things:

Channel

Mechanism

Proves

Geometry

audit_figure — deterministic, read-only

internal correctness: containment, degenerate sizes, duplicate names, overset text, raster declarations, connector routing and bindings, repeated-series alignment, trace signatures

Appearance

export to PNG, compared against the reference crop

resemblance

Geometry is proved. Similarity is judged. Neither alone is enough — a traced figure passes every geometric check while being entirely non-editable, and a good-looking render says nothing about structure.

audit_figure returning passed: true means no hard geometric failure. It does not mean the figure is correct.

Related MCP server: Illustrator MCP Vectorizer

Reconstruct, never trace

Tracing preserves appearance and destroys semantics, which is the whole point of rebuilding a figure. Three defences make the shortcut hard to take:

  • Semantic tagging at creation. Every object gets a UUID and a semantic type as it is made, so the auditor can tell constructed objects from foreign geometry.

  • trace-signature. Image Trace's expandTracing() drops one untagged group holding a pile of untagged paths; that, dense untagged paths, and bulk geometry exceeding the declared draw log are all hard failures.

  • The raster gate. place_image refuses any placement that is not provably irreducible.

The raster gate

Every retained image must declare all five, and they are validated, not just recorded:

Declaration

Requirement

raster_reason

specific description of the irreducible pixel content — "image", "PNG", "screenshot" are rejected

source_is_tightly_cropped

true — every border, label, arrow, legend, axis, and neighbouring panel cropped away

atomic_raster_unit

true — one indivisible datum, not a grid or montage

contains_reconstructable_content

false — nothing left inside that should be an editable object

decomposition_note

≥ 8 chars: what was split out and rebuilt

Enforcement is on the creation path, not in the auditor: an auditor-only check is bypassed by not auditing.

Connectors

Illustrator has no connector primitive. An arrow is a PathItem and has no relationship to the box it points at — move the box and the arrow stays behind, silently wrong.

add_connector records the binding (source, target, attachment sites) on the path. reflow_connectors re-solves the geometry from the objects' current bounds. audit_figure reports connector-detached when the drawn path no longer agrees with its binding.

Routing is straight, orthogonal, or curved — a bezier that leaves and arrives perpendicular to the attachment edges, which is the standard pathway-diagram look and makes arrowheads read as pointing squarely into their target. The auditor samples the actual curve rather than the chord between anchors, so it checks where the ink is.

Any operation that moves or resizes a connected object must be followed by reflow_connectors. Arrowheads are drawn as filled triangles, since Illustrator exposes no arrowhead property to scripting.

→ Full usage guide — install, core rules, tool reference, two worked examples, and how to read an audit report.

Install

npm install && npm run build

Add it to Claude Code:

claude mcp add illustrator-figure -- node /absolute/path/to/IllustratorFigureMCP/dist/index.js

Grant Automation permission the first time a tool runs: System Settings → Privacy & Security → Automation → Claude → Adobe Illustrator.

Install the four role skills:

cp -R skills/* ~/.claude/skills/

The four roles

Ask Claude to "recreate this figure in Illustrator" with a reference image, and recreate-scientific-figure coordinates the loop:

Skill

Role

design-scientific-figure

Designer — produces the reconstruction spec before anything is drawn

recreate-scientific-figure

Drawer + orchestrator — builds a region per round trip, runs the gates

audit-scientific-figure

Reviewer — reads both evidence channels, issues findings

correct-scientific-figure

Corrector — turns findings into ordered, object-level operations

Each region must pass before the next begins; then the whole figure runs the same loop.

Tools added by this fork

Tool

Purpose

audit_figure

deterministic structure audit; every finding carries evidence, a correction, and an acceptance criterion

draw_sequence

build a whole region in one round trip, optionally auditing in the same call

add_connector

create a connector bound to two objects by name

reflow_connectors

re-solve connector geometry after objects move

fit_text

resolve overset area text — resizing the frame with modify_object does not reflow it

Plus the raster gate on place_image, and semantic tagging on every create_* tool. The remaining 66 tools are upstream's (71 in total).

draw_sequence is the one to reach for: nine objects — boxes, area-text labels, two bound connectors — build and audit in roughly 750ms, where one call per object would be nine round trips.

Documentation

docs/USAGE.md

How to use it: install, rules, every tool, worked examples, audit findings, troubleshooting

CLAUDE.md

Internals and the constraints that are easy to break, for anyone editing this repo

skills/

The four role skills

Development

npm test        # 245 tests, runs on any platform

The ported geometry is pure ES3, so the .jsx modules are loaded into a VM and the Liang–Barsky and segment-crossing maths is tested without Illustrator. Anything that touches Illustrator must be tested on macOS with it running — see CLAUDE.md for the constraints that are easy to break (ES3, UUID-before-metadata ordering, pageItems snapshotting).

Credits

  • Tool layer forked from ie3jp/illustrator-mcp-server (MIT) — transport, JSX runner, UUID identity, note metadata, and 63 Illustrator tools. See LICENSE.

  • The two-channel validation loop, the audit taxonomy, and the four-role protocol are ported from icebird1998/scientific-illustrator, which implements them for draw.io, PowerPoint, and WPS. The maths is backend-neutral; the object model is not.

Not affiliated with Adobe.

A
license - permissive license
Not graded
quality - not tested
B
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

View all related MCP servers

Related MCP Connectors

  • Art provenance intelligence — 282K-node knowledge graph with cited answers and honest gaps.

  • AI agent draws editable hand-drawn diagrams (flowchart, ER, architecture) via MCP, not static images

  • DXF and PDF/X-4 for AI agents: structured facts, PNG renders, an interactive in-chat viewer.

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ymo6/illustrator-figure-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server