NeFut Logo NeFut
中 Admin Login

[CS.AI] When to Compile a Computer-Use Agent? Measuring Payback and Making Compilation Decisions for Token Efficiency

Published at: 2026-10-06 22:00 Last updated: 2026-10-08 01:25
#AI #optimization #LLM

Compiling GUI procedures that agents run repeatedly into standalone programs can markedly cut token usage. Two key challenges arise: compilation cost is uncertain because attempts may need repair and still fail; and future reuse is unknown since task streams may stop or GUI drift can break the program. To tackle these, we introduce PACE (Payback‑Aware Compilation from Experience), which consists of a measurement protocol and an online compilation algorithm. The protocol logs both successful and failed compilation expenses and, on matched task inputs, compares the agent’s execution cost with that of the compiled program to estimate per‑use savings and payback counts. Using these measurements, the online algorithm leverages past task arrival patterns and compilation outcomes to forecast cumulative future savings and weigh them against total compilation costs, including failed attempts. Before executing or compiling, it checks a cumulative budget: an action is permitted only if the observed task arrivals can cover the expected cost. Under the assumed action‑cost model, the total cost after each arrival is at most $1+\epsilon$ times the cost of running every task with the raw agent. In experiments, successful compilations achieve estimated payback counts (excluding the original agent runs) of 2‑16 uses. Simulations on recorded task arrivals show that PACE reduces token costs on average by 17.3% versus ReAct, 24.9% versus the AutoRPA adaptation, and 17.3% versus the ToolPro adaptation (\epsilon=0.25).

Review

Original Source: https://arxiv.org/abs/2610.02932

[h] Back to Home