@tangle-network/agent-eval 0.129.0 → 0.130.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +21 -0
- package/README.md +2 -0
- package/dist/active-curriculum-C4mk67HP.js +214 -0
- package/dist/active-curriculum-C4mk67HP.js.map +1 -0
- package/dist/adversarial-smnADNFS.d.ts +21 -0
- package/dist/adversarial-smnADNFS.d.ts.map +1 -0
- package/dist/analyst/index.d.ts +81 -2872
- package/dist/analyst/index.d.ts.map +1 -0
- package/dist/analyst/index.js +319 -360
- package/dist/analyst/index.js.map +1 -1
- package/dist/analyst-BkTS3C58.d.ts +89 -0
- package/dist/analyst-BkTS3C58.d.ts.map +1 -0
- package/dist/analyst-LsnNpSkm.js +152 -0
- package/dist/analyst-LsnNpSkm.js.map +1 -0
- package/dist/analyze-runs-C1CavBMk.js +1067 -0
- package/dist/analyze-runs-C1CavBMk.js.map +1 -0
- package/dist/analyze-runs-FsgYCinh.d.ts +72 -0
- package/dist/analyze-runs-FsgYCinh.d.ts.map +1 -0
- package/dist/attribute-vocabulary-DLJ6303h.d.ts +54 -0
- package/dist/attribute-vocabulary-DLJ6303h.d.ts.map +1 -0
- package/dist/authenticity/index.d.ts +81 -79
- package/dist/authenticity/index.d.ts.map +1 -0
- package/dist/authenticity/index.js +209 -193
- package/dist/authenticity/index.js.map +1 -1
- package/dist/baseline-HsBvw_dk.js +550 -0
- package/dist/baseline-HsBvw_dk.js.map +1 -0
- package/dist/baseline-hG3K85h4.d.ts +125 -0
- package/dist/baseline-hG3K85h4.d.ts.map +1 -0
- package/dist/belief-state/index.d.ts +448 -1188
- package/dist/belief-state/index.d.ts.map +1 -0
- package/dist/belief-state/index.js +1617 -1709
- package/dist/belief-state/index.js.map +1 -1
- package/dist/benchmarks/index.d.ts +2 -891
- package/dist/benchmarks/index.js +2 -60
- package/dist/benchmarks-BJgDGkAD.js +754 -0
- package/dist/benchmarks-BJgDGkAD.js.map +1 -0
- package/dist/builder-eval/index.d.ts +150 -662
- package/dist/builder-eval/index.d.ts.map +1 -0
- package/dist/builder-eval/index.js +356 -345
- package/dist/builder-eval/index.js.map +1 -1
- package/dist/calibration-CNWWA6K8.js +94 -0
- package/dist/calibration-CNWWA6K8.js.map +1 -0
- package/dist/campaign/index.d.ts +5 -6381
- package/dist/campaign/index.js +3 -213
- package/dist/campaign-aKJt6emI.js +3886 -0
- package/dist/campaign-aKJt6emI.js.map +1 -0
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +164 -175
- package/dist/cli.js.map +1 -1
- package/dist/client-C97NMzqi.d.ts +581 -0
- package/dist/client-C97NMzqi.d.ts.map +1 -0
- package/dist/client-CYzbdJOZ.js +637 -0
- package/dist/client-CYzbdJOZ.js.map +1 -0
- package/dist/code-agent-session-BjkMTQ7H.js +1390 -0
- package/dist/code-agent-session-BjkMTQ7H.js.map +1 -0
- package/dist/code-agent-session-DqqgOJaz.d.ts +143 -0
- package/dist/code-agent-session-DqqgOJaz.d.ts.map +1 -0
- package/dist/concurrency-DIxRZF_J.js +85 -0
- package/dist/concurrency-DIxRZF_J.js.map +1 -0
- package/dist/contract/index.d.ts +645 -5565
- package/dist/contract/index.d.ts.map +1 -0
- package/dist/contract/index.js +1730 -1938
- package/dist/contract/index.js.map +1 -1
- package/dist/control.d.ts +3 -1030
- package/dist/control.js +2 -33
- package/dist/cost-ledger-DIgQUFZZ.js +801 -0
- package/dist/cost-ledger-DIgQUFZZ.js.map +1 -0
- package/dist/cost-ledger-Dye6jCgg.d.ts +236 -0
- package/dist/cost-ledger-Dye6jCgg.d.ts.map +1 -0
- package/dist/dataset-BvtnC8Dc.d.ts +115 -0
- package/dist/dataset-BvtnC8Dc.d.ts.map +1 -0
- package/dist/default-registry-C-vFCSEc.js +2579 -0
- package/dist/default-registry-C-vFCSEc.js.map +1 -0
- package/dist/default-registry-CNPo-Vsb.d.ts +540 -0
- package/dist/default-registry-CNPo-Vsb.d.ts.map +1 -0
- package/dist/emitter-CPBAhxum.js +266 -0
- package/dist/emitter-CPBAhxum.js.map +1 -0
- package/dist/emitter-DGQGoLyj.d.ts +113 -0
- package/dist/emitter-DGQGoLyj.d.ts.map +1 -0
- package/dist/errors-8YnH8WlF.js +64 -0
- package/dist/errors-8YnH8WlF.js.map +1 -0
- package/dist/errors-CEk209JS.d.ts +76 -0
- package/dist/errors-CEk209JS.d.ts.map +1 -0
- package/dist/eval-campaign-DEm6c8ru.js +349 -0
- package/dist/eval-campaign-DEm6c8ru.js.map +1 -0
- package/dist/execution-tracks-CpgFPpS5.js +93 -0
- package/dist/execution-tracks-CpgFPpS5.js.map +1 -0
- package/dist/exporters-q9iL-2Jf.js +148 -0
- package/dist/exporters-q9iL-2Jf.js.map +1 -0
- package/dist/extract-usage-BrQ8mCLX.js +155 -0
- package/dist/extract-usage-BrQ8mCLX.js.map +1 -0
- package/dist/failure-cluster-CqcvCcdR.d.ts +59 -0
- package/dist/failure-cluster-CqcvCcdR.d.ts.map +1 -0
- package/dist/feedback-trajectory-CVaeREXV.d.ts +340 -0
- package/dist/feedback-trajectory-CVaeREXV.d.ts.map +1 -0
- package/dist/fuzz.d.ts +320 -646
- package/dist/fuzz.d.ts.map +1 -0
- package/dist/fuzz.js +670 -618
- package/dist/fuzz.js.map +1 -1
- package/dist/hf-dataset-DBJXXoY1.js +763 -0
- package/dist/hf-dataset-DBJXXoY1.js.map +1 -0
- package/dist/hosted/index.d.ts +11 -831
- package/dist/hosted/index.d.ts.map +1 -0
- package/dist/hosted/index.js +2 -37
- package/dist/index-2JJSA6-r2.d.ts +926 -0
- package/dist/index-2JJSA6-r2.d.ts.map +1 -0
- package/dist/index-6N0aYmpW.d.ts +217 -0
- package/dist/index-6N0aYmpW.d.ts.map +1 -0
- package/dist/index-BAvgST_9.d.ts +131 -0
- package/dist/index-BAvgST_9.d.ts.map +1 -0
- package/dist/index-BvnJuTGD.d.ts +68 -0
- package/dist/index-BvnJuTGD.d.ts.map +1 -0
- package/dist/index-C61Wi7yg.d.ts +547 -0
- package/dist/index-C61Wi7yg.d.ts.map +1 -0
- package/dist/index-CD_WZ_Xr.d.ts +2250 -0
- package/dist/index-CD_WZ_Xr.d.ts.map +1 -0
- package/dist/index-DSC51roc.d.ts +102 -0
- package/dist/index-DSC51roc.d.ts.map +1 -0
- package/dist/index-Em67JBjs.d.ts +335 -0
- package/dist/index-Em67JBjs.d.ts.map +1 -0
- package/dist/index.d.ts +3755 -15555
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +11182 -11216
- package/dist/index.js.map +1 -1
- package/dist/integrity-BzRbCHzi.js +424 -0
- package/dist/integrity-BzRbCHzi.js.map +1 -0
- package/dist/integrity-rmVhXWA7.d.ts +61 -0
- package/dist/integrity-rmVhXWA7.d.ts.map +1 -0
- package/dist/judge-calibration-DFtEMlde.d.ts +146 -0
- package/dist/judge-calibration-DFtEMlde.d.ts.map +1 -0
- package/dist/ledger-core/index.d.ts +2 -0
- package/dist/ledger-core/index.js +2 -0
- package/dist/ledger-core-DtZz1RG0.js +388 -0
- package/dist/ledger-core-DtZz1RG0.js.map +1 -0
- package/dist/llm-client--GR4JbZE.js +687 -0
- package/dist/llm-client--GR4JbZE.js.map +1 -0
- package/dist/llm-client-B_nIBlYo.d.ts +290 -0
- package/dist/llm-client-B_nIBlYo.d.ts.map +1 -0
- package/dist/matrix/index.d.ts +3 -155
- package/dist/matrix/index.js +2 -8
- package/dist/matrix-BzQnu2S6.js +270 -0
- package/dist/matrix-BzQnu2S6.js.map +1 -0
- package/dist/meta-eval/index.d.ts +4 -1027
- package/dist/meta-eval/index.js +393 -390
- package/dist/meta-eval/index.js.map +1 -1
- package/dist/metrics-C9YY1OcL.js +239 -0
- package/dist/metrics-C9YY1OcL.js.map +1 -0
- package/dist/mint-yN2M2eh0.js +201 -0
- package/dist/mint-yN2M2eh0.js.map +1 -0
- package/dist/multi-layer-verifier-BHY1gWAc.d.ts +138 -0
- package/dist/multi-layer-verifier-BHY1gWAc.d.ts.map +1 -0
- package/dist/multishot/index.d.ts +273 -480
- package/dist/multishot/index.d.ts.map +1 -0
- package/dist/multishot/index.js +595 -548
- package/dist/multishot/index.js.map +1 -1
- package/dist/off-policy-DvgzvtIx.js +220 -0
- package/dist/off-policy-DvgzvtIx.js.map +1 -0
- package/dist/off-policy-mskQw8Mb.d.ts +153 -0
- package/dist/off-policy-mskQw8Mb.d.ts.map +1 -0
- package/dist/openapi.json +1 -1
- package/dist/opencode-sqlite-BGrHeDu3.js +318 -0
- package/dist/opencode-sqlite-BGrHeDu3.js.map +1 -0
- package/dist/outcome-store-BYHIuO0e.d.ts +65 -0
- package/dist/outcome-store-BYHIuO0e.d.ts.map +1 -0
- package/dist/outcome-store-ChBKlTd_.js +75 -0
- package/dist/outcome-store-ChBKlTd_.js.map +1 -0
- package/dist/paired-arms-D9D0wXj2.js +260 -0
- package/dist/paired-arms-D9D0wXj2.js.map +1 -0
- package/dist/pipelines/index.d.ts +95 -532
- package/dist/pipelines/index.d.ts.map +1 -0
- package/dist/pipelines/index.js +497 -478
- package/dist/pipelines/index.js.map +1 -1
- package/dist/pre-registration-DakwTRXk.js +96 -0
- package/dist/pre-registration-DakwTRXk.js.map +1 -0
- package/dist/propose-review-control-LhIWGzHl.js +1458 -0
- package/dist/propose-review-control-LhIWGzHl.js.map +1 -0
- package/dist/query-CJ_DX8vl.d.ts +28 -0
- package/dist/query-CJ_DX8vl.d.ts.map +1 -0
- package/dist/query-Di7eEQ79.js +83 -0
- package/dist/query-Di7eEQ79.js.map +1 -0
- package/dist/raw-provider-sink-BQd7mzyT.js +201 -0
- package/dist/raw-provider-sink-BQd7mzyT.js.map +1 -0
- package/dist/raw-provider-sink-BU29Sh8h.d.ts +134 -0
- package/dist/raw-provider-sink-BU29Sh8h.d.ts.map +1 -0
- package/dist/redact-7Aq1ukl-.js +107 -0
- package/dist/redact-7Aq1ukl-.js.map +1 -0
- package/dist/release-report-Cz9NKH39.js +603 -0
- package/dist/release-report-Cz9NKH39.js.map +1 -0
- package/dist/release-report-mvB2G4_J.d.ts +244 -0
- package/dist/release-report-mvB2G4_J.d.ts.map +1 -0
- package/dist/replay-GnyotH0J.js +1741 -0
- package/dist/replay-GnyotH0J.js.map +1 -0
- package/dist/replay-OoidtG1E.d.ts +749 -0
- package/dist/replay-OoidtG1E.d.ts.map +1 -0
- package/dist/reporting.d.ts +6 -1312
- package/dist/reporting.js +6 -51
- package/dist/researcher-CwTdwXG1.d.ts +314 -0
- package/dist/researcher-CwTdwXG1.d.ts.map +1 -0
- package/dist/reward-hacking-eAnOsynk.d.ts +224 -0
- package/dist/reward-hacking-eAnOsynk.d.ts.map +1 -0
- package/dist/reward-hacking-qipEpKvY.js +596 -0
- package/dist/reward-hacking-qipEpKvY.js.map +1 -0
- package/dist/reward-nw2xZGZG.js +137 -0
- package/dist/reward-nw2xZGZG.js.map +1 -0
- package/dist/rl.d.ts +760 -4010
- package/dist/rl.d.ts.map +1 -0
- package/dist/rl.js +2325 -1958
- package/dist/rl.js.map +1 -1
- package/dist/rolldown-runtime-8H4AJuhK.js +14 -0
- package/dist/rollout/index.d.ts +3 -2087
- package/dist/rollout/index.js +8 -168
- package/dist/rollout-BOYjemfR.js +624 -0
- package/dist/rollout-BOYjemfR.js.map +1 -0
- package/dist/rubric-predictive-validity-B3xmbmS1.js +141 -0
- package/dist/rubric-predictive-validity-B3xmbmS1.js.map +1 -0
- package/dist/rubric-predictive-validity-Ku_clp_1.d.ts +74 -0
- package/dist/rubric-predictive-validity-Ku_clp_1.d.ts.map +1 -0
- package/dist/run-evidence-ClRX_8A9.d.ts +225 -0
- package/dist/run-evidence-ClRX_8A9.d.ts.map +1 -0
- package/dist/run-record-BuoE80Dq.js +467 -0
- package/dist/{chunk-56TAVBOK.js.map → run-record-BuoE80Dq.js.map} +1 -1
- package/dist/run-record-CnZu_gjl.d.ts +357 -0
- package/dist/run-record-CnZu_gjl.d.ts.map +1 -0
- package/dist/run-score-iEEAWiBY.js +41 -0
- package/dist/run-score-iEEAWiBY.js.map +1 -0
- package/dist/runtime-trajectory-1gyaTOoC.js +93 -0
- package/dist/runtime-trajectory-1gyaTOoC.js.map +1 -0
- package/dist/runtime-trajectory-BvSZcCHD.d.ts +50 -0
- package/dist/runtime-trajectory-BvSZcCHD.d.ts.map +1 -0
- package/dist/schema-BtVldJ3T.d.ts +206 -0
- package/dist/schema-BtVldJ3T.d.ts.map +1 -0
- package/dist/schema-C6DW4ZHR.js +821 -0
- package/dist/schema-C6DW4ZHR.js.map +1 -0
- package/dist/schema-CRhEY1SO.js +69 -0
- package/dist/schema-CRhEY1SO.js.map +1 -0
- package/dist/schema-Cef2cFmb.d.ts +408 -0
- package/dist/schema-Cef2cFmb.d.ts.map +1 -0
- package/dist/semantic-concept-judge-B6cWNJ2K.js +725 -0
- package/dist/semantic-concept-judge-B6cWNJ2K.js.map +1 -0
- package/dist/sequential-Br0mAPHA.js +148 -0
- package/dist/sequential-Br0mAPHA.js.map +1 -0
- package/dist/sequential-CYwq6Ff_.d.ts +141 -0
- package/dist/sequential-CYwq6Ff_.d.ts.map +1 -0
- package/dist/series-convergence-CjO2QdRW.js +43 -0
- package/dist/series-convergence-CjO2QdRW.js.map +1 -0
- package/dist/series-convergence-ofsqPWhs.d.ts +35 -0
- package/dist/series-convergence-ofsqPWhs.d.ts.map +1 -0
- package/dist/server-m5D9cvnG.js +1040 -0
- package/dist/server-m5D9cvnG.js.map +1 -0
- package/dist/skill-usage-C_pXm7lP.d.ts +534 -0
- package/dist/skill-usage-C_pXm7lP.d.ts.map +1 -0
- package/dist/skillopt-optimization-method-CUmHkGbI.js +7718 -0
- package/dist/skillopt-optimization-method-CUmHkGbI.js.map +1 -0
- package/dist/skillopt-optimization-method-CWKVTnks.d.ts +1740 -0
- package/dist/skillopt-optimization-method-CWKVTnks.d.ts.map +1 -0
- package/dist/statistics-Cmj6nynr.d.ts +514 -0
- package/dist/statistics-Cmj6nynr.d.ts.map +1 -0
- package/dist/statistics-CnnxdpOg.js +1437 -0
- package/dist/statistics-CnnxdpOg.js.map +1 -0
- package/dist/store-CT9YIIve.d.ts +117 -0
- package/dist/store-CT9YIIve.d.ts.map +1 -0
- package/dist/store-CxJry_cs.d.ts +229 -0
- package/dist/store-CxJry_cs.d.ts.map +1 -0
- package/dist/storyboard/index.d.ts +84 -203
- package/dist/storyboard/index.d.ts.map +1 -0
- package/dist/storyboard/index.js +609 -542
- package/dist/storyboard/index.js.map +1 -1
- package/dist/summary-report-BNs5nmXI.js +862 -0
- package/dist/summary-report-BNs5nmXI.js.map +1 -0
- package/dist/summary-report-Cj9gdw4i.d.ts +407 -0
- package/dist/summary-report-Cj9gdw4i.d.ts.map +1 -0
- package/dist/supervisor-run/index.d.ts +2 -959
- package/dist/supervisor-run/index.js +2 -65
- package/dist/supervisor-run-_lnTLM3z.js +1679 -0
- package/dist/supervisor-run-_lnTLM3z.js.map +1 -0
- package/dist/task-failure-attributes-CQZlB3et.js +311 -0
- package/dist/task-failure-attributes-CQZlB3et.js.map +1 -0
- package/dist/test-graded-scenario-BsqWLmPt.js +318 -0
- package/dist/test-graded-scenario-BsqWLmPt.js.map +1 -0
- package/dist/test-graded-scenario-D1TaI2va.d.ts +141 -0
- package/dist/test-graded-scenario-D1TaI2va.d.ts.map +1 -0
- package/dist/tools-BmuN627J.js +1085 -0
- package/dist/tools-BmuN627J.js.map +1 -0
- package/dist/trace-attributes.d.ts +2 -52
- package/dist/trace-attributes.js +131 -61
- package/dist/trace-attributes.js.map +1 -1
- package/dist/traces.d.ts +12 -2365
- package/dist/traces.js +12 -252
- package/dist/trajectory-D_7rLrvE.js +56 -0
- package/dist/trajectory-D_7rLrvE.js.map +1 -0
- package/dist/types-DGsxbAEd.d.ts +387 -0
- package/dist/types-DGsxbAEd.d.ts.map +1 -0
- package/dist/types-k9tZGKUg.d.ts +640 -0
- package/dist/types-k9tZGKUg.d.ts.map +1 -0
- package/dist/verdict-Dps8_okt.d.ts +37 -0
- package/dist/verdict-Dps8_okt.d.ts.map +1 -0
- package/dist/wire/index.d.ts +702 -1173
- package/dist/wire/index.d.ts.map +1 -0
- package/dist/wire/index.js +2 -81
- package/docs/campaign-proposers.md +1 -0
- package/package.json +17 -9
- package/dist/benchmarks/index.js.map +0 -1
- package/dist/campaign/index.js.map +0 -1
- package/dist/chunk-2QU3YOPR.js +0 -7374
- package/dist/chunk-2QU3YOPR.js.map +0 -1
- package/dist/chunk-3OCR4R5I.js +0 -728
- package/dist/chunk-3OCR4R5I.js.map +0 -1
- package/dist/chunk-3RF76KTD.js +0 -84
- package/dist/chunk-3RF76KTD.js.map +0 -1
- package/dist/chunk-56TAVBOK.js +0 -698
- package/dist/chunk-5DTSBUL2.js +0 -159
- package/dist/chunk-5DTSBUL2.js.map +0 -1
- package/dist/chunk-7FO3TNPI.js +0 -232
- package/dist/chunk-7FO3TNPI.js.map +0 -1
- package/dist/chunk-7ZZMD7UK.js +0 -386
- package/dist/chunk-7ZZMD7UK.js.map +0 -1
- package/dist/chunk-BOD4O7OF.js +0 -40
- package/dist/chunk-BOD4O7OF.js.map +0 -1
- package/dist/chunk-BSO5JDQH.js +0 -2335
- package/dist/chunk-BSO5JDQH.js.map +0 -1
- package/dist/chunk-C6LXANRU.js +0 -1550
- package/dist/chunk-C6LXANRU.js.map +0 -1
- package/dist/chunk-DODXQREJ.js +0 -752
- package/dist/chunk-DODXQREJ.js.map +0 -1
- package/dist/chunk-DRYIUNWY.js +0 -622
- package/dist/chunk-DRYIUNWY.js.map +0 -1
- package/dist/chunk-E7QXT7SX.js +0 -183
- package/dist/chunk-E7QXT7SX.js.map +0 -1
- package/dist/chunk-EG66UGL4.js +0 -341
- package/dist/chunk-EG66UGL4.js.map +0 -1
- package/dist/chunk-FXTVJPYD.js +0 -576
- package/dist/chunk-FXTVJPYD.js.map +0 -1
- package/dist/chunk-G7MGMCZD.js +0 -153
- package/dist/chunk-G7MGMCZD.js.map +0 -1
- package/dist/chunk-GGE4NNQT.js +0 -65
- package/dist/chunk-GGE4NNQT.js.map +0 -1
- package/dist/chunk-H23X7XKK.js +0 -181
- package/dist/chunk-H23X7XKK.js.map +0 -1
- package/dist/chunk-HHWE3POT.js +0 -94
- package/dist/chunk-HHWE3POT.js.map +0 -1
- package/dist/chunk-HPWUNB47.js +0 -289
- package/dist/chunk-HPWUNB47.js.map +0 -1
- package/dist/chunk-IYCLP2N2.js +0 -766
- package/dist/chunk-IYCLP2N2.js.map +0 -1
- package/dist/chunk-JHCHEVET.js +0 -274
- package/dist/chunk-JHCHEVET.js.map +0 -1
- package/dist/chunk-JQSF5DQT.js +0 -701
- package/dist/chunk-JQSF5DQT.js.map +0 -1
- package/dist/chunk-K4DBDHLK.js +0 -158
- package/dist/chunk-K4DBDHLK.js.map +0 -1
- package/dist/chunk-K6N6XJJX.js +0 -306
- package/dist/chunk-K6N6XJJX.js.map +0 -1
- package/dist/chunk-M4YBQKIJ.js +0 -1040
- package/dist/chunk-M4YBQKIJ.js.map +0 -1
- package/dist/chunk-MA6HLL3S.js +0 -65
- package/dist/chunk-MA6HLL3S.js.map +0 -1
- package/dist/chunk-MAZ26DC7.js +0 -99
- package/dist/chunk-MAZ26DC7.js.map +0 -1
- package/dist/chunk-NPCTHQIO.js +0 -91
- package/dist/chunk-NPCTHQIO.js.map +0 -1
- package/dist/chunk-NY44NC4A.js +0 -1056
- package/dist/chunk-NY44NC4A.js.map +0 -1
- package/dist/chunk-OIUOT4QD.js +0 -44
- package/dist/chunk-OIUOT4QD.js.map +0 -1
- package/dist/chunk-ONWEPEDO.js +0 -57
- package/dist/chunk-ONWEPEDO.js.map +0 -1
- package/dist/chunk-OWN5NPMC.js +0 -152
- package/dist/chunk-OWN5NPMC.js.map +0 -1
- package/dist/chunk-P6FYH6K4.js +0 -1161
- package/dist/chunk-P6FYH6K4.js.map +0 -1
- package/dist/chunk-PC4UYEBM.js +0 -166
- package/dist/chunk-PC4UYEBM.js.map +0 -1
- package/dist/chunk-PC5DOSM7.js +0 -579
- package/dist/chunk-PC5DOSM7.js.map +0 -1
- package/dist/chunk-PXE2VKMX.js +0 -140
- package/dist/chunk-PXE2VKMX.js.map +0 -1
- package/dist/chunk-PZ5AY32C.js +0 -10
- package/dist/chunk-PZ5AY32C.js.map +0 -1
- package/dist/chunk-QB6BDBP2.js +0 -4464
- package/dist/chunk-QB6BDBP2.js.map +0 -1
- package/dist/chunk-RXHCETDZ.js +0 -536
- package/dist/chunk-RXHCETDZ.js.map +0 -1
- package/dist/chunk-RZTMDUO7.js +0 -49
- package/dist/chunk-RZTMDUO7.js.map +0 -1
- package/dist/chunk-SFLLL76A.js +0 -669
- package/dist/chunk-SFLLL76A.js.map +0 -1
- package/dist/chunk-SZLVEKMJ.js +0 -1446
- package/dist/chunk-SZLVEKMJ.js.map +0 -1
- package/dist/chunk-T4SQEITX.js +0 -95
- package/dist/chunk-T4SQEITX.js.map +0 -1
- package/dist/chunk-T6RLYGAD.js +0 -158
- package/dist/chunk-T6RLYGAD.js.map +0 -1
- package/dist/chunk-TJVT4QFF.js +0 -911
- package/dist/chunk-TJVT4QFF.js.map +0 -1
- package/dist/chunk-TQ7LNKZ3.js +0 -136
- package/dist/chunk-TQ7LNKZ3.js.map +0 -1
- package/dist/chunk-U4L7JRPZ.js +0 -1706
- package/dist/chunk-U4L7JRPZ.js.map +0 -1
- package/dist/chunk-U4PHLT2N.js +0 -419
- package/dist/chunk-U4PHLT2N.js.map +0 -1
- package/dist/chunk-VCZ5FQYW.js +0 -928
- package/dist/chunk-VCZ5FQYW.js.map +0 -1
- package/dist/chunk-VI2UW6B6.js +0 -162
- package/dist/chunk-VI2UW6B6.js.map +0 -1
- package/dist/chunk-VQMK5FMP.js +0 -247
- package/dist/chunk-VQMK5FMP.js.map +0 -1
- package/dist/chunk-WGXIEX7P.js +0 -116
- package/dist/chunk-WGXIEX7P.js.map +0 -1
- package/dist/chunk-WVATSFCP.js +0 -1553
- package/dist/chunk-WVATSFCP.js.map +0 -1
- package/dist/chunk-X4YIBDER.js +0 -1662
- package/dist/chunk-X4YIBDER.js.map +0 -1
- package/dist/chunk-YQN4ICPP.js +0 -355
- package/dist/chunk-YQN4ICPP.js.map +0 -1
- package/dist/chunk-ZET2UAYW.js +0 -89
- package/dist/chunk-ZET2UAYW.js.map +0 -1
- package/dist/chunk-ZHTZ4EYI.js +0 -1212
- package/dist/chunk-ZHTZ4EYI.js.map +0 -1
- package/dist/control.js.map +0 -1
- package/dist/hosted/index.js.map +0 -1
- package/dist/matrix/index.js.map +0 -1
- package/dist/reporting.js.map +0 -1
- package/dist/rollout/index.js.map +0 -1
- package/dist/run-campaign-OJJ7CZF4.js +0 -18
- package/dist/run-campaign-OJJ7CZF4.js.map +0 -1
- package/dist/supervisor-run/index.js.map +0 -1
- package/dist/traces.js.map +0 -1
- package/dist/wire/index.js.map +0 -1
package/dist/chunk-JQSF5DQT.js
DELETED
|
@@ -1,701 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
summaryTable
|
|
3
|
-
} from "./chunk-TJVT4QFF.js";
|
|
4
|
-
import {
|
|
5
|
-
validateRunRecord
|
|
6
|
-
} from "./chunk-56TAVBOK.js";
|
|
7
|
-
import {
|
|
8
|
-
FAILURE_CLASSES
|
|
9
|
-
} from "./chunk-MA6HLL3S.js";
|
|
10
|
-
import {
|
|
11
|
-
isRealnessGated,
|
|
12
|
-
observedSplitScore
|
|
13
|
-
} from "./chunk-OIUOT4QD.js";
|
|
14
|
-
import {
|
|
15
|
-
ValidationError,
|
|
16
|
-
VerificationError
|
|
17
|
-
} from "./chunk-ONWEPEDO.js";
|
|
18
|
-
|
|
19
|
-
// src/release-confidence.ts
|
|
20
|
-
var DEFAULT_THRESHOLDS = {
|
|
21
|
-
requireCorpus: true,
|
|
22
|
-
minScenarioCount: 1,
|
|
23
|
-
minSearchRuns: 1,
|
|
24
|
-
minHoldoutRuns: 1,
|
|
25
|
-
requireHoldout: true,
|
|
26
|
-
minPassRate: 0.8,
|
|
27
|
-
minMeanScore: 0.7,
|
|
28
|
-
maxOverfitGap: 0.15,
|
|
29
|
-
maxMeanCostUsd: Number.POSITIVE_INFINITY,
|
|
30
|
-
maxP95WallMs: Number.POSITIVE_INFINITY,
|
|
31
|
-
requireAsiForFailures: true,
|
|
32
|
-
failureScoreThreshold: 0.5
|
|
33
|
-
};
|
|
34
|
-
function evaluateReleaseConfidence(input) {
|
|
35
|
-
const thresholds = { ...DEFAULT_THRESHOLDS, ...input.thresholds };
|
|
36
|
-
const candidateId = input.candidateId ?? null;
|
|
37
|
-
const runs = filterCandidate(
|
|
38
|
-
(input.runs ?? []).map(validateRunRecord),
|
|
39
|
-
candidateId,
|
|
40
|
-
input.baselineId
|
|
41
|
-
);
|
|
42
|
-
const traces = filterTraceCandidate(
|
|
43
|
-
(input.traces ?? []).map(validateReleaseTraceEvidence),
|
|
44
|
-
candidateId,
|
|
45
|
-
input.baselineId
|
|
46
|
-
);
|
|
47
|
-
const scenarios = input.scenarios ?? [];
|
|
48
|
-
const scenarioCount = input.dataset?.scenarioCount ?? scenarios.length;
|
|
49
|
-
const splitCounts = input.dataset?.splitCounts ?? countScenarioSplits(scenarios);
|
|
50
|
-
const searchScores = scoresFor(runs, "search");
|
|
51
|
-
const holdoutScores = scoresFor(runs, "holdout");
|
|
52
|
-
const runScores = runs.map(runSplitScore).filter(isFiniteNumber);
|
|
53
|
-
const traceScores = traces.map((t) => t.score).filter(isFiniteNumber);
|
|
54
|
-
const scoreUniverse = runs.length > 0 ? runScores : traceScores;
|
|
55
|
-
const qualityRuns = runs.filter((run) => runSplitScore(run) !== void 0);
|
|
56
|
-
const unscoredRuns = runs.filter(
|
|
57
|
-
(run) => runSplitScore(run) === void 0 && !hasExplicitTaskFailure(run) && !isFailedTerminalOutcome(run.terminalOutcome)
|
|
58
|
-
).length;
|
|
59
|
-
const honestRuns = runs.filter((run) => !isRealnessGated(run));
|
|
60
|
-
const passOutcomes = runs.length > 0 ? honestRuns.map((run) => runPassOutcome(run, thresholds.failureScoreThreshold)) : traces.map((trace) => tracePassOutcome(trace, thresholds.failureScoreThreshold));
|
|
61
|
-
const reliabilityRows = runs.length > 0 ? runs.map((run) => terminalSuccess(run.terminalOutcome)) : traces.map((trace) => trace.ok);
|
|
62
|
-
const unclassifiedTerminalRuns = reliabilityRows.filter((outcome) => outcome === void 0).length;
|
|
63
|
-
const terminalFailureRuns = reliabilityRows.filter((outcome) => outcome === false).length;
|
|
64
|
-
const reliabilityRate = reliabilityRows.length === 0 || unclassifiedTerminalRuns > 0 ? null : (reliabilityRows.length - terminalFailureRuns) / reliabilityRows.length;
|
|
65
|
-
const searchRuns = qualityRuns.filter((r) => r.splitTag === "search").length;
|
|
66
|
-
const holdoutRuns = qualityRuns.filter((r) => r.splitTag === "holdout").length;
|
|
67
|
-
const failed = failedRows(runs, traces, thresholds.failureScoreThreshold);
|
|
68
|
-
const searchMeanScore = meanOrNull(searchScores);
|
|
69
|
-
const holdoutMeanScore = meanOrNull(holdoutScores);
|
|
70
|
-
const runCosts = runs.flatMap(
|
|
71
|
-
(run) => run.costProvenance.kind === "uncaptured" ? [] : [run.costProvenance.usd]
|
|
72
|
-
);
|
|
73
|
-
const traceCosts = traces.map((trace) => trace.costUsd).filter(isFiniteNumber);
|
|
74
|
-
const meanCostUsd = runs.length > 0 ? runCosts.length === runs.length ? meanOrNull(runCosts) : null : meanOrNull(traceCosts);
|
|
75
|
-
const wallTimes = runs.length > 0 ? runs.map((run) => run.wallMs) : traces.map((trace) => trace.durationMs).filter(isFiniteNumber);
|
|
76
|
-
const metrics = {
|
|
77
|
-
scenarioCount,
|
|
78
|
-
searchRuns,
|
|
79
|
-
holdoutRuns,
|
|
80
|
-
unscoredRuns,
|
|
81
|
-
unclassifiedTerminalRuns,
|
|
82
|
-
terminalFailureRuns,
|
|
83
|
-
reliabilityRate,
|
|
84
|
-
passRate: passOutcomeRate(passOutcomes),
|
|
85
|
-
realnessGatedRuns: runs.length - honestRuns.length,
|
|
86
|
-
meanScore: meanOrNull(scoreUniverse),
|
|
87
|
-
searchMeanScore,
|
|
88
|
-
holdoutMeanScore,
|
|
89
|
-
overfitGap: diffOrNull(searchMeanScore, holdoutMeanScore),
|
|
90
|
-
meanCostUsd,
|
|
91
|
-
p95WallMs: percentileOrNull(wallTimes, 0.95),
|
|
92
|
-
failedRows: failed.length,
|
|
93
|
-
failuresWithAsi: failed.filter((row) => row.hasAsi).length,
|
|
94
|
-
singleShotTraces: traces.filter((t) => t.turnCount === 1).length,
|
|
95
|
-
multiShotTraces: traces.filter((t) => (t.turnCount ?? 0) > 1).length,
|
|
96
|
-
splitCounts,
|
|
97
|
-
domainCounts: countDomains(scenarios),
|
|
98
|
-
failureClassCounts: countFailureClasses(runs, traces, thresholds.failureScoreThreshold),
|
|
99
|
-
responsibleSurfaceCounts: countResponsibleSurfaces(traces)
|
|
100
|
-
};
|
|
101
|
-
const issues = [];
|
|
102
|
-
checkCorpus(input, thresholds, metrics, issues);
|
|
103
|
-
checkQuality(thresholds, metrics, issues);
|
|
104
|
-
checkReliability(metrics, issues);
|
|
105
|
-
checkGeneralization(input.gateDecision ?? null, thresholds, metrics, issues);
|
|
106
|
-
checkDiagnostics(thresholds, metrics, issues);
|
|
107
|
-
checkEfficiency(thresholds, metrics, issues);
|
|
108
|
-
const axes = buildAxes(metrics, thresholds, issues);
|
|
109
|
-
const status = issues.some((i) => i.severity === "critical") ? "fail" : issues.length > 0 ? "warn" : "pass";
|
|
110
|
-
return {
|
|
111
|
-
target: input.target,
|
|
112
|
-
candidateId,
|
|
113
|
-
baselineId: input.baselineId ?? null,
|
|
114
|
-
status,
|
|
115
|
-
promote: status === "pass" && (input.gateDecision ? input.gateDecision.promote : true),
|
|
116
|
-
axes,
|
|
117
|
-
issues,
|
|
118
|
-
metrics,
|
|
119
|
-
dataset: input.dataset ?? null,
|
|
120
|
-
gateDecision: input.gateDecision ?? null,
|
|
121
|
-
summary: renderSummary(input.target, status, metrics, issues)
|
|
122
|
-
};
|
|
123
|
-
}
|
|
124
|
-
function assertReleaseConfidence(input) {
|
|
125
|
-
const scorecard = evaluateReleaseConfidence(input);
|
|
126
|
-
if (scorecard.status === "fail") {
|
|
127
|
-
throw new VerificationError(scorecard.summary);
|
|
128
|
-
}
|
|
129
|
-
return scorecard;
|
|
130
|
-
}
|
|
131
|
-
function filterCandidate(runs, candidateId, baselineId) {
|
|
132
|
-
if (candidateId) return runs.filter((r) => r.candidateId === candidateId);
|
|
133
|
-
if (baselineId) return runs.filter((r) => r.candidateId !== baselineId);
|
|
134
|
-
return [...runs];
|
|
135
|
-
}
|
|
136
|
-
function filterTraceCandidate(traces, candidateId, baselineId) {
|
|
137
|
-
if (candidateId)
|
|
138
|
-
return traces.filter((t) => t.candidateId === void 0 || t.candidateId === candidateId);
|
|
139
|
-
if (baselineId)
|
|
140
|
-
return traces.filter((t) => t.candidateId === void 0 || t.candidateId !== baselineId);
|
|
141
|
-
return [...traces];
|
|
142
|
-
}
|
|
143
|
-
function validateReleaseTraceEvidence(trace, index) {
|
|
144
|
-
const value = trace;
|
|
145
|
-
if (Object.hasOwn(value, "failureMode")) {
|
|
146
|
-
throw new ValidationError(
|
|
147
|
-
`traces[${index}].failureMode is not supported; use canonical failureClass`
|
|
148
|
-
);
|
|
149
|
-
}
|
|
150
|
-
if (trace.failureClass !== void 0 && !FAILURE_CLASSES.includes(trace.failureClass)) {
|
|
151
|
-
throw new ValidationError(
|
|
152
|
-
`traces[${index}].failureClass must be one of ${FAILURE_CLASSES.join(", ")}`
|
|
153
|
-
);
|
|
154
|
-
}
|
|
155
|
-
return trace;
|
|
156
|
-
}
|
|
157
|
-
function checkCorpus(input, thresholds, metrics, issues) {
|
|
158
|
-
if (thresholds.requireCorpus && !input.dataset && (input.scenarios?.length ?? 0) === 0) {
|
|
159
|
-
issues.push({
|
|
160
|
-
axis: "corpus",
|
|
161
|
-
severity: "critical",
|
|
162
|
-
code: "missing_corpus",
|
|
163
|
-
detail: "No Dataset manifest or scenarios supplied."
|
|
164
|
-
});
|
|
165
|
-
}
|
|
166
|
-
if (metrics.scenarioCount < thresholds.minScenarioCount) {
|
|
167
|
-
issues.push({
|
|
168
|
-
axis: "corpus",
|
|
169
|
-
severity: "critical",
|
|
170
|
-
code: "few_scenarios",
|
|
171
|
-
detail: `${metrics.scenarioCount} scenario(s) < min ${thresholds.minScenarioCount}.`
|
|
172
|
-
});
|
|
173
|
-
}
|
|
174
|
-
if (thresholds.requireHoldout && metrics.splitCounts.holdout === 0) {
|
|
175
|
-
issues.push({
|
|
176
|
-
axis: "corpus",
|
|
177
|
-
severity: "critical",
|
|
178
|
-
code: "missing_holdout_split",
|
|
179
|
-
detail: "Corpus has no holdout scenarios."
|
|
180
|
-
});
|
|
181
|
-
}
|
|
182
|
-
}
|
|
183
|
-
function checkQuality(thresholds, metrics, issues) {
|
|
184
|
-
if (metrics.searchRuns < thresholds.minSearchRuns) {
|
|
185
|
-
issues.push({
|
|
186
|
-
axis: "quality",
|
|
187
|
-
severity: "critical",
|
|
188
|
-
code: "few_search_runs",
|
|
189
|
-
detail: `${metrics.searchRuns} search run(s) < min ${thresholds.minSearchRuns}.`
|
|
190
|
-
});
|
|
191
|
-
}
|
|
192
|
-
if (metrics.unscoredRuns > 0) {
|
|
193
|
-
issues.push({
|
|
194
|
-
axis: "quality",
|
|
195
|
-
severity: "critical",
|
|
196
|
-
code: "unscored_runs",
|
|
197
|
-
detail: `${metrics.unscoredRuns} supplied run(s) have no task result.`
|
|
198
|
-
});
|
|
199
|
-
}
|
|
200
|
-
if (metrics.passRate === null || metrics.meanScore === null) {
|
|
201
|
-
issues.push({
|
|
202
|
-
axis: "quality",
|
|
203
|
-
severity: "critical",
|
|
204
|
-
code: "missing_quality_scores",
|
|
205
|
-
detail: "No task-quality scores are available for pass-rate and mean-score checks."
|
|
206
|
-
});
|
|
207
|
-
}
|
|
208
|
-
if (metrics.passRate !== null && metrics.passRate < thresholds.minPassRate) {
|
|
209
|
-
issues.push({
|
|
210
|
-
axis: "quality",
|
|
211
|
-
severity: "critical",
|
|
212
|
-
code: "low_pass_rate",
|
|
213
|
-
detail: `passRate ${fmt(metrics.passRate)} < ${fmt(thresholds.minPassRate)}.`
|
|
214
|
-
});
|
|
215
|
-
}
|
|
216
|
-
if (metrics.meanScore !== null && metrics.meanScore < thresholds.minMeanScore) {
|
|
217
|
-
issues.push({
|
|
218
|
-
axis: "quality",
|
|
219
|
-
severity: "critical",
|
|
220
|
-
code: "low_mean_score",
|
|
221
|
-
detail: `meanScore ${fmt(metrics.meanScore)} < ${fmt(thresholds.minMeanScore)}.`
|
|
222
|
-
});
|
|
223
|
-
}
|
|
224
|
-
}
|
|
225
|
-
function checkReliability(metrics, issues) {
|
|
226
|
-
if (metrics.reliabilityRate === null) {
|
|
227
|
-
issues.push({
|
|
228
|
-
axis: "reliability",
|
|
229
|
-
severity: "critical",
|
|
230
|
-
code: "missing_reliability_evidence",
|
|
231
|
-
detail: metrics.unclassifiedTerminalRuns > 0 ? `${metrics.unclassifiedTerminalRuns} supplied run(s) have no classified terminal result.` : "No classified terminal results are available."
|
|
232
|
-
});
|
|
233
|
-
}
|
|
234
|
-
if (metrics.terminalFailureRuns > 0) {
|
|
235
|
-
issues.push({
|
|
236
|
-
axis: "reliability",
|
|
237
|
-
severity: "critical",
|
|
238
|
-
code: "terminal_run_failures",
|
|
239
|
-
detail: `${metrics.terminalFailureRuns} run(s) ended failed, cancelled, or incomplete.`
|
|
240
|
-
});
|
|
241
|
-
}
|
|
242
|
-
}
|
|
243
|
-
function checkGeneralization(gateDecision, thresholds, metrics, issues) {
|
|
244
|
-
if (thresholds.requireHoldout && metrics.holdoutRuns < thresholds.minHoldoutRuns) {
|
|
245
|
-
issues.push({
|
|
246
|
-
axis: "generalization",
|
|
247
|
-
severity: "critical",
|
|
248
|
-
code: "few_holdout_runs",
|
|
249
|
-
detail: `${metrics.holdoutRuns} holdout run(s) < min ${thresholds.minHoldoutRuns}.`
|
|
250
|
-
});
|
|
251
|
-
}
|
|
252
|
-
if (metrics.overfitGap !== null && metrics.overfitGap > thresholds.maxOverfitGap) {
|
|
253
|
-
issues.push({
|
|
254
|
-
axis: "generalization",
|
|
255
|
-
severity: "critical",
|
|
256
|
-
code: "overfit_gap",
|
|
257
|
-
detail: `search-holdout gap ${fmt(metrics.overfitGap)} > ${fmt(thresholds.maxOverfitGap)}.`
|
|
258
|
-
});
|
|
259
|
-
}
|
|
260
|
-
if (gateDecision && !gateDecision.promote) {
|
|
261
|
-
issues.push({
|
|
262
|
-
axis: "generalization",
|
|
263
|
-
severity: "critical",
|
|
264
|
-
code: `gate_${gateDecision.rejectionCode ?? "reject"}`,
|
|
265
|
-
detail: gateDecision.reason
|
|
266
|
-
});
|
|
267
|
-
}
|
|
268
|
-
}
|
|
269
|
-
function checkDiagnostics(thresholds, metrics, issues) {
|
|
270
|
-
if (!thresholds.requireAsiForFailures) return;
|
|
271
|
-
if (metrics.failedRows > metrics.failuresWithAsi) {
|
|
272
|
-
issues.push({
|
|
273
|
-
axis: "diagnostics",
|
|
274
|
-
severity: "critical",
|
|
275
|
-
code: "missing_failure_asi",
|
|
276
|
-
detail: `${metrics.failedRows - metrics.failuresWithAsi} failed row(s) have no actionable side information.`
|
|
277
|
-
});
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
|
-
function checkEfficiency(thresholds, metrics, issues) {
|
|
281
|
-
if (Number.isFinite(thresholds.maxMeanCostUsd) && metrics.meanCostUsd === null) {
|
|
282
|
-
issues.push({
|
|
283
|
-
axis: "efficiency",
|
|
284
|
-
severity: "critical",
|
|
285
|
-
code: "missing_cost",
|
|
286
|
-
detail: "A finite cost limit was configured but no cost evidence is available."
|
|
287
|
-
});
|
|
288
|
-
} else if (metrics.meanCostUsd !== null && metrics.meanCostUsd > thresholds.maxMeanCostUsd) {
|
|
289
|
-
issues.push({
|
|
290
|
-
axis: "efficiency",
|
|
291
|
-
severity: "critical",
|
|
292
|
-
code: "cost_budget",
|
|
293
|
-
detail: `meanCostUsd ${fmt(metrics.meanCostUsd)} > ${fmt(thresholds.maxMeanCostUsd)}.`
|
|
294
|
-
});
|
|
295
|
-
}
|
|
296
|
-
if (Number.isFinite(thresholds.maxP95WallMs) && metrics.p95WallMs === null) {
|
|
297
|
-
issues.push({
|
|
298
|
-
axis: "efficiency",
|
|
299
|
-
severity: "critical",
|
|
300
|
-
code: "missing_latency",
|
|
301
|
-
detail: "A finite latency limit was configured but no latency evidence is available."
|
|
302
|
-
});
|
|
303
|
-
} else if (metrics.p95WallMs !== null && metrics.p95WallMs > thresholds.maxP95WallMs) {
|
|
304
|
-
issues.push({
|
|
305
|
-
axis: "efficiency",
|
|
306
|
-
severity: "critical",
|
|
307
|
-
code: "latency_budget",
|
|
308
|
-
detail: `p95WallMs ${fmt(metrics.p95WallMs)} > ${fmt(thresholds.maxP95WallMs)}.`
|
|
309
|
-
});
|
|
310
|
-
}
|
|
311
|
-
}
|
|
312
|
-
function buildAxes(metrics, thresholds, issues) {
|
|
313
|
-
return [
|
|
314
|
-
axis(
|
|
315
|
-
"corpus",
|
|
316
|
-
issues,
|
|
317
|
-
bounded(metrics.scenarioCount / Math.max(1, thresholds.minScenarioCount)),
|
|
318
|
-
`${metrics.scenarioCount} scenarios; holdout=${metrics.splitCounts.holdout}`
|
|
319
|
-
),
|
|
320
|
-
axis(
|
|
321
|
-
"quality",
|
|
322
|
-
issues,
|
|
323
|
-
metrics.passRate === null || metrics.meanScore === null ? null : Math.min(metrics.passRate, metrics.meanScore),
|
|
324
|
-
`passRate=${fmt(metrics.passRate)} meanScore=${fmt(metrics.meanScore)}`
|
|
325
|
-
),
|
|
326
|
-
axis(
|
|
327
|
-
"reliability",
|
|
328
|
-
issues,
|
|
329
|
-
metrics.reliabilityRate,
|
|
330
|
-
`successRate=${fmt(metrics.reliabilityRate)} terminalFailures=${metrics.terminalFailureRuns} unclassified=${metrics.unclassifiedTerminalRuns}`
|
|
331
|
-
),
|
|
332
|
-
axis(
|
|
333
|
-
"generalization",
|
|
334
|
-
issues,
|
|
335
|
-
gapScore(metrics.overfitGap, thresholds.maxOverfitGap),
|
|
336
|
-
`holdoutRuns=${metrics.holdoutRuns} overfitGap=${fmt(metrics.overfitGap)}`
|
|
337
|
-
),
|
|
338
|
-
axis(
|
|
339
|
-
"diagnostics",
|
|
340
|
-
issues,
|
|
341
|
-
metrics.failedRows === 0 ? 1 : metrics.failuresWithAsi / metrics.failedRows,
|
|
342
|
-
`failuresWithAsi=${metrics.failuresWithAsi}/${metrics.failedRows}`
|
|
343
|
-
),
|
|
344
|
-
axis(
|
|
345
|
-
"efficiency",
|
|
346
|
-
issues,
|
|
347
|
-
efficiencyScore(metrics, thresholds),
|
|
348
|
-
`meanCostUsd=${fmt(metrics.meanCostUsd)} p95WallMs=${fmt(metrics.p95WallMs)}`
|
|
349
|
-
)
|
|
350
|
-
];
|
|
351
|
-
}
|
|
352
|
-
function axis(name, issues, score, detail) {
|
|
353
|
-
const own = issues.filter((i) => i.axis === name);
|
|
354
|
-
const status = own.some((i) => i.severity === "critical") ? "fail" : own.length > 0 ? "warn" : "pass";
|
|
355
|
-
return { name, status, score: score === null ? null : bounded(score), detail };
|
|
356
|
-
}
|
|
357
|
-
function countScenarioSplits(scenarios) {
|
|
358
|
-
const counts = { train: 0, dev: 0, test: 0, holdout: 0 };
|
|
359
|
-
for (const scenario of scenarios) counts[scenario.split ?? "train"]++;
|
|
360
|
-
return counts;
|
|
361
|
-
}
|
|
362
|
-
function countDomains(scenarios) {
|
|
363
|
-
const out = {};
|
|
364
|
-
for (const scenario of scenarios) {
|
|
365
|
-
const domain = scenario.tags?.domain ?? scenario.tags?.category ?? "uncategorized";
|
|
366
|
-
out[domain] = (out[domain] ?? 0) + 1;
|
|
367
|
-
}
|
|
368
|
-
return out;
|
|
369
|
-
}
|
|
370
|
-
function countFailureClasses(runs, traces, threshold) {
|
|
371
|
-
const out = {};
|
|
372
|
-
for (const run of runs) {
|
|
373
|
-
if (runPassOutcome(run, threshold) === false) {
|
|
374
|
-
const failureClass = run.failureClass !== void 0 && run.failureClass !== "success" ? run.failureClass : "unknown";
|
|
375
|
-
out[failureClass] = (out[failureClass] ?? 0) + 1;
|
|
376
|
-
}
|
|
377
|
-
}
|
|
378
|
-
for (const trace of traces) {
|
|
379
|
-
if (tracePassOutcome(trace, threshold) === false) {
|
|
380
|
-
const failureClass = trace.failureClass !== void 0 && trace.failureClass !== "success" ? trace.failureClass : "unknown";
|
|
381
|
-
out[failureClass] = (out[failureClass] ?? 0) + 1;
|
|
382
|
-
}
|
|
383
|
-
}
|
|
384
|
-
return out;
|
|
385
|
-
}
|
|
386
|
-
function countResponsibleSurfaces(traces) {
|
|
387
|
-
const out = {};
|
|
388
|
-
for (const trace of traces) {
|
|
389
|
-
for (const asi of trace.asi ?? []) {
|
|
390
|
-
const surface = asi.responsibleSurface ?? "unknown";
|
|
391
|
-
out[surface] = (out[surface] ?? 0) + 1;
|
|
392
|
-
}
|
|
393
|
-
}
|
|
394
|
-
return out;
|
|
395
|
-
}
|
|
396
|
-
function failedRows(runs, traces, threshold) {
|
|
397
|
-
const out = [];
|
|
398
|
-
for (const run of runs) {
|
|
399
|
-
if (runPassOutcome(run, threshold) === false) {
|
|
400
|
-
const asiMetric = run.outcome.raw.asi;
|
|
401
|
-
out.push({ hasAsi: typeof asiMetric === "number" && asiMetric > 0 });
|
|
402
|
-
}
|
|
403
|
-
}
|
|
404
|
-
for (const trace of traces) {
|
|
405
|
-
if (tracePassOutcome(trace, threshold) === false) {
|
|
406
|
-
out.push({ hasAsi: (trace.asi?.length ?? 0) > 0 });
|
|
407
|
-
}
|
|
408
|
-
}
|
|
409
|
-
return out;
|
|
410
|
-
}
|
|
411
|
-
function passOutcomeRate(outcomes) {
|
|
412
|
-
const classified = outcomes.filter((outcome) => outcome !== null);
|
|
413
|
-
if (classified.length === 0) return null;
|
|
414
|
-
return classified.filter(Boolean).length / classified.length;
|
|
415
|
-
}
|
|
416
|
-
function runPassOutcome(run, threshold) {
|
|
417
|
-
if (hasExplicitTaskFailure(run)) return false;
|
|
418
|
-
const score = runSplitScore(run);
|
|
419
|
-
return score === void 0 ? null : score >= threshold;
|
|
420
|
-
}
|
|
421
|
-
function hasExplicitTaskFailure(run) {
|
|
422
|
-
return run.failureClass !== void 0 && run.failureClass !== "success";
|
|
423
|
-
}
|
|
424
|
-
function tracePassOutcome(trace, threshold) {
|
|
425
|
-
if (trace.failureClass !== void 0 && trace.failureClass !== "success") return false;
|
|
426
|
-
if (trace.ok === false) return false;
|
|
427
|
-
if (isFiniteNumber(trace.score)) return trace.score >= threshold;
|
|
428
|
-
return trace.ok === true ? true : null;
|
|
429
|
-
}
|
|
430
|
-
function isFailedTerminalOutcome(outcome) {
|
|
431
|
-
return outcome === "failed" || outcome === "cancelled" || outcome === "incomplete";
|
|
432
|
-
}
|
|
433
|
-
function terminalSuccess(outcome) {
|
|
434
|
-
if (outcome === "succeeded") return true;
|
|
435
|
-
if (isFailedTerminalOutcome(outcome)) return false;
|
|
436
|
-
return void 0;
|
|
437
|
-
}
|
|
438
|
-
function scoresFor(runs, split) {
|
|
439
|
-
return runs.filter((run) => run.splitTag === split).map(runSplitScore).filter(isFiniteNumber);
|
|
440
|
-
}
|
|
441
|
-
function runSplitScore(run) {
|
|
442
|
-
const score = observedSplitScore(run, run.splitTag === "holdout" ? "holdout" : "search");
|
|
443
|
-
return isFiniteNumber(score) ? score : void 0;
|
|
444
|
-
}
|
|
445
|
-
function meanOrNull(xs) {
|
|
446
|
-
if (xs.length === 0) return null;
|
|
447
|
-
return xs.reduce((sum, x) => sum + x, 0) / xs.length;
|
|
448
|
-
}
|
|
449
|
-
function percentileOrNull(xs, p) {
|
|
450
|
-
if (xs.length === 0) return null;
|
|
451
|
-
const sorted = [...xs].sort((a, b) => a - b);
|
|
452
|
-
return sorted[Math.min(sorted.length - 1, Math.max(0, Math.ceil(p * sorted.length) - 1))];
|
|
453
|
-
}
|
|
454
|
-
function isFiniteNumber(value) {
|
|
455
|
-
return typeof value === "number" && Number.isFinite(value);
|
|
456
|
-
}
|
|
457
|
-
function diffOrNull(a, b) {
|
|
458
|
-
if (a === null || b === null) return null;
|
|
459
|
-
return a - b;
|
|
460
|
-
}
|
|
461
|
-
function gapScore(gap, maxGap) {
|
|
462
|
-
if (gap === null) return null;
|
|
463
|
-
if (maxGap <= 0) return gap <= 0 ? 1 : 0;
|
|
464
|
-
return bounded(1 - Math.max(0, gap) / maxGap);
|
|
465
|
-
}
|
|
466
|
-
function efficiencyScore(metrics, thresholds) {
|
|
467
|
-
const cost = Number.isFinite(thresholds.maxMeanCostUsd) ? metrics.meanCostUsd === null ? null : bounded(thresholds.maxMeanCostUsd / Math.max(metrics.meanCostUsd, 1e-12)) : 1;
|
|
468
|
-
const latency = Number.isFinite(thresholds.maxP95WallMs) ? metrics.p95WallMs === null ? null : bounded(thresholds.maxP95WallMs / Math.max(metrics.p95WallMs, 1e-12)) : 1;
|
|
469
|
-
if (cost === null || latency === null) return null;
|
|
470
|
-
return Math.min(cost, latency);
|
|
471
|
-
}
|
|
472
|
-
function bounded(x) {
|
|
473
|
-
if (!Number.isFinite(x)) return 0;
|
|
474
|
-
return Math.max(0, Math.min(1, x));
|
|
475
|
-
}
|
|
476
|
-
function renderSummary(target, status, metrics, issues) {
|
|
477
|
-
const prefix = `release confidence ${status}: ${target}`;
|
|
478
|
-
const metricText = `scenarios=${metrics.scenarioCount} searchRuns=${metrics.searchRuns} holdoutRuns=${metrics.holdoutRuns} passRate=${fmt(metrics.passRate)} meanScore=${fmt(metrics.meanScore)}`;
|
|
479
|
-
if (issues.length === 0) return `${prefix}; ${metricText}`;
|
|
480
|
-
return `${prefix}; ${metricText}; issues=${issues.map((i) => i.code).join(",")}`;
|
|
481
|
-
}
|
|
482
|
-
function fmt(x) {
|
|
483
|
-
if (x === null) return "n/a";
|
|
484
|
-
return x.toFixed(4);
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
// src/promotion-gate.ts
|
|
488
|
-
function bootstrapCi(baseline, candidate, options = {}) {
|
|
489
|
-
const alpha = options.alpha ?? 0.05;
|
|
490
|
-
const iterations = options.iterations ?? 1e3;
|
|
491
|
-
const minTotal = options.minTotalSamples ?? 6;
|
|
492
|
-
const rng = mulberry32(options.seed ?? hashSeed(baseline, candidate));
|
|
493
|
-
const baselineMean = mean(baseline);
|
|
494
|
-
const candidateMean = mean(candidate);
|
|
495
|
-
const delta = candidateMean - baselineMean;
|
|
496
|
-
if (baseline.length + candidate.length < minTotal || baseline.length === 0 || candidate.length === 0) {
|
|
497
|
-
return {
|
|
498
|
-
baselineMean,
|
|
499
|
-
candidateMean,
|
|
500
|
-
delta,
|
|
501
|
-
ciLower: -Infinity,
|
|
502
|
-
ciUpper: Infinity,
|
|
503
|
-
iterations: 0,
|
|
504
|
-
alpha,
|
|
505
|
-
verdict: "INCONCLUSIVE"
|
|
506
|
-
};
|
|
507
|
-
}
|
|
508
|
-
const deltas = new Array(iterations);
|
|
509
|
-
for (let i = 0; i < iterations; i++) {
|
|
510
|
-
const bResample = resample(baseline, rng);
|
|
511
|
-
const cResample = resample(candidate, rng);
|
|
512
|
-
deltas[i] = mean(cResample) - mean(bResample);
|
|
513
|
-
}
|
|
514
|
-
deltas.sort((a, b) => a - b);
|
|
515
|
-
const lowerIdx = Math.floor(alpha / 2 * iterations);
|
|
516
|
-
const upperIdx = Math.floor((1 - alpha / 2) * iterations) - 1;
|
|
517
|
-
const ciLower = deltas[Math.max(0, lowerIdx)];
|
|
518
|
-
const ciUpper = deltas[Math.min(iterations - 1, upperIdx)];
|
|
519
|
-
let verdict;
|
|
520
|
-
if (ciLower > 0) verdict = "ADVANCE";
|
|
521
|
-
else if (ciUpper < 0) verdict = "REVERT";
|
|
522
|
-
else if (delta >= 0) verdict = "KEEP";
|
|
523
|
-
else verdict = "INCONCLUSIVE";
|
|
524
|
-
return {
|
|
525
|
-
baselineMean,
|
|
526
|
-
candidateMean,
|
|
527
|
-
delta,
|
|
528
|
-
ciLower,
|
|
529
|
-
ciUpper,
|
|
530
|
-
iterations,
|
|
531
|
-
alpha,
|
|
532
|
-
verdict
|
|
533
|
-
};
|
|
534
|
-
}
|
|
535
|
-
function mean(xs) {
|
|
536
|
-
if (xs.length === 0) return 0;
|
|
537
|
-
let s = 0;
|
|
538
|
-
for (const x of xs) s += x;
|
|
539
|
-
return s / xs.length;
|
|
540
|
-
}
|
|
541
|
-
function resample(xs, rng) {
|
|
542
|
-
const out = new Array(xs.length);
|
|
543
|
-
for (let i = 0; i < xs.length; i++) out[i] = xs[Math.floor(rng() * xs.length)];
|
|
544
|
-
return out;
|
|
545
|
-
}
|
|
546
|
-
function mulberry32(seed) {
|
|
547
|
-
let t = seed >>> 0;
|
|
548
|
-
return () => {
|
|
549
|
-
t += 1831565813;
|
|
550
|
-
let r = t;
|
|
551
|
-
r = Math.imul(r ^ r >>> 15, r | 1);
|
|
552
|
-
r ^= r + Math.imul(r ^ r >>> 7, r | 61);
|
|
553
|
-
return ((r ^ r >>> 14) >>> 0) / 4294967296;
|
|
554
|
-
};
|
|
555
|
-
}
|
|
556
|
-
function hashSeed(a, b) {
|
|
557
|
-
let h = 2166136261;
|
|
558
|
-
for (const x of [...a, ...b]) {
|
|
559
|
-
const view = new Float64Array([x]);
|
|
560
|
-
const bytes = new Uint8Array(view.buffer);
|
|
561
|
-
for (const byte of bytes) {
|
|
562
|
-
h ^= byte;
|
|
563
|
-
h = Math.imul(h, 16777619);
|
|
564
|
-
}
|
|
565
|
-
}
|
|
566
|
-
return h >>> 0;
|
|
567
|
-
}
|
|
568
|
-
async function judgeReplayGate(args) {
|
|
569
|
-
const concurrency = args.judgeConcurrency ?? 4;
|
|
570
|
-
const baselineScores = await scoreAll(args.baselineOutputs, args.judge, concurrency);
|
|
571
|
-
const candidateScores = await scoreAll(args.candidateOutputs, args.judge, concurrency);
|
|
572
|
-
const ci = bootstrapCi(baselineScores, candidateScores, {
|
|
573
|
-
...args.alpha !== void 0 ? { alpha: args.alpha } : {},
|
|
574
|
-
...args.iterations !== void 0 ? { iterations: args.iterations } : {},
|
|
575
|
-
...args.seed !== void 0 ? { seed: args.seed } : {}
|
|
576
|
-
});
|
|
577
|
-
return {
|
|
578
|
-
...ci,
|
|
579
|
-
baselineSamples: baselineScores.length,
|
|
580
|
-
candidateSamples: candidateScores.length
|
|
581
|
-
};
|
|
582
|
-
}
|
|
583
|
-
async function scoreAll(outputs, judge, concurrency) {
|
|
584
|
-
const results = new Array(outputs.length);
|
|
585
|
-
let next = 0;
|
|
586
|
-
async function worker() {
|
|
587
|
-
while (true) {
|
|
588
|
-
const i = next++;
|
|
589
|
-
if (i >= outputs.length) return;
|
|
590
|
-
const v = await judge(outputs[i]);
|
|
591
|
-
results[i] = Number.isFinite(v) ? v : 0;
|
|
592
|
-
}
|
|
593
|
-
}
|
|
594
|
-
await Promise.all(Array.from({ length: Math.max(1, concurrency) }, () => worker()));
|
|
595
|
-
return results;
|
|
596
|
-
}
|
|
597
|
-
|
|
598
|
-
// src/release-report.ts
|
|
599
|
-
function renderReleaseReport(scorecard, options = {}) {
|
|
600
|
-
const title = options.title ?? `Release Report: ${scorecard.target}`;
|
|
601
|
-
const lines = [];
|
|
602
|
-
lines.push(`# ${title}`);
|
|
603
|
-
lines.push("");
|
|
604
|
-
lines.push(`Status: **${scorecard.status.toUpperCase()}**`);
|
|
605
|
-
lines.push(`Promote: **${scorecard.promote ? "yes" : "no"}**`);
|
|
606
|
-
if (scorecard.candidateId) lines.push(`Candidate: \`${scorecard.candidateId}\``);
|
|
607
|
-
if (scorecard.baselineId) lines.push(`Baseline: \`${scorecard.baselineId}\``);
|
|
608
|
-
lines.push("");
|
|
609
|
-
lines.push(scorecard.summary);
|
|
610
|
-
lines.push("");
|
|
611
|
-
lines.push("## Metrics");
|
|
612
|
-
lines.push("");
|
|
613
|
-
lines.push("| Metric | Value |");
|
|
614
|
-
lines.push("|---|---:|");
|
|
615
|
-
lines.push(`| Scenarios | ${scorecard.metrics.scenarioCount} |`);
|
|
616
|
-
lines.push(`| Search runs | ${scorecard.metrics.searchRuns} |`);
|
|
617
|
-
lines.push(`| Holdout runs | ${scorecard.metrics.holdoutRuns} |`);
|
|
618
|
-
lines.push(`| Unscored runs | ${scorecard.metrics.unscoredRuns} |`);
|
|
619
|
-
lines.push(`| Terminal failures | ${scorecard.metrics.terminalFailureRuns} |`);
|
|
620
|
-
lines.push(`| Pass rate | ${pct(scorecard.metrics.passRate)} |`);
|
|
621
|
-
lines.push(`| Mean score | ${num(scorecard.metrics.meanScore)} |`);
|
|
622
|
-
lines.push(`| Search mean | ${num(scorecard.metrics.searchMeanScore)} |`);
|
|
623
|
-
lines.push(`| Holdout mean | ${num(scorecard.metrics.holdoutMeanScore)} |`);
|
|
624
|
-
lines.push(`| Overfit gap | ${num(scorecard.metrics.overfitGap)} |`);
|
|
625
|
-
lines.push(`| Mean cost | $${num(scorecard.metrics.meanCostUsd)} |`);
|
|
626
|
-
lines.push(`| p95 wall time | ${duration(scorecard.metrics.p95WallMs)} |`);
|
|
627
|
-
lines.push("");
|
|
628
|
-
if (scorecard.issues.length > 0) {
|
|
629
|
-
lines.push("## Issues");
|
|
630
|
-
lines.push("");
|
|
631
|
-
for (const issue of scorecard.issues) {
|
|
632
|
-
lines.push(`- **${issue.severity}** \`${issue.code}\` (${issue.axis}): ${issue.detail}`);
|
|
633
|
-
}
|
|
634
|
-
lines.push("");
|
|
635
|
-
}
|
|
636
|
-
const surfaces = entries(scorecard.metrics.responsibleSurfaceCounts);
|
|
637
|
-
if (surfaces.length > 0) {
|
|
638
|
-
lines.push("## Responsible Surfaces");
|
|
639
|
-
lines.push("");
|
|
640
|
-
for (const [surface, count] of surfaces) lines.push(`- ${surface}: ${count}`);
|
|
641
|
-
lines.push("");
|
|
642
|
-
}
|
|
643
|
-
const failures = entries(scorecard.metrics.failureClassCounts);
|
|
644
|
-
if (failures.length > 0) {
|
|
645
|
-
lines.push("## Failure Classes");
|
|
646
|
-
lines.push("");
|
|
647
|
-
for (const [mode, count] of failures) lines.push(`- ${mode}: ${count}`);
|
|
648
|
-
lines.push("");
|
|
649
|
-
}
|
|
650
|
-
if (options.runs && options.runs.length > 0) {
|
|
651
|
-
lines.push("## Run Summary");
|
|
652
|
-
lines.push("");
|
|
653
|
-
lines.push(
|
|
654
|
-
summaryTable([...options.runs], {
|
|
655
|
-
comparator: options.comparator ?? scorecard.baselineId ?? void 0,
|
|
656
|
-
split: "holdout"
|
|
657
|
-
}).markdown
|
|
658
|
-
);
|
|
659
|
-
lines.push("");
|
|
660
|
-
}
|
|
661
|
-
if (options.traceAnalystFindings && options.traceAnalystFindings.length > 0) {
|
|
662
|
-
lines.push("## TraceAnalyst Findings");
|
|
663
|
-
lines.push("");
|
|
664
|
-
for (const finding of options.traceAnalystFindings) lines.push(`- ${finding}`);
|
|
665
|
-
lines.push("");
|
|
666
|
-
}
|
|
667
|
-
const nextActions = options.nextActions ?? defaultNextActions(scorecard);
|
|
668
|
-
if (nextActions.length > 0) {
|
|
669
|
-
lines.push("## Next Actions");
|
|
670
|
-
lines.push("");
|
|
671
|
-
for (const action of nextActions) lines.push(`- ${action}`);
|
|
672
|
-
lines.push("");
|
|
673
|
-
}
|
|
674
|
-
return `${lines.join("\n").trimEnd()}
|
|
675
|
-
`;
|
|
676
|
-
}
|
|
677
|
-
function defaultNextActions(scorecard) {
|
|
678
|
-
if (scorecard.promote) return ["Promote the candidate and keep canaries enabled."];
|
|
679
|
-
return scorecard.issues.filter((issue) => issue.severity === "critical").map((issue) => `Resolve ${issue.code}: ${issue.detail}`);
|
|
680
|
-
}
|
|
681
|
-
function entries(values) {
|
|
682
|
-
return Object.entries(values).filter(([, count]) => count > 0).sort((a, b) => b[1] - a[1] || a[0].localeCompare(b[0]));
|
|
683
|
-
}
|
|
684
|
-
function pct(value) {
|
|
685
|
-
return value === null ? "n/a" : `${(value * 100).toFixed(1)}%`;
|
|
686
|
-
}
|
|
687
|
-
function num(value) {
|
|
688
|
-
return value === null ? "n/a" : value.toFixed(3);
|
|
689
|
-
}
|
|
690
|
-
function duration(value) {
|
|
691
|
-
return value === null ? "n/a" : `${Math.round(value)} ms`;
|
|
692
|
-
}
|
|
693
|
-
|
|
694
|
-
export {
|
|
695
|
-
evaluateReleaseConfidence,
|
|
696
|
-
assertReleaseConfidence,
|
|
697
|
-
bootstrapCi,
|
|
698
|
-
judgeReplayGate,
|
|
699
|
-
renderReleaseReport
|
|
700
|
-
};
|
|
701
|
-
//# sourceMappingURL=chunk-JQSF5DQT.js.map
|