CLI Reference

June 10, 2026 · View on GitHub

The tau2 command provides a unified interface for all τ-bench functionality. Use tau2 <command> --help to see full details for any command.

Run tau2 intro (or just tau2) to see an overview of available domains, commands, and a quick-start guide directly in the terminal.

tau2 run — Run Evaluations

Run agent evaluations across different communication modes.

Basic Usage

tau2 run \
  --domain <domain> \
  --agent-llm <llm_name> \
  --user-llm <llm_name> \
  --num-trials <trial_count> \
  --num-tasks <task_count>

Common Options

OptionDescription
--domain, -dDomain to evaluate: airline, retail, telecom, mock, banking_knowledge
--agent-llmLLM model for the agent
--user-llmLLM model for the user simulator
--agent-llm-argsJSON dict of extra args for agent LLM (e.g. '{"temperature": 0.5}')
--user-llm-argsJSON dict of extra args for user LLM
--agentAgent implementation to use (default: llm_agent)
--userUser simulator implementation to use (default: user_simulator)
--num-trialsNumber of evaluation trials (default: 1)
--num-tasksNumber of tasks to evaluate (omit for all tasks)
--task-idsSpecific task IDs to evaluate
--task-split-nameTask split to use (default: base)
--task-set-nameTask set to use (default: domain default)
--max-stepsMaximum simulation steps (default: 200)
--max-errorsMaximum consecutive tool errors allowed (default: 10)
--max-concurrencyMaximum concurrent simulations (default: 3)
--seedRandom seed for reproducibility (default: 300)
--save-toCustom output directory name (saved under data/simulations/)
--log-levelLog level (default: ERROR)
--verbose-logsSave detailed logs (LLM calls, audio, ticks)
--audio-debugSave per-tick audio files and timing analysis (requires --audio-native)
--llm-log-modeLLM log mode when --verbose-logs is on: all or latest (default: latest)
--max-retriesMax retries for failed tasks (default: 3)
--retry-delayDelay in seconds between retries (default: 1.0)
--enforce-communication-protocolEnforce protocol rules (e.g. no mixed text + tool call messages)
--user-personaUser persona config as JSON dict
--xml-promptForce XML tags in system prompt
--no-xml-promptForce plain text system prompt (no XML tags)
--auto-resumeAutomatically resume from existing save file without prompting
--auto-reviewAutomatically run LLM conversation review after each simulation
--review-modeReview mode when --auto-review is on: full or user (default: full)
--review-modelLLM model to use for review calls (default: claude-opus-4-5)
--hallucination-retriesMax retries when user simulator hallucination is detected (full-duplex only, default: 3). Set to 0 to disable
--timeoutMaximum wallclock time in seconds per simulation (no timeout by default)
--audio-nativeEnable audio native mode (voice full-duplex)
--audio-tapsSave WAV files at each pipeline stage for debugging (requires --audio-native)
--retrieval-configRetrieval configuration for banking_knowledge domain (e.g., alltools, bm25, terminal_use)
--retrieval-config-kwargsJSON arguments for the retrieval config constructor (e.g., '{"top_k": 10}')

Audio Native Options

OptionDefaultDescription
--audio-nativefalseEnable audio native mode
--audio-native-provideropenaiProvider: openai, gemini, xai
--audio-native-model(per-provider)Model to use (defaults to provider-specific model if not set)
--tick-duration0.2Tick duration in seconds (simulation timestep)
--max-steps-seconds600Maximum conversation duration in seconds
--speech-complexityregularSpeech complexity: control, regular, or ablation variants (control_audio, control_accents, control_behavior, control_audio_accents, control_audio_behavior, control_accents_behavior)
--pcm-sample-rate16000User simulator PCM synthesis rate
--telephony-rate8000API/agent telephony rate

Turn-taking thresholds:

OptionDefaultDescription
--wait-to-respond-other1.0Min seconds since agent spoke before user responds
--wait-to-respond-self5.0Min seconds since user spoke before responding again
--yield-when-interrupted1.0How long user keeps speaking when agent interrupts
--yield-when-interrupting5.0How long user keeps speaking when interrupting agent
--interruption-check-interval2.0Interval for checking interruptions
--integration-duration0.5Integration duration for linearization
--silence-annotation-threshold4.0Silence threshold for annotations

Examples

# Standard text evaluation
tau2 run --domain airline --agent-llm gpt-4.1 --user-llm gpt-4.1 --num-trials 1 --num-tasks 5

# Audio native (voice full-duplex)
tau2 run --domain retail --audio-native --num-tasks 1 --verbose-logs

# Audio native with custom provider and settings
tau2 run --domain retail --audio-native --audio-native-provider gemini \
  --tick-duration 0.2 --max-steps-seconds 240 --speech-complexity control \
  --verbose-logs --save-to my_audio_native_run

# Audio native with hallucination retries disabled
tau2 run --domain retail --audio-native --hallucination-retries 0 --num-tasks 1

# Knowledge retrieval with BM25
tau2 run --domain banking_knowledge --retrieval-config bm25 \
  --agent-llm gpt-4.1 --user-llm gpt-4.1 --num-tasks 5

# Knowledge retrieval with embeddings and reranker
tau2 run --domain banking_knowledge --retrieval-config openai_embeddings_reranker \
  --agent-llm gpt-4.1 --user-llm gpt-4.1 --num-tasks 5

