> ## Documentation Index
> Fetch the complete documentation index at: https://agent-compass.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# CLI

> Run evaluations, regenerate summaries, re-run analysis, and list registered components.

AgentCompass exposes one console script, `agentcompass`, from the project package.

```bash theme={null}
uv run agentcompass --help
```

If you have activated `.venv`, the shorter form is equivalent:

```bash theme={null}
source .venv/bin/activate

agentcompass --help
```

## Top-Level Commands

| Command                  | Purpose                                                                                                      |
| ------------------------ | ------------------------------------------------------------------------------------------------------------ |
| `agentcompass run`       | Run an evaluation directly.                                                                                  |
| `agentcompass summary`   | Regenerate `summary.md` for an existing run directory.                                                       |
| `agentcompass analysis`  | Re-run post-analysis over an existing result directory and update `analysis_result` plus `analysis_summary`. |
| `agentcompass list`      | Command group for registered component discovery.                                                            |
| `agentcompass config`    | Inspect merged config YAML and component config docs.                                                        |
| `agentcompass --help`    | Show CLI help.                                                                                               |
| `agentcompass --version` | Show CLI version.                                                                                            |

<Note>
  `agentcompass list dump` reflects the components imported by the current checkout. Run it again after pulling new code, and use [Supported Components](/reference/supported_components) as the public documented surface.
</Note>

## Run

```bash theme={null}
agentcompass run <benchmark> <harness> <model> [OPTIONS]
```

A full SWE-bench Verified command using a local GLM-5.2 endpoint and Docker:

```bash theme={null}
export MODEL_BASE_URL="http://localhost:8000/v1"
export MODEL_API_KEY="EMPTY"

agentcompass run \
  swebench_verified \
  mini_swe_agent \
  glm-5.2 \
  --config config/defaults.yaml \
  --env docker \
  --benchmark-params '{"sample_ids":["astropy__astropy-12907"]}' \
  --harness-params '{}' \
  --env-params '{}' \
  --model-base-url "$MODEL_BASE_URL" \
  --model-api-key "$MODEL_API_KEY" \
  --model-api-protocol openai-chat \
  --model-params '{"temperature":0}' \
  --task-concurrency 1 \
  --results-dir results \
  --data-dir data \
  --progress auto \
  --log-level INFO
```

A minimal command can rely on defaults:

```bash theme={null}
agentcompass run \
  swebench_verified \
  mini_swe_agent \
  glm-5.2 \
  --env docker \
  --benchmark-params '{"sample_ids":["astropy__astropy-12907"]}' \
  --model-base-url "$MODEL_BASE_URL" \
  --model-api-key "$MODEL_API_KEY" \
  --model-api-protocol openai-chat \
  --task-concurrency 1
```

## Summary vs Analysis

`summary` is lightweight. It reads existing `details/`, recomputes aggregate metrics, and regenerates `summary.md`:

```bash theme={null}
agentcompass summary results/swebench_verified/your-model/20260703_120000
```

`analysis` is heavier. It re-runs registered analyzers over task attempts, writes `analysis_result.<AnalyzerId>` into details files, and regenerates `analysis_summary.json` / `analysis_summary.md`:

```bash theme={null}
agentcompass analysis \
  --input results/swebench_verified/your-model/20260703_120000 \
  --analysis-params '{"analyzers":["ExceptionAnalyzer","TruncationAnalyzer"]}'
```

By default `analysis` copies the input run into a new timestamped sibling. Use `--override` only when you intentionally want in-place mutation.

## List Components

```bash theme={null}
agentcompass list benchmark
agentcompass list harness
agentcompass list env
agentcompass list analyzer
agentcompass list dump
```

The table subcommands print live registry contents in the terminal. `agentcompass list dump` writes `agentcompass_components.md` in the current working directory with tables for benchmarks, harnesses, model API protocols, and analyzers. See [Supported Components](/reference/supported_components) for the docs version of the benchmark, harness, and protocol tables.

## Config

`agentcompass config` has two subcommands:

```bash theme={null}
agentcompass config show [OPTIONS]
agentcompass config docs <kind> <component-id>
```

`config show` prints the merged effective config as YAML by default. Use it to inspect or redirect editable config files:

```bash theme={null}
agentcompass config show --benchmark swebench_verified --harness mini_swe_agent --env docker > configs/swebench-glm52-docker.yaml
```

Without `--benchmark`, `--harness`, or `--env`, `config show` prints the global `runtime` and `execution` sections. Add the selectors for the components you want included in the YAML. Use repeatable `--config` flags to layer existing overrides before printing, and `--format json` when a JSON payload is easier to consume:

```bash theme={null}
agentcompass config show --config config.yaml --config configs/private.yaml --benchmark swebench_verified --format json
```

`config docs` prints a Rich table for one component's config class. `kind` is `benchmark`, `harness`, or `env`:

```bash theme={null}
agentcompass config docs benchmark swebench_verified
agentcompass config docs harness mini_swe_agent
agentcompass config docs env docker
```

## Parameter Rules

* `benchmark`, `harness`, and `model` are positional for `run`.
* JSON flags such as `--benchmark-params`, `--harness-params`, `--env-params`, `--model-params`, and `--analysis-params` must be valid JSON objects.
* `--model-api-protocol` accepts a single protocol string or a JSON string array.
* Explicit CLI flags override values loaded from `config/defaults.yaml`.
* `--model` is repeatable after the positional model for comparison runs.
* `--provider-limit provider=count` is repeatable and caps process-global provider sessions.
* `--recipe-dir <package-dir>` is repeatable and loads trusted external recipes only for the current run.
