AI News HubLIVE
原文2 min read

Remember, Don't Re-read: Stateful ReAct Agents for Token-Efficient Autonomous Experimentation

This paper introduces a stateful ReAct agent built with LangGraph that avoids re-reading entire history at each iteration, cutting token costs by 90% in hyperparameter tuning and 52% in code optimization while maintaining performance. It provides a blueprint for practitioners to implement token-efficient autonomous experimentation. (Source: arXiv, June 2026)

SourcearXiv Machine LearningAuthor: Faramarz Jabbarvaziri

[2606.14945] Remember, Don't Re-read: Stateful ReAct Agents for Token-Efficient Autonomous Experimentation

[Submitted on 12 Jun 2026]

Title:Remember, Don't Re-read: Stateful ReAct Agents for Token-Efficient Autonomous Experimentation

View a PDF of the paper titled Remember, Don't Re-read: Stateful ReAct Agents for Token-Efficient Autonomous Experimentation, by Faramarz Jabbarvaziri

View PDF HTML (experimental)

Abstract:The autoresearch pattern enables autonomous experimentation by having a large language model (LLM) iteratively modify code to optimize a target metric. Its stateless design, however, reconstructs experimental context from scratch at every iteration, incurring $O(n)$ token cost per iteration and $O(n^{2})$ total. This work reformulates the pattern as a stateful ReAct agent using LangGraph, where typed persistent state carries experimental history across iterations via a tool-calling interface. Two benchmarks are evaluated: hyperparameter tuning (15 iterations, small per-iteration observations) and code performance optimization (40 iterations, large per-iteration observations containing full source code and benchmark results). On hyperparameter tuning, the stateful agent consumes 90\% fewer tokens (2{,}492 vs.\ 24{,}465). On code optimization, the stateful agent consumes 52\% fewer tokens (627K vs.\ 1{,}275K) while achieving comparable optimization quality on both tasks. The token reduction is structural: the stateless agent re-reads the full history at $O(n)$ cost per iteration, while the stateful agent operates within a fixed-size conversation window at $O(1)$ cost. This paper describes the architecture in sufficient detail for practitioners to implement a stateful autoresearch agent for their own workflows.

Subjects:

Machine Learning (cs.LG)

Cite as: arXiv:2606.14945 [cs.LG]

(or arXiv:2606.14945v1 [cs.LG] for this version)

https://doi.org/10.48550/arXiv.2606.14945

arXiv-issued DOI via DataCite (pending registration)

Submission history

From: Faramarz Jabbarvaziri [view email] [v1] Fri, 12 Jun 2026 20:40:59 UTC (733 KB)

Full-text links:

Access Paper:

View a PDF of the paper titled Remember, Don't Re-read: Stateful ReAct Agents for Token-Efficient Autonomous Experimentation, by Faramarz Jabbarvaziri

View PDF

HTML (experimental)

TeX Source

view license

Current browse context:

cs.LG

new | recent | 2026-06

Change to browse by:

cs

References & Citations

NASA ADS

Google Scholar

Semantic Scholar

Loading...

Data provided by:

Bibliographic Tools

Bibliographic and Citation Tools

Bibliographic Explorer Toggle

Bibliographic Explorer (What is the Explorer?)

Connected Papers Toggle

Connected Papers (What is Connected Papers?)

Litmaps Toggle

Litmaps (What is Litmaps?)

scite.ai Toggle

scite Smart Citations (What are Smart Citations?)

Code, Data, Media

Code, Data and Media Associated with this Article

alphaXiv Toggle

alphaXiv (What is alphaXiv?)

Links to Code Toggle

CatalyzeX Code Finder for Papers (What is CatalyzeX?)

DagsHub Toggle

DagsHub (What is DagsHub?)

GotitPub Toggle

Gotit.pub (What is GotitPub?)

Huggingface Toggle

Hugging Face (What is Huggingface?)

ScienceCast Toggle

ScienceCast (What is ScienceCast?)

Demos

Demos

Replicate Toggle

Replicate (What is Replicate?)

Spaces Toggle

Hugging Face Spaces (What is Spaces?)

Spaces Toggle

TXYZ.AI (What is TXYZ.AI?)

Related Papers

Recommenders and Search Tools

Link to Influence Flower

Influence Flower (What are Influence Flowers?)

Core recommender toggle

CORE Recommender (What is CORE?)

IArxiv recommender toggle

IArxiv Recommender (What is IArxiv?)

Author

Venue

Institution

Topic

About arXivLabs

arXivLabs: experimental projects with community collaborators

arXivLabs is a framework that allows collaborators to develop and share new arXiv features directly on our website.

Both individuals and organizations that work with arXivLabs have embraced and accepted our values of openness, community, excellence, and user data privacy. arXiv is committed to these values and only works with partners that adhere to them.

Have an idea for a project that will add value for arXiv's community? Learn more about arXivLabs.

Which authors of this paper are endorsers? | Disable MathJax (What is MathJax?)