PreparedTask -> RunResult contract.
Harnesses should not own benchmark scoring. They run the agent, collect trajectory and output, and return normalized data for the benchmark and analyzers.
What Harnesses Own
Compatibility
Declare whether the harness supports the selected environment and model protocol.
Session setup
Start any local process, remote entrypoint, tmux session, or framework session needed for tasks.
Task execution
Consume
PreparedTask and return RunResult with prediction, trajectory, errors, and metadata.Cleanup
Close sessions without deleting benchmark-owned result artifacts.
Core Interface
| Method | Responsibility |
|---|---|
supports(environment, model) | Validate environment and model compatibility before tasks run. |
build_config(req) | Build harness-specific config from merged params. |
build_plan(req, environment) | Add harness-side execution plan fields. |
start_session(env, req, plan) | Prepare reusable state for one environment session. |
run_task(session, prepared, req, plan) | Execute one prepared task and return RunResult. |
close_session(session) | Release harness-owned resources. |
Harness Families
| Family | Examples | Best Use when |
|---|---|---|
| Direct model calls | openai_chat, qwen3vl_gui | The task is a prompt, messages, or GUI grounding request. |
| Coding agents | mini_swe_agent, openhands, claude_code, codex | The task provides a repository workspace and issue prompt. |
| Terminal agents | terminus2, terminus2_skills | The task requires shell actions in an environment. |
| Research agents | researchharness, naive_search_agent | The task requires browsing, search, or long-form research. |
| Tool-use benchmark harnesses | scicode_tool_use, openclaw | The benchmark has a specialized tool protocol or framework. |
Usage: GUI Grounding Harness
screenspot prepares image and instruction data. qwen3vl_gui sends the prepared GUI grounding request to the model endpoint. ScreenSpot still owns scoring.
Usage: Coding Agent Harness
/testbed; the Modal recipe selects the task image; mini_swe_agent runs the repair workflow against that workspace.
Usage: Terminal Agent Harness
What Harnesses Return
Good harness output includes:- final prediction or generated files;
- structured trajectory steps;
- model usage, latency, and tool-call metadata when available;
- error fields that can be parsed by analyzers;
- enough workspace or command context for benchmark evaluation.
