Skip to main content
Install the CLI with uv tool install hud --python 3.12.

Authentication

Get your API key from HUD settings, then save it locally:
This stores the key in ~/.hud/.env. For CI, set HUD_API_KEY in the process environment.

Build & iterate

hud init

Start a new environment package in a fresh <name> directory. HUD provides example environments from the SDK repository; a named non-interactive run uses coding by default. In a source checkout, hud init copies the matching environments/ directory. An installed release fetches the matching SDK tag and extracts that same directory, so the example always matches the installed SDK rather than main.

hud serve

Serve an environment’s control channel locally (tcp JSON-RPC).

hud deploy

Build and publish to HUD infra in one step. The environment’s name comes from the Environment(...) declaration in code; deploying the same name again rebuilds that environment.

Evaluate

hud eval

The primary local iteration loop: run an agent over a task source (.py, directory, or JSON/JSONL), grade the result, and print the reward. Each rollout gets a fresh subprocess for the env - no shared state between tasks.
hud eval loads tasks from the path you pass. In a split project, point it at tasks.py (or . to scan the directory). It spawns env.py for the control channel automatically - you don’t pass both files.
What you don’t need for a local run:
  • A HUD API key - local evals don’t hit the platform
  • hud serve running - hud eval spawns the env subprocess for you
  • Docker - unless your env explicitly uses DockerRuntime
  • An SSH connection - the gateway timeout only applies when env.workspace() is declared
For a platform taskset, pass its name or id directly: hud eval "My Tasks" claude. The tasks are fetched from the platform and the rollouts run remotely by default, since the env source is not on disk. Single-task runs show step-by-step progress (step number + tool calls). Multi-task batches are silent unless --verbose is passed.

Run a packaged image

hud task start / hud task grade resolve authored task slugs and arguments from --source. Without --url, HUD also spawns that source locally. With --url, it runs the resolved task against the already-served environment instead. Omit --source to call a raw template id with explicit --args. hud task list always reads from source (default .) - it doesn’t attach.

Platform

hud project

Show and choose the HUD Project where new environments and tasksets are created.

Project selection

hud deploy and hud sync tasks resolve their destination in this order: --project does not change .hud/config.json. Use hud project use <name-or-id> when later deploys and task syncs from the directory should use that Project. Set a fallback for unconfigured directories with hud set HUD_DEFAULT_PROJECT=<name-or-id>. hud project list marks the team default and read-only Projects. Pinning a directory, deploying, or syncing to a Project requires create access. Only team admins can create Projects. An existing environment or taskset stays in its original Project. Selecting a different Project for an existing resource fails rather than moving it; use its current Project or create a separately named resource in the new one.

hud sync

Publish task definitions or link a local directory to a deployed environment:
hud sync tasks --project is a one-command override, like hud deploy --project. Existing resources remain in their original Project. See Projects for the conceptual overview. External benchmark formats can be adapted into runnable Tasksets through the experimental Harbor integration.

Platform QA

hud qa lists trace agents (name and UUID), including public ones. Copy an id into hud qa run. Reuses matching evidence by default and waits for every requested trace. Pass --overwrite to create a fresh attempt, --no-wait to return after launch, or --json for machine-readable output. Exit code 1 means a completed QA result failed or the SDK could not complete the command. hud qa results prints the analysis verdict (passed or failed), not the job status. Failure Analysis shows a cause and numbered findings when present. Boolean agents (false negative, false positive, reward hacking, prompt alignment) show yes/no and a summary, without a findings list. Pass --rollout for the sanitized analysis trajectory. --json still prints the raw result list and does not fetch the trajectory.

Inspect

hud jobs [<id>]

Without an id, lists your most recent jobs. With an id, lists every trace in that job.

hud trace <trace_id>

Inspect a single rollout. Reads from the local telemetry JSONL file first (HUD_TELEMETRY_LOCAL_DIR/<trace_id>.jsonl) and falls back to the platform API.
Set HUD_TELEMETRY_LOCAL_DIR in your environment to write spans to disk during a rollout so hud trace can read them offline without an API call.

Other commands

See also

Quickstart

Run & deploy