The Research Report
You Can Measure When AI Agents Explore Badly — And When They Exploit Badly Too
Language model agents are everywhere now. They write code. They navigate websites. They control robots. All of those tasks share a core demand: the agent has to explore the environment to discover new information, and then exploit what it learned to actually get things done.
We talk about "exploration vs. exploitation" all the time in AI. It is one of the oldest ideas in reinforcement learning. But for LM agents, we have had a measurement problem. You can see what the agent did. You cannot see why it did it. Without access to the agent's internal policy, how do you know whether a failure came from bad exploration, bad exploitation, or both?
A new paper from researchers at the University of Wisconsin–Madison, KRAFTON, and Ludo Robotics gives a concrete answer. They built a framework that measures exploration and exploitation errors from observed actions alone. No peeking inside the model. No assuming a fixed optimal strategy. Just the trajectory.
The paper is "Exploration and Exploitation Errors Are Measurable for Language Model Agents" by Jaden Park, Jungtaek Kim, Jongwon Jeong, Robert D. Nowak, Kangwook Lee, and Yong Jae Lee (arXiv:2604.13151, April 2026). Code is available at github.com/jjj-madison/measurable-explore-exploit.
The Setup: Grids and DAGs
The authors designed a controllable environment that captures the structure of real embodied AI tasks without relying on semantic information. Each episode pairs two things:
- A partially observable 2D grid map where the agent can move up, down, left, or right. Visiting a cell reveals its neighbors and whether it contains a task node. Unvisited cells stay unknown.
- A task directed acyclic graph (DAG) that defines prerequisite relationships between task nodes. Nodes can require AND (all parents achieved) or OR (any parent achieved) preconditions. The agent must discover where these nodes are, satisfy their dependencies, and reach the goal.
Crucially, all task nodes use symbolic labels instead of real-world names. The agent cannot rely on pretraining knowledge about "tomato sauce" or "cheese." It must reason purely from what it observes in the environment.
The environment generation is programmatically adjustable across two axes:
- Exploration level (low, medium, high): Controls grid footprint, corridor width, and spatial exploration burden. Higher exploration levels mean wider maps and sparser task node placement.
- Task DAG difficulty (easy, medium, hard): Controls dependency depth, branching, and exploitation burden. Harder DAGs mean deeper prerequisite chains and more complex AND/OR logic.
This 3x3 grid of configurations lets the authors dial up exploration demands, exploitation demands, or both.
The Metric: Catching Redundant Behavior
The key contribution is a policy-agnostic error metric. It does not compare the agent against a single optimal trajectory. Instead, it identifies actions that no reasonable strategy would produce.
Here is how it works.
At every timestep, the agent's state determines a target set of productive destinations. If there are pending tasks with satisfied prerequisites, those are exploitation targets. If there are unobserved cells, those are exploration targets. The agent should move toward one of these targets.
A move that steps into a target cell or reduces the minimum distance to at least one target counts as a gain. A move with no gain is flagged as an error.
But gain alone is not enough. When targets sit symmetrically around the agent, every move looks like a gain. An agent could oscillate back and forth forever, scoring gain on each step, without ever making real progress.
The authors solve this with a concept they call the stale score. Between progress events (achieving a pending task or entering an unobserved cell), they track three quantities in the no-progress trajectory:
- Cyclomatic complexity (c_t): Increases when the agent closes a loop in already-explored territory. Backtracking once is fine. Closing loops is a sign of wandering.
- Edge reuse (e_t): Counts edges traversed more than twice. Classical graph exploration results guarantee that optimal online exploration traverses each edge at most twice. Going beyond that is structurally redundant.
- Node revisit (n_t): Counts nodes visited more than twice. The node-level analog of edge reuse.
The stale score St = ct + et + nt rises when the agent accumulates redundant structure. When S_t increases from one step to the next, the action is flagged as an error, even if it had positive gain. When the agent makes actual progress, the stale score resets to zero.
Each error gets attributed to exploration, exploitation, or both, depending on whether unobserved cells or pending tasks were available at that timestep.
The result is two error rates per trajectory: exploration error rate and exploitation error rate. These are independent. An agent can explore well but exploit poorly, or vice versa.
What They Found
The authors evaluated a range of frontier LM agents across the full 3x3 configuration matrix. The findings are sharp.
Exploration error predicts success. The log-log relationship between exploration error and success rate is strikingly linear, with R² = 0.947. Agents that explore well have a real chance of completing the task. Agents that explore poorly almost never succeed.
Exploitation error does not predict success as cleanly. The R² between exploitation error and success rate is just 0.006. This makes sense: you need to explore before you can exploit. Exploitation errors only matter once you have something to exploit.
Different models fail in different ways. On the same episode, Claude Haiku 4.5 and Gemini 3.1 Flash Lite show qualitatively different behavior patterns. Claude Haiku 4.5 shows moderate exploration and exploitation errors but still reaches success. Gemini 3.1 Flash Lite shows large exploration errors and fails. The metric captures these distinct failure modes, which a simple success/failure binary would miss entirely.
Reasoning models perform better. Models that do extended reasoning before acting achieve higher success rates. This aligns with other recent findings that chain-of-thought and reasoning capabilities improve planning and decision-making in agentic settings.
Harness engineering helps a lot. This is one of the most practical findings. Providing the agent with a structured summary of accumulated state (the "agent harness") improves both exploration and exploitation. GPT-4.1 jumps from 63.0% to 92.6% success. Gemini 3.1 Flash Lite jumps from 51.9% to 88.9%. These are not incremental gains. They come from simply giving the agent better scaffolding for tracking what it has seen and what it needs to do.
Prompt steering shifts failure modes. Exploration-focused prompts reduce exploration error. Exploitation-focused prompts reduce exploitation error. You can dial the knob depending on where your agent is struggling.
Why This Matters
Most LM agent evaluations stop at success rate. Did the agent complete the task or not? That is useful, but it tells you nothing about why the agent failed. Two agents with the same 40% success rate might be failing for completely different reasons. One might be an overconfident exploiter that never ventures far enough. The other might be an aimless explorer that discovers everything but cannot put the pieces together.
This paper gives you a diagnostic, not just a score. The exploration/exploitation error decomposition tells you where to invest your engineering effort. If exploration error is high, give the agent better scaffolding for discovery. If exploitation error is high, improve its planning and state tracking.
The symbolic task DAGs are also worth noting. By stripping away real-world semantics, the authors prevent models from coasting on pretrained knowledge. An agent that aces a cooking benchmark because it has memorized recipes is not demonstrating reasoning. The symbolic setup forces genuine in-environment reasoning.
The connection to classical graph theory is another strength. The stale score borrows from decades of work on graph exploration bounds (Tarjan, Edmonds-Johnson, Deng and Papadimitriou, Panaite and Pelc). This is not an ad hoc metric. It has mathematical teeth.
Limitations and Open Questions
The environment is a simplified proxy for real tasks. A 2D grid with symbolic DAGs is not a coding environment or a physical robot. The authors argue the structure maps onto these domains, and they make a reasonable case. The exploration-exploitation tension in a partially observable environment with task dependencies is genuine and general. But validating the metric on real-world agent trajectories is a natural next step.
The harness engineering results are impressive but raise a question: how much of the improvement comes from the metric's sensitivity to well-scaffolded agents versus genuine capability gains? The authors are transparent that the harness provides structured information that the agent could in principle reconstruct from context. The gap between what the agent could do and what it actually does is itself a finding.
The paper also focuses on single-agent settings. Multi-agent exploration and exploitation, where information sharing and coordination enter the picture, is uncharted territory for this framework.
The Bigger Picture
LM agents are moving from constrained benchmarks to open-ended decision-making. The old evaluation playbook (pass@k, success rate, exact match) does not cut it when the task space is large, partially observable, and structurally complex. We need finer-grained diagnostics.
This paper offers one. It is grounded, reproducible, and comes with working code. The 3x3 evaluation grid is a practical tool for anyone benchmarking agent behavior. The metric itself is a contribution that could generalize beyond this specific environment.
The core insight is simple: you do not need to know what the agent is thinking. You just need to watch what it does, identify actions that no reasonable strategy would produce, and separate the ones where it should have explored from the ones where it should have exploited.
That is measurable. Now we have the ruler.
Citations
- Park, J., Kim, J., Jeong, J., Nowak, R.D., Lee, K., & Lee, Y.J. (2026). Exploration and Exploitation Errors Are Measurable for Language Model Agents. arXiv:2604.13151. https://arxiv.org/abs/2604.13151
- Code repository: https://github.com/jjj-madison/measurable-explore-exploit
- Yao, S. et al. (2023). ReAct: Synergizing Reasoning and Acting in Language Models. ICLR.
- Tarjan, R.E. (1972). Depth-first search and linear graph algorithms. SIAM Journal on Computing.
- Panaite, P. & Pelc, A. (1999). Exploring unknown undirected graphs. Journal of Algorithms.
- Dessmark, A. & Pelc, A. (2004). Optimal adaptive exploration of anonymous graphs. SSPAC.