Taxonomized diagram data
1,449 quality-controlled diagrams spanning six domains and fifteen subdomains, with rich captions and structural metadata; the public Task 1 release includes 1,444 restored XML files.
VCG-Bench · Diagram-as-Code
VCG-Bench separates two capabilities that visual benchmarks often conflate: reconstructing executable mxGraph XML from a diagram image and structured caption, and modifying known structure through natural-language instructions.
Towards A Unified Visual-Centric Benchmark for Structured Generation and Editing
01 Research contribution
Diagram understanding becomes useful when the result remains executable, editable, and structurally faithful. VCG-Bench turns that requirement into a reproducible evaluation protocol.
1,449 quality-controlled diagrams spanning six domains and fifteen subdomains, with rich captions and structural metadata; the public Task 1 release includes 1,444 restored XML files.
Task 1 measures structure recovery from visual evidence. Task 2 measures reliable modification when the source structure is already available.
Executability, structural correctness, semantic relations, visual similarity, and patch fidelity expose different—and actionable—failure modes.
02 Benchmark design
The tasks are complementary but evaluated independently. A model may be excellent at editing valid XML and still fail to infer that XML from pixels.
Visual → Structure
ReconstructionGiven a raster image and a structured caption, generate complete, executable <mxGraphModel> XML that preserves topology, layout, text, and style.
Protocol note Image + structured caption is the main setting; image-only reconstruction is reported as a harder ablation.
Structure → Patch
EditingGiven source XML, its rendering, and an instruction, return a JSON differential patch containing original and modified XML fragments. A deterministic applier performs the edit.
Protocol note 1,005 instructions cover 14 atomic edit categories at Easy, Medium, and Hard composition levels.
03 Dataset & construction
Template libraries, research papers, anonymized enterprise artifacts, and permissively licensed web sources are normalized into a consistent mxGraph representation and verified through automated and human checks.
Coverage map
AcademicArchitecture, neural networks, data visualization
SoftwareUML, sequence, ER diagrams
BusinessProduct, report, strategy
ManagementGantt, hierarchy, flow
UI/UXWeb and mobile interfaces
GeneralMind maps
04 Evaluation protocol
Every output must run first. Then VCG-Bench asks a different, task-specific question: was the source reconstructed correctly, or was the requested edit completed correctly?
ESR · Execution Success Rate
The generated XML must parse successfully and produce a valid rendering before any quality score is calculated.
Image + caption → complete XML
Three checks cover appearance, diagram content, and rendered similarity.
Judges visual style, layout consistency, and aesthetic quality.
Checks counting, attributes, and connections directly from the XML.
Measures visual-semantic similarity between the two rendered images.
Source XML + instruction → patch
Two checks verify that the result stays polished and satisfies every requested change.
Compares style consistency and aesthetic quality against the pre-edit diagram.
Verifies each decomposed edit requirement directly in the modified XML.
Why fewer checks? Task 2 already receives the source XML. It evaluates precise modification—not reconstruction from pixels.
05 Key findings
Models can modify valid mxGraph programs with high reliability, yet the same models struggle to infer those programs from visual evidence. The gap is largest for open models and compositionally dense diagrams.
Executable Success Rate
XDRFR across evaluated models
A revealing capability gap
Reliable XML manipulation does not imply reliable visual-to-structure recovery.
Counting is the dominant Task 1 failure for evaluated open models. They omit, duplicate, or merge repeated visual elements.
Captions materially help structure recovery. In a 100-example ablation, removing them reduced SCS from .805 to .690 and CodeXQA from .930 to .786.
Executability is necessary, not sufficient. Valid XML can still encode the wrong topology, text, or relationships.
06 Paper examples
Qualitative results from the paper show both reconstruction behavior and instruction-driven edits. Select a task, then expand the figure for full-resolution inspection.
07 Project ecosystem
The benchmark repository supports the research release and reproducible evaluation. The companion Skill turns the same diagram-as-code principle into a hands-on Codex reconstruction workflow.
sxy1499894281 / VCG-Bench
sxy1499894281 / drawio-reconstruction-skill
Beyond the benchmark
These are companion workflow demonstrations created with Codex and the reconstruction Skill. They are not leaderboard samples or benchmark model outputs.
08 Scope & limitations
Clear boundaries make the benchmark easier to interpret and extend.
09 Resources
Citation
@article{su2026vcgbench,
title = {Towards A Unified Visual-Centric Benchmark for Structured Generation and Editing},
author = {Su, Xiaoyan and Dong, Peijie and Tang, Zhenheng and Tang, Song and Zhai, Yuyao and Lin, Kaitao and Chen, Liang and Gai, Yuhang and Luo, Yuyu and Wang, Qiang and Chu, Xiaowen},
journal = {arXiv preprint arXiv:2605.15677},
year = {2026}
}