Benchmark Guide

简体中文

Use codex-quota-benchmark when you want two measurements from the same CLIProxyAPI-backed Codex OAuth pool:

The benchmark isolates traffic by launching temporary loopback-only cli-proxy-api processes, each with exactly one copied auth file. It does not need to mutate the live gateway routing.

Requirements

Before running a long benchmark, use the monitor doctor to catch the common setup failures:

codex-quota-monitor doctor \
  --management-base-url http://127.0.0.1:8317 \
  --management-key-file /path/to/management-key \
  --auth-dir /path/to/auth-files

The benchmark writes selectors, account labels, token counts, quota deltas, and possibly copied auth files when --keep-work-dir is used. Treat the output directory as private data.

How Selectors Work

You identify accounts with selectors instead of raw paths:

A selector matches against auth_index, file name, label, email, account, or path. The match must be unique. If the same email exists in both Team and Plus form, use the full file name or auth_index.

codex-quota-benchmark \
  --management-base-url http://127.0.0.1:8317 \
  --management-key-file /path/to/management-key \
  --team-selector codex-team-slot-team.json \
  --plus-selector codex-plus-slot-a-plus.json \
  --plus-selector codex-plus-slot-b-plus.json \
  --prolite-selector codex-prolite-slot-prolite.json

By default the tool will:

Common Flags

Benchmark outputs contain account selectors, labels, paths, token counts, and quota deltas. Treat the result/ directory as private, especially when --keep-work-dir is enabled because copied auth files are preserved there.

Output Files

Interpretation