Skip to content

v1.91.6.0 feat: balance PR eval slices by recorded duration without weakening timeout coverage - #2991

Merged
garrytan merged 1 commit into
mainfrom
capy/eval-slice-balance
Sep 28, 2026
Merged

garrytan merged 1 commit into
mainfrom
capy/eval-slice-balance

Conversation

@garrytan

Copy link
Copy Markdown
Owner

PR eval slices were split so that every slice's worst-case wall fits its CI timeout: registered long files are spread by supervision budget and the rest go round-robin. That keeps the timeout guarantee, but it ignores how long evals actually take. On #2989's runs, one slice carried about 29 minutes of recorded eval time and another about 8, and the slowest slice set the pace for the whole eval lane (about 18.5 minutes).

Planner

  • buildRunManifest keeps the existing allocation as a baseline and records the baseline's worst-case wall (paidShardWallUpperBoundMs) for 1–4 workers.
  • It then re-packs by the recorded per-file wall times in the new scripts/paid-test-durations.json. A file moves or swaps out of the heaviest slice only when no slice's worst case rises above the baseline maximum for any of those worker counts.
  • Registered files only trade places with other registered files, and the overlay and dedicated Autoplan slices are untouched. The result is deterministic.
  • With no seed, allocation is unchanged. Unrecorded files are weighted at the 75th percentile of recorded ones.

Seed

Expected effect

Estimated from the recorded times with two workers per slice:

Plan Heaviest slice before Heaviest slice after
PR-profile file set ~15.0 min ~11.9 min (the length of skill-e2e-shared-libs-paths alone)
Full gate census ~17.1 min ~13.2 min

This PR's own eval run will show the real number.

Validation

  • Paid planner and eval-selection tests: all 626 existing tests pass, including paid-retry-supervision's CI-wall coverage checks, which a naive duration packing broke.
  • New tests in test/paid-run-manifest.test.ts:
    • no slice's worst case rises for 1–4 workers on the gate ×6, gate ×7, and periodic ×8 plans;
    • the PR-profile set gets a lower maximum load and is order-independent;
    • the seed merge rules;
    • --write-durations requires --report.
  • Full free suite: bun run test:ubicloud on a 16-vCPU Ubicloud VM, 1,065 files and 27,331 tests, 0 failures, no flaky retries.
  • Credential scan: 0 high findings. Generated docs are fresh.

Open in Capy

@trunk-io

trunk-io Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

😎 This pull request was merged.

@github-actions

Copy link
Copy Markdown
Contributor

E2E Evals: ✅ PASS

115 automated passed / 115 final results | 0 failed, 0 manual accepted (unscored; no score-cache credit) | 115 executed, 0 reused | $35.57 total cost | reconcile exit: 0

Profile: pr / full-fallback; selected behaviors: 91, judges: 27. Deferred to scheduled/release coverage: 125 behaviors and 0 changed prompt files. Deferred checks did not run and receive no PR-pass credit.

Shard Automated result Manual/unscored Executed Reused Status Cost
e2e-third-party-actions/skill-e2e-third-party-actions 5/5 0 5 0 ✅ $0.58
e2e-learnings/skill-e2e-learnings 1/1 0 1 0 ✅ $0.28
e2e-plan-tune/skill-e2e-plan-tune 1/1 0 1 0 ✅ $0.41
e2e-review-attribution/skill-e2e-review-attribution 3/3 0 3 0 ✅ $0.49
e2e-opus-47/skill-e2e-opus-47 6/6 0 6 0 ✅ $1.35
e2e-session-intelligence/skill-e2e-session-intelligence 4/4 0 4 0 ✅ $0.54
e2e/skill-e2e-workflow 4/4 0 4 0 ✅ $1.41
e2e-design/skill-e2e-design 4/4 0 4 0 ✅ $1.17
e2e/skill-e2e-shared-libs-paths 3/3 0 3 0 ✅ $5.8
e2e/skill-e2e-investigate-owned-completion 1/1 0 1 0 ✅ $0.11
e2e-triage/skill-e2e-triage 1/1 0 1 0 ✅ $0.35
e2e/skill-e2e-shared-libs 4/4 0 4 0 ✅ $6.14
e2e-qa-workflow/skill-e2e-qa-workflow 3/3 0 3 0 ✅ $1.93
e2e-review-army/skill-e2e-review-army 5/5 0 5 0 ✅ $2.35
e2e/skill-e2e-ship-hook-consent 2/2 0 2 0 ✅ $0.33
llm-judge/skill-llm-eval 27/27 0 27 0 ✅ $0.54
e2e-ship-docsync/skill-e2e-ship-docsync 1/1 0 1 0 ✅ $0.65
e2e-retro/skill-e2e-retro 1/1 0 1 0 ✅ $0.64
e2e/skill-e2e-coverage-audit 2/2 0 2 0 ✅ $0.71
e2e-hermetic/skill-e2e-hermetic-canary 2/2 0 2 0 ✅ $0.02
e2e/skill-e2e-ship-hook-refresh 1/1 0 1 0 ✅ $0.19
e2e-skillify/skill-e2e-skillify 3/3 0 3 0 ✅ $1.58
e2e/skill-e2e-plan 7/7 0 7 0 ✅ $2.35
e2e/skill-e2e-investigate-owned-termination 2/2 0 2 0 ✅ $0.27
e2e-review/skill-e2e-review 2/2 0 2 0 ✅ $0.6
e2e-cso/skill-e2e-cso 1/1 0 1 0 ✅ $1.1
e2e-plan-tune-cathedral/skill-e2e-plan-tune-cathedral 5/5 0 5 0 ✅ $0
e2e-docsync-spawned/skill-e2e-docsync-spawned 1/1 0 1 0 ✅ $0.2
e2e-browse/skill-e2e-bws 7/7 0 7 0 ✅ $0.59
e2e-deploy/skill-e2e-deploy 6/6 0 6 0 ✅ $2.89
Fail-closed reconciliation
[test:paid] report: 6/6 slices, 42 planned shards, tier=gate
[test:paid] coverage: profile=pr mode=full-fallback; selected E2E=91, judges=27
[test:paid] deferred: 125 broad behaviors, 0 changed prompts without quick live coverage; these are not PR passes
  slice 1  passed             84s  test/skill-e2e-plan-devex-plan-mode.test.ts
  slice 1  passed            236s  test/skill-e2e-plan-mode-no-op.test.ts
  slice 1  passed             95s  test/skill-e2e-review-attribution.test.ts
  slice 1  passed            686s  test/skill-e2e-shared-libs-paths.test.ts
  slice 1  passed             67s  test/skill-e2e-ship-hook-consent.test.ts
  slice 2  passed             60s  test/skill-e2e-ask-user-question-format-compliance.test.ts
  slice 2  passed             53s  test/skill-e2e-coverage-audit.test.ts
  slice 2  passed             42s  test/skill-e2e-investigate-owned-completion.test.ts
  slice 2  passed            268s  test/skill-e2e-plan.test.ts
  slice 2  passed            151s  test/skill-e2e-retro.test.ts
  slice 2  passed            565s  test/skill-e2e-review-army.test.ts
  slice 3  passed            295s  test/skill-e2e-cso.test.ts
  slice 3  passed             26s  test/skill-e2e-learnings.test.ts
  slice 3  passed             98s  test/skill-e2e-review.test.ts
  slice 3  passed            669s  test/skill-e2e-shared-libs.test.ts
  slice 3  passed             54s  test/skill-e2e-triage.test.ts
  slice 3  passed            310s  test/skill-llm-eval.test.ts
  slice 4  passed             87s  test/skill-e2e-bws.test.ts
  slice 4  passed            459s  test/skill-e2e-deploy.test.ts
  slice 4  passed             42s  test/skill-e2e-docsync-spawned.test.ts
  slice 4  passed             67s  test/skill-e2e-office-hours-auto-mode.test.ts
  slice 4  passed            234s  test/skill-e2e-plan-ceo-finding-floor.test.ts
  slice 4  passed             68s  test/skill-e2e-plan-tune.test.ts
  slice 4  passed             58s  test/skill-e2e-session-intelligence.test.ts
  slice 4  passed            158s  test/skill-e2e-skillify.test.ts
  slice 5  passed            233s  test/skill-e2e-design.test.ts
  slice 5  passed             23s  test/skill-e2e-diagram.test.ts
  slice 5  passed             17s  test/skill-e2e-opus-47.test.ts
  slice 5  passed            235s  test/skill-e2e-plan-devex-finding-floor.test.ts
  slice 5  passed            394s  test/skill-e2e-qa-workflow.test.ts
  slice 5  passed             85s  test/skill-e2e-third-party-actions.test.ts
  slice 5  passed              0s  test/skill-llm-eval-spec.test.ts
  slice 5  passed              0s  test/skill-routing-e2e.test.ts
  slice 6  passed              0s  test/llm-judge-recommendation.test.ts
  slice 6  passed              6s  test/skill-e2e-hermetic-canary.test.ts
  slice 6  passed             46s  test/skill-e2e-investigate-owned-termination.test.ts
  slice 6  passed             33s  test/skill-e2e-plan-ceo-plan-mode.test.ts
  slice 6  passed            529s  test/skill-e2e-plan-design-with-ui.test.ts
  slice 6  passed              0s  test/skill-e2e-plan-tune-cathedral.test.ts
  slice 6  passed            112s  test/skill-e2e-ship-docsync.test.ts
  slice 6  passed             59s  test/skill-e2e-ship-hook-refresh.test.ts
  slice 6  passed            286s  test/skill-e2e-workflow.test.ts
[test:paid] collector final outcomes: 115 executed, 0 reused; 115 passed, 0 failed, 0 manual accepted (unscored; no score-cache credit) (115 attempt records from 31 collectors)
[test:paid] report: ⚠ 2 shard(s) passed with EVERY test skipped — they verified nothing:
  ⚠ test/skill-routing-e2e.test.ts (10 skipped — external service missing or tier mismatch)
  ⚠ test/llm-judge-recommendation.test.ts (1 skipped — external service missing or tier mismatch)
[test:paid] report: every planned shard accounted and passed

Sliced lane: declared PR profile or broad fallback via scripts/test-paid-shards.ts (planner → 6 executors → fail-closed report). Reused scores retain their original provenance and expiry.

@garrytan
garrytan merged commit 65bfb0c into main Sep 28, 2026
47 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant