|
|
@@ -1,5 +1,7 @@
|
|
|
# Agent Benchmark Runner Implementation Plan
|
|
|
|
|
|
+**Status:** done
|
|
|
+
|
|
|
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
|
|
|
|
|
**Goal:** Build a packaged benchmark CLI that runs deterministic mock or live OpenAI-compatible comparisons for both invocation modes and writes secret-safe JSON/Markdown reports.
|
|
|
@@ -65,9 +67,62 @@
|
|
|
- Modify: `docs/plans/todo-52-agent-benchmark-runner.md`
|
|
|
- Modify: `docs/plans/todos.md`
|
|
|
|
|
|
-- [ ] Add a secret-free example covering both modes and all six cases; ignore `outputs/benchmarks/`.
|
|
|
-- [ ] Document `.env`, config copy/edit, mock command, live command, output fields, exit codes, fairness controls, and the limits of scripted/mock adapters.
|
|
|
-- [ ] Run `agent-lab-benchmark --config benchmarks/single-target.example.json --mock --output-dir /tmp/agent-lab-benchmark` and inspect both reports.
|
|
|
-- [ ] Run focused benchmark tests, `uv run pytest`, CLI help, app import, `node --check`, and `git diff --check`.
|
|
|
-- [ ] Perform specification review then code-quality review; add Todo 52.x rows for post-execution fixes.
|
|
|
-- [ ] Record evidence and Workflow Evolution findings, mark Todo 52 done, and commit with `docs: close benchmark runner todo`.
|
|
|
+- [x] Add a secret-free example covering both modes and all six cases; ignore `outputs/benchmarks/`.
|
|
|
+- [x] Document `.env`, config copy/edit, mock command, live command, output fields, exit codes, fairness controls, and the limits of scripted/mock adapters.
|
|
|
+- [x] Run `agent-lab-benchmark --config benchmarks/single-target.example.json --mock --output-dir /tmp/agent-lab-benchmark` and inspect both reports.
|
|
|
+- [x] Run focused benchmark tests, `uv run pytest`, CLI help, app import, `node --check`, and `git diff --check`.
|
|
|
+- [x] Perform specification review then code-quality review; add Todo 52.x rows for post-execution fixes.
|
|
|
+- [x] Record evidence and Workflow Evolution findings, mark Todo 52 done, and commit with `docs: close benchmark runner todo`.
|
|
|
+
|
|
|
+## Final Evidence
|
|
|
+
|
|
|
+Verified on 2026-07-14 (Asia/Shanghai):
|
|
|
+
|
|
|
+- benchmark suite: `196 passed in 1.19s`;
|
|
|
+- full suite: `601 passed in 3.67s`, with one existing Starlette/httpx deprecation warning;
|
|
|
+- `agent-lab-benchmark --help`: exit `0`;
|
|
|
+- application import prints `Agent Lab`;
|
|
|
+- `node --check src/agent_lab/presentation/static/app.js`: exit `0`;
|
|
|
+- `git diff --check`: exit `0`;
|
|
|
+- zero-network mock CLI: `12 attempted / 12 passed / 0 failed`;
|
|
|
+- final JSON: `/tmp/agent-lab-benchmark-final-20260714/20260713T194850Z/report.json`;
|
|
|
+- final Markdown: `/tmp/agent-lab-benchmark-final-20260714/20260713T194850Z/report.md`;
|
|
|
+- both parallel-mode runs report `parallel_events_overlapped=true`;
|
|
|
+- both web-search runs report two model calls and one tool execution;
|
|
|
+- no mock run has missing token usage.
|
|
|
+
|
|
|
+Specification and code-quality reviews found no remaining Critical or Important
|
|
|
+issues after Todos 52.1-52.13. The remaining non-blocking risks are documented
|
|
|
+below.
|
|
|
+
|
|
|
+## Residual Risks and Limits
|
|
|
+
|
|
|
+- No live provider request was run because no real benchmark target or credential
|
|
|
+ was supplied; live latency, usage support, semantic adherence, and provider
|
|
|
+ tool-stream compatibility still require operator verification.
|
|
|
+- The example uses one run per case, so its 60 p95 warnings are expected and the
|
|
|
+ mock percentile values are not suitable for ranking architectures.
|
|
|
+- Atomic bundle publication uses a relative directory symlink and is verified on
|
|
|
+ macOS; Windows symlink behavior is not verified.
|
|
|
+- An interruption inside `mkdtemp()` may leave an empty hidden bundle directory.
|
|
|
+ A close failure during a narrow consumer-pause cancellation window may be
|
|
|
+ logged as a secondary async-generator exception. Neither case changes the
|
|
|
+ primary cancellation result or exposes a mixed public report.
|
|
|
+
|
|
|
+## Workflow Evolution Update
|
|
|
+
|
|
|
+The requirement loop exposed three durable workflow lessons:
|
|
|
+
|
|
|
+- paired filesystem artifacts need one explicit atomic publication boundary;
|
|
|
+ repeated two-file rollback fixes were replaced by a single report bundle;
|
|
|
+- benchmark plans must define clock boundaries, missing-data semantics, and
|
|
|
+ observable concurrency proof before implementation, not only metric names and
|
|
|
+ event counts;
|
|
|
+- parallel subagents need shared-contract integration checks when one task changes
|
|
|
+ an output layout consumed by another task's tests.
|
|
|
+
|
|
|
+These lessons are recorded in this task report and the benchmark design. No
|
|
|
+`AGENTS.md` change was made because the repository's existing PAOU, todo-first,
|
|
|
+TDD, per-todo commit, and post-review follow-up rules already caused the issues to
|
|
|
+be found and corrected; adding more global workflow rules would duplicate the
|
|
|
+current core process.
|