Preprint
Reinforcement Learning

Activity Frames: Deterministic Screen-Activity Compilation for Agent Memory and Replay

Nossa Iyamu
August 6, 2026

0

Citations

0

Influential Citations

Venue

2026

Year

Abstract

Computer-use agents pay full frontier inference to re-derive routines their user has already performed, because an agent's memory today records what the user said, not what the user did. We compile passively captured screen activity into agent memory with a deterministic, zero-model pipeline: it segments a local capture stream into typed activity frames, bounded episodes carrying application, site, timing, input volume, and evidence pointers back to the raw rows, with no model in the loop, so the output is byte-identical, cacheable, and mechanically auditable. On one professional's single-user corpus of 128,756 frames over 51 active days, the compiler reduces a day of raw capture to a prompt-ready context block 86x smaller in 68 ms, and an agent reading that block answers questions about the day at 98.4% accuracy (Wilson 95% CI 91.7-99.7%) against an independent oracle, versus 66-80% for an LLM summary of the same capture, a mid-tier model reading the block matching a frontier one. The same compiler doubles as a demand-side cost instrument. Read off passive, pre-delegation human activity rather than agent rollouts, it supplies two parameters that agent-cost models assume but, to our knowledge, have not measured: the Routine Overhead Ratio R and the routine recurrence h. We report first values of R, a modeled upper bound, at 60-343x, and a delegable recurrence of 9.0% in-sample and 7.7% out-of-sample, for a realistic all-fleet token ceiling near 8%; a compiled routine replays deterministically with the model out of the loop, demonstrated live at zero model tokens on a guard-matched hit. Schema, compiler, and evaluation harness are open.

Analysis

Why This Paper Matters

Computer-use agents today often re-derive routines that users have already performed, wasting inference tokens and time. This paper addresses a critical gap: agent memory typically records what users say, not what they do. By compiling passively captured screen activity into structured, deterministic frames, the authors offer a memory system that is both efficient and auditable, directly tackling the cost and reliability challenges in agent deployment.

The significance extends beyond memory. The paper introduces a novel use of the compiler as a demand-side cost instrument, measuring parameters that agent cost models have long assumed but never empirically grounded. This could reshape how we estimate and optimize token budgets for fleets of agents, making large-scale deployment more predictable and affordable.

Technical Contributions

  • Deterministic, zero-model compilation: The pipeline segments raw screen capture into typed activity frames without any model in the loop, ensuring byte-identical, cacheable, and mechanically auditable outputs.
  • Typed activity frames: Each frame is a bounded episode with application, site, timing, input volume, and evidence pointers to raw rows, enabling precise replay and analysis.
  • Cost parameter measurement: The compiler reads passive human activity to derive Routine Overhead Ratio (R) and routine recurrence (h), providing first empirical values for these cost-model inputs.
  • Zero-token replay: Compiled routines can be replayed deterministically with the model out of the loop, demonstrated live at zero model tokens on a guard-matched hit.
  • Open-source artifacts: Schema, compiler, and evaluation harness are released, facilitating reproducibility and further research.

Results

The compiler processes a day of raw capture into a context block 86x smaller in just 68 ms, a dramatic efficiency gain. In question-answering tasks, an agent reading the compiled block achieves 98.4% accuracy (Wilson 95% CI 91.7-99.7%), outperforming LLM summaries of the same capture (66-80%). Notably, a mid-tier model reading the block matches a frontier model, suggesting that the structured representation reduces the need for powerful reasoning. The measured Routine Overhead Ratio R ranges from 60x to 343x, and routine recurrence h is 9.0% in-sample and 7.7% out-of-sample, leading to an all-fleet token ceiling near 8%—a realistic bound for delegable routines.

Significance

This work introduces a practical, deterministic memory layer for computer-use agents, potentially reducing inference costs and improving reliability. By providing empirical cost parameters, it enables more accurate budgeting for agent fleets, which is crucial for commercial deployment. The open-source release encourages adoption and further innovation, possibly leading to standardized activity frame formats. The approach also raises interesting questions about privacy and the trade-offs between passive capture and active logging, which future work must address. Overall, this paper is a step toward more efficient, auditable, and cost-effective autonomous agents.