# self-bench Documentation > Operator and integrator reference for the self-bench CLI, HTTP API, Temporal worker, and Harbor export pipeline that turns completed repository work into private coding-agent evaluations. This is a Grok-Wiki source-grounded repository documentation set. Use the complete Markdown link when an agent needs the full repo context. ## Context Links - [Complete Markdown docs](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/llms-full.txt) - [Complete Markdown alias](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc.md) - [Human interactive docs](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc) - [GitHub repository](https://github.com/mupt-ai/self-bench) ## Repository - Repository: mupt-ai/self-bench - Generated: 2026-08-15T02:16:57.473Z - Updated: 2026-08-15T02:36:00.741Z - Runtime: Grok CLI - Format: Documentation - Pages: 25 ## Pages - [Overview](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/01-overview.md): What self-bench generates, who should run it, the CLI/API/worker surfaces, and the first docs routes after install. - [Installation](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/02-installation.md): Prerequisites, global install, Modal and GitHub auth, required environment variables, and the first successful CLI help check. - [Quickstart](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/03-quickstart.md): Shortest path: start the Modal-backed local stack, submit a tiered run with --output, extract accepted Harbor tasks, and verify one Codex trial. - [Provenance sources](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/04-provenance-sources.md): Where self-bench collects human requests: Pi, Claude Code, and Codex session roots, merged GitHub pull requests, sanitization rules, and the empty-corpus failure. - [Difficulty gates](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/05-difficulty-gates.md): easy, medium, and hard eligibility: implementation file and line minima, fail-to-pass and pass-to-pass counts, and static audit blockers. - [Run lifecycle](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/06-run-lifecycle.md): Temporal phases, per-candidate statuses, eight-shard discovery, candidate budgets versus accepted tasks, and blocked, failed, or cancelled terminals. - [Validation and repair](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/07-validation-and-repair.md): Static audit, Harbor nop and oracle gates, determinism rerun, one validation-repair attempt, one coupling-repair retry, then reject. - [Agent-visible boundary](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/08-agent-visible-boundary.md): What a Harbor trial mounts, what stays hidden, gold-only contract artifacts, coupling verdicts, and the held-out-test-only repair constraint. - [Start the local stack](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/09-start-the-local-stack.md): self-bench up and down: Compose services, --backend docker or modal, --modal-config, named volumes, and what happens when the worker stops. - [Build a benchmark](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/10-build-a-benchmark.md): self-bench run: --repo GitHub origin, 1-100 tier budgets, --model, --run-id, HEAD pin, provenance upload, and --output wait plus SHA-256 download. - [Manage runs](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/11-manage-runs.md): list, status, cancel, and download against SELFBENCH_API_URL, including phase polling, create-only writes, and integrity headers. - [Evaluate with Harbor](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/12-evaluate-with-harbor.md): Extract an export, run one task or the Codex matrix via self-bench-eval, resume completed jobs, and smoke Harbor agent adapters. - [Review exports](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/13-review-exports.md): Open the API-hosted review UI or a local archive, inspect accepted tasks, drop tasks, and download a cleaned tar.gz. - [Deploy Temporal Cloud](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/14-deploy-temporal-cloud.md): Split API and worker processes, GCS artifacts, Temporal TLS and API key, Modal tokens, and matching image digest plus task queue. - [CLI reference](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/15-cli-reference.md): self-bench commands, flags, defaults, run-id rules, wait and download semantics, and command-level errors. - [Companion commands](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/16-companion-commands.md): Flags, defaults, and outputs for self-bench-eval, self-bench-validate, self-bench-reaudit, self-bench-repair, and self-bench-agent-smoke. - [HTTP API](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/17-http-api.md): Routes, Bearer auth, status codes, run submission schema, provenance upload limits, export headers, and review-asset serving. - [Configuration reference](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/18-configuration-reference.md): SELFBENCH_* environment keys, defaults, validation, loopback token rule, artifact backends, and Temporal connection fields. - [Task definition](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/19-task-definition.md): definition.json fields, {tests} placeholder rules, toolchains, timeouts, resources, submit_task output files, and schemaVersion 1 constraints. - [Harbor task compiler](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/20-harbor-task-compiler.md): How authored patches become a Harbor task: task.toml schema 1.4, agent and verifier Dockerfiles, toolchain layers, and dependency-setup.patch. - [Export format](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/21-export-format.md): Outer tar.gz layout, manifest.json fields, per-task harbor-task contents, SHA-256 checks, and what the archive excludes. - [Execution backends](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/22-execution-backends.md): Docker versus Modal sandboxes: images, default concurrency, resource limits, inactivity timeouts, and Harbor environment pairing. - [Authentication](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/23-authentication.md): OPENAI_API_KEY precedence, Pi and Codex subscription JSON fallbacks, GH_TOKEN, API Bearer token, and Modal profile versus token secrets. - [Troubleshooting](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/24-troubleshooting.md): No-provenance, blocked candidate pool, 409 export-not-ready, SHA-256 mismatch, Harbor infrastructure failures, and leftover Docker resources. - [Contributing](https://grok-wiki.com/public/docs/mupt-ai-self-bench-62fff2be9bcc/pages/25-contributing.md): Clone, bun install, bun run validate, source CLI, API/worker/review dev servers, CI, package verification, and npm tag publish. ## Source Files - `.github/workflows/ci.yml` - `.github/workflows/publish-npm.yml` - `biome.json` - `compose.yaml` - `Dockerfile` - `Dockerfile.sandbox` - `docs/evaluations.md` - `docs/operations.md` - `docs/task-construction.md` - `package.json` - `README.md` - `review/src/App.tsx` - `review/src/export-loader.test.ts` - `review/src/export-loader.ts` - `review/src/types.ts` - `scripts/verify-package.ts` - `src/agent-smoke-main.ts` - `src/agent-smoke.ts` - `src/api-main.ts` - `src/api.ts` - `src/artifacts.ts` - `src/audit.ts` - `src/cli.ts` - `src/codex-review.ts` - `src/config.ts` - `src/contracts.ts` - `src/coupling.ts` - `src/docker-executor.ts` - `src/eval-main.ts` - `src/evaluate.ts` - `src/extensions/authoring.ts` - `src/extensions/discovery.ts` - `src/github.ts` - `src/harbor-results.ts` - `src/harbor-task.ts` - `src/modal-auth.ts` - `src/modal-executor.ts` - `src/provenance.ts` - `src/reaudit-main.ts` - `src/repair-main.ts` - `src/repair.ts` - `src/run-wait.ts` - `src/sandbox.ts` - `src/skills/selfbench/SKILL.md` - `src/subscription-auth.ts` - `src/temporal/activities.ts` - `src/temporal/connection.ts` - `src/temporal/worker-main.ts` - `src/temporal/workflow.ts` - `src/validate-main.ts` - `src/validation-repair.ts` - `tests/audit.test.ts` - `tests/cli.test.ts` - `tests/contracts.test.ts` - `tests/coupling.test.ts` - `tests/evaluate.test.ts` - `tests/harbor-results.test.ts` - `tests/harbor-task.test.ts` - `tests/provenance.test.ts` - `tests/run-wait.test.ts` - `tests/subscription-auth.test.ts` - `tests/workflow.test.ts` - `tsconfig.build.json`