arXiv:2610.31307cs.AIOct 2026

Manuscript Offprint

arXiv:2610.31307

Subgoal-aware Memory Graph for GUI Agent

Dezhao Luo, Daniel Beechey, Derek Yuen, Weilin Luo

Abstract

GUI agents aim to automate complex user tasks by interacting with mobile interfaces, but effective decision-making in long-horizon settings requires reusing prior experience rather than relying solely on the environment observations. Existing memory-based methods typically store experience either at the single-action level or as entire trajectories. Single-step actions are often too fine-grained to carry meaningful semantics, since the success of an individual action does not necessarily imply progress towards the overall goal. In contrast, whole trajectories are often too coarse-grained and difficult to reuse across different tasks.

We propose a subgoal-aware memory graph that distils past trajectories into structured, reusable evidence at the level of subgoals. We define a subgoal as consecutive actions sharing a single intent, the granularity at which progress toward the task becomes meaningful. To reduce redundancy and support cross-task reuse, we organise subgoal experiences as nodes in a graph, where related memories can be merged, extended, and retrieved based on the environment observation. On SPA-Bench, our method improves success rate by 11.11% over the baseline.

1 Introduction

GUI agents aim to complete complex user goals by interacting with graphical user interfaces, from web pages (Zheng et al., 2024; Deng et al., 2023; Zhou et al., 2024) to mobile phone screens, such as ordering items on a shopping app, setting up an alarm, or navigating settings (Zhang et al., 2025; Wang et al., 2024a; Hong et al., 2024; Rawles et al., 2023, 2025). In benchmarks like SPA-Bench (Chen et al., 2025), a single task can require more than 30 GUI actions across several screens. In such long-horizon settings, relying solely on the environment observation is insufficient because many subgoals recur across tasks and apps, and without reusing prior interaction experience, an agent must re-explore the same workflows from scratch (Xie et al., 2025; Zhu et al., 2026).

A straightforward solution is to equip the agent with an episodic memory it can query at inference time (Packer et al., 2023; Park et al., 2023). Existing memory-based methods, however, typically store experience either at the single-action level (Xie et al., 2025) or as entire trajectories (Zhu et al., 2026), and both granularities are problematic on mobile GUIs. Single-step actions are too fine-grained to carry semantics on task progress, since whether a tap or swipe “succeeds” locally tells the agent little about whether the overall goal is being approached. Whole trajectories, on the other hand, are too coarse-grained, since a full episode, as stored in representations such as HyMEM (Zhu et al., 2026), is tied to a specific task path, making it rarely reusable across tasks that share intermediate steps but diverge in specifics.

We argue for an intermediate abstraction level, namely subgoals, which we define as contiguous sequences of actions that jointly express a coherent sub-intent. Unlike raw actions, subgoals reflect progress toward the goal. As illustrated in Figure 1, the same subgoal can either succeed or fail depending on the underlying behaviour, a distinction that is invisible at the single-action level. Unlike whole trajectories, subgoals transfer naturally across related tasks, since many tasks share the same underlying subgoals.

Building on this granularity, we organise past experience into a subgoal-level memory graph. Each raw trajectory is first segmented into a chain of subgoals. Rather than storing the full action sequence, we represent each subgoal as a transition between its boundary visual states (the starting and ending screenshots), annotated with a subgoal de-

∗^{*}Corresponding author. Email: luoweilin3@huawei.com

Subgoal: Find Google Play Store

Figure

Behavior pattern:

Opened search, typed Google Play Store, submitted it, selected the result, and changed the filter.

Figure

Behavior pattern:

Repeatedly scrolled through the app notification list looking for Google Play Store.

Figure 1: The same subgoal can succeed (left) or fail (right) depending on the underlying behaviour. Subgoal granularity exposes progress toward the user goal that is invisible at the single-action level.

scription, a success label, a behaviour summary of the underlying actions, and an effect description obtained by comparing the boundary states. Boundary states are then embedded and merged across trajectories when visually similar, so that each subgoal becomes a directed edge between two shared memory nodes. The resulting graph consolidates reusable visual states and the semantic transitions between them, and can be incrementally extended with new trajectories.

On the SPA-Bench (Chen et al., 2025) English single-app level-3 split, our subgoal-aware memory graph achieves an improvement of 11.11% over a memory-free baseline with the same Qwen3-VL-8B-Instruct (Bai et al., 2025) backbone.

References (12)