tau2 play — Interactive Play Mode

Experience τ-bench interactively from either perspective.

tau2 play

Play mode allows you to:

  • Play as Agent: Manually control the agent's responses and tool calls
  • Play as User: Control the user while an LLM agent handles requests (available in domains with user tools like telecom)
  • Understand tasks by walking through scenarios step-by-step
  • Test strategies before implementing them in code
  • Choose task splits to practice on training data or test on held-out tasks

See the Gym Documentation for using the gymnasium interface programmatically.


tau2 view — View Results

Browse and analyze simulation results.

tau2 view
OptionDescription
--dirDirectory containing simulation files (defaults to data/simulations/)
--filePath to a specific results file to view
--only-show-failedOnly show failed tasks
--only-show-all-failedOnly show tasks that failed in all trials
--expanded-ticksShow expanded tick view (for full-duplex simulations)

tau2 domain — View Domain Documentation

View domain policy and API documentation.

tau2 domain <domain>

Then visit http://127.0.0.1:8004/redoc to see the domain policy and available tools.


tau2 check-data — Check Data Configuration

Verify that your data directory is properly configured.

tau2 check-data

tau2 start — Start All Servers

Start all domain servers.

tau2 start

tau2 evaluate-trajs — Evaluate Trajectories

Re-evaluate trajectory files and optionally update rewards.

tau2 evaluate-trajs <paths...>
OptionDescription
<paths>Paths to trajectory files, directories, or glob patterns
-o, --output-dirDirectory to save updated trajectories. If omitted, only displays metrics

tau2 review — LLM Conversation Review

Run LLM-based review on simulation results to detect agent and/or user errors.

tau2 review <path>
OptionDescription
<path>Path to a results.json file or directory containing them
-m, --modeReview mode: full (agent + user, default) or user (user simulator only)
-o, --outputOutput path for reviewed results (single file only)
--interruption-enabledFlag indicating interruption was enabled in these simulations
--show-detailsShow detailed review for each simulation
-c, --max-concurrencyMax concurrent reviews (default: 32)
--limitLimit review to first N simulations
--task-idsOnly review simulations for these task IDs
--log-llmLog LLM request/response for each review call
--review-modelLLM model to use for review calls (default: claude-opus-4-5)

tau2 convert-results — Convert Results Format

Convert simulation results between monolithic JSON and directory-based formats.

tau2 convert-results <path> [--to {json,dir}] [--no-backup]
OptionDescription
<path>Path to a results.json file or directory containing one
--toTarget format: json (monolithic) or dir (directory with individual sim files). If omitted, converts to the opposite of the current format
--no-backupSkip creating a backup before conversion

Text runs default to monolithic JSON; voice runs default to directory-based format. Use this command to convert between them when needed.


tau2 leaderboard — View Leaderboard

Show the τ-bench leaderboard in the terminal.

tau2 leaderboard
OptionDescription
--domain, -dShow leaderboard for a specific domain: retail, airline, telecom, or banking_knowledge
--metric, -mMetric to rank by: pass_1, pass_2, pass_3, pass_4, cost (default: pass_1)
--limit, -nLimit the number of entries shown

tau2 submit — Leaderboard Submission

See the full Leaderboard Submission Guide.

# Prepare a submission
tau2 submit prepare <paths...> --output ./my_submission

# Prepare a voice submission (auto-detected, or force with --voice)
tau2 submit prepare <paths...> --output ./my_submission --voice

# Skip trajectory verification during preparation
tau2 submit prepare <paths...> --output ./my_submission --no-verify

# Validate a submission
tau2 submit validate <submission_dir> [--mode public|private]

# Verify trajectory files
tau2 submit verify-trajs <paths...> [--mode public|private]

Environment CLI (beta)

An interactive CLI for directly querying and testing domain environments.

make env-cli

Commands:

  • :q — quit
  • :d — change domain
  • :n — start new session (clears history)

Example:

$ make env-cli

Welcome to the Environment CLI!
Connected to airline domain.

Query (:n new session, :d change domain, :q quit)> What flights are available from SF to LA tomorrow?
Assistant: Let me check the flight availability for you...

Useful for testing domain tools, debugging environment responses, and exploring domain functionality without starting the full server stack.


Running Tests

make test              # Core tests (requires: uv sync --extra dev)
make test-voice        # Voice + streaming tests (requires: uv sync --extra dev --extra voice)
make test-knowledge    # Banking knowledge tests (requires: uv sync --extra dev --extra knowledge)
make test-gym          # Gymnasium tests (requires: uv sync --extra dev --extra gym)
make test-all          # All tests (requires: uv sync --all-extras)

Advanced: Ablation Studies

The telecom domain supports ablation studies for research purposes.

No-user mode

The LLM is given all tools and information upfront (no user interaction):

tau2 run \
  --domain telecom \
  --agent llm_agent_solo \
  --agent-llm gpt-4.1 \
  --user dummy_user

Oracle-plan mode

The LLM is given an oracle plan, removing the need for action planning:

tau2 run \
  --domain telecom \
  --agent llm_agent_gt \
  --agent-llm gpt-4.1 \
  --user-llm gpt-4.1

Workflow policy format

Test the impact of policy format using the workflow policy for telecom:

tau2 run \
  --domain telecom-workflow \
  --agent-llm gpt-4.1 \
  --user-llm gpt-4.1