arXiv:2610.26503cs.AIOct 2026

Manuscript Offprint

arXiv:2610.26503

ScopeMem: Latent Memory That Learns Where to Revise Frozen GUI Agents

Zhicheng Zheng, Cheng Zhang, Shengping Yu, Tianxiang Zhao

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

Latent memory is gaining ground as a lightweight history supplement for GUI agents. It supplies history to a frozen vision-language model via prefix vectors trained with step-wise cross-entropy (CE). While resulting gains are naturally attributed to encoded history, our controlled experiments show they primarily stem from action revision. The prefix learns to alter the model's default actions. However, this revision is unscoped because step-wise CE pushes outputs toward reference actions at every step without explicitly preserving correct decisions. Consequently, it repairs errors but also breaks 8–13% of initially correct answers. Overall accuracy metrics hide these losses. We therefore propose SCOPEMEM, a latent-memory method for scoped revision. Its encoder conditions prefix generation on the model's initial answer and is trained to correct errors while preserving correct decisions. On the controlled ablation set, SCOPEMEM reduces the share of broken correct decisions to 5.6% while repairing more errors than any evaluated CE-trained prefix. On AndroidControl, GUI-Odyssey, and zero-shot AITW, SCOPEMEM outperforms all evaluated prompting and latent-memory baselines, enabling a frozen Qwen3-VL-8B to match or surpass GUI-specialized agents and Qwen3-VL-32B.

1 Introduction

Latent memory is gaining ground as a lightweight history supplement for GUI agents built on general-purpose vision–language models (Wu et al., 2025a; Zhang et al., 2026b,c). We call the frozen model that selects each action the actor. An encoder converts history into a small set of continuous prefix vectors, which are prepended to the actor's input (Li and Liang, 2021). Only the encoder is trained, with step-wise cross-entropy (CE) on reference actions. The prefix's gains are often attributed

Fixed-query prefix ← Actor alone → ScopeMem without a scope with a scope

Figure

Figure 1: Revision cuts both ways. Of the frozen actor's 1,463 decisions (centre), a fixed-query latent-memory prefix (left) repairs 196 errors but harms 115 correct decisions. Its 5.5-point accuracy gain (pp: percentage points) hides these harms. SCOPEMEM (right) learns to focus revisions on the actor's errors, repairing 254 and harming 49.

to stored history. We test this explanation by examining which decisions the prefix changes.

Our controlled experiments ( §3§3) show that much of the gain persists even when the encoder does not read history. Holding the actor, its context and training fixed, a task-only encoder improves accuracy by 12.0 percentage points, compared with 11.8 points for an encoder that also reads recent history. The actor already sees the same recent history in both conditions, so this comparison isolates the benefit of encoding that history again into the prefix. The small difference suggests that, in this setting, the prefix mainly revises actions using the actor's existing context.

At every step, CE rewards changes that move the actor’s output towards the reference action, without requiring its output distribution to remain unchanged when its decision is already correct. This leaves the revision unscoped. A change can repair

Code available at ScopeMem Open-Source Code an incorrect decision, but it can also turn a correct decision into an incorrect one, which we call a harm. Across our CE-trained prefixes, 8–13% of the actor's originally correct decisions become incorrect. Encoders that read different inputs exhibit similar harm rates, pointing to their shared objective. Figure 1 illustrates how overall accuracy gains can conceal many harms because accuracy reports only the net effect of repairs and harms.

We therefore propose SCOPEMEM, a latent-memory method for scoped revision. It aims to repair the actor's errors while preserving the decisions it already gets right. To make this judgement, the encoder needs to see the particular answer it may revise, which a context-only encoder never directly observes. SCOPEMEM therefore conditions prefix generation on the actor's first opinion. Figure 2 shows the resulting two-pass process. The frozen actor first responds without a prefix. The encoder then reads this answer and its confidence signals together with the task and recent history, and generates a prefix for a second pass over the same context. The resulting second opinion is the action SCOPEMEM takes.

However, seeing the first opinion does not teach the encoder which decisions to preserve. We therefore train only the encoder with a scoped preservation objective. We call the steps where the actor's original answer is wrong the scope of revision. During training, reference actions identify these steps. CE remains active at every step to encourage the reference action. Outside the scope, we additionally penalise changes to the actor's original output distribution. At deployment, the encoder uses the first opinion and context to decide which answers to preserve, without access to reference actions.

On the controlled ablation set, scoped preservation reduces harms for every encoder, most strongly for the first-opinion encoder. SCOPEMEM lowers the harm rate to 5.6% while repairing more errors than any CE-trained prefix. Across AndroidControl, GUI-Odyssey and zero-shot AITW, it outperforms all evaluated prompting and latent-memory baselines. With SCOPEMEM, the frozen Qwen3-VL-8B actor matches or surpasses GUI-specialised agents and Qwen3-VL-32B under the same actor context.

Our contributions are threefold:

  • With recent history already in context, our CE-trained prefixes mainly revise decisions rather than supply history ( §3\S3 ).
Line of workActorRevisionHarms
frozenreadslearnedpreventedreported
GUI fine-tuning and RL✕✕✓✕✕
Explicit memory✓✕✕✕✕
Latent memory✓✕✓✕✕
Self-reflection✓✓✕✕⊙
SCOPEMEM✓✓✓✓✓

Table 1: Only SCOPEMEM combines learned revision, access to the first opinion, and an objective for preserving correct decisions. Reads: sees the first opinion; learned: trained; prevented: preservation is a training objective; reported: repairs and harms reported; Ⓤ: partially.

  • Cross-entropy leaves this revision unscoped. Every tested prefix trained with CE alone breaks some correct decisions, and aggregate accuracy hides these losses. We therefore recommend reporting repairs and harms alongside accuracy.

  • We propose SCOPEMEM, which combines an encoder that reads the actor's first opinion with a scoped preservation objective. SCOPEMEM outperforms the evaluated prompting and latent-memory baselines across three benchmarks ( §§4–6\S\S4–6 ).

References (19)