Papers › Recursive Visual Programming

Recursive Visual Programming

4 Dec 2023arXiv:2312.02249archive 2025-07-28

Jiaxin Ge, Sanjay Subramanian, Baifeng Shi, Roei Herzig, Trevor Darrell

Visual Programming (VP) has emerged as a powerful framework for Visual Question Answering (VQA). By generating and executing bespoke code for each question, these methods demonstrate impressive compositional and reasoning capabilities, especially in few-shot and zero-shot scenarios. However, existing VP methods generate all code in a single function, resulting in code that is suboptimal in terms of both accuracy and interpretability. Inspired by human coding practices, we propose Recursive Visual Programming (RVP), which simplifies generated routines, provides more efficient problem solving, and can manage more complex data structures. RVP is inspired by human coding practices and approaches VQA tasks with an iterative recursive code generation approach, allowing decomposition of complicated problems into smaller parts. Notably, RVP is capable of dynamic type assignment, i.e., as the system recursively generates a new piece of code, it autonomously determines the appropriate return type and crafts the requisite code to generate that output. We show RVP's efficacy through extensive experiments on benchmarks including VSR, COVR, GQA, and NextQA, underscoring the value of adopting human-like recursive and modular programming techniques for solving VQA tasks through coding.

PaperPDFCodeCode Syntology ran

In Syntology Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, Syntology's MCP tool lists every function and class Syntology harvested from this paper and whether it ran (how to connect): get_harvested_code_for_paper(arxiv_id="2312.02249")

Code

Syntology Ran 11 of 13 code samples harvested from 1 repository linked to this paper; 2 have no recorded run. Of those that ran: 3 ran · our draft was wrong; 8 ran with no contract checked.

By repository: official repository: 13 samples from 1 repository, 11 ran. The run record, sample by sample. “Ran” means executed on a synthesized input, not that the code is correct or reproduces the paper.

para-lost/rvp officialmentioned in papermentioned on GitHubpytorchNOASSERTION report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

Code Syntology ran Syntology

13 samples harvested; 11 ran; 0 honoured the contract we drafted; 2 have no recorded run. Read from Syntology's graph 2026-09-24; that is when this build read the record, not when the samples ran.

3ran · our draft was wrong
8ran
2unverified

Licence: 13 of the 13 samples are pointer only, meaning Syntology does not serve that copy's text. This page shows no code text for any sample; each one links to its file in the repository.

Harvested from para-lost/rvp. “Ran” means the sample executed on a synthesized input. It does not mean the output is correct, and nothing here reproduces the paper's results. “Honoured” and “violated” refer to a contract Syntology drafted from the code itself; “our draft was wrong” and “fixture could not drive it” are failures of Syntology's instrument, not of the code.

Each sample ends with its code_sha256, Syntology's identity for that exact code. An agent fetches the stored sample with Syntology's MCP tool get_code(code_sha256="…") (how to connect); click an identity to copy that call.

Repository labels, per sample. official repository: The archive marks this repository official for the paper. named in the paper: The archive records that the paper mentions this repository; it is not marked official. community (archive-listed): In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper. found in paper text by Syntology: Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted. community: Not in the archive's code links for this paper; a community repository Syntology harvested. Samples from a repository marked official are listed first. Licence labels name the repository's licence as recorded at harvest. “Pointer only” means Syntology does not serve that copy's text, for one of four reasons: no licence file was found; the licence was not identified; the licence is recorded as permissive but that copy's record is not marked cleared; or the licence is outside the permissive list Syntology serves text under (MIT, Apache-2.0, BSD and similar). Some licences outside that list permit redistribution, such as WTFPL, and GPL-3.0 under its conditions; they are simply not on the list. Hover a licence label for the reason. File links open the file on GitHub at the default branch, which may have changed since the harvest.

whitespace_tokenize para-lost/rvp/base_models/tcl/tcl_tokenization_bert.py official repository ran · our draft was wrong fingerprinted no licence file found · pointer only · cf9ffa02a42184af · report
bool_to_yesno para-lost/rvp/image_patch.py official repository ran licence not identified · pointer only · 38e334384d86aaa1 · report
collate para-lost/rvp/vision_processes.py official repository ran licence not identified · pointer only · b54134f48b26b8b8 · report
denormalize para-lost/rvp/utils.py official repository ran no licence file found · pointer only · 191a0905a11888a1 · report
draw_bounding_boxes para-lost/rvp/utils.py official repository ran licence not identified · pointer only · 44efca8c80c8d48f · report
extract_start_index para-lost/rvp/main_batch.py official repository ran fingerprinted licence not identified · pointer only · 7cc4a60389346b00 · report
get_index_from_sample_id para-lost/rvp/utils.py official repository ran licence not identified · pointer only · ef08d7159362c3db · report
get_transform para-lost/rvp/base_models/inspyrenet/saliency_transforms.py official repository ran licence not identified · pointer only · bc2728b9cedba3e5 · report
interpolate_pos_embed para-lost/rvp/base_models/tcl/tcl_vit.py official repository ran licence not identified · pointer only · 4262ed39e3ce5c97 · report
load_vocab para-lost/rvp/base_models/tcl/tcl_tokenization_bert.py official repository ran · our draft was wrong no licence file found · pointer only · e7fbc7a74a3457c7 · report
my_collate para-lost/rvp/main_batch.py official repository ran · our draft was wrong no licence file found · pointer only · 18839b05574cb883 · report
concat_all_gather para-lost/rvp/base_models/tcl/tcl_model_pretrain.py official repository unverified no licence file found · pointer only · 73cecca9f3575f09 · report
load_tf_weights_in_bert para-lost/rvp/base_models/tcl/tcl_xbert.py official repository unverified no licence file found · pointer only · 26be70dca3249c0b · report

Tasks

Code GenerationQuestion AnsweringVisual Question AnsweringVisual Question Answering (VQA)

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections