This release is a pre-release and may not be stable for production use.
BenchFlow runs AI agents on tasks in sandboxes and scores them. Point it at a benchmark's tasks and pick an agent: Claude Code, Codex, Gemini CLI, OpenHands and more, over ACP. Each run records its reward, cost and full trajectory.
Tasks run on Docker (local or remote), Daytona, Modal or AgentCore. The same runtime serves evaluation and RL training.
These docs describe BenchFlow 0.10. bench --version prints the version you have; What's new in 0.9 lists what changed since 0.7, and the changelog what 0.10 adds.
Quick start
You need Docker running and uv. Steps 1 and 2 need no model and no API key.
1. Install BenchFlow and check this machine.
uv tool install --python 3.12 benchflow
bench doctor # needs 0.8 or newer; checks Docker, agent logins and network, with a fix for each problem
The examples use bench; the installed benchflow command is the same CLI.
Before you log in to an agent, bench doctor reports that no agent can run. That is expected: step 2 needs no login.
2. Run a task with the oracle. The oracle runs the task's own reference solution. It tests the sandbox, the task and its verifier with no model:
bench run benchflow-ai/skillsbench/tasks/econ-detrending-correlation \
--agent oracle --sandbox docker --jobs-dir jobs/oracle
BenchFlow downloads only that task from SkillsBench, builds its image, runs its solution and verifier, and prints Score: 1/1. A cold-cache first run took 6 minutes 12 seconds, including the verifier's package downloads; allow longer on a slow connection.
3. Run a model. With a Claude subscription, no API key is needed. claude setup-token comes with Claude Code and prints a login token that lasts a year:
claude setup-token
export CLAUDE_CODE_OAUTH_TOKEN='<token>'
bench run benchflow-ai/skillsbench/tasks/econ-detrending-correlation \
--agent claude --model claude-haiku-4-5-20251001 --sandbox docker --jobs-dir jobs/claude
Billing: an exported
ANTHROPIC_API_KEYorANTHROPIC_AUTH_TOKENwins over the token and is billed. Unset both to use your subscription.
With an API key, export it and name a provider-prefixed model. For a DeepSeek key:
export DEEPSEEK_API_KEY='<key>'
bench run benchflow-ai/skillsbench/tasks/econ-detrending-correlation \
--agent openhands --model deepseek/deepseek-flash --sandbox docker --jobs-dir jobs/model
The agent may pass or fail. Either way, the run worked. Version 0.9.0 of bench doctor warns that deepseek/ also needs DEEPSEEK_BASE_URL; it does not, so the run goes ahead without it. Quick start: run a model has the agent and model to use for OpenAI, Anthropic, Gemini and other keys, and for a ChatGPT plan.
4. Read the results.
bench results jobs/ # one row per job, named by its folder, with its score
bench eval metrics jobs/claude # pass rate, solve rate, pass@k, tool calls and time
bench view jobs/claude # trajectory, verifier output and score, in your browser
jobs/claude is a jobs directory; each timestamped child is one job. Copy the exact Artifacts: path printed by bench run to inspect or resume that job with bench results <job> or bench eval resume <job>. If you skipped the model run, use jobs/oracle instead.
Each run writes its rewards, token usage and trajectory under --jobs-dir. A trial's reward is in verifier/reward.txt and in result.json under rewards.reward; its transcript is in trajectory/. Run the same command again to resume the latest matching job: finished tasks are kept, not rerun. Add --fresh to start over.
Next steps
- Write and test your own task:
bench new my-task, then the oracle and a do-nothing agent. - Run several tasks at once on Daytona, a cloud sandbox.
- Export runs for training: rewards and rollouts as JSONL.
- Run a whole benchmark: Quick start.
- Check every agent login at once:
bench eval smokeruns a bundled hello-world task once per logged-in agent. - Run from Python:
quickstart.pyruns a task with the oracle, with no key. - Learn the words: Core concepts.
- Upgrading from 0.7? Read What's new in 0.9.
Documentation
To have a coding agent do the quick start for you, paste the agent quickstart prompt into Claude Code, Codex CLI or Gemini CLI.
Start and run
| If you want to… | Read |
|---|---|
| Run your first task, then a model | Quick start |
| Install, upgrade or uninstall | Install |
Keep the Rust bench beside this one |
Which bench runs |
| Log in to an agent, or use an API key | Auth |
| Know what a task, dataset, agent, sandbox, verifier, trial and job are | Core concepts |
| Run any benchmark, including ones with their own task format | Run any benchmark |
| Find out why a run failed, whose problem it is, and what to do | When a run fails |
| Resume an interrupted job | Resume a job |
| Run an agent from the public agents repo (goose, qwen-code, prime-agent, …) | Running external agents |
| Run Claude Code or Codex through their own CLIs instead of their ACP adapters | Native harness |
| Run a hosted PrimeIntellect / Verifiers environment | CLI reference |
| Run tasks on a Docker host you control | Remote Docker |
| Keep BenchFlow loaded between CLI calls, and prepare the next sandbox | Local runtime |
| Cap a job's spend, sandbox time, tokens or rollouts | Budgets |
Several agents, several rounds, branching
| If you want to… | Read |
|---|---|
| Run several agents in one task: coder and reviewer, simulated user | Scenes and simulated users |
| Give one agent hints over several rounds | Progressive disclosure |
| Fork a run at a checkpoint into scored children | Branching |
| Evaluate a skill rather than a workspace | Skill eval |
| Run robots and simulators | Embodied rollouts |
Scores you can trust
| If you want to… | Read |
|---|---|
| Understand the security model | Sandbox hardening |
| Score in a sandbox that holds only the agent's final workspace and declared artifacts | Separate verifier sandboxes |
| Check what the agent did to the things its reward depends on (BenchShield) | Reward integrity |
| Re-score stored runs after fixing a verifier, without running the agent again | Regrade |
Tasks
| If you want to… | Read |
|---|---|
| Write a new task | Task authoring |
Write a task in the native task.md format |
task.md authoring |
| Run task.md draft 2 packages | task.md draft 2 packages |
| Run a benchmark's own task folders with no conversion | Task formats |
Results and training
| If you want to… | Read |
|---|---|
| Read, compare and export runs in Python or a notebook | Analysing runs |
| Turn runs into rows a trainer reads (JSONL with rewards and messages) | Export runs for training |
| Stream rollouts to a trainer while a job runs | Streaming rollouts |
| Capture token ids and logprobs for training | Token capture |
| Share a coding-agent session or trial | Share a trajectory |
Reference
| If you want to… | Read |
|---|---|
| Every command and flag, generated from the CLI | Command reference |
| Worked CLI examples: run configs, resuming, reading the score | CLI guide |
| Every public Python name, generated from the package | Python reference |
| Worked Python examples | Python API guide |
| The JSON documents BenchFlow writes, generated from their schemas | Schema reference |
| Stable and preview releases | Install: stable and preview releases |
Runnable scripts and notebooks are in docs/examples/.
Run a benchmark from a Git repository
A run config names the repository and the folder of tasks in it, then the agent and model:
# benchmarks/harvey-lab/harvey-lab-gemini-flash-lite.yaml
source:
repo: benchflow-ai/benchmarks
path: datasets/harvey-lab/tasks
agent: gemini
model: gemini/gemini-3.5-flash-lite
environment: docker
concurrency: 4
# From the config, in a clone of this repository (benchmarks/ is not in the installed package)
bench run --config benchmarks/harvey-lab/harvey-lab-gemini-flash-lite.yaml
# The same source, inline
bench run benchflow-ai/benchmarks/datasets/harvey-lab/tasks \
--agent gemini --model gemini/gemini-3.5-flash-lite --sandbox docker --concurrency 4
BenchFlow caches repositories in .cache/datasets-v2/, at the root of the Git repository you run from, or in the current folder outside one. BenchFlow writes a .gitignore there, so the cache never shows in git status. With a folder in the target, it downloads only that folder. A target with no folder, or a folder with no BenchFlow task in it, downloads the whole repository.
Write a task
A task is a folder: a task.md (YAML settings on top, the instruction below), an environment/ folder and a verifier/ folder. Four commands cover a task's life:
bench new my-task # scaffold tasks/my-task
bench check tasks/my-task # validate it (default: --level structural)
bench import legacy-task/ --remove-legacy # convert a task.toml + instruction.md task
bench export tasks/my-task out/ # write the split layout, with a loss report
bench new leaves placeholders for the task author; bench check reports them until you fill in the instruction, oracle and verifier. The import command assumes an existing legacy-task/ folder in the split format.
BenchFlow also runs older split tasks (task.toml, instruction.md, solution/, tests/), task.md draft 2 packages, and any task format a benchmark registers. See task.md authoring and the task standard.
Contributing
For a source build, prepare the pinned bfx binaries first; see Build from a checkout. Without them, Docker uses the fallback root steps.
Open pull requests against main. CI runs ruff (lint and format), ty, the unit tests, a Docker integration tier and pip-audit. Run the same checks before you push:
uv sync --extra dev --extra sandbox-daytona --extra sandbox-modal
uv run ruff check src tests tools
uv run ruff format --check src tests tools
uv run ty check
uv run python -m pytest tests/ -k 'not cloud_metadata'
A checkout has no bfx binaries (BenchFlow's helper for root's steps on Docker; they are not in git). An editable install runs without them, as with BENCHFLOW_BFX_DELIVERY=off. To run Docker trials with bfx, or before you build a wheel, build them on Linux with rustup installed: BFX_REQUIRE_PIN=1 scripts/build_bfx.sh (or make bfx). See Try a pre-release.
Merges to main publish an internal preview once CI passes. A release tag publishes the public release. See Stable and preview releases; maintainers, see Publishing a release.
License
Apache-2.0.
Metadata
Release files for benchflow 0.10.0rc3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| benchflow-0.10.0rc3.tar.gz | 4.9 MB | Without provenance | Details for benchflow-0.10.0rc3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| benchflow-0.10.0rc3-py3-none-any.whl | Python 3 | none | any | Details for benchflow-0.10.0rc3-py3-none-any.whl |
Total release size: 10.1 MB
Release files / benchflow-0.10.0rc3.tar.gz
| Download URL | benchflow-0.10.0rc3.tar.gz |
|---|---|
| Size | 4.9 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ce95e604eafd3ab4601274bb43ffd40c4f2bbaa1b269d9ecc66008d91f436258
|
|
BLAKE2b-256 checksum How to use checksums |
2514d9c7aae0701c8efa92139421feb5180d6f5bd95d12979c954a48acb0ff36
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.4 {"installer":{"name":"uv","version":"0.13.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / benchflow-0.10.0rc3-py3-none-any.whl
| Download URL | benchflow-0.10.0rc3-py3-none-any.whl |
|---|---|
| Size | 5.2 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
867a9cbadacd2b366a21b25715965efee109e6a891c738644a51f1d786af31d4
|
|
BLAKE2b-256 checksum How to use checksums |
fe97cce6de49aaa3c580ad8d6790aece927ad95efc2557b3c6e0c7c2a5fd2a2c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.4 {"installer":{"name":"uv","version":"0.13.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for benchflow 0.10.0rc3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.