hue eval runs your own agent against Hue cases and prints the run link and verdicts. Your agent, prompts and model keys stay in your process; Hue never executes the agent. Use this command instead of writing a harness, a runner or tool stand-ins around the SDK.
Before you start
- Node.js 22 or 24 on the machine that runs the command, even for a Python agent.
- A Read and write project key in an ignored env file.
hue login --gitignorewrites.env.hueand ignores it; when the shell has noHUE_API_KEY,hue evalloads./.env.hueby default. Pass--env-file <path>for another file, and add.hue/to.gitignorefor checkpoints. - A start command that reads
{"inputs","config"}as JSON on stdin and prints the answer on stdout. Logs go to stderr. - For cases with a World, the one-time helper that points the agent’s app clients at Hue instead of production.
Run it
Check first, then run the same command without--check:
--check resolves the key’s project, the selection and its evaluators, and whether cases are answer-only or get a world. It creates no run, world or checkpoint. A published case carries its own evaluators.
Use --concurrency <n> to control how many agent cases run at once. The default is 20. Hosted verifiers and hosted judges grade uploaded evidence on Hue with their own concurrency limits. One-shot runs execute pinned model judges by default. Use --no-judges to skip them; --no-output also disables them.
- One command, one run. The run holds every selected case: a 100-case eval set is one run with 100 executions. The command prints the
https://app.hue.run/runs/<id>link once the run exists. - Let it finish. Start the command with a long timeout. After a local interruption, run the identical command to recover from
.hue/eval/<agent-key>. Finished cases are kept. An uncertain agent attempt is not replayed automatically, including a World attempt. If Hue cannot recover its outcome, the run remains incomplete. Saved judging can resume without executing completed cases again. Keep the checkpoint directory when investigating a failure. From 0.30.2, an interrupted run in CI (CIset to anything but empty,0orfalse) cancels its unfinished cases and closes instead, unless you pass--on-interrupt resume. - Exit codes. 0 every case passed; 1 a case failed, errored, is inconclusive or is incomplete; 2 usage error; 130 interrupted.
- Compare. Pass
--baseline <run id|url>to see improvements and regressions against an earlier run. - Read replies. With
--json, the command prints one JSON document on stdout, and from 0.30.0 each case in it carriesreply, the answer Hue stored for it: the command’s stdout, parsed when it is JSON, or{"replies": [...]}for a conversation case.replyisnullwith--no-output.
Run an eval set
Pass--set "<eval set>" instead of --case. From hue eval 0.30.0, the run uses every evaluator the set’s cases need, and the command prints them before it starts: the outcome evaluator that grades the cases’ World checks, and each judge a case’s criteria name. Run eval set on the eval set’s page in Evals copies a prompt that has your coding agent set this up and run it.
- Judges grade their own case. A judge that one case names grades that case alone. The other cases record it as not applicable, so pinning several cases’ judges never grades a case against another case’s rubric.
- Required evaluators stay pinned. If
--scoreror--scorer-versionleaves out an evaluator the cases need, such as the outcome evaluator,hue evalnames it and stops before creating a run. Drop those flags to use the set’s evaluators, add the missing one, or pass--allow-missing-evaluatorsto run without it; the command then prints a warning, and those checks or judges are not graded. - Rerun some cases. Add
--only "<case key or title>", once per case, to run just those cases as a new run with the evaluators they need.--case "<case key or title>"together with--setdoes the same for one case. A case added to an eval set is not a published case, so--casewithout--setdoes not find it.
HUE_WORLD_NOW, not the wall clock; see relative dates.
Run in CI
Use the CI/CD guide to add the GitHub Action, configure baseline comparisons, and require passing evaluations before merging. Without a configuration file, run an eval set from the CLI in CI.Answer-only and World cases
The helper fails closed: with an execution but no world token, or a missing app URL, a required app connection throws before any request. Outside a Hue eval it returns production values unchanged.
hue eval removes HUE_API_KEY and other Hue credentials from the command’s environment unless you pass --allow-hue-credentials.
Local or deployed
- Local, one run: the one-shot command above.
- Local, launched from Hue:
hue eval --worker --command "<start command>"registers the agent and runs what the Run button orlaunch_runstarts, one run per launch, until you stop it. - Deployed: run the worker beside the deployment with a non-production key and a start command that forwards stdin to the deployed agent and prints its answer. Never put World variables or a Read and write key in production configuration.
hue eval for every flag and Worlds for what a World case runs against.