AhaBench: Do Agents Learn from Prior Experience? A Benchmark for Long-Horizon Continual Learning

Zerui Cheng, Jiawei Xu, Huacan Chai, Jiayang Sun, Pramod Viswanath, Maxm PanarXiv 2026

TL;DR

AHABENCH is a new benchmark designed to test whether LLM agents can actually learn and adapt their strategies from prior experience within a single deployment run. By evaluating models across interactive puzzles, math problems, and business simulations, it reveals a critical gap: an agent's ability to follow a visible hint does not necessarily mean it can independently reuse that strategy once the help is removed.

What Problem Does This Paper Address?

When we deploy AI agents in the real world, we expect them to handle long-horizon tasks—things like troubleshooting systems, solving complex math, or running a business. To do this well, an agent needs to learn from its immediate past actions and feedback.

However, standard AI benchmarks usually reset the agent after every prompt or only look at the final state of a single attempt. This creates a massive blind spot. We cannot tell if an agent is genuinely getting smarter from its experiences during a run, or if it is simply copying immediate, visible context. AHABENCH introduces a framework to measure "inference-time continual learning" (learning within the prompt context without updating the model's weights) by testing if an agent can maintain its performance when initial support—like a hint or a code template—is removed, altered, or delayed.

Methods

The authors formalize a three-part scorecard to track an agent's learning trajectory:

  1. Initial Score ($B$): The "cold start" baseline competence before any relevant experience is provided.
  2. Post-Experience Score ($P$): The performance on a related task after gaining experience, but under a harder evaluation condition where direct help is withheld.
  3. Learning Lift ($\Delta = P - B$): The net improvement, which isolates what the agent actually learned and transferred to its independent policy.

This setup explicitly separates temporary context-copying from durable strategy adaptation.

Fig. 1: What AHABENCH measures. The left panel expands the common before–experience–after construction: Initial Score B is direct puzzle solving, cold mathematical solving, or early vending profit; experience is solved traces, a related taught task, or a business trajectory; Post-Experience Score P is the no-hint puzzle endpoint, answer-only held-out task, or incident-setting profit. The right panel reports the aggregate leaderboard sorted by P, with Learning Lift ∆= P −B in parentheses.

Datasets

The paper introduces AHABENCH, a evaluation suite consisting of three distinct, newly constructed or curated environments:

  • AHA-PUZZLE: Curated from classic lateral-thinking situation puzzles (like the classic "albatross puzzle"). Agents must ask yes/no questions to uncover a hidden story. The final challenge removes all trace prefixes to see if the agent learned how to interrogate an unknown state.
  • AHA-EULER: Inspired by Project Euler mathematical programming problems, these are algorithmic tasks with exact validators. It pairs a taught instance (with answers/code) with a structurally related, held-out test instance to measure algorithmic reconstruction.
  • AHA-VENDING: An open-source business simulator where the agent manages a vending machine business over a 365-day horizon. It forces the agent to learn from delayed environmental feedback while dealing with cash-flow pressure, stockouts, and adversarial incidents (like phishing and machine failures).

Key Insights and Ideas

  • Visible Support Masks True Capability: Models often score exceptionally high when a full trace or code solution is visible in their context window. However, their performance frequently plummets the moment that support is removed. True learning requires reconstructing the underlying method, not just copying it.
  • The "Axis Disagreement": An agent's strength is not a single monolithic metric. Models that excel at using visible support are not always the ones that achieve the highest post-experience scores or show the largest Learning Lift.
  • The Long-Context Tension: Providing more history gives agents more data to learn from, but it also introduces irrelevant state information. If a model cannot filter this noise, the extra history can actually degrade its performance, leading to a negative Learning Lift.

Key Results

  • Claude Opus 4.6 led the aggregate leaderboard with a Post-Experience Score of 64.3 and the highest overall Learning Lift at +25.8.
  • Gemini 3.1 Pro followed closely with a Post-Experience Score of 63.4, though its Learning Lift was lower (+8.2) because it started from a much higher initial baseline.
  • GPT-5.4 demonstrated strong initial capabilities and led the mathematical reasoning category (AHA-EULER post-experience score of 73.9), but showed a slightly negative aggregate Learning Lift (-0.7), indicating difficulties adapting across the entire suite.
  • In AHA-PUZZLE, while visible traces boosted everyone's scores, only Qwen 3.6 showed a clear, robust transfer gain (+12.15) when the hints were completely removed.
  • In AHA-VENDING, Claude and Gemini maintained strong profitability under adversarial incidents, whereas weaker models like Doubao and DeepSeek collapsed into bankruptcy.

Limitations and Future Work

  • Long-Horizon Cost: Evaluating agents over long trajectories with multiple interaction turns dramatically scales up token consumption and evaluation time, making rapid benchmarking expensive.
  • Competitive Dynamics: The single-agent policies evaluated in the main suite do not directly translate to competitive environments. In a "Shared-Market Arena" test where multiple agents competed for the same customer demand, all models failed and lost money.
  • The authors suggest that future work should focus on helping agents better filter irrelevant history in long contexts and developing robust policies that can survive competitive, multi-agent market dynamics.

Summary updated

BibTeX
@misc{cheng2026ahabench,
  author = {Zerui Cheng and Jiawei Xu and Huacan Chai and Jiayang Sun and Pramod Viswanath and Maxm Pan},
  title = {{AhaBench: Do Agents Learn from Prior Experience? A Benchmark for Long-Horizon Continual Learning}},
  year = {2026},
  eprint = {2609.05435},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2609.05435},
}
Figure