{"slug": "scaling-proactive-compute-when-agents-anticipate-the-task", "title": "Scaling Proactive Compute: When Agents Anticipate the Task", "summary": "Sweeping a proactive study budget from 64 to 128k tokens across nine benchmarks and three model families, researchers found that agents which study their context while idle reach the same accuracy with a fraction of the test-time tokens and far fewer tool calls, according to the study. The work controls both the proactive budget and the test-time budget (64 to 64k tokens) with budget forcing, and covers SWE-QA-Pro, StudyBench, ARC-AGI-1, MIR-Bench, Harvey LAB and four AIME and HMMT math contests. Because every task on the same context reuses the study, its cost amortizes across multiple tasks, which the authors frame as a second axis of scaling complementary to test-time compute.", "body_md": "**TL;DR:** Today's agents are mostly reactive, and they spend much of their time waiting even though they have access to their environment the whole time. We show that they become more effective as they grow more proactive. We let agents study their environment while they wait for new tasks or tool calls, by spending what we call *proactive compute*, and we scale it as an axis of inference complementary to test-time compute.\n\nWhen an agent spawns in a codebase, it won't explore the code until you ask a question. When it runs a tool, it just sits there, waiting for the result. But people don't work this way! Students don't wait for the exam to start before opening the textbook, and chess players don't go to sleep while their opponents think.\n\nInstead of being reactive, agents can use this idle time by spending what we call *proactive compute.* They can study the available context [before a task arrives](https://arxiv.org/abs/2504.13171), or plan ahead [while they wait for tool results](https://arxiv.org/abs/2605.22154). In this work, we study how proactive compute scales: we sweep the proactive study budget from 64 to 128k tokens across nine benchmarks and three model families, and measure how accuracy, latency, and cost change with scale. We ask:\n\n*How does agent performance scale with proactive compute, and what makes it effective at large budgets?*\n\nWe find that an agent that has studied its context reaches the same accuracy with a fraction of the test-time tokens and far fewer tool calls, and an agent that keeps working while its tools run gets ahead in wall-clock time. Because every task on the same context reuses the study, we can amortize its cost over multiple tasks. Overall, we view proactive compute as a second axis of scaling, complementary to test-time compute.\n\n## Proactive agents use idle time to study the context and plan ahead\n\nIn the *offline* setting, when the agent is waiting for its task, the agent explores the context *C* before the task *q* arrives and writes a trace of *P* tokens, which we call the *study* ([Figure 2](#fig-2)). When the task *q* arrives, the study stays in its history, and the same agent, now the *solver*, solves the task using *T* test-time tokens. In the *online* setting, when the agent is waiting for a tool result, it writes up to *P* tokens per wait while a command runs in the background, and a command that finishes early cuts the wait short.\n\nWe control both budgets exactly with [budget forcing](https://arxiv.org/abs/2501.19393). If the model stops early, we tell it to keep going, and if it goes over, we cut it off at our desired budget. We sweep *P* from 0 to 128k and *T* from 64 to 64k tokens. We evaluate 9 benchmarks: two software-engineering benchmarks, [SWE-QA-Pro](https://arxiv.org/abs/2603.16124) and [StudyBench](https://jacobxli.com/blog/2026/machine-studying/); two algorithmic reasoning benchmarks, [ARC-AGI-1](https://arxiv.org/abs/1911.01547) and [MIR-Bench](https://arxiv.org/abs/2502.09933); one legal knowledge-work benchmark, [Harvey LAB](https://www.harvey.ai/blog/introducing-harveys-legal-agent-benchmark); and four math contests from AIME and HMMT.\n\n## Example: the solver uses the study (StudyBench, DSPy)\n\n**Context *C*:** the DSPy repository. DeepSeek-V4-Flash, *P* = 16k, *T* = 256.\n\n**Study (excerpt):** near the end of its 16k-token study, the agent reads `dspy/predict/react.py`:\n\n```\n105  trajectory[f\"thought_{idx}\"] = pred.next_thought\n106  trajectory[f\"tool_name_{idx}\"] = pred.next_tool_name\n107  trajectory[f\"tool_args_{idx}\"] = pred.next_tool_args\n```\n\n**Task *q* (paraphrased):** My `dspy.ReAct` agent has an `add` tool. I want a metric that gives credit only when the answer is correct *and* the agent actually called `add`. My metric checks `pred.tool_calls`, but it never awards credit. Write a small runnable harness that scores this correctly.\n\n**Solver (excerpt, no tool calls):**\n\n```\n# NOTE: ReAct does NOT populate `pred.tool_calls'. It returns a Prediction [...] plus a `trajectory' dict containing `tool_name_{idx}', `tool_args_{idx}' [...] That is where we must look for tool usage.\n```\n\n## Example: the study finds where override paths are anchored (SWE-QA-Pro, CEKit)\n\n**Context *C*:** the CEKit repository, explored with the same read, list and search tool as the solver. DeepSeek-V4-Flash, *P* = 16k, *T* = 64.\n\n**Task *q*:** How does CEKit’s descriptor override system coordinate between configuration loading, descriptor merging, and path resolution when processing override files?\n\n**Study:** in its first 16k tokens the agent makes 215 tool calls. It reads the CLI, the descriptor classes, the documentation and the tests. One of the files is `cekit/generator/base.py`, which loads each override with `os.path.dirname(os.path.abspath(override))` as its directory.\n\n**Solver with the study (excerpt, no tool calls):** “Each parsed override is then wrapped in an `Overrides` descriptor with `os.path.dirname(os.path.abspath(override))` used as its artifact directory (`cekit/generator/base.py: 37-50`). This is where path resolution for override files is anchored: a relative `path` artifact inside an override is later resolved relative to the override file’s directory […]”\n\n**Solver without the study (excerpt, no tool calls):** “This method receives the override file paths, resolves them relative to the current working directory (or the image definition’s directory if `--overrides` are given as relative paths), and loads each file.”\n\n## Studying reduces the tokens needed for the same accuracy\n\nStudying helps most when latency (time to answer) is critical and the solver has little budget at test time ([Figure 3](#fig-3)). On SWE-QA-Pro, a 128k-token study lets DeepSeek-V4-Flash answer as accurately with 64 test-time tokens as it does with about 950 tokens and no study (15× fewer).\n\nWe summarize each curve on the Accuracy vs Test Budget plot using a metric called *test-time efficiency,* which is calculated from the area under the curve.\n\n## Test-time efficiency *E*\n\nTest-time efficiency is the ability to achieve higher accuracy at lower test-time budgets. To summarize the whole accuracy–*T* curve in a single number, we adapt the expertise metric of [Machine Studying](https://jacobxli.com/blog/2026/machine-studying/) and define *E* as the area under the curve with *T* on a log scale, normalized by the curve’s width. Each doubling of *T* counts equally:\n\nwhere $T_1 < T_2 < \\dots$ are the tested budgets.\n\n## Proactive agents save tool calls and thinking tokens while keeping accuracy\n\nWith the study in context, the solver makes fewer tool calls ([Figure 4](#fig-4)): at the largest test budget, a 128k study cuts tool calls by 10× on StudyBench, 4× on SWE-QA-Pro and 1.7× on Harvey LAB. When the solver sets its own budget, a 16k study on SWE-QA-Pro more than halves its thinking and cuts its tool calls tenfold at matched accuracy. On Harvey LAB the uncapped solver can stop too early. All these savings come while the model keeps almost the same accuracy as without a study.\n\n## Studying a 112M‑token filesystem\n\nIn the experiments so far, our studies are contained in one context window (<1M). But we wanted to see if we could scale studying beyond a context window to millions of tokens, and huge contexts. On [Harvey LAB](https://www.harvey.ai/blog/introducing-harveys-legal-agent-benchmark), a 112M-token filesystem from a fictitious law firm, we find that 1) making the study specific to the structure of the context helps a lot, 2) parallel and serial agents can scale proactive compute to millions of tokens, and 3) a hierarchical summary matches the highest expertise at a lower cost.\n\n## Agents that work while commands run beat the median human up to 2× sooner\n\nOn eight [MLE-Bench](https://arxiv.org/abs/2410.07095) (Kaggle) tasks, an agent works in a shell for two hours on one B200 GPU. While a command runs, the proactive agent keeps working for up to 1k, 4k or 16k tokens, while the reactive agent sits idle.\n\nHalf of the 16k agent’s sessions beat the median human after 24 minutes ([Figure 6](#fig-6)), compared to 49 minutes for the reactive agent, about 2× sooner.\n\nTo get to the median human score, the 16k agents generate about 1.7× as many tokens as the reactive agents do, spending tokens for faster wall-clock performance ([Figure 7](#fig-7)).\n\n## A future full of proactive agents\n\nWe think proactive agents will become the norm. We envision a future full of proactive agents that work alongside us all the time. One reads the new papers in your field while your experiment runs. Another fixes the flaky tests in your codebase overnight. Another sees a storm in tomorrow’s forecast and rebooks your flight before you check your email.\n\nToday, most systems improve only when someone asks. With proactive agents, this work can continue between questions, and find problems and opportunities we didn't know we should ask for.\n\n## Acknowledgements\n\nWe thank the members of the [Language, Data, and Reasoning (LDR) Lab](https://ldr.stanford.edu/) and the [Scaling Intelligence Lab](https://scalingintelligence.stanford.edu/) for constructive feedback and helpful comments on this work, in particular Mridul Agarwal, Agam Bhatia, Tanvir Bhathal, Ethan Boneh, Francois Costa, Miria Feng, Alexander Huang, Senem Işık, Hangoo Kang, Seil Kang, Ishan Khare, Hermann Kumbong, Jacky Kwok, Yuzhen Mao, Anay Mehrotra, Iddah Mlauzi, Avanika Narayan, Jon Saad-Falcon, Arshia Soltani Moakhar, Tarun Suresh, Xizhi Tan, Kaitlyn Wang, Annika Young, and Fangzhao Zhang. We are especially grateful to Amin Karbasi for discussions in the early stages of this project that helped shape its direction.\n\nWe thank Meta for generously providing GPU compute resources that supported part of the experiments in this work, and we gratefully acknowledge computing resources provided by Stanford’s Marlowe Computing Instrument.", "url": "https://wpnews.pro/news/scaling-proactive-compute-when-agents-anticipate-the-task", "canonical_source": "https://proactive-compute.stanford.edu/", "published_at": "2026-12-05 10:27:25+00:00", "updated_at": "2026-12-05 10:45:10.937632+00:00", "lang": "en", "topics": ["ai-agents", "ai-research", "large-language-models", "artificial-intelligence"], "entities": ["SWE-QA-Pro", "StudyBench", "ARC-AGI-1", "MIR-Bench", "Harvey LAB", "DSPy", "DeepSeek-V4-Flash", "AIME"], "also_reported_by": [], "takeaway": "Scaling an agent's idle-time study budget from 64 to 128k tokens lets it match baseline accuracy with a fraction of the test-time tokens and far fewer tool calls, and the study cost amortizes across tasks sharing the same context.", "recommendation": {"advice": "Give agents a proactive study budget of up to 128k tokens on the context before tasks arrive, since the study is reused across tasks and cuts test-time tokens and tool calls.", "playbook": "llm-cost", "playbook_url": "https://wpnews.pro/playbooks/llm-cost"}, "alternates": {"html": "https://wpnews.pro/news/scaling-proactive-compute-when-agents-anticipate-the-task", "markdown": "https://wpnews.pro/news/scaling-proactive-compute-when-agents-anticipate-the-task.md", "text": "https://wpnews.pro/news/scaling-proactive-compute-when-agents-anticipate-the-task.txt", "jsonld": "https://wpnews.pro/news/scaling-proactive-compute-when-agents-anticipate-the-task.jsonld"}}