HistGramBench: Can AI Pass Mr. Dollhopf’s Geometry Class?
www.deerfieldfocalpoint.com/articles/histgrambench-can-ai-pass-mr-dollhopfs-geometry-class

You need to be able to sketch a triangle to pass Geometry Accelerated at Deerfield. Consider a hypothetical world where AI policies are non-existent. Should students trust an AI agent to read a geometry sketch and complete their geometry homework? Consider this problem from The Teaching of Geometry (1911): reproduce the semicircle and triangle shown in Figure 3a. Before an agent can solve a geometry problem, it needs to “see” the figure correctly and reconstruct it. One way to rebuild these figures is to redraw them as code. TikZ is a drawing language used with LaTeX, the standard typesetting in mathematics. A TikZ drawing is a short program that compiles the details of a figure so that a computer can read it. Today’s frontier AI models that read images, known as vision-language models, can write such programs from a picture1.
The problem is: how can the accuracy of a redrawn figure be objectively measured? The standard method compares pixels, but differences in line thickness can produce misleading results. Code-by-code comparison is impossible because historical diagrams do not have original code.
We introduce HistGramBench, a benchmark for evaluating how accurately AI models reconstruct historical geometry diagrams. It uses an alternative judging method that checks the facts a reader relies on: which points exist, which points lie on which shape, which lines are parallel to each other, etc. The benchmark seeks to answer a question: How much of a figure’s structure do AI models get right, and how often do they fail to produce a drawing at all?
Existing benchmarks that turn pictures into code use modern material that has original TikZ code: scientific figures in TikZ1, charts in Python8, and web pages in HTML7. These benchmarks grade an AI’s output on how similar the output looks compared to the answer key. HistGramBench’s foundation is built on Inter-GPS, which describes geometry diagrams as lists of objects and relationships6.
The figures come from public-domain historical articles (Figure 1). Each sample is a single figure cropped from its page. An automated check procedure and screening model are introduced to remove non-geometry crops and duplicates. Our final test set contains 2,507 crops from an original dataset of 411 books (Figure 2).


Each figure is given to each model in two ways (Table 1). In Track A, the model sees only the figure and is asked to redraw “the mathematical figure the original intended,” leaving out stains and printing flaws. In Track B, models receive additional captions and nearby text from the same page. In both tracks, the answer must be a single TikZ drawing. Comparison between Track A and Track B shows us to what degree context influences a model’s performance.
Each figure has an answer key: a list of facts of three kinds (Table 2). Entity facts say that an object exists (“there is a point”), relation facts say how objects connect (“Point A lies on the circle”), and label facts show how things are marked (“This point is printed as A”). The answer key avoids recording exact position or size.


Two self-contained AI models, GPT-6.1 Sol and Kimi K2.5, independently write down facts. Their lists are then lined up, and every fact in the combined list U is voted on. Writing a fact counts as a vote for it unless the writer later rejects it. With vw(f) standing for writer w’s vote on fact f, the key is:

So facts enter the key only when both writers agree. The rule also prefers a shorter, reliable key to an overly complete one. Figures with keys that are too thin or too uncertain are omitted from the test set.
The benchmark takes the TikZ code from the model’s answer and runs it on one attempt in a contained environment (Docker) and reads the output picture as a set of points, lines, curves and text (Figure 2, right). If the code fails to compile or contains forbidden commands, the output is considered a complete failure.
The objects in the key are first paired with objects in the drawing. Each fact is then checked by measuring the drawing. For instance, let d(p, x) be the distance from a point p to an object x, and let ∠(ℓ1, ℓ2) be the angle between two lines.
A point counts as lying on a circle when it sits within one percent of the drawing’s size from it. Two lines count as parallel when their directions differ by at most 1.5 degrees. The drawing’s size is independent of these criteria because distances are compared with the size of the whole drawing. The checking process is only dependent on written facts, so line thickness, font and colour do not make significant differences. Other relations such as right angles are checked with the same methodology. More complex facts such as shaded regions or marks showing equal lengths go to a third independent judge for further corroboration.

A model’s performance is measured mathematically. Let Ki be the answer key, Pi the facts reproduced, and Xi the facts excluded because a required object is missing. The set difference Ki ∖ Xi contains the checkable facts. Let gi equal 1 for a valid drawing and 0 for a compilation failure:

The corpus also contains books from adjacent authors so some figures tend to resemble each other. The benchmark tackles this by averaging scores within each group of related books and then averaging the groups:

where S̄k is the average score in group k and G = 87 is the number of groups. The 95 percent range around each result uses the 87 group averages as the sample3.
Six vision-language models were tested: Gemma 4 26B, Llama 4 Maverick, Ministral 3 14B, Gemma 4 E2B, Claude Haiku 4.5 and Nemotron Nano 12B v2. These models’ outputs shared the same configurations and the same limit on answer length.
Gemma 4 26B does best, with a Track A score of 0.59 (Table 3). Performance of Gemma 4 E2B and Claude Haiku 4.5 is in the same bound through sorting the six into five distinct levels2.
Many answers failed to compile: Of 2,507 Track A answers, Nemotron Nano 12B v2 ran out of answer length on 651, Llama 4 Maverick introduced forbidden commands on 292, and Claude Haiku 4.5 wrote code that failed with syntax errors on 1,218; in 1,007 cases it left out the line opening a LaTeX document. Models struggled the most with relations.
Adding page text does not have a significant influence on the overall performance of models. Individual models move both ways, with gains from Ministral 3 14B to a loss of 0.08 for Gemma 4 26B (Figure 5), and the five levels of Track A merge into two (Figure 4).

