Repository navigation
feat(auto-routing): scoreboard for Auto Efficient latency, cost and quality - #7492
Conversation
Code Review SummaryStatus: No Issues Found | Recommendation: Merge Executive SummaryThe incremental commit (51f9cbd) fixes the previously reported estimator bias and I found no new correctness, security, or reliability issues; the new sampling weight matches the worker's logging semantics in Files Reviewed (4 files)
Verification Notes
Previous Review Summaries (2 snapshots, latest commit 9c17577)Current summary above is authoritative. Previous snapshots are kept for context only. Previous review (commit 9c17577)Status: 1 Issue Found | Recommendation: Address before merge Executive SummaryThe review-fix commit resolves all five prior findings; the one new issue is that the classified-population estimate in Overview
Issue Details (click to expand)SUGGESTION
Files Reviewed (6 files)
Fix these issues in Kilo Cloud Previous review (commit 7e51b68)Status: 5 Issues Found | Recommendation: Address before merge Executive SummaryThe scoreboard's production pipeline can silently emit a fully-null weighted benchmark set when the observed route mix is empty, and its Postgres and Axiom halves measure different request populations; the remaining findings are lower-severity observability and classification nits. Overview
Issue Details (click to expand)WARNING
SUGGESTION
Files Reviewed (12 files)
Reviewed by deepseek-v4.1-flash · Input: 47.6K · Output: 19.6K · Cached: 880.4K Review guidance: REVIEW.md from base branch |
bot: Add one repeatable scoreboard for
kilo-auto/efficienton three axes: router latency, cost and quality. This PR does not change routing. The next PRs in this series use the scoreboard to prove their changes.Change
/decidelogstimingsfor each phase in theauto_routing_decisionevent: coding plan, settings, capabilities, table, preparation, cache read, classifier and total.auto_routing_decide_clientwith the time to/decidefrom the gateway side. It samples 1% of successful calls and logs every failure.pnpm --filter auto-routing-benchmark scoreboard:prodcollects production aggregates from Axiom and the read replica. It reads credentials only from the environment.pnpm --filter auto-routing replaysends cold, new-turn and exact-repeat sessions to a running worker and writes the latency distributions.pnpm --filter auto-routing-benchmark scoreboard build|comparejoins the live routing table, the classifier winner, the production metrics and the replay.compare --relative-onlyprints deltas without absolute values, for PR bodies.Findings from the first baseline
/decide./deciderequests are classification cache hits. On the hit path, round trips to the Durable Object and KV take most of the time.Verification
auto-routing,auto-routing-benchmarkandweb-shared.auto-routing207 passed.auto-routing-benchmark299 passed, plus 7 new scoreboard tests. The gateway decision client passes 14 Jest tests.scoreboard:prodrun wrote every non-timing field. The timing fields stay null until this PR deploys. A fallback gives the baseline worker overhead.timingskeys.scoreboard build --table liveloaded the published table. It loaded candidate latency from the registry provenance and the classifier route accuracy.