RECODE: Reasoning Through Code Generation for Visual Question Answering

Junhong Shen, Mu Cai, Bo Hu, Ameet Talwalkar, David A Ross +2 more
10/15/2025
cs.CVcs.AIcs.LG

No confident code implementation found for this paper. 7 possible matches can be shown below.

Abstract

Multimodal Large Language Models (MLLMs) struggle with precise reasoning for structured visuals like charts and diagrams, as pixel-based perception lacks a mechanism for verification. To address this, we propose to leverage derendering -- the process of reverse-engineering visuals into executable code -- as a new modality for verifiable visual reasoning. Specifically, we propose RECODE, an agentic framework that first generates multiple candidate programs to reproduce the input image. It then uses a critic to select the most faithful reconstruction and iteratively refines the code. This process not only transforms an ambiguous perceptual task into a verifiable, symbolic problem, but also enables precise calculations and logical inferences later on. On various visual reasoning benchmarks such as CharXiv, ChartQA, and Geometry3K, RECODE significantly outperforms methods that do not leverage code or only use code for drawing auxiliary lines or cropping. Our work demonstrates that grounding visual perception in executable code provides a new path toward more accurate and verifiable multimodal reasoning.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 7 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{shen2025recode,
  title  = {RECODE: Reasoning Through Code Generation for Visual Question Answering},
  author = {Junhong Shen and Mu Cai and Bo Hu and Ameet Talwalkar and David A Ross and Cordelia Schmid and Alireza Fathi},
  year   = {2025},
  eprint = {2510.13756},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2510.13756v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2510.13756.svg)](https://codeofpaper.com/paper/2510.13756)

Discussion