![Main results. Columns: Model; H Track A; H Track B; Track A Valid (%); Track A Recall Entity; Relation; Label. Gemma 4 26B: 0.589, 0.511, 72.7, 0.592, 0.538, 0.648 (all bold, best). Llama 4 Maverick: 0.524, 0.506, 70.4, 0.532, 0.427, 0.582 (all underlined, second). Ministral 3 14B: 0.391, 0.495, 70.4 (underlined, tied second), 0.509, 0.395, 0.533. Gemma 4 E2B: 0.309, 0.325, 60.2, 0.407, 0.332, 0.450. Claude Haiku 4.5: 0.300, 0.296, 50.8, 0.389, 0.317, 0.384. Nemotron Nano 12B v2: 0.197, 0.266, 51.0, 0.325, 0.235, 0.346. Pooled ΔH (B − A) = +0.015, 95% CI [−0.010, +0.040].](https://static.wixstatic.com/media/f78279_9f6cd68f841b495cae66bf34aa822e80~mv2.png/v1/fill/w_1008,h_338,al_c,q_90,enc_auto/f78279_9f6cd68f841b495cae66bf34aa822e80~mv2.png)
To see if ranking is dependent on the family of the AI Judges, each judge’s model family was removed in turn and the six models were reranked. There was no significant correlation between grading and model family.


So, can AI pass Mr. Dollhopf’s geometry class? Six frontier AI models surely did not, at least not yet. Even the best model gets a large part of each figure wrong, and many answers fail to produce drawings, which is like giving a blank page as a submission. Proprietary frontier models like Claude Haiku 4.5 still fail on fundamentals like leaving out the first line of code, equivalent to not signing the Honor Pledge on the test. If you use AI, whether your school’s policy allows it or not, you are setting yourself up to fail geometry class.
For engineers, the quickest step-improvement is configuring the model to produce a valid output. Most failures are mechanical, such as running out of answer length or breaking syntax. In model training, engineers should focus on training models to understand relations instead of just learning how to look at a figure and guess. Fact-level checks in this benchmark can serve as a framework for data that can be used in reinforcement learning. Additionally, researchers should be mindful of page text. It is dependent on individual models, so keeping image-only examples in training can help models learn to read the figure instead of over-relying on context and captions. Finally, bigger does not mean better. Gemma 4 26B, an open-sourced model by Google with only 26 billion parameters, performed better than a proprietary Claude model.
HistGramBench shows that current vision-language models have trouble redrawing historical geometry figures, especially in producing a drawing that adheres to syntax and relations. We hope HistGramBench will encourage work on models that read a figure’s geometry with higher precision and grounding from textbooks that are centuries old to a printed homework worksheet due on a Thursday.
Notes
- Belouadi, J., Ponzetto, S. P., & Eger, S. (2024). DeTikZify: Synthesizing graphics programs for scientific figures and sketches with TikZ. arXiv. https://doi.org/10.48550/arXiv.2405.15306 Back
- Benjamini, Y., & Hochberg, Y. (1995). Controlling the false discovery rate: A practical and powerful approach to multiple testing. Journal of the Royal Statistical Society: Series B (Methodological), 57(1), 289–300. https://doi.org/10.1111/j.2517-6161.1995.tb02031.x Back
- Ibragimov, R., & Müller, U. K. (2010). t-statistic based correlation and heterogeneity robust inference. Journal of Business & Economic Statistics, 28(4), 453–468. https://doi.org/10.1198/jbes.2009.08046 Back
- Levchenko, M. (2025). Evaluating LLMs for historical document OCR: A methodological framework for digital humanities. arXiv. https://doi.org/10.48550/arXiv.2510.06743 Back
- Lu, P., Bansal, H., Xia, T., Liu, J., Li, C., Hajishirzi, H., Cheng, H., Chang, K.-W., Galley, M., & Gao, J. (2023). MathVista: Evaluating mathematical reasoning of foundation models in visual contexts. arXiv. https://doi.org/10.48550/arXiv.2310.02255 Back
- Lu, P., Gong, R., Jiang, S., Qiu, L., Huang, S., Liang, X., & Zhu, S.-C. (2021). Inter-GPS: Interpretable geometry problem solving with formal language and symbolic reasoning. arXiv. https://doi.org/10.48550/arXiv.2105.04165 Back
- Si, C., Zhang, Y., Li, R., Yang, Z., Liu, R., & Yang, D. (2024). Design2Code: Benchmarking multimodal code generation for automated front-end engineering. arXiv. https://doi.org/10.48550/arXiv.2403.03163 Back
- Wu, C., Ge, Y., Guo, Q., Wang, J., Liang, Z., Lu, Z., Shan, Y., & Luo, P. (2024). Plot2Code: A comprehensive benchmark for evaluating multi-modal large language models in code generation from scientific plots. arXiv. https://doi.org/10.48550/arXiv.2405.07990 Back
- Zheng, L., Chiang, W.-L., Sheng, Y., Zhuang, S., Wu, Z., Zhuang, Y., Lin, Z., Li, Z., Li, D., Xing, E. P., Zhang, H., Gonzalez, J. E., & Stoica, I. (2023). Judging LLM-as-a-judge with MT-Bench and Chatbot Arena. arXiv. https://doi.org/10.48550/arXiv.2306.05685 Back
- Tran, H. (n.d.). HistGramBench: Can AI pass Mr. Dollhopf’s geometry class?. Deerfield Academy. Figure 1 reproduces historical diagrams identified in the figure; Figures 2–5 and Tables 1–3 present the author’s benchmark design and results. Back




