# Sketchpad: certified exact arithmetic with a small vision-language model

DevFeed: [Sketchpad: certified exact arithmetic with a small vision-language model](<https://devfeed.tech/articles/sketchpad-certified-exact-arithmetic-with-a-small-vision-language-model-116940.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2611.04434>)

Author: Mostafa 'Neo' Mohsenvand

Published: 2026-11-04T05:00:00Z

Content type: article

Language: en

Sources: [arXiv: Machine Learning](<https://devfeed.tech/sources/arxiv-machine-learning.md>)

Topics: [vlm](<https://devfeed.tech/topics/vlm.md>), [lora](<https://devfeed.tech/topics/lora.md>), [Agent Harness](<https://devfeed.tech/topics/agent-harness.md>)

Tags: [arithmetic](<https://devfeed.tech/tags/arithmetic.md>), [cs-cl](<https://devfeed.tech/tags/cs-cl.md>), [cs-lg](<https://devfeed.tech/tags/cs-lg.md>), [cs-lo](<https://devfeed.tech/tags/cs-lo.md>), [language-model](<https://devfeed.tech/tags/language-model.md>), [lean](<https://devfeed.tech/tags/lean.md>), [vision-language-model](<https://devfeed.tech/tags/vision-language-model.md>)

## AI overview

Sketchpad makes arbitrary-length arithmetic exact by constraining Qwen3.5-0.8B with a low-rank adapter to read a three-cell view of a rendered working sheet and emit one step at a time; a fixed runtime moves the view and writes no result digits. A Lean proof reduces the all-length guarantee to checking the finite set of views presented by the runtime, while noting that no finite test suffices if steps can also read earlier steps. All 2,446 views passed on a laptop GPU in a browser. The model handled signed addition and subtraction, multiplication, division, square roots and greatest common divisors, and solved 220 of 220 reported large-number problems; GPT-6.1 Sol solved 217. The abstract also reports polynomial operations built on these procedures and a multiplicative adapter gate that restores the base model when the sheet is unused.

## Source excerpt

arXiv:2611.04434v1 Announce Type: new Abstract: Language models are accurate on most long-arithmetic problems, but their accuracy is estimated on samples and carries no guarantee for an unseen input; tool use is exact but moves the computation outside the network. We show that exactness at all input lengths becomes a finite, checkable property of a network when each of its steps reads only a bounded view of an external working memory. In Sketchpad, Qwen3.5-0.8B with a low-rank adapter executes arithmetic procedures on a rendered sheet. Each forward pass reads a three-cell view and emits one step: a digit, a carry or borrow, and the next operation. A fixed runtime moves the view and writes no digit of a result. We prove in Lean that the model is then exact on all inputs of any length if and only if it is exact on the finite set of views the runtime presents, that no finite test suffices when steps also read earlier steps, and that the guarantee tolerates bounded numerical perturbation and extends to compositions of procedures. All 2,446 views pass on the deployment device, a laptop GPU running the model in a web browser. The certified model performs signed addition and subtraction, long multiplication and division, square roots and greatest common divisors at arbitrary length. It solved 200 of 200 pre-registered problems in the browser, and 220 of 220 sums of up to 1,000 digits and products of up to 20 digits, of which GPT-6.1 Sol, the strongest of ten other models, solved 217. A symbolic runtime built on these procedures solves, expands and factors polynomials with every number computed by the model, and a multiplicative gate on the adapter recovers the base model exactly when the sheet is not in use.