Web agents built on vision-language models (systems that read a screenshot plus text and output an action) are given a memory of past experience because, with frozen weights, they otherwise repeat the same mistakes in every session. The usual memory is a set of text "workflows" distilled from earlier successful runs. We propose that this memory has a cost nobody has measured. A retrieved routine that says "click the Sort button, then choose Price" is strong text context, and text context is known to pull a vision-language model away from what is actually on the screen. The agent then clicks a button that is not there, or a similar-looking one, because its memory said so. Our plan is to measure this failure on a visual web benchmark and then fix the memory, not the policy. For every retrieved memory at every step, we compute how much it changed the action the agent took, using a cheap counterfactual: rerun the forward pass without that memory. We then ask a generative reward model whether the step was correct given the screenshot. Here a generative reward model means a judge that writes out a reasoned critique before giving a verdict. Multiplying the two gives each memory a signed credit: positive if it pushed the agent toward a correct, screen-supported action, negative if it pushed the agent toward a hallucinated one. Memories that keep earning negative credit are demoted or deleted.
The opportunity is that existing memory-learning methods assign credit only from whole-episode success. They cannot tell a helpful memory from a harmful one that happened to be retrieved alongside it. Existing hallucination fixes, for their part, work on single images and know nothing about memory. Splitting credit into "influence," measured causally, and "correctness," judged against the screen, is what makes per-memory credit possible without running extra episodes.
Core Claim
The claim has two parts. The first is that on visually grounded web tasks, retrieving text experience raises the rate of actions driven by language priors rather than by the pixels on the screen. We call this memory-induced visual hallucination. The second is that a per-step, per-memory signed credit, built from counterfactual influence and a screen-grounded step critique, curates memory better than outcome-level credit. It also preserves more useful memory than conservative write-time filtering. Concretely, for a policy $\pi$ acting on screen state $s_t$ with retrieved memory set $M_t$ and taking action $a_t$, the influence of memory $m$ is
$$I(m,t) = \log \pi(a_t \mid s_t, M_t) - \log \pi(a_t \mid s_t, M_t \setminus \{m\}),$$
and the memory's accumulated credit is $C(m) = \sum_t v_t \, I(m,t)$. Here $v_t \in \{-1,+1\}$ is the critic's verdict on whether step $t$ was correct given the screenshot, and the sum runs over every step at which $m$ was retrieved. Alongside this we track a visual-dependence score, $D(t) = \log \pi(a_t \mid s_t, M_t) - \log \pi(a_t \mid \tilde{s}_t, M_t)$, where $\tilde{s}_t$ is the same state with the screenshot removed. A low $D(t)$ means the action would have been chosen without looking at the screen. This contrast with and without the image is borrowed from IRIS, which uses the same comparison to find prior-driven captions. We apply it to agent actions and pair it with a second contrast over memories.
Why This Gap Is Real
Three findings motivate the work. Agent Workflow Memory induces reusable text workflows from past trajectories and lifts WebArena success from 23.5% to 35.5%. It does this on text-only page representations, and its online variant commits whatever a fallible LLM evaluator calls a success. Memory-Induced Tool-Drift in LLM Agents shows that stored memories that share surface words with the current task act as steering signals inside the model and bend tool calls, even when the model is told to ignore them. Why LVLMs Are More Prone to Hallucinations in Longer Responses shows that as text accumulates, attention shifts away from image tokens toward text tokens. Put together, these predict that injected workflows should make a visual agent look at the screen less. That prediction has not been tested. VisualWebArena shows that visual grounding errors already dominate agent failures there.
Two findings constrain the design. RoMeRL names the "memory-reward trap": one successful episode credits every memory retrieved with it. RoMeRL handles this by compressing memory into four coarse utility states, and it concedes that outcome rewards cannot isolate which entry helped. It is also text-only, evaluated on ALFWorld and LifelongAgentBench. Before It Persists shows that strict write-time filtering of multimodal memory stops poisoning, but it cuts benign task completion from 0.655 to 0.418 on LoCoMo-Adv. Whatever curates memory must therefore be selective, not blanket.
The method draws on generative reward modeling. WebArbiter is a step-level judge that writes principles and justifications for web actions, reaching 74.6% best-of-N accuracy on WebPRMBench. It reads only accessibility trees and keeps no cross-episode memory. GenAlign is a multimodal rubric-based judge that reaches 73.68% on VL-Reward-Bench and raises LLaVA-1.5 on HaloQuest from 14.52% to 45.16%. It judges single-turn responses, and its authors note that the link from rubric to verdict is not shown to be causal. Our design deliberately avoids relying on that link. The critic is never asked which memory caused the action; that attribution comes from the counterfactual $I(m,t)$. The critic answers only a narrower, checkable question: is this action correct given this screen? VLRewardBench adds a warning. Vision-language judges fail mostly on basic perception, and sampling more judgments can make them worse. We therefore use a single judgment and audit the critic's perception directly.
Research Program
The first stage is diagnostic. We run an open-weight vision-language policy, so that action log-probabilities are available, on VisualWebArena in three conditions: no memory, relevant memory, and lexically similar but task-mismatched memory. Relevant memory means workflows induced from training tasks on the same site. Mismatched memory means workflows sharing entities but serving a different goal, the distractor type identified by Grounding Agent Memory in Contextual Intent. We measure task success, the distribution of $D(t)$, and a memory-induced grounding error rate. That error rate is the fraction of actions targeting an element absent from the current Set-of-Marks screen or contradicted by it, labeled automatically from the marked elements and audited by hand on a sample.
The second stage builds the critic. We fine-tune a multimodal generative judge to produce a short critique and a correct/incorrect verdict for a (screenshot, task, action) triple. Training data comes from execution-checked VisualWebArena training trajectories. The critic is required to name the screen element its verdict rests on, so its perception can be audited against Set-of-Marks labels. We check it on VL-Reward-Bench and on a held-out set of step labels.
The third stage curates memory. After each episode, $C(m)$ is updated for every retrieved memory; a memory whose credit falls below a threshold is retired. Influence costs one extra forward pass per retrieved memory per step and needs no new environment rollouts. A small subset of episodes gets expensive leave-one-out reruns, in which the full episode is rerun without memory $m$. These serve as a ground-truth credit signal for validating $C(m)$.
Baselines
The naive reference point is the same policy with no memory, alongside the closed GPT-4o with Set-of-Marks system, which VisualWebArena reports at 19.78% overall success. That figure anchors the scale but is not a matched comparison.
The strongest existing memory method is AWM-style workflow memory with RoMeRL-style outcome credit. This combines Agent Workflow Memory induction with RoMeRL's four-state utility updates driven by episode success. It is the strongest competitor because it is exactly "learn memory from outcomes," the alternative our credit replaces. AWM's text result is 35.5% on WebArena and RoMeRL's is 0.862 success on its text suites; we found no reported result on Lacuna for either AWM or RoMeRL on VisualWebArena, so we will run both ourselves.
We also include STITCH-style intent-structured retrieval, which filters at read time, and a SAGE-Mem-style write-time admission filter, which filters at write time.
To keep the comparison fair, all methods share the same policy, the same training-task stream, the same memory capacity, the same retriever backbone, and the same number of environment episodes. Any method that uses a judge, including AWM's online evaluator, gets our critic, so differences reflect how credit is used rather than judge quality. Threshold hyperparameters get the same tuning budget on a held-out split.
Two ablations isolate the key ingredients. In the first, influence is kept but the critic's $v_t$ is replaced by episode success, which tests whether step-level, screen-grounded valence matters. In the second, the counterfactual is replaced by asking the critic to name the responsible memory, which tests whether causal attribution matters. Beating the strongest baseline means higher held-out VisualWebArena success at matched memory size and episode budget. It also means a lower memory-induced grounding error rate, and closer agreement of $C(m)$ with leave-one-out rollout credit than outcome credit achieves.
Why not just…?
Why not just tell the agent to ignore memory that doesn't match the screen? Breaking Focus found that instructing models to ignore irrelevant context did not repair an average degradation above 45%. Memory-Induced Tool-Drift found such instructions only partly reduce drift. We nonetheless include this prompt in the diagnostic stage, because if it closes the visual-dependence gap on screens, the rest of the program is unnecessary.
Why not just compute leave-one-out credit with real rollouts? This is the most principled alternative and a real threat on accuracy. Its cost is one full episode per memory per task. With success rates near 20%, most reruns also return the same failure and carry little signal. We use it as the oracle on a subset. If our cheap $C(m)$ tracks it poorly, the method fails, and that is the decisive comparison.
Why not just use the implicit image-contrast reward from IRIS and skip the generative judge? $D(t)$ flags actions taken without looking, but a prior-driven action can still be correct, especially when the memory is right. IRIS itself reports modest gains on compositional reasoning. The first ablation, plus a variant that sets $v_t$ from the sign of $D(t)$, tests directly whether the explicit critic earns its cost.
Why not just retrieve better, as STITCH does? Better retrieval removes mismatched memories but cannot detect a relevant-looking workflow that is stale for the current layout. AWM identifies this brittleness to UI changes as its main limitation. The STITCH-style baseline, run on our layout-perturbed task split, settles whether credit adds anything beyond retrieval.
Proposed Experiments and Decisive Checks
The main benchmark is VisualWebArena, using its Classifieds, Shopping, and Reddit sites with training and test task splits and a layout-perturbed copy of the test sites. We report success rate, memory-induced grounding error rate, the distribution of $D(t)$, retained memory size, and judge calls per episode. The critic is audited on VL-Reward-Bench, where GPT-4o scores 62.4% and GenAlign 73.68%. On text-only WebArena we check that the method does not hurt AWM's 35.5% setting. A noisy-evaluator stress test flips 20% of success labels during online induction, to measure how much bad memory survives under AWM credit versus ours.
Three results would be decisive. First, if relevant or mismatched memory does not raise grounding errors or lower $D(t)$ relative to no memory, the premise is false and we stop. Second, $C(m)$ must rank memories closer to leave-one-out rollout credit than outcome credit does, and closer than the critic-attribution ablation does. Third, at matched memory size, the curated store must beat AWM with RoMeRL credit on held-out and layout-perturbed success, without the benign-recall collapse seen with write-time filtering. If the critic misreads the screen on more than a small fraction of its own cited elements, its verdicts are unreliable. In that case we report the method's upper bound using execution-checked step labels, and treat critic perception as the bottleneck.
References
- IRIS: Implicit Reward-Guided Internal Sifting for Mitigating Multimodal Hallucination
- Agent Workflow Memory
- Memory-Induced Tool-Drift in LLM Agents
- Why LVLMs Are More Prone to Hallucinations in Longer Responses: The Role of Context
- VisualWebArena: Evaluating Multimodal Agents on Realistic Visual Web Tasks
- RoMeRL: Balancing Feedback Coverage and the Memory-Reward Trap in Self-Evolving Agent Memory via Reduced-Order Utility States
- Before It Persists: Write-Time Defense for Multimodal Agent Memory
- WebArbiter: A Generative Reasoning Process Reward Model for Web Agents
- GenAlign: Towards Unified Alignment Framework of MLLMs via Generative Reward Model
- VL-RewardBench: A Challenging Benchmark for Vision-Language Generative Reward Models
- Grounding Agent Memory in Contextual Intent
- Breaking Focus: Contextual Distraction Curse in Large Language Models