BlogDecember 1, 2026Agent evaluation · Framework12 min read
ageval: A Composable Framework for Evaluating Agents on Long-Running Tasks
Agent tasks now run for hours. ageval keeps each task and its grading fixed, swaps models, harnesses and environments through plugins that are checked before a run starts, and records enough of every run that an interruption costs a resume rather than a restart.
Contents
TL;DR
An agent evaluation measures a system, not just a model. The model makes the decisions, the harness runs the interaction loop and the tool calls, and the environment executes the actions. A fair comparison of any one of them holds the other two fixed, along with the task and its grading. And as tasks stretch to hours (Terminal-Bench 4.0 allows eight per task), a run that dies halfway should not have to start over.
ageval runs every task as one Attempt. The configuration is locked first; then the core engine runs four fixed phases (environment, run, evaluate, record) and always cleans up. Task scripts call agents by role. The model, the harness (command-line agents such as Codex CLI, Claude Code, pi and opencode over the Agent Client Protocol, or mini-SWE-agent, OpenHands, DeepSeek Harness, NVIDIA OO Agents and Terminus 2 through their own executors) and the environment (local, Docker, SSH, E2B or Daytona) are plugins bound in configuration and checked for compatibility before anything starts. Reference materials become visible only during grading. An activity log paired with file checkpoints lets an interrupted Attempt resume, a new Attempt fork from the same progress under another model, and recorded terminal actions be replayed in a clean environment.
We evaluated eight frontier models on five kinds of benchmark. No model leads everywhere. Switching the harness on Terminal-Bench 2 flips the outcome of 17 to 33 of the 89 tasks per model, without a significant change in pass rate. In runs with network access, 4.6% of the audited passes had retrieved the task’s own tests or reference solutions. And when recovering one Deep-SWE evaluation, reusing archived results instead of rerunning every task saved 66.1% of solver time and 54.8% of token cost.
1Why long runs are hard to compare
Agent benchmarks differ in how the agent interacts and how it is scored. SWE-bench grades code patches with test suites; τ-bench scores multi-turn tool dialogues and the state they leave behind; Terminal-Bench pairs terminal environments with task-specific verifiers; MultiAgentBench grades collaboration between agents. Each assumes its own task interface and environment conventions.
Evaluation frameworks reduce this by standardizing tasks and moving components into configuration. Harbor packages tasks as standard directories and migrates benchmarks through adapters; AgentCompass separates benchmark, harness, environment and model settings and checks their compatibility before a run; Inspect AI and EvalScope write evaluation steps in code and reach command-line agents through bridges. Two gaps remain. First, multi-turn interaction and tool loops often live in harness-specific solvers or bridges, so changing the harness still means changing the orchestration, and nothing checks that a swapped environment or harness meets the task’s needs. Second, long tasks make interruptions expensive: if resumption keeps only finished tasks, an unfinished one restarts from scratch, and keeping progress inside a task means saving the conversation and the environment state together.
ageval addresses both with three pieces: task scripts that call agents by role, plugins whose contracts are checked before execution, and execution records that can be resumed, forked and replayed.
2Lock, then four phases
Figure 1 follows one Attempt of a task from the repository’s minimal demo: aggregate a few JSONL files into aggregates.json, solved by the pi coding agent inside a Docker container.
Attempt environmentdocker
- /attempt/workspace
- instruction.md
- records_1.jsonl
- records_2.jsonl
- records_3.jsonl
- aggregates.json by the agent
- /attempt/evaluation
- expected.json
ageval lock
# profiles.yaml
environment: docker
agent_profiles:
"*":
executor: acp
model:
id: zai-coding-cn/glm-5.3
api_key: ${ZHIPU_API_KEY}
options:
entry: pi
- task.yaml and profiles.yaml validated
- model contract checked before any machine starts
- acp needs
attach_stdio; docker provides it - the key is stored as a variable name, never its value
environment
The docker plugin starts the Attempt container and uploads the task’s data/ into /attempt/workspace.
The reference answer in evaluation/ is not uploaded. It is not in the container at all.
run.py
async with ctx.agent.session("solver") as s:
inv = await s.invoke(instruction)
ctx.publish_json("aggregates", data)
The task script asks for an agent session by role. Which harness answers is the profile’s choice; the script never names it.
seal_run: queued calls are cancelled, running ones drained, the solver session closed.
evaluator.py
expected = load("expected.json")
ok = data == expected
return {"status": "PASS" if ok else "FAIL"}
Only now is the reference answer uploaded, after nothing the agent controls is still writing.
record, then cleanup
The trajectory is merged, sealed and checked for secrets; phase timings go into summary.json.
cleanup runs in finally, so the container is stopped whether the Attempt passed, failed or crashed.
Evidenceruns/<attempt>/
- lock.json
- activity.jsonl
- checkpoints/
- task-artifacts/aggregates.json
- result.json
- trajectory.jsonl
- summary.json
terminal-jsonl-agg task from the repository’s examples/datasets/minimal-demo. The profile, the task script and the evaluator are excerpts of the files in the repository; the run itself is illustrative. The reference answer only enters the environment after the solver is sealed, and only evaluator.py writes the verdict. Click a phase to jump to it.Lock before anything runs. ageval lock merges the task and the profile, resolves which plugin fills each slot for each role, and checks three things: that every capability a plugin asks of a service is one that service declares, that the environment provides what the task requires, and that the executor accepts the model settings. Any failure stops the run before a machine starts. If all pass, the configuration is frozen with a digest, and every result is recorded against it. Credentials appear only as the names of environment variables.
The answer key arrives last. A task’s reference materials are never visible during environment or run. Grading starts only after the run ends and the evaluated role, the solver, has stopped writing and calling agents; then the reference materials are uploaded, into the same environment by default or into a separate scoring container when the task asks for one. This holds on every environment kind because it is enforced by ordering, not by mounts.
One place decides PASS. The agent saying it is done, a clean exit or a non-empty trajectory never counts as success. Only the task’s evaluator returns PASS or FAIL, either by a deterministic script that compares artifacts or environment state with the reference, or through an independent judge role that runs after the solver. Because each Attempt archives its locked configuration, trajectory, artifact snapshots and grading output, ageval results regrade can rerun grading on old answers without calling the model again.
3Swap the agent, keep the task
Task scripts are ordinary Python. They describe the interaction, including multi-turn simulations, branches, several cooperating roles and domain tools, and call agents by role through the SDK. Which model and harness answer each role is set outside the script, so a study can hold the task and its auxiliary roles (the user simulator in τ³-bench, for instance) fixed and change only the evaluated role.
Three kinds of component are swappable. Environments share one interface for lifecycle, command execution, file transfer and a two-way connection to a process’s standard streams, and declare which of these they support. Executors give every harness the same role-session interface, whether it is a command-line agent spoken to over ACP, a loop running on the host, a worker inside the environment or a direct model API, and declare which environment capabilities they need. Model settings are a separate axis: each role’s model is resolved into a ModelSpec (model ID, chat or responses API, reasoning effort, timeouts) that the executor must explicitly accept, with no silent fallback to another protocol.
Environments and executors fill exclusive slots, one implementation each; smaller extensions such as environment setup or trajectory collection fill chain slots at fixed points of the lifecycle. A plugin declares what it needs from other services, and the lock step checks that the requirement is a subset of what the bound service provides: Req(p, s) ⊆ Cap(s). Figure 2 lets you try combinations.
Task files
- task.yamlunchanged
- run.pyunchanged
- evaluator.pyunchanged
- data/unchanged
- evaluation/unchanged
profiles.yaml
ageval lock
requires: [compose] is rejected on the others before anything starts. The sidecar task is a hypothetical example; model IDs are written as they appear on the Hub.The same task package also carries one environment/Dockerfile, which becomes a local image under Docker, a template under E2B and a snapshot under Daytona. Thirteen benchmarks have been adapted so far, from Terminal-Bench 2.0 to 4.0, Deep-SWE and τ³-bench to GAIA, WideSearch and Humanity’s Last Exam. The CLI also ships as skills for coding agents, so an agent can convert a benchmark into the ageval format and run it end to end.
4Runs that survive a crash
Most of the work in a long Attempt happens inside the harness, where one call from the task script can hide dozens of model turns and tool calls. ageval records at that level. Every model turn and tool call goes into an activity log before it starts and again when it settles, and completed steps are paired with a checkpoint of the workspace, the agent’s home directory and the artifacts directory. The snapshot is saved before the log record that points to it, so a log prefix together with its snapshot is always a consistent recovery point. Keeping the home directory matters: harnesses such as pi keep their own session files there, including the summaries they write when they compact a long context.
run, before the solver is sealed and before the reference answer is uploaded, can be forked. Forking currently needs a single solver session under a fixed harness, and replay currently covers the terminal actions of mini-SWE-agent runs. The step counts are schematic; the commands are the ageval CLI.Resume continues the same Attempt. Core checks the log and the configuration digest, then probes the original environment. If it is idle and matches the log, Core reattaches; otherwise it rebuilds the environment, replays the recorded setup and restores the referenced checkpoint. When the task script restarts, calls that already completed with the same parameters are answered from the log instead of being run again. A tool call whose outcome is unknown is retried only if it is marked safe to repeat; otherwise the agent is told it was interrupted.
Fork starts a new Attempt from a checkpoint under a different solver model, with the task, harness and environment type unchanged. An expensive first half runs once, and several models can continue from the same point. Forking is refused for any cut after the solver is sealed or after reference materials were uploaded.
Replay starts a new Attempt in a clean environment, re-executes the recorded terminal actions without calling the model, reports where the results differ and can grade the new artifacts. It asks whether the actions, rather than the agent, reproduce the result. Fork and replay results record their source and are kept out of the default leaderboard aggregates.
5Eight models, five benchmarks
We evaluated eight model configurations on five benchmarks covering software engineering, tool use, terminal tasks, knowledge questions and office automation: Deep-SWE (113 tasks, mini-SWE-agent in Docker), τ³-bench (airline, retail and telecom, with DeepSeek V4.1 Flash simulating the user), Terminal-Bench 2 (89 tasks, run with both pi and opencode over ACP), the text-only HLE-Verified subset of Humanity’s Last Exam (573 questions, graded by Qwen3.7 Max) and AutomationBench (600 tasks). Each cell is one settled outcome per task and configuration. Every score on the leaderboard links to its Attempts and their trajectories.
No model leads everywhere. Six different models top the eight columns. Claude Opus 5.5 leads coding and terminal tasks (80.5% on Deep-SWE, 71.9% on Terminal-Bench 2 with pi) yet ranks fifth on HLE and fourth on AutomationBench, where GPT-6.1 Sol (78.5%) and Qwen3.8 Max (49.3%) lead. On τ³-bench every tested model passes more than 75% of tasks, but each domain has a different leader. Rankings invert even inside one family: DeepSeek V4 Pro leads τ³ telecom at 95.6% and falls to 17.7% on AutomationBench, while DeepSeek V4.1 Flash reaches 44.5% there. Cost does not track pass rate uniformly either: on software engineering and terminal tasks the configurations with higher pass rates used more output tokens, but on office automation and knowledge questions more tokens did not consistently buy more passes.
Does the harness matter?
On Terminal-Bench 2, six models ran the same 89 tasks under pi and opencode at the same reasoning effort. The pass rate barely moves: the gaps are 1.1 to 11.2 points, no pair is significant under an exact McNemar test (all p > 0.05), and pooled over models 64 tasks passed only with pi and 70 only with opencode. But which tasks pass changes a lot, 17 to 33 per model, and so does how the agent works. opencode used 10% to 50% fewer tool calls per task, likely because its glob and grep tools search files in batches, yet in five of six pairs its median run time was 1.3 to 4.0 times longer; its default prompt asks for search, implementation and test verification. In those five pairs, ACP timeouts or cancelled calls ended 45% to 75% of the failures.
What the trajectories show
Because every Attempt keeps its trajectory, a pass rate can be taken apart. Failures fall into recognisable patterns. Kimi K2.7 Code and Qwen3.8 Max often run out of steps or budget: on AutomationBench, 230 of Kimi K2.7 Code’s 283 zero-score failures exhausted the step budget. GPT-6.1 Sol and GLM-5.3 usually stop normally and then fail verification; all 28 of GPT-6.1 Sol’s Terminal-Bench 2 failures look like that. On Deep-SWE, most failures pass some but not all of the target tests.
Passes can be audited the same way. Deep-SWE and Terminal-Bench 2 allowed network access in the sandbox by default. We screened the archived tool calls, their returned content and the visible reasoning for outside access, and then checked every candidate by hand, counting only cases where the agent actually obtained the reference content. Of 918 audited passes, 42 (4.6%) had retrieved the task’s own tests or reference solutions: 17 used them to check their answer and 25 read them. Counting those as failures, DeepSeek V4.1 Flash drops from 71.7% to 55.8% on Deep-SWE and from 68.5% to 56.2% (pi) and 65.2% to 57.3% (opencode) on Terminal-Bench 2; the other affected configurations drop by 1.1 to 2.2 points.
The same archive makes reruns cheaper. When recovering the Deep-SWE evaluation of Kimi K2.7 Code, we reran only the 39 tasks that had produced empty patches and kept the archived results for the other 74. Compared with rerunning all 113 tasks, that saved 66.1% of solver time and 54.8% of token cost.
6Getting started
ageval installs as a command-line tool. A dataset can come from the Hub by name or from a local directory:
uv tool install ageval-cli
ageval run official/minimal-demo@0.1.3 --task terminal-jsonl-agg
ageval view official/minimal-demo@0.1.3
# resume, fork under another model, or replay and grade
ageval run <dataset> --task <id> --resume <attempt_id>
ageval run <dataset> --task <id> --fork <attempt_id> --checkpoint <seq> --model <model_id>
ageval replay <dataset> --run <attempt_id> --evaluate
ageval view opens a local viewer with phase timings, tool-call trajectories and the command that reproduces each Attempt. To let a coding agent write or convert benchmarks with ageval, install the skills with npx skills add ZJU-REAL/ageval. The documentation covers dataset authoring, plugins and the Python SDK.
- Fix the task and the grading, vary the rest. Models, harnesses and environments are plugins whose contracts are checked before a run, so a comparison changes one thing at a time.
- Read past the pass rate. The same pass rate can hide different tasks, tool use and run time across harnesses, different failure modes across models, and passes that found the answer key.
- Do not pay twice for a long run. Step-level logs and paired checkpoints let an Attempt resume, fork under another model or replay its actions, and archived results can be regraded or reused.
Citation
@misc{zjureal2026ageval,
title = {ageval: A Composable Framework for Evaluating Agents on Long-Running Tasks},
author = {{ZJU-REAL Team}},
year = {2026},
howpublished = {\url{https://github.com/ZJU-REAL/ageval}}
}References
- Harbor Contributors (2026). Harbor: Agent evaluation framework.
- Zhu et al. (2026). AgentCompass: A Unified Evaluation Infrastructure for Agent Capabilities. EMNLP System Demonstrations.
- UK AI Security Institute (2026). Inspect AI: An open-source framework for large language model evaluations.
- Merrill et al. (2026). Terminal-Bench: Benchmarking Agents on Hard, Realistic Tasks in Command Line Interfaces. ICLR.
- Yao et al. (2025). τ-bench: A Benchmark for Tool-Agent-User Interaction in Real-World Domains. ICLR.
- Huang et al. (2026). DeepSWE: Measuring Frontier Coding Agents on Original, Long-Horizon Engineering Tasks.
- Shepard and Salimans (2026). AutomationBench.
- Zhai et al. (2026). HLE-Verified: A Systematic Verification and Structured Revision of Humanity’s Last Exam.
Design notes for every mechanism are in the repository’s docs/; the scores, Attempts and trajectories behind the tables are on the leaderboard.