TL;DR
The paper introduces Chain-of-Experience (CoE), a framework that allows Large Language Models (LLMs) to continually improve at test-time by interacting with their environment and accumulating a history of attempts and feedback. Across math, coding, and knowledge tasks, CoE consistently outperforms traditional inference methods, achieving a 5.6% overall accuracy boost while simultaneously reducing API costs by 19%.
What Problem Does This Paper Address?
Conventional LLMs are deployed in a fixed state. When faced with a difficult problem, they treat each inference attempt as an isolated event, ignoring the rich trial-and-error feedback embedded in the problem-solving process.
While existing test-time scaling strategies (like majority voting or tree search) generate multiple candidate answers, they typically discard the intermediate reasoning paths once a final answer is chosen. Other memory-based methods focus on cross-task memory (carrying strategies from one problem to a completely different one) rather than same-task iterative refinement. The authors address this gap by asking: How can LLMs systematically evolve from their own accumulated experience and feedback during test-time inference?
Methods
The authors formalize Chain-of-Experience (CoE) as a sequential decision process. Instead of just mapping a question $Q$ to an answer $A$, the model generates a response $a_t$ at step $t$ based on the question and the entire history of prior attempts and environmental feedback $e_i = (a_i, f_i)$.
The paper explores a spectrum of four feedback types:
- No Feedback: The model relies purely on internal reflection over its past attempts without external guidance.
- Execution Feedback: For coding tasks, the model receives compiler error messages, runtime logs, or unit test results.
- Model Feedback: An auxiliary LLM acts as a critic, providing textual critiques or structured evaluations.
- Correctness Feedback: An oracle provides a binary success/failure signal (correct/incorrect).
The framework also evaluates Dual Feedback (combining model critiques with binary correctness/execution signals) and Selective Majority Voting (SelMV) to aggregate answers over multiple valid attempts.
Datasets
The CoE framework was evaluated across six diverse benchmarks spanning three core domains:
- Math: AIME 2025 (30 challenging competition problems) and OmniMath (an Olympiad-level math benchmark).
- Coding: LiveCodeBench (V6) and LiveBench (Code), which focus on holistic and uncontaminated code generation.
- Knowledge: EvaLearn (evaluating sequential problem-solving) and GPQA Diamond (a high-difficulty, PhD-level multiple-choice science question set).
- Out-of-Distribution Knowledge: BrowseComp-Plus was used to test the limits of self-feedback when tasks require external, search-based knowledge.
Key Insights and Ideas
- The Rich Get Richer (Base Capacity vs. Learning Gain): There is a strong positive correlation (an average Pearson correlation of +0.50) between a model's initial zero-shot capability and its capacity to learn from experience. Stronger models (like GPT-5 or Claude 4.5 Sonnet) are inherently better at digesting feedback and correcting their mistakes than weaker models.
- The Power of "Constructive Noise": Surprisingly, models are highly robust to spurious or adversarial feedback. When intentionally given entirely incorrect feedback (e.g., always telling the model its answer is wrong), advanced models like GPT-5 mini quickly adapt, forcing themselves to critically re-evaluate their reasoning. Conversely, constantly giving positive feedback can induce overconfidence, leading the model to accept flawed initial responses.
- Diminishing Returns After Early Iterations: When extending iterations from 20 to 50, the authors found that the vast majority of performance gains occur early—within the first 20 iterations. Shorter adaptation loops are sufficient for most reasoning tasks.
- Why Do Models Improve? Using a dual-axis attribution judge, the authors categorized why models flipped from incorrect to correct answers. They found that 47.7% of improvements were directly driven by external feedback (Feedback Fidelity), while coding tasks relied heavily on re-aligning with formatting and syntax constraints (Specification Recall).
Key Results
- Superior Performance: CoE with self-feedback alone outperformed popular cross-task memory baselines like Dynamic CheatSheet (DC) and Agentic Context Engineering (ACE) by an average of 7–9% (improving average accuracy from 62.9% to 71.0%).
- Cost Efficiency: CoE strikes a better balance between accuracy and token efficiency. It achieved a 5.6% overall improvement across tasks while reducing API costs by 19% compared to no-feedback baselines, because feedback-guided iterations prevent the model from generating overly verbose, unguided reasoning paths.
- Complementary Dual Channels: Combining model feedback with execution/correctness signals yielded the best results. For example, using Claude 4.5 Sonnet on LiveBench (Code), dual feedback reached 81.2% accuracy, surpassing executor-only (78.1%) and model-only (57.8%) baselines.
Limitations and Future Work
- Domain Constraints: CoE was primarily validated on structured math, coding, and knowledge benchmarks. Its efficacy drops on tasks requiring out-of-distribution knowledge (like BrowseComp-Plus), where self-feedback can lead to hallucination loops without external search tools.
- No Parameter Updates: This framework operates entirely at test-time via context window manipulation. The model does not actually update its weights, meaning the "learning" is temporary and confined to the current session. The authors note that integrating weight updates to internalize these experiential traces permanently is a vital next step.
Summary updated