EvoViM: Recursively Self-Evolving Visual Agents for Exploration with Deferred Queries

Xinyu Cao, Tianjie Ju, Zhuosheng Zhang

It’s late, you’re tired, and you’ve probably spent half your day trying to get an LLM to follow a simple instruction. Now imagine you’re an AI agent dropped into a virtual museum. You wander around, looking at paintings, and only after you leave does someone ask: "In the third room, was the painting on the left a landscape or a portrait?"

If you didn't know that question was coming, you probably didn't take notes. This is the "deferred query" problem, and it’s where most current AI agents fall flat on their faces.

TL;DR

EvoViM is a framework that allows AI agents to "self-evolve" by writing their own Python-based visual memory programs. Instead of relying on lossy text summaries, the agent learns from its past failures to decide exactly which pixels to save and how to compare them later, leading to massive performance gains in complex visual tasks.

What Problem Does This Paper Address?

Most Multimodal Large Language Model (MLLM) agents are "instruction-first." They are told what to do, and then they go do it. But real-world exploration is often "exploration-first." You explore an environment, and the specific questions come later.

To handle this, agents need a memory. Currently, they usually choose one of two paths:

  1. Textual Memory: They write down what they see. (Problem: "A red pattern" might describe 50 different objects in a complex scene. Text is too "lossy.")
  2. Fixed Visual Buffers: They save every single frame. (Problem: This is computationally expensive and doesn't tell the agent how to actually use those thousands of images to answer a specific question.)

The authors identify a "representation gap": text loses visual nuance, and raw images lack the logic to be useful.

Methods

The authors introduce EvoViM (Evolving Visual Memory). The core idea is that a frozen MLLM (like GPT-4 or Claude) acts as a meta-programmer.

Instead of just performing the task, the MLLM evolves a Visual Program—a suite of Python functions and specialized prompts. This program handles two phases:

  • Record: Decides which frames or crops to save to a "visual store."
  • Act: Uses tools like pixel-matchers to compare the current view against the stored memory to make decisions.
The EvoViM framework: The agent executes tasks using a memory program, then a "Revision" process uses failure data to rewrite the program for the next generation.

The "magic" happens in the Recursive Self-Evolution. When the agent fails a task during development, the MLLM inspects the "visual trajectory" (the sequence of images and actions). It traces the failure back to a specific operation—maybe it didn't save the right frame, or its matching algorithm was too loose—and then rewrites the code to fix it. It even maintains a "playbook" of past mistakes to ensure it doesn't repeat them in future generations.

Datasets

The researchers evaluated EvoViM on six diverse tasks across three categories:

  1. Visual Matching: Card Matching (finding pairs on a 12x12 board) and DMV-Hard (identifying products from tiny, transformed crops).
  2. Spatial Recall: MC Gallery (a Minecraft-style gallery walk) and Poster Maze (navigating a maze to find specific posters).
  3. Sequential Decision-Making: Classic games like Tetris and Pac-Man.
Example observations from the six evaluation tasks, ranging from card games to 3D navigation and classic arcade games.

Crucially, the first four tasks involve deferred queries, where the agent explores the environment before knowing what it will be asked.

Key Insights and Ideas

  • Pixels are the Source of Truth: For tasks involving subtle visual differences (like the noise-textures in Card Matching), text descriptions are useless. EvoViM’s ability to compute directly on pixels is its "superpower."
  • Failure is the Best Teacher: The agent doesn't just guess how to remember things. It tries a generic strategy, fails, and then uses that failure to realize, "Aha! I need to save a crop of the doorway number to associate it with the painting."
  • Code as a Compressed Skill: By evolving Python code, the agent offloads heavy lifting (like rotating and scaling images to find a match) to efficient scripts. This makes the agent both smarter and, surprisingly, often cheaper to run in terms of API tokens.

Key Results

EvoViM didn't just beat the baselines; it demolished them.

  • Performance Jump: It improved average scores over AutoMem (the previous state-of-the-art for evolving memory) by 31.3 to 47.6 points.
  • Visual Nuance: In the DMV-Hard task, EvoViM was able to distinguish between generated patterns that text-based agents found identical.
  • Efficiency: For Card Matching, the evolved EvoViM program used about 1/10th the input tokens of the starting program because it stopped asking the MLLM to "look" at everything and let the code handle the matching logic.
EvoViM significantly improves scores while often reducing or stabilizing the number of tokens used per episode compared to the starting programs.

Limitations and Future Work

While impressive, EvoViM isn't perfect:

  • Purely Visual: It currently doesn't handle audio or other sensory inputs.
  • Static Environments: The tasks are mostly static. Handling dynamic environments where objects move or change while the agent isn't looking is a much harder "memory" problem.
  • Exploration Strategy: While it learns what to remember, its actual navigation/exploration strategy is still relatively simple. Future versions could evolve the "how to explore" logic alongside the "how to remember" logic.

In short, EvoViM suggests that the future of AI agents isn't just bigger models, but models that are clever enough to build their own specialized tools. Now, go get some sleep—you've earned it.

Summary updated

Abstract

Multimodal large language model (MLLM) agents have shown promising capabilities in task-oriented environments. However, they still struggle when queries are deferred until after exploration, requiring them to retain visual evidence before knowing which details will matter. We introduce EvoViM, a recursively self-evolving framework in which a frozen multimodal model turns its own interaction experience into one visual program for memory and skills. The program retains images and computes directly on pixels, and its operations decide how this evidence is used in each task. During memory evolution, the same model traces failures in its visual trajectories to the operations that lost or misused evidence and revises them. It also rewrites the notes and analysis tools that guide later revisions, which then build on earlier findings and skip changes that have already failed. We evaluate EvoViM with three multimodal models on six tasks covering visual matching, spatial recall, and sequential decision-making, including three tasks with deferred queries. Across the six tasks, EvoViM improves the average score over AutoMem, the strongest baseline in the main comparison, by 31.3-47.6 points on held-out episodes. Programs written once from the initial environment instructions perform substantially worse, highlighting the value of interaction experience in shaping how visual evidence is retained and used. Code and dataset are available at https://evovim.github.io/.
BibTeX
@misc{cao2026evovim,
  author = {Xinyu Cao and Tianjie Ju and Zhuosheng Zhang},
  title = {{EvoViM: Recursively Self-Evolving Visual Agents for Exploration with Deferred Queries}},
  year = {2026},
  eprint = {2611.28574},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.28574},
}
Figure