Quickstart
This guide takes you from an empty machine to a completed LLM measurement against the in-repo dummy model server. Follow each step in order. Once the toolchain is installed, the loop usually takes under ten minutes.
What you'll do
- Install a release binary or build from source
- Start the dummy OpenAI-compatible server
- Write a tiny JSONL prompt file
- Run
metrum-ai-bench-llm(or the unifiedmetrum-ai-bench llmentry) - Inspect the JSONL data log and end-of-run summary
If you already have a binary and only need a smoke check:
metrum-ai-bench selftest
Before you start
You'll need:
- A Linux (
x86_64oraarch64glibc) or macOS Darwin host for release binaries, or Rust 1.85+ to build from source. Windows has no release binaries (see Platforms). - Go 1.26.6+ if you will run the dummy model server from this repository
(matches
dummy-model-server/go.modand CI). - Network access only if you download a GitHub Release or fetch the prompt
library later. The dummy-server loop needs no API key beyond the literal
value
dummy.
1. Install
Option A: GitHub Release (preferred for binaries)
- Open Releases and download the archive for your target.
- Verify the accompanying
.sha256checksum (and optional Sigstore bundle when present). - Unpack the archive so
metrum-ai-bench(and modality binaries) are on yourPATH.
Release archives are cross-built with cargo-zigbuild for:
| Target | Notes |
|---|---|
Linux *-unknown-linux-gnu | glibc 2.17 floor; not musl |
| macOS Darwin | x86_64 / aarch64 |
TLS uses rustls (no OpenSSL link). An optional Homebrew formula
(metrum-ai-bench.rb) is attached to each release when the publish workflow is
configured with a tap repository.
Option B: Build from source
git clone https://github.com/metrum-ai/bench-cli.git
cd bench-cli
cargo build --release
Binaries land under target/release/. Run tests when you want a local gate:
cargo test --all-targets --all-features
Release archives include the otlp feature but not tokenizer. See
Platforms for the feature matrix.
2. Start the dummy server
From the repository root (second terminal is fine):
go run ./dummy-model-server/cmd/dummy-model-server \
-port 18321 -latency 100ms -chunk-interval 20ms
Leave it running. The server speaks OpenAI-compatible paths used by the
modality tools. Use --api-key dummy on the client.
This is the Go dummy model server (modality compatibility). For strategic
sweeps, embeddings, and rerank fixtures, use the separate Rust
metrum-ai-bench-mock-server instead - see
Strategic benchmarking.
3. Create a prompt file
Prompt and input files are JSONL only (.csv is rejected).
printf '%s\n' '{"prompt":"Hi"}' > /tmp/metrum-prompts.jsonl
4. Run the LLM client
metrum-ai-bench-llm \
--url http://127.0.0.1:18321/v1/chat/completions \
--api-key dummy \
--scenario reference \
--num-requests 16 \
--concurrency 4 \
--prompts /tmp/metrum-prompts.jsonl \
--mode chat \
--streaming \
--model dummy \
--max-tokens 20 \
--seed 7 \
--warmup-requests 0 \
--data-log /tmp/metrum-reference.jsonl \
--log-level error
Or through the unified entry point (forward modality flags after --):
metrum-ai-bench llm -- \
--url http://127.0.0.1:18321/v1/chat/completions \
--api-key dummy \
--scenario reference \
--num-requests 16 \
--concurrency 4 \
--prompts /tmp/metrum-prompts.jsonl \
--mode chat \
--streaming \
--model dummy \
--max-tokens 20 \
--seed 7 \
--warmup-requests 0 \
--data-log /tmp/metrum-reference.jsonl \
--log-level error
During the v1.x compatibility period the four modality binaries can also be invoked directly. Deprecated legacy shims remain and print a v2.0 removal notice.
What success looks like
- Request records stream into
--data-logas each request finishes. - A
summary.v3object is appended when the run completes. - Console statistics match the same
RunSummary/DistSummaryvalues written to JSONL.
Against this dummy configuration on an unloaded machine, the checked-in reproduction guide expects roughly:
| Metric | Expected band |
|---|---|
| Mean TTFT | 0.100–0.200 s |
| Mean E2E latency | 0.420–0.650 s |
| Mean ITL | 0.010–0.040 s |
Those bands surround the dummy server's timing model for
-latency 100ms -chunk-interval 20ms with --max-tokens 20: TTFT ≈ 120 ms
(latency + first chunk) and response time ≈ 500 ms (100 + 20Ã-20). See
dummy-model-server/README.md in the repository.
Scheduling and counts should match test-data/reference-result.json when you
follow reproducing the reference
exactly. Wall-clock timestamps, UUIDs, hostname, and exact timings differ by
design.
5. Read the result
Every completed request is flushed incrementally to JSONL. Warmup records remain
auditable but are excluded from measured distributions. A graceful Ctrl-C stops
issuance, drains already-started work, and emits partial: true on the summary.
Next steps:
- User Guide for vocabulary and run shapes
- Modalities for VLM, ASR, and imagegen
- Performance Methodology for metric definitions
- Publishing-oriented runs before you publish a named result