Audited Editable Scientific Diagrams
Scientific figures can look polished while distorting a method; autoillustrate grounds panels in editable geometry, audits them, and treats image enhancement as a checked, reversible final step.
Read the paper ↗What it is
- Editable panels The figure is built from separate editable diagram panels, with layout coordinates checked for overlap before the panels are combined.
- Audited enhancement An image model may restyle the composed figure, but the result is checked against the editable source; if it cannot pass, the source render is used.
Why it matters
A polished scientific figure is not useful if its arrows or content misrepresent the method. Keeping an editable source makes defects repairable and gives the pipeline a reliable fallback.
Before getting into the moving parts, here is the short version: autoillustrate builds a scientific figure as editable diagram panels, checks those panels, and only then asks an image model to restyle the exported picture. The important bit is that the source diagram stays around as the reference and fallback, so a prettier image does not get to quietly replace the method it was supposed to explain.
-
Editability: A scientific figure is often revised as the method or explanation changes. A flattened image is awkward to edit; an editable diagram keeps labels, boxes, and arrows available for direct changes. The canonical example is a multi-panel methods figure: if one panel's sequence changes, you want to adjust that panel rather than redraw the whole image. This does not mean every visual can be represented as simple diagram primitives.
-
Faithfulness: A neat layout can still encode the wrong relationship. For example, two boxes connected by an arrow may suggest a data flow that the method does not have. So the pipeline checks each panel for rendering fidelity, factual accuracy, and enough detail, then edits and rebuilds a panel when it finds a defect. A geometry check can establish that boxes do not overlap; it cannot decide whether the arrow is scientifically right. What should happen when a visual cannot be drawn with those primitives?
-
Controlled polish: The pipeline composes the accepted panels into an editable source and exports a raster image. An image model restyles that export, but it does not become the authority on the figure's content. The candidate is compared with the editable reference and checked again; if no candidate passes after repair attempts, the deterministic export is the fallback. Think of the source as the notebook copy and the restyle as a cleaned-up presentation copy—the analogy stops short because the image can introduce structural changes, which is why it has to be audited.
The geometry work is intentionally concrete. Rendering agents create draw.io panels from templates, while Python code calculates positions and checks bounding boxes for overlap. If a visual is outside what draw.io can render, it can remain a placeholder, and a generated matplotlib script may fill it. This makes layout problems visible and repairable, but it does not turn geometric validity into semantic correctness.
So the real question is not whether image enhancement can make a figure look better. It is whether the enhancement still says what the editable diagram says. I like that the fallback makes this a real engineering boundary rather than a promise: if verification fails, the generated polish does not get to win by default. The cost is more agent work and runtime, and the editable primitives can limit how compact or visually abstract the result becomes. How much of that extra control is useful depends on how costly a misleading diagram would be.
Read the deep dive
Why People Wanted It
A scientific diagram has two jobs that can pull in opposite directions: it should explain a method faithfully, and a scientist should be able to revise it. A raster image can be attractive but hard to edit; a generative image model can also alter small structural details while restyling. So the real question is not simply how to draw a figure. It is how to make a figure whose structure stays inspectable while still allowing visual polish.
The Core Move
Build the figure as an editable draw.io source first, audit its panels and the composed figure against the methodology, and accept image-model restyling only when it passes comparison with that source. If enhancement cannot pass, keep the deterministic render.
Why Geometry Is Kept Out of the Image Model
Now the version for readers who want more of the machinery: the crucial separation is between semantic choices and geometric placement. A planning agent describes panels in a configurable layout, and a styling agent establishes shared colors and typography. Rendering agents independently create editable panel diagrams; templates define topology, while Python generators compute coordinates and check bounding boxes for overlap.
That division makes the geometry testable rather than merely plausible. A box-overlap check can catch collisions in the layout, but it does not establish that an arrow means the right thing or that the panel faithfully represents the method. When draw.io cannot express a visual, the pipeline can leave a placeholder box and, when possible, fill it with a generated matplotlib script. What remains for the panel audit to judge beyond geometry?
Why Audits Repair the Source
Here is the part that gets technical: each panel is inspected for rendering fidelity, factual accuracy, and sufficient detail. A detected defect leads to edits to the editable source, a panel rebuild, and another audit—not a paint-over on a flattened image. Once panels pass, they are composed into one editable draw.io source and exported as a raster reference.
This repair loop keeps the source as the place where content and layout are corrected. It also means panel-level checks and final checks have distinct jobs: the former inspect individual panels, while the latter must catch problems introduced or exposed in the complete figure. What changes when a generative model is allowed to touch the composed render?
Why Enhancement Needs a Source Comparison
Now for the final layer of machinery: an image-generation model restyles the raster export, but its candidate is compared with the editable reference and checked against the same criteria used in panel inspection. A discrepancy triggers another source edit, export, enhancement, and verification pass. After several repair passes, the system returns the candidate with the strongest verification results; if none passes, it returns the raster exported from the editable source.
The fallback matters because a failed restyle should not erase the known editable figure. The source remains available for direct content or layout revisions, whether or not an enhanced image is accepted. How much polish is worth pursuing before the deterministic version is preferable?
Minimal Causal Code
This loop is deliberately plain: it shows that enhancement is conditional on verification, and that failure returns the source render.
best = None
for _ in range(max_repair_passes):
candidate = restyle(source_render)
audit = compare(candidate, editable_reference, panel_checks)
if audit.passes:
if best is None or audit.score > best.score:
best = (candidate, audit)
else:
editable_source = repair(editable_source, audit.issues)
editable_reference = rebuild(editable_source)
source_render = export(editable_source)
result = best.candidate if best is not None else source_render
What You Gain, and What You Lose
You gain an editable source, explicit geometry checks, and repair points where factual or structural defects can be addressed before the figure is finalized. In reported PaperBananaBench comparisons, the Claude-based autoillustrate variant scored higher overall than the best PaperBanana variant, with the advantage driven by faithfulness; removing panel inspections and final verification lowered faithfulness and overall scores. These results do not make the pipeline a substitute for human refinement: its editable primitives constrain compact, complex abstraction, and the reported human-reference overall score remained higher.
You also pay for the machinery. Agents must produce diagram templates and coordinate-generating code, and autoillustrate variants generally had higher median API costs and runtime than PaperBanana in the reported setup. The tradeoff is explicit: spend reasoning and verification effort to keep the figure editable and method-grounded, or accept a simpler image-generation workflow with less control over the underlying structure.
Let the image model restyle the figure, but let an editable, audited source decide whether that restyling survives.