@tangle-network/agent-eval 2.0.7 → 2.0.9

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.
Files changed (285) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/adapters/http.d.ts +2 -2
  3. package/dist/{agent-profile-CRdalpZv.d.ts → agent-profile-ORN4aArD.d.ts} +5 -5
  4. package/dist/{agent-profile-CRdalpZv.d.ts.map → agent-profile-ORN4aArD.d.ts.map} +1 -1
  5. package/dist/analyst/index.d.ts +14 -13
  6. package/dist/analyst/index.d.ts.map +1 -1
  7. package/dist/analyst/index.js +9 -9
  8. package/dist/{analyze-runs-C_9cXPZn.js → analyze-runs-CE_5VKh2.js} +6 -5
  9. package/dist/{analyze-runs-C_9cXPZn.js.map → analyze-runs-CE_5VKh2.js.map} +1 -1
  10. package/dist/analyze-runs-DT693FJ7.d.ts +65 -0
  11. package/dist/analyze-runs-DT693FJ7.d.ts.map +1 -0
  12. package/dist/app-grade/index.d.ts +4 -4
  13. package/dist/app-grade/index.js +1 -1
  14. package/dist/{benchmark-command-DkBMUDwy.js → benchmark-command-DLg8E4y8.js} +9 -6
  15. package/dist/benchmark-command-DLg8E4y8.js.map +1 -0
  16. package/dist/benchmarks/index.d.ts +4 -4
  17. package/dist/benchmarks/index.js +4 -4
  18. package/dist/builder-eval/index.js +2 -2
  19. package/dist/calibration-CrORXMWx.d.ts +128 -0
  20. package/dist/calibration-CrORXMWx.d.ts.map +1 -0
  21. package/dist/{calibration-Cfoup0xz.js → calibration-Dz8mQb5P.js} +2 -2
  22. package/dist/{calibration-Cfoup0xz.js.map → calibration-Dz8mQb5P.js.map} +1 -1
  23. package/dist/campaign/index.d.ts +8 -8
  24. package/dist/campaign/index.js +12 -11
  25. package/dist/{campaign-DfSWSreo.js → campaign-C_S3MOYa.js} +1589 -14
  26. package/dist/campaign-C_S3MOYa.js.map +1 -0
  27. package/dist/{campaign-evidence-D_oBFfLc.js → campaign-evidence-BTfzZo1u.js} +4 -4
  28. package/dist/{campaign-evidence-D_oBFfLc.js.map → campaign-evidence-BTfzZo1u.js.map} +1 -1
  29. package/dist/{campaign-evidence-BojANgU7.d.ts → campaign-evidence-CM4FBOkX.d.ts} +5 -5
  30. package/dist/{campaign-evidence-BojANgU7.d.ts.map → campaign-evidence-CM4FBOkX.d.ts.map} +1 -1
  31. package/dist/{cluster-Bj90LK-1.d.ts → chat-client-uQNXGuO4.d.ts} +3 -240
  32. package/dist/chat-client-uQNXGuO4.d.ts.map +1 -0
  33. package/dist/cli.js +5 -5
  34. package/dist/cluster-C-K0N2br.d.ts +241 -0
  35. package/dist/cluster-C-K0N2br.d.ts.map +1 -0
  36. package/dist/{cluster-bootstrap-DPzVy3_K.js → cluster-bootstrap-DXbnIdm8.js} +3 -2
  37. package/dist/{cluster-bootstrap-DPzVy3_K.js.map → cluster-bootstrap-DXbnIdm8.js.map} +1 -1
  38. package/dist/{completion-verifier-Cy38EpGE.d.ts → completion-verifier-C7wipJOK.d.ts} +2 -2
  39. package/dist/{completion-verifier-Cy38EpGE.d.ts.map → completion-verifier-C7wipJOK.d.ts.map} +1 -1
  40. package/dist/contract/index.d.ts +14 -12
  41. package/dist/contract/index.js +13 -11
  42. package/dist/contract/index.js.map +1 -1
  43. package/dist/{decision-point-C46p-p9v.js → decision-point-CfqtnGop.js} +3 -3
  44. package/dist/{decision-point-C46p-p9v.js.map → decision-point-CfqtnGop.js.map} +1 -1
  45. package/dist/{default-registry-xoX0PMCb.d.ts → default-registry-Bskl2HzV.d.ts} +6 -6
  46. package/dist/{default-registry-xoX0PMCb.d.ts.map → default-registry-Bskl2HzV.d.ts.map} +1 -1
  47. package/dist/{default-registry-BWFPtmuI.js → default-registry-kps1SOaD.js} +2 -2
  48. package/dist/{default-registry-BWFPtmuI.js.map → default-registry-kps1SOaD.js.map} +1 -1
  49. package/dist/define-agent-eval-Dnh4jXLX.js +96 -0
  50. package/dist/define-agent-eval-Dnh4jXLX.js.map +1 -0
  51. package/dist/define-agent-eval-tu3anVlk.d.ts +52 -0
  52. package/dist/define-agent-eval-tu3anVlk.d.ts.map +1 -0
  53. package/dist/diagnosis/index.d.ts +3 -3
  54. package/dist/diagnosis/index.js +1 -1
  55. package/dist/{dspy-rlm-engine-r7YpKLhS.js → dspy-rlm-engine-DQbPdT_o.js} +2 -2
  56. package/dist/{dspy-rlm-engine-r7YpKLhS.js.map → dspy-rlm-engine-DQbPdT_o.js.map} +1 -1
  57. package/dist/{emitter-BjW3NnX-.js → emitter-xN9wGTVw.js} +9 -2
  58. package/dist/{emitter-BjW3NnX-.js.map → emitter-xN9wGTVw.js.map} +1 -1
  59. package/dist/{eval-campaign-Cyk-tkLh.js → eval-campaign-DswSn7Gm.js} +3 -3
  60. package/dist/{eval-campaign-Cyk-tkLh.js.map → eval-campaign-DswSn7Gm.js.map} +1 -1
  61. package/dist/{evaluation-X5E22NQK.d.ts → evaluation-C4-tf3Z_.d.ts} +4 -4
  62. package/dist/{evaluation-X5E22NQK.d.ts.map → evaluation-C4-tf3Z_.d.ts.map} +1 -1
  63. package/dist/evaluation.d.ts +1 -1
  64. package/dist/{exact-types-DjuabhUV.d.ts → exact-types-CUsSMW3n.d.ts} +2 -2
  65. package/dist/{exact-types-DjuabhUV.d.ts.map → exact-types-CUsSMW3n.d.ts.map} +1 -1
  66. package/dist/{execution-insight-CE20Bxq0.d.ts → execution-insight-YihQrSqd.d.ts} +2 -2
  67. package/dist/{execution-insight-CE20Bxq0.d.ts.map → execution-insight-YihQrSqd.d.ts.map} +1 -1
  68. package/dist/experiment/index.d.ts +5 -5
  69. package/dist/experiment/index.js +10 -184
  70. package/dist/experiment/index.js.map +1 -1
  71. package/dist/{external-optimizer-process-4QdcF7Kd.js → external-optimizer-process-CVi1x2nb.js} +2 -2
  72. package/dist/{external-optimizer-process-4QdcF7Kd.js.map → external-optimizer-process-CVi1x2nb.js.map} +1 -1
  73. package/dist/{external-optimizer-subprocess-BW0ZWUUr.js → external-optimizer-subprocess-mV-2swJI.js} +3 -357
  74. package/dist/external-optimizer-subprocess-mV-2swJI.js.map +1 -0
  75. package/dist/{feedback-trajectory-BMkJezPc.d.ts → feedback-trajectory-D7hgL6y5.d.ts} +3 -3
  76. package/dist/{feedback-trajectory-BMkJezPc.d.ts.map → feedback-trajectory-D7hgL6y5.d.ts.map} +1 -1
  77. package/dist/finding-scope-B_As3F_v.js +359 -0
  78. package/dist/finding-scope-B_As3F_v.js.map +1 -0
  79. package/dist/{findings-store-DV8WA5nD.js → findings-store-CZy5kUDo.js} +2 -2
  80. package/dist/{findings-store-DV8WA5nD.js.map → findings-store-CZy5kUDo.js.map} +1 -1
  81. package/dist/fuzz.js +1 -1
  82. package/dist/{index-DKpMyD_Z.d.ts → index--vDCtdaj.d.ts} +7 -7
  83. package/dist/{index-DKpMyD_Z.d.ts.map → index--vDCtdaj.d.ts.map} +1 -1
  84. package/dist/{index-CKjqN9_U.d.ts → index-CIqYaySd.d.ts} +89 -3
  85. package/dist/index-CIqYaySd.d.ts.map +1 -0
  86. package/dist/{index-C6TG1LwA.d.ts → index-Cav3abKy.d.ts} +256 -131
  87. package/dist/index-Cav3abKy.d.ts.map +1 -0
  88. package/dist/{index-DAFZRMlF.d.ts → index-DmMHTDjT.d.ts} +10 -8
  89. package/dist/index-DmMHTDjT.d.ts.map +1 -0
  90. package/dist/{index-BqAPIToS.d.ts → index-Er8TKQ3q.d.ts} +3 -3
  91. package/dist/{index-BqAPIToS.d.ts.map → index-Er8TKQ3q.d.ts.map} +1 -1
  92. package/dist/{index-xEM_SoCl.d.ts → index-moZnazVj.d.ts} +22 -20
  93. package/dist/index-moZnazVj.d.ts.map +1 -0
  94. package/dist/index.d.ts +33 -29
  95. package/dist/index.js +23 -20
  96. package/dist/index.js.map +1 -1
  97. package/dist/{analyze-runs-xjKBBqIB.d.ts → insight-report-DYofCMLx.d.ts} +4 -64
  98. package/dist/insight-report-DYofCMLx.d.ts.map +1 -0
  99. package/dist/{integrity-B9320cw1.d.ts → integrity-BJGstiCh.d.ts} +2 -2
  100. package/dist/{integrity-B9320cw1.d.ts.map → integrity-BJGstiCh.d.ts.map} +1 -1
  101. package/dist/{judge-gate-DqlzOBOm.js → judge-gate-DANg5FLq.js} +2 -2
  102. package/dist/{judge-gate-DqlzOBOm.js.map → judge-gate-DANg5FLq.js.map} +1 -1
  103. package/dist/llm-judge-DFoSy4Qn.js +476 -0
  104. package/dist/llm-judge-DFoSy4Qn.js.map +1 -0
  105. package/dist/{matrix-CqZSpwgN.d.ts → matrix-OgdWQBQa.d.ts} +6 -2
  106. package/dist/matrix-OgdWQBQa.d.ts.map +1 -0
  107. package/dist/measure-validity-plan-B1_qYlsk.d.ts +143 -0
  108. package/dist/measure-validity-plan-B1_qYlsk.d.ts.map +1 -0
  109. package/dist/measure-validity-plan-t0YQRzJQ.js +117 -0
  110. package/dist/measure-validity-plan-t0YQRzJQ.js.map +1 -0
  111. package/dist/meta-eval/index.d.ts +5 -3
  112. package/dist/meta-eval/index.js +664 -14
  113. package/dist/meta-eval/index.js.map +1 -1
  114. package/dist/multishot/golden/index.d.ts +1 -1
  115. package/dist/multishot/index.d.ts +458 -4
  116. package/dist/multishot/index.d.ts.map +1 -1
  117. package/dist/multishot/index.js +926 -47
  118. package/dist/multishot/index.js.map +1 -1
  119. package/dist/openapi.json +1 -1
  120. package/dist/{llm-judge-DQJTQx01.js → optimization-method-D4CpYsVA.js} +18 -482
  121. package/dist/optimization-method-D4CpYsVA.js.map +1 -0
  122. package/dist/{outcome-observations-DL3CC8w1.js → outcome-observations-DEh8_V_P.js} +31 -6
  123. package/dist/outcome-observations-DEh8_V_P.js.map +1 -0
  124. package/dist/outcome-store-CHtuvstd.d.ts +56 -0
  125. package/dist/outcome-store-CHtuvstd.d.ts.map +1 -0
  126. package/dist/{paired-arms-DZhH3FGu.js → paired-arms-B6EXnI47.js} +3 -2
  127. package/dist/{paired-arms-DZhH3FGu.js.map → paired-arms-B6EXnI47.js.map} +1 -1
  128. package/dist/{paired-promotion-decision-ChHBuuHV.d.ts → paired-promotion-decision-DuvRdnsW.d.ts} +2 -2
  129. package/dist/{paired-promotion-decision-ChHBuuHV.d.ts.map → paired-promotion-decision-DuvRdnsW.d.ts.map} +1 -1
  130. package/dist/{paired-promotion-decision-Dn3-jaq4.js → paired-promotion-decision-xYe881cD.js} +3 -2
  131. package/dist/{paired-promotion-decision-Dn3-jaq4.js.map → paired-promotion-decision-xYe881cD.js.map} +1 -1
  132. package/dist/{paired-promotion-power-BlzXdgMD.js → paired-promotion-power-DirShsIs.js} +3 -3
  133. package/dist/{paired-promotion-power-BlzXdgMD.js.map → paired-promotion-power-DirShsIs.js.map} +1 -1
  134. package/dist/paired-tests-CXcD_B80.js +688 -0
  135. package/dist/paired-tests-CXcD_B80.js.map +1 -0
  136. package/dist/pareto-DIVE5D0T.js +81 -0
  137. package/dist/pareto-DIVE5D0T.js.map +1 -0
  138. package/dist/pipelines/index.d.ts +2 -1
  139. package/dist/pipelines/index.d.ts.map +1 -1
  140. package/dist/pipelines/index.js +1 -1
  141. package/dist/{sequential-BphITa5b.js → power-DTg6u30w.js} +181 -4
  142. package/dist/power-DTg6u30w.js.map +1 -0
  143. package/dist/{prime-protocol-Cv6_47rh.d.ts → prime-protocol-Jm2pWh--.d.ts} +2 -2
  144. package/dist/{prime-protocol-Cv6_47rh.d.ts.map → prime-protocol-Jm2pWh--.d.ts.map} +1 -1
  145. package/dist/{promotion-gate-CGkxh36r.d.ts → promotion-gate-BXgcORnM.d.ts} +2 -2
  146. package/dist/{promotion-gate-CGkxh36r.d.ts.map → promotion-gate-BXgcORnM.d.ts.map} +1 -1
  147. package/dist/{promotion-policy-CxDIh-9p.js → promotion-policy-Z5E-C32U.js} +4 -4
  148. package/dist/{promotion-policy-CxDIh-9p.js.map → promotion-policy-Z5E-C32U.js.map} +1 -1
  149. package/dist/{proposal-findings-DedMih-u.js → proposal-findings-CfRFCFXS.js} +2 -2
  150. package/dist/{proposal-findings-DedMih-u.js.map → proposal-findings-CfRFCFXS.js.map} +1 -1
  151. package/dist/{registry-CIjC6SdV.d.ts → registry-DEZDECdr.d.ts} +4 -4
  152. package/dist/{registry-CIjC6SdV.d.ts.map → registry-DEZDECdr.d.ts.map} +1 -1
  153. package/dist/{release-confidence-BLHOMK5Q.js → release-confidence-Cndq1hwi.js} +2 -2
  154. package/dist/{release-confidence-BLHOMK5Q.js.map → release-confidence-Cndq1hwi.js.map} +1 -1
  155. package/dist/reporting.d.ts +5 -5
  156. package/dist/reporting.js +6 -5
  157. package/dist/reporting.js.map +1 -1
  158. package/dist/{research-report-D6XIK0eK.d.ts → research-report-CIgUe1lv.d.ts} +2 -2
  159. package/dist/{research-report-D6XIK0eK.d.ts.map → research-report-CIgUe1lv.d.ts.map} +1 -1
  160. package/dist/{researcher---DhHG4J.d.ts → researcher-CY_byuZl.d.ts} +4 -4
  161. package/dist/{researcher---DhHG4J.d.ts.map → researcher-CY_byuZl.d.ts.map} +1 -1
  162. package/dist/{reward-hacking-DKAflk2c.js → reward-hacking-DMTm1OBd.js} +2 -2
  163. package/dist/{reward-hacking-DKAflk2c.js.map → reward-hacking-DMTm1OBd.js.map} +1 -1
  164. package/dist/rl.d.ts +9 -8
  165. package/dist/rl.d.ts.map +1 -1
  166. package/dist/rl.js +11 -10
  167. package/dist/rl.js.map +1 -1
  168. package/dist/rollout/index.d.ts +2 -2
  169. package/dist/{rubric-predictive-validity--6z0q8s6.js → rubric-predictive-validity-BXJ92Jp_.js} +3 -9
  170. package/dist/rubric-predictive-validity-BXJ92Jp_.js.map +1 -0
  171. package/dist/{rubric-predictive-validity-C9wc7f_D.d.ts → rubric-predictive-validity-DH94_0Q1.d.ts} +3 -56
  172. package/dist/rubric-predictive-validity-DH94_0Q1.d.ts.map +1 -0
  173. package/dist/{run-improvement-loop-BfwOUudy.d.ts → run-improvement-loop-BaPDVbW8.d.ts} +384 -11
  174. package/dist/run-improvement-loop-BaPDVbW8.d.ts.map +1 -0
  175. package/dist/{run-record-Bqg0NZ_e.js → run-record-CuO8ErrI.js} +3 -2
  176. package/dist/run-record-CuO8ErrI.js.map +1 -0
  177. package/dist/{runtime-rollouts-drQynu3t.js → runtime-rollouts-Vv-BAqmq.js} +2 -2
  178. package/dist/{runtime-rollouts-drQynu3t.js.map → runtime-rollouts-Vv-BAqmq.js.map} +1 -1
  179. package/dist/search/index.d.ts +2 -2
  180. package/dist/search/index.js +2 -2
  181. package/dist/{search-kernel-DJq9bUDU.d.ts → search-kernel-BzTeb89p.d.ts} +3 -3
  182. package/dist/{search-kernel-DJq9bUDU.d.ts.map → search-kernel-BzTeb89p.d.ts.map} +1 -1
  183. package/dist/{pareto-Bg75Gajo.js → search-kernel-DOPW08Hx.js} +6 -88
  184. package/dist/search-kernel-DOPW08Hx.js.map +1 -0
  185. package/dist/{search-summary-B1x1Vmzh.js → search-summary-CYOHZAAy.js} +4 -4
  186. package/dist/{search-summary-B1x1Vmzh.js.map → search-summary-CYOHZAAy.js.map} +1 -1
  187. package/dist/{define-agent-eval-B6uE3gNu.js → self-improve-CIFqccHV.js} +8 -97
  188. package/dist/self-improve-CIFqccHV.js.map +1 -0
  189. package/dist/{define-agent-eval-Cjc0wWnO.d.ts → self-improve-DY8ZY4lY.d.ts} +8 -54
  190. package/dist/self-improve-DY8ZY4lY.d.ts.map +1 -0
  191. package/dist/{sequential-BhbTSxpt.d.ts → sequential-B9iROM1S.d.ts} +2 -2
  192. package/dist/{sequential-BhbTSxpt.d.ts.map → sequential-B9iROM1S.d.ts.map} +1 -1
  193. package/dist/{sequential-ux_XrjBf.js → sequential-tZjGysXY.js} +3 -3
  194. package/dist/{sequential-ux_XrjBf.js.map → sequential-tZjGysXY.js.map} +1 -1
  195. package/dist/{skillopt-optimization-method-D_swD0Cy.js → skillopt-optimization-method-CbHBkopM.js} +9 -8
  196. package/dist/{skillopt-optimization-method-D_swD0Cy.js.map → skillopt-optimization-method-CbHBkopM.js.map} +1 -1
  197. package/dist/{statistical-heldout-CaS4T-43.js → statistical-heldout-C7Jjo5nP.js} +3 -3
  198. package/dist/{statistical-heldout-CaS4T-43.js.map → statistical-heldout-C7Jjo5nP.js.map} +1 -1
  199. package/dist/{statistics-DSidA5I2.js → statistics-BPl13X3G.js} +208 -700
  200. package/dist/statistics-BPl13X3G.js.map +1 -0
  201. package/dist/statistics.d.ts +3 -3
  202. package/dist/statistics.js +3 -2
  203. package/dist/{store-tool-spans-DniaFwjM.d.ts → store-tool-spans-Dq8r0PbJ.d.ts} +4 -4
  204. package/dist/{store-tool-spans-DniaFwjM.d.ts.map → store-tool-spans-Dq8r0PbJ.d.ts.map} +1 -1
  205. package/dist/{summary-report-CI4J6gxU.js → summary-report-DzbnK81K.js} +15 -7
  206. package/dist/summary-report-DzbnK81K.js.map +1 -0
  207. package/dist/summary-report-figures-CJHygLgw.d.ts.map +1 -1
  208. package/dist/supervisor-run/index.d.ts +1 -1
  209. package/dist/supervisor-run/index.js +1 -1
  210. package/dist/{systemone-DzY-2Zri.d.ts → systemone-BuSZTI88.d.ts} +8 -7
  211. package/dist/systemone-BuSZTI88.d.ts.map +1 -0
  212. package/dist/{systemone-review-CXecR_m-.d.ts → systemone-review-mlfxWdLz.d.ts} +2 -2
  213. package/dist/{systemone-review-CXecR_m-.d.ts.map → systemone-review-mlfxWdLz.d.ts.map} +1 -1
  214. package/dist/systemone.d.ts +3 -3
  215. package/dist/systemone.js +1 -1
  216. package/dist/{tool-groups-DF6OqhoG.d.ts → tool-groups-PNDX8fd-.d.ts} +2 -2
  217. package/dist/tool-groups-PNDX8fd-.d.ts.map +1 -0
  218. package/dist/{tool-waste-u7JJ_BlE.js → tool-waste-783VCo1y.js} +3 -2
  219. package/dist/{tool-waste-u7JJ_BlE.js.map → tool-waste-783VCo1y.js.map} +1 -1
  220. package/dist/tool-waste-B01AMpID.d.ts +121 -0
  221. package/dist/tool-waste-B01AMpID.d.ts.map +1 -0
  222. package/dist/{trace-questions-DO8y3J-E.d.ts → trace-questions-DBtr4jWi.d.ts} +2 -2
  223. package/dist/{trace-questions-DO8y3J-E.d.ts.map → trace-questions-DBtr4jWi.d.ts.map} +1 -1
  224. package/dist/trace-repair/index.d.ts +1 -1
  225. package/dist/trace-repair/index.js +1 -1
  226. package/dist/traces.d.ts +4 -4
  227. package/dist/traces.js +1 -1
  228. package/dist/trajectory-B3o6Ald_.d.ts +100 -0
  229. package/dist/trajectory-B3o6Ald_.d.ts.map +1 -0
  230. package/dist/trajectory-replay/index.js +1 -1
  231. package/dist/{tree-DQMlcNFI.js → tree-CtlQQL1w.js} +6 -4
  232. package/dist/{tree-DQMlcNFI.js.map → tree-CtlQQL1w.js.map} +1 -1
  233. package/dist/{types-BMSDkS8l.d.ts → types-BO948H-U.d.ts} +7 -4
  234. package/dist/{types-BMSDkS8l.d.ts.map → types-BO948H-U.d.ts.map} +1 -1
  235. package/dist/{types-fuOwNq1C.d.ts → types-CKNAzCSA.d.ts} +3 -2
  236. package/dist/types-CKNAzCSA.d.ts.map +1 -0
  237. package/dist/{types-BLv2Ngla.d.ts → types-D-WF1KM3.d.ts} +2 -2
  238. package/dist/{types-BLv2Ngla.d.ts.map → types-D-WF1KM3.d.ts.map} +1 -1
  239. package/dist/types-DK4vNv5q.js.map +1 -1
  240. package/dist/{types-D_PfKC59.d.ts → types-DbeIGi73.d.ts} +2 -2
  241. package/dist/{types-D_PfKC59.d.ts.map → types-DbeIGi73.d.ts.map} +1 -1
  242. package/dist/wire/index.d.ts +4 -4
  243. package/dist/world/index.d.ts +529 -0
  244. package/dist/world/index.d.ts.map +1 -0
  245. package/dist/world/index.js +1356 -0
  246. package/dist/world/index.js.map +1 -0
  247. package/docs/campaign-proposers.md +7 -0
  248. package/docs/concepts.md +2 -0
  249. package/docs/design/statistics-decisions.md +31 -0
  250. package/docs/eval-surface-map.md +4 -1
  251. package/docs/feature-guide.md +2 -0
  252. package/docs/multi-turn-optimization.md +80 -0
  253. package/docs/outcome-validity.md +69 -0
  254. package/docs/public-api.md +86 -31
  255. package/docs/world.md +104 -0
  256. package/package.json +6 -1
  257. package/dist/analyze-runs-xjKBBqIB.d.ts.map +0 -1
  258. package/dist/benchmark-command-DkBMUDwy.js.map +0 -1
  259. package/dist/campaign-DfSWSreo.js.map +0 -1
  260. package/dist/cluster-Bj90LK-1.d.ts.map +0 -1
  261. package/dist/define-agent-eval-B6uE3gNu.js.map +0 -1
  262. package/dist/define-agent-eval-Cjc0wWnO.d.ts.map +0 -1
  263. package/dist/external-optimizer-subprocess-BW0ZWUUr.js.map +0 -1
  264. package/dist/index-C6TG1LwA.d.ts.map +0 -1
  265. package/dist/index-CKjqN9_U.d.ts.map +0 -1
  266. package/dist/index-DAFZRMlF.d.ts.map +0 -1
  267. package/dist/index-xEM_SoCl.d.ts.map +0 -1
  268. package/dist/interval-CWyxqDpE.d.ts +0 -43
  269. package/dist/interval-CWyxqDpE.d.ts.map +0 -1
  270. package/dist/llm-judge-DQJTQx01.js.map +0 -1
  271. package/dist/matrix-CqZSpwgN.d.ts.map +0 -1
  272. package/dist/outcome-observations-DL3CC8w1.js.map +0 -1
  273. package/dist/pareto-Bg75Gajo.js.map +0 -1
  274. package/dist/rubric-predictive-validity--6z0q8s6.js.map +0 -1
  275. package/dist/rubric-predictive-validity-C9wc7f_D.d.ts.map +0 -1
  276. package/dist/run-improvement-loop-BfwOUudy.d.ts.map +0 -1
  277. package/dist/run-record-Bqg0NZ_e.js.map +0 -1
  278. package/dist/sequential-BphITa5b.js.map +0 -1
  279. package/dist/statistics-DSidA5I2.js.map +0 -1
  280. package/dist/summary-report-CI4J6gxU.js.map +0 -1
  281. package/dist/systemone-DzY-2Zri.d.ts.map +0 -1
  282. package/dist/tool-groups-DF6OqhoG.d.ts.map +0 -1
  283. package/dist/tool-waste-CIhtU1ad.d.ts +0 -217
  284. package/dist/tool-waste-CIhtU1ad.d.ts.map +0 -1
  285. package/dist/types-fuOwNq1C.d.ts.map +0 -1
@@ -1 +0,0 @@
1
- {"version":3,"file":"summary-report-CI4J6gxU.js","names":["avg"],"sources":["../src/research-report-render.ts","../src/research-report-analysis.ts","../src/summary-report-evidence.ts","../src/summary-report-figures.ts","../src/research-report.ts"],"sourcesContent":["/** Markdown research reports and their shared numeric text formatting. */\n\nimport type { FailureClusterReport } from './pipelines/failure-cluster'\nimport type {\n ResearchReportCandidate,\n ResearchReportMethodology,\n ResearchReportRecommendation,\n} from './research-report'\nimport type {\n GainDistributionFigureSpec,\n ParetoFigureSpec,\n SummaryTable,\n} from './summary-report-figures'\n\nexport function renderResearchMarkdown(report: {\n title: string\n generatedAt: string\n split: 'search' | 'holdout'\n comparator: string | null\n executiveSummary: string[]\n recommendation: ResearchReportRecommendation\n candidates: ResearchReportCandidate[]\n summary: SummaryTable\n pareto: ParetoFigureSpec\n gains: GainDistributionFigureSpec[]\n rope: { low: number; high: number } | null\n runFingerprint: string\n preregistrationHash: string | null\n methodology: ResearchReportMethodology\n failureClusters?: FailureClusterReport\n}): string {\n const lines: string[] = []\n lines.push(`# ${report.title}`)\n lines.push('')\n lines.push(`**Generated:** ${report.generatedAt}`)\n lines.push(`**Primary split:** ${report.split}`)\n lines.push(`**Comparator:** ${report.comparator ?? 'not configured'}`)\n lines.push(`**ROPE:** ${report.rope ? formatRope(report.rope) : 'not configured'}`)\n lines.push(`**Run fingerprint:** \\`${report.runFingerprint}\\``)\n lines.push(\n `**Preregistration:** ${report.preregistrationHash ? `\\`${report.preregistrationHash}\\`` : 'none'}`,\n )\n lines.push('')\n lines.push('## Executive Summary')\n lines.push('')\n for (const item of report.executiveSummary) lines.push(`- ${item}`)\n lines.push('')\n lines.push('## Recommendation')\n lines.push('')\n lines.push(`**Decision:** ${report.recommendation.decision}`)\n lines.push(`**Candidate:** ${report.recommendation.candidateId ?? 'N/A'}`)\n lines.push('')\n lines.push('### Rationale')\n lines.push('')\n for (const item of report.recommendation.rationale) lines.push(`- ${item}`)\n lines.push('')\n lines.push('### Risks')\n lines.push('')\n for (const item of report.recommendation.risks.length\n ? report.recommendation.risks\n : ['No material report-level risks detected.']) {\n lines.push(`- ${item}`)\n }\n lines.push('')\n lines.push('### Next Actions')\n lines.push('')\n for (const item of report.recommendation.nextActions) lines.push(`- ${item}`)\n lines.push('')\n lines.push('## Candidate Decision Table')\n lines.push('')\n lines.push(\n '| Candidate | Decision | Mean | Δ̄ | Pr(Δ>0) | q | dz | Paired N | Median Gain CI | MDE | Pareto | Gate |',\n )\n lines.push('|---|---|---:|---:|---:|---:|---:|---:|---|---:|---|---|')\n for (const c of report.candidates) {\n const delta = c.meanDeltaVsComparator === null ? '-' : signed(c.meanDeltaVsComparator)\n const prGt = c.prGreaterThanZero === null ? '-' : c.prGreaterThanZero.toFixed(3)\n const q = c.qValue !== null ? c.qValue.toFixed(4) : '-'\n const d = c.cohensD !== null ? c.cohensD.toFixed(3) : '-'\n const gain = c.gainCi ? `[${fmt(c.gainCi.low)}, ${fmt(c.gainCi.high)}]` : '-'\n const mde = c.mde === null || !Number.isFinite(c.mde) ? '-' : fmt(c.mde)\n lines.push(\n `| ${c.candidateId} | ${c.decision} | ${fmt(c.mean)} | ${delta} | ${prGt} | ${q} | ${d} | ${c.pairedN} | ${gain} | ${mde} | ${c.onParetoFrontier ? 'yes' : 'no'} | ${c.gate ?? '-'} |`,\n )\n }\n lines.push('')\n lines.push('## Statistical Summary')\n lines.push('')\n lines.push(report.summary.markdown)\n lines.push('')\n lines.push('## Methodology')\n lines.push('')\n lines.push('### Assumptions')\n lines.push('')\n for (const item of report.methodology.assumptions) lines.push(`- ${item}`)\n lines.push('')\n lines.push('### Methods')\n lines.push('')\n for (const item of report.methodology.methods) lines.push(`- ${item}`)\n lines.push('')\n lines.push('### Alternatives Considered')\n lines.push('')\n for (const item of report.methodology.alternatives) lines.push(`- ${item}`)\n lines.push('')\n lines.push('### When NOT To Apply')\n lines.push('')\n for (const item of report.methodology.whenNotToApply) lines.push(`- ${item}`)\n lines.push('')\n lines.push('### Citations')\n lines.push('')\n for (const item of report.methodology.citations) lines.push(`- ${item}`)\n lines.push('')\n lines.push('## Chart Specs')\n lines.push('')\n lines.push(\n 'The report carries JSON chart specs for Pareto cost/quality and paired gain histograms.',\n )\n lines.push('')\n lines.push('```json')\n lines.push(JSON.stringify({ pareto: report.pareto, gains: report.gains }, null, 2))\n lines.push('```')\n if (report.failureClusters) {\n lines.push('')\n lines.push('## Failure Clusters')\n lines.push('')\n lines.push('| Failure Class | Runs | Scenarios | Tool | Example |')\n lines.push('|---|---:|---:|---|---|')\n for (const c of report.failureClusters.clusters.slice(0, 10)) {\n lines.push(\n `| ${c.failureClass} | ${c.runCount} | ${c.scenarioIds.length} | ${c.toolName ?? '-'} | ${escapePipes(c.exampleError ?? c.exampleRunId)} |`,\n )\n }\n }\n return lines.join('\\n')\n}\n\nfunction escapePipes(s: string): string {\n return s.replace(/\\|/g, '\\\\|')\n}\n\nfunction signed(x: number): string {\n return `${x >= 0 ? '+' : ''}${fmt(x)}`\n}\n\nexport function formatRope(rope: { low: number; high: number }): string {\n return `[${fmt(rope.low)}, ${fmt(rope.high)}]`\n}\n\nexport function fmt(x: number): string {\n if (!Number.isFinite(x)) return String(x)\n return x.toFixed(4)\n}\n","/** Evidence-based report verdicts, recommendations, and methodology. */\n\nimport type { HeldOutGateDecision } from './held-out-gate'\nimport type { FailureClusterReport } from './pipelines/failure-cluster'\nimport type {\n ResearchReportCandidate,\n ResearchReportDecision,\n ResearchReportMethodology,\n ResearchReportRecommendation,\n} from './research-report'\nimport { fmt, formatRope } from './research-report-render'\nimport type { pairedPosterior } from './summary-report-evidence'\nimport type { ParetoPoint, SummaryTableRow } from './summary-report-figures'\n\n/**\n * Hard floor below which a paired comparison is treated as uninformative\n * regardless of `minPairs`. Mirrors the lower limit on Wilcoxon signed-rank\n * exact tables; below this the test has no power to separate effect sizes.\n */\nexport const RESEARCH_REPORT_HARD_PAIR_FLOOR = 6\n\nexport function buildMethodology(ctx: {\n split: 'search' | 'holdout'\n comparator: string | null\n fdr: number\n minPairs: number\n rope: { low: number; high: number } | null\n confidence: number\n mdePower: number\n mdeAlpha: number\n}): ResearchReportMethodology {\n const assumptions: string[] = [\n 'Pairs are matched by (experimentId, scenarioId, seed); input order does not affect the comparison.',\n 'Paired deltas are exchangeable conditional on the matched scenario — no mid-run distribution shift.',\n `Decisions are pre-specified at fdr=${ctx.fdr}, minPairs=${ctx.minPairs}, confidence=${ctx.confidence}; deviating from these post-hoc invalidates the false-discovery control.`,\n ]\n if (ctx.rope) {\n assumptions.push(\n `The Region of Practical Equivalence ${formatRope(ctx.rope)} is supplied by the domain owner; equivalent verdicts are only meaningful if that range is treated as the standing definition of \"no material difference.\"`,\n )\n }\n if (ctx.comparator === null) {\n assumptions.push('No comparator was configured; this run is descriptive, not causal.')\n }\n const methods: string[] = [\n \"Marginal scores summarised with BH-FDR-adjusted Wilcoxon signed-rank q-values and paired Cohen's dz via summaryTable.\",\n 'Paired evidence summarised with a frequentist bootstrap CI on the median delta and a Dirichlet-weight Bayesian bootstrap for Pr(Δ>0) and Pr(Δ∈ROPE) on the mean delta.',\n `Minimum detectable effect reported per candidate at α=${ctx.mdeAlpha} (two-sided), power=${ctx.mdePower}, standardised by the observed paired-delta SD.`,\n 'Pareto frontier flagged as a separate axis (cost vs quality); a candidate can be on-frontier without winning the paired test.',\n 'Held-out gate decisions, when supplied, override the statistical verdict in the reject direction.',\n ]\n const alternatives: string[] = [\n 'Paired t-test rejected: not robust to the heavy-tailed score distributions common in agent benchmarks.',\n 'Unpaired Mann–Whitney rejected: matched scenarios make pairing free; unpaired throws away that variance reduction.',\n 'Sequential / always-valid inference (e-values, mSPRT) is the right tool for iterative sweeps and is out of scope for this single-look report — preregister and run once, or wrap this report in an alpha-spending schedule.',\n 'Hierarchical Bayesian shrinkage across many candidates is future work; the current ranking uses raw paired statistics.',\n ]\n const whenNotToApply: string[] = [\n `Paired N below ${RESEARCH_REPORT_HARD_PAIR_FLOOR} on any candidate — the bootstrap CI is degenerate.`,\n 'Comparator chosen post-hoc by inspecting the same data; q-values are no longer false-discovery-controlled.',\n 'Scenarios not drawn under a stable preregistered protocol; the report can describe the data but cannot anchor a launch decision.',\n 'Score distributions with mid-run shift (judge model swap, rubric change, infra outage) — pair exchangeability is violated.',\n ]\n const citations: string[] = [\n 'Benjamini, Y. & Hochberg, Y. (1995). Controlling the false discovery rate: a practical and powerful approach to multiple testing. JRSS B, 57(1), 289–300.',\n 'Wilcoxon, F. (1945). Individual comparisons by ranking methods. Biometrics Bulletin, 1(6), 80–83.',\n 'Efron, B. (1979). Bootstrap methods: another look at the jackknife. Annals of Statistics, 7(1), 1–26.',\n 'Rubin, D. B. (1981). The Bayesian bootstrap. Annals of Statistics, 9(1), 130–134.',\n 'Kruschke, J. K. (2018). Rejecting or accepting parameter values in Bayesian estimation. Advances in Methods and Practices in Psychological Science, 1(2), 270–280. (ROPE.)',\n ]\n return { assumptions, methods, alternatives, whenNotToApply, citations }\n}\n\nexport function classifyCandidate(\n row: SummaryTableRow,\n ctx: {\n comparator: string | null\n posterior: ReturnType<typeof pairedPosterior> | null\n point?: ParetoPoint\n gateDecision?: HeldOutGateDecision\n split: 'search' | 'holdout'\n fdr: number\n minPairs: number\n rope: { low: number; high: number } | null\n },\n): { decision: ResearchReportDecision; reason: string } {\n if (ctx.comparator && row.candidateId === ctx.comparator) {\n return { decision: 'hold', reason: 'Comparator baseline.' }\n }\n if (ctx.gateDecision && !ctx.gateDecision.promote) {\n const code = ctx.gateDecision.rejectionCode ?? 'rejected'\n return {\n decision: 'reject',\n reason: `Held-out gate returned ${code}: ${ctx.gateDecision.reason}`,\n }\n }\n if (!ctx.comparator) {\n return {\n decision: ctx.point?.onFrontier ? 'hold' : 'needs_more_data',\n reason:\n 'No comparator configured; report ranks candidates but cannot anchor a promotion call.',\n }\n }\n if (!ctx.posterior || ctx.posterior.n < RESEARCH_REPORT_HARD_PAIR_FLOOR) {\n return {\n decision: 'needs_more_data',\n reason: `Only ${ctx.posterior?.n ?? 0} paired observations; below hard floor of ${RESEARCH_REPORT_HARD_PAIR_FLOOR} for any paired inference.`,\n }\n }\n const ci = ctx.posterior.ci\n if (ctx.split === 'search') {\n return {\n decision: 'hold',\n reason:\n 'Search-split evidence is descriptive; release decisions require matched holdout runs.',\n }\n }\n // A ZERO-WIDTH interval cannot support any directional or equivalence claim:\n // every resample was identical, so it says nothing about how far the estimate\n // could be wrong. It is the shape that sits fully inside any ROPE containing\n // it (a fake \"practically equivalent\") and clears any threshold below it (a\n // fake \"promote\"). Both are an absence of evidence, so it is disqualified from\n // each claim rather than short-circuiting the whole classifier — the\n // sample-size and MDE diagnostics below are still the more useful answer when\n // they apply.\n const degenerate = !Number.isFinite(ci.low) || !Number.isFinite(ci.high) || ci.low === ci.high\n if (!degenerate && ctx.rope && ci.low >= ctx.rope.low && ci.high <= ctx.rope.high) {\n return {\n decision: 'equivalent',\n reason: `Paired-delta CI [${fmt(ci.low)}, ${fmt(ci.high)}] is fully inside ROPE ${formatRope(ctx.rope)}; candidate is practically equivalent to comparator.`,\n }\n }\n const gainPositive = !degenerate && ci.low > 0\n const gainNegative = !degenerate && ci.high < 0\n if (gainNegative) {\n return {\n decision: 'reject',\n reason: `Paired-delta CI [${fmt(ci.low)}, ${fmt(ci.high)}] lies entirely below zero.`,\n }\n }\n if (ctx.posterior.n < ctx.minPairs) {\n return {\n decision: 'needs_more_data',\n reason: `Only ${ctx.posterior.n} paired observations; minimum detectable effect at this N is ${fmt(ctx.posterior.mde)} score units (need ≥ ${ctx.minPairs} pairs to issue a directional verdict).`,\n }\n }\n if (degenerate) {\n return {\n decision: 'needs_more_data',\n reason: `Paired-delta CI [${fmt(ci.low)}, ${fmt(ci.high)}] has zero width — every resample was identical, so the interval carries no information about how far the estimate could be wrong and cannot support a promote or equivalence call.`,\n }\n }\n if (row.qValue !== null && row.qValue <= ctx.fdr && gainPositive) {\n return {\n decision: 'promote',\n reason: `BH-adjusted q=${fmt(row.qValue)} ≤ ${ctx.fdr} and paired-delta CI [${fmt(ci.low)}, ${fmt(ci.high)}] excludes zero; Pr(Δ>0)=${fmt(ctx.posterior.prGreaterThanZero)}.`,\n }\n }\n return {\n decision: 'hold',\n reason: `Pr(Δ>0)=${fmt(ctx.posterior.prGreaterThanZero)} but CI [${fmt(ci.low)}, ${fmt(ci.high)}] crosses zero; effect not decisive at fdr=${ctx.fdr}.`,\n }\n}\n\nexport function buildRecommendation(\n candidates: ResearchReportCandidate[],\n ctx: {\n comparator: string | null\n failureClusters?: FailureClusterReport\n rope: { low: number; high: number } | null\n minPairs: number\n preregistrationHash: string | null\n },\n): ResearchReportRecommendation {\n const nonComparator = candidates.filter((c) => c.candidateId !== ctx.comparator)\n const bestPromote = nonComparator.find((c) => c.decision === 'promote')\n const bestEquivalent = nonComparator.find((c) => c.decision === 'equivalent')\n const chosen = bestPromote ?? bestEquivalent ?? nonComparator[0] ?? null\n const decision: ResearchReportDecision = bestPromote\n ? 'promote'\n : nonComparator.some((c) => c.decision === 'needs_more_data')\n ? 'needs_more_data'\n : bestEquivalent\n ? 'equivalent'\n : nonComparator.some((c) => c.decision === 'hold')\n ? 'hold'\n : 'reject'\n\n const rationale: string[] = []\n const risks: string[] = []\n const nextActions: string[] = []\n\n if (chosen) {\n rationale.push(`${chosen.candidateId}: ${chosen.decisionReason}`)\n if (chosen.gainCi) {\n const probSummary =\n chosen.prGreaterThanZero !== null ? `, Pr(Δ>0)=${fmt(chosen.prGreaterThanZero)}` : ''\n rationale.push(\n `Median paired gain CI: [${fmt(chosen.gainCi.low)}, ${fmt(chosen.gainCi.high)}]${probSummary}.`,\n )\n }\n if (chosen.mde !== null && Number.isFinite(chosen.mde)) {\n rationale.push(`MDE at current paired N=${chosen.pairedN}: ${fmt(chosen.mde)} score units.`)\n }\n }\n if (!ctx.comparator) {\n risks.push('No comparator was configured; verdict is descriptive, not causal.')\n nextActions.push('Re-run with a stable comparator candidate for paired inference.')\n }\n if (!ctx.preregistrationHash) {\n risks.push(\n 'No preregistration hash supplied; readers cannot verify the analysis was specified before data inspection.',\n )\n nextActions.push(\n 'Sign a HypothesisManifest before the next sweep and pass `preregistrationHash` so the report cites it.',\n )\n }\n if (ctx.rope === null && nonComparator.length > 0) {\n risks.push(\n 'No ROPE configured; the report cannot distinguish \"equivalent\" from \"inconclusive\".',\n )\n nextActions.push(\n 'Define a domain-specific Region of Practical Equivalence and pass it to lock in the equivalence threshold.',\n )\n }\n const inconclusive = nonComparator.filter((c) => c.decision === 'needs_more_data')\n if (inconclusive.length > 0) {\n const worst = inconclusive.reduce((a, b) => (b.pairedN < a.pairedN ? b : a))\n risks.push(\n `${inconclusive.length} candidate(s) below soft floor (${ctx.minPairs} pairs); thinnest is ${worst.candidateId} with ${worst.pairedN}.`,\n )\n nextActions.push(\n `Collect at least ${ctx.minPairs - worst.pairedN} more matched holdout runs for ${worst.candidateId}.`,\n )\n }\n const rejected = nonComparator.filter((c) => c.decision === 'reject')\n if (rejected.length > 0) {\n risks.push(\n `${rejected.length} candidate(s) failed the paired test or held-out gate; do not ship those variants.`,\n )\n }\n if (ctx.failureClusters && ctx.failureClusters.clusters.length > 0) {\n const top = ctx.failureClusters.clusters[0]!\n risks.push(`Top failure cluster: ${top.failureClass} across ${top.runCount} run(s).`)\n nextActions.push('Prioritize the largest failure cluster before broad rollout.')\n }\n if (decision === 'promote') {\n nextActions.push('Ship behind the existing promotion gate and monitor canaries.')\n } else if (decision === 'hold') {\n nextActions.push('Keep current production candidate while expanding holdout evidence.')\n } else if (decision === 'equivalent') {\n nextActions.push(\n 'Either keep the comparator (no quality regression) or promote on cost/latency grounds — equivalence does not justify either; the choice is a product decision, not a stats one.',\n )\n } else if (decision === 'reject') {\n nextActions.push(\n 'Do not promote this sweep; inspect failures and generate a revised candidate.',\n )\n }\n\n return {\n decision,\n candidateId: chosen?.candidateId ?? null,\n rationale,\n risks,\n nextActions,\n }\n}\n\nexport function buildExecutiveSummary(\n candidates: ResearchReportCandidate[],\n recommendation: ResearchReportRecommendation,\n ctx: {\n comparator: string | null\n split: 'search' | 'holdout'\n failureClusters?: FailureClusterReport\n preregistrationHash: string | null\n },\n): string[] {\n const lines: string[] = []\n const nonComparator = candidates.filter((c) => c.candidateId !== ctx.comparator)\n lines.push(\n `Evaluated ${nonComparator.length} candidate(s) on the ${ctx.split} split${ctx.comparator ? ` against ${ctx.comparator}` : ''}.`,\n )\n lines.push(\n `Recommendation: ${recommendation.decision}${recommendation.candidateId ? ` ${recommendation.candidateId}` : ''}.`,\n )\n const promoted = nonComparator.filter((c) => c.decision === 'promote').length\n const held = nonComparator.filter((c) => c.decision === 'hold').length\n const equivalent = nonComparator.filter((c) => c.decision === 'equivalent').length\n const rejected = nonComparator.filter((c) => c.decision === 'reject').length\n const more = nonComparator.filter((c) => c.decision === 'needs_more_data').length\n lines.push(\n `Decision mix: ${promoted} promote, ${equivalent} equivalent, ${held} hold, ${rejected} reject, ${more} need more data.`,\n )\n const frontier = nonComparator.filter((c) => c.onParetoFrontier).map((c) => c.candidateId)\n if (frontier.length > 0) lines.push(`Pareto-frontier candidates: ${frontier.join(', ')}.`)\n if (ctx.failureClusters) {\n lines.push(\n `Failure clustering found ${ctx.failureClusters.totalFailures}/${ctx.failureClusters.totalRuns} failed runs across ${ctx.failureClusters.clusters.length} reportable cluster(s).`,\n )\n }\n lines.push(\n ctx.preregistrationHash\n ? `Preregistered analysis: ${ctx.preregistrationHash.slice(0, 12)}…`\n : 'Analysis is post-hoc — no preregistration hash supplied.',\n )\n return lines\n}\n\nexport function decisionWeight(decision: ResearchReportDecision): number {\n if (decision === 'promote') return 5\n if (decision === 'equivalent') return 4\n if (decision === 'hold') return 3\n if (decision === 'needs_more_data') return 2\n return 1\n}\n","/** Matched split scores and paired statistical evidence for report consumers. */\n\nimport { interpolatedQuantile } from './math/quantile'\nimport { pairRunRecords } from './paired-arms'\nimport { observedSplitScore, type ScorePreference } from './rollout/reward'\nimport type { RunRecord } from './run-record'\nimport { pairedBootstrap, pairedMde } from './statistics'\nimport { makeRng } from './statistics/internal'\n\nexport function pairScoresByKey(\n candidate: RunRecord[],\n baseline: RunRecord[],\n split: ScorePreference,\n): {\n before: number[]\n after: number[]\n unpairedCandidateN: number\n unpairedComparatorN: number\n} {\n // RAW, split-exact reads through `observedSplitScore` — the single allowed\n // spelling of the split-score derivation (see rollout/score-derivation-guard).\n const scoreOf = (run: RunRecord): number | undefined => {\n const v = observedSplitScore(run, split)\n return typeof v === 'number' && Number.isFinite(v) ? v : undefined\n }\n const scoredCandidate = candidate.filter((run) => scoreOf(run) !== undefined)\n const scoredBaseline = baseline.filter((run) => scoreOf(run) !== undefined)\n const pairing = pairRunRecords(scoredBaseline, scoredCandidate)\n return {\n before: pairing.pairs.map((pair) => scoreOf(pair.baseline) as number),\n after: pairing.pairs.map((pair) => scoreOf(pair.treatment) as number),\n unpairedCandidateN: pairing.unpairedTreatment.length,\n unpairedComparatorN: pairing.unpairedBaseline.length,\n }\n}\n\n/**\n * Internal: paired posterior summary on (candidate − comparator) deltas.\n *\n * Returns the bootstrap CI on the median (matching `gainHistogram`) plus\n * Bayesian-bootstrap posterior summaries Pr(Δ>0) and Pr(Δ∈ROPE) computed\n * from Dirichlet(1, ..., 1) weights on the observed paired deltas\n * (Rubin 1981), and the\n * minimum detectable paired effect at the configured power and α.\n *\n * `null` is returned when no paired observations exist; callers must\n * gate on `n` before consuming the bootstrap statistics.\n */\nexport function pairedPosterior(\n runs: RunRecord[],\n candidateId: string,\n comparator: string,\n opts: {\n split: 'search' | 'holdout'\n confidence: number\n seed?: number\n rope: { low: number; high: number } | null\n mdePower: number\n mdeAlpha: number\n },\n): {\n n: number\n meanDelta: number\n medianDelta: number\n sdDelta: number\n ci: { low: number; high: number }\n prGreaterThanZero: number\n prInRope: number | null\n mde: number\n} | null {\n const candidate = runs.filter((r) => r.candidateId === candidateId && r.splitTag === opts.split)\n const baseline = runs.filter((r) => r.candidateId === comparator && r.splitTag === opts.split)\n const { before, after } = pairScoresByKey(candidate, baseline, opts.split)\n const n = before.length\n if (n === 0) return null\n\n const deltas = before.map((b, i) => after[i]! - b)\n const meanDelta = deltas.reduce((s, x) => s + x, 0) / n\n const sortedDeltas = [...deltas].sort((a, b) => a - b)\n const medianDelta = interpolatedQuantile(sortedDeltas, 0.5)\n const sdDelta = stdev(deltas, meanDelta)\n\n const ci = pairedBootstrap(before, after, {\n confidence: opts.confidence,\n resamples: 2000,\n statistic: 'median',\n seed: opts.seed,\n })\n\n const meanSamples = bayesianBootstrapMeanSamples(deltas, 2000, opts.seed)\n const prGreaterThanZero =\n meanSamples.length === 0 ? 0 : meanSamples.filter((s) => s > 0).length / meanSamples.length\n const prInRope =\n opts.rope === null || meanSamples.length === 0\n ? null\n : meanSamples.filter((s) => s >= opts.rope!.low && s <= opts.rope!.high).length /\n meanSamples.length\n\n const dStandardised = pairedMde({ nPaired: n, alpha: opts.mdeAlpha, power: opts.mdePower })\n const mde = sdDelta === 0 ? 0 : dStandardised * sdDelta\n\n return {\n n,\n meanDelta,\n medianDelta,\n sdDelta,\n ci: { low: ci.low, high: ci.high },\n prGreaterThanZero,\n prInRope,\n mde,\n }\n}\n\nfunction bayesianBootstrapMeanSamples(\n deltas: number[],\n resamples: number,\n seed?: number,\n): number[] {\n const n = deltas.length\n if (n === 0) return []\n if (n === 1) return new Array<number>(resamples).fill(deltas[0]!)\n const rng = makeRng(seed, deltas)\n const samples = new Array<number>(resamples)\n for (let b = 0; b < resamples; b++) {\n let weightedSum = 0\n let weightSum = 0\n for (let k = 0; k < n; k++) {\n const weight = -Math.log(Math.max(Number.MIN_VALUE, rng()))\n weightedSum += deltas[k]! * weight\n weightSum += weight\n }\n samples[b] = weightedSum / weightSum\n }\n return samples\n}\n\nfunction stdev(xs: number[], mean: number): number {\n if (xs.length < 2) return 0\n let sse = 0\n for (const x of xs) sse += (x - mean) ** 2\n return Math.sqrt(sse / (xs.length - 1))\n}\n","/** Tables and library-independent chart specifications from scored runs. */\n\nimport type { HeldOutGateDecision } from './held-out-gate'\nimport { interpolatedQuantile } from './math/quantile'\nimport { fmt } from './research-report-render'\nimport { observedSplitScore } from './rollout/reward'\nimport type { RunRecord } from './run-record'\nimport {\n benjaminiHochberg,\n confidenceInterval,\n pairedBootstrap,\n pairedCohensDz,\n wilcoxonSignedRank,\n} from './statistics'\nimport { mean as avg } from './statistics/mean'\nimport { pairScoresByKey } from './summary-report-evidence'\n\n// ── summaryTable ───────────────────────────────────────────────────────\n\nexport interface SummaryTableOptions {\n /** Comparator candidate id. Wilcoxon + paired Cohen's dz are computed\n * versus this candidate. Required for paired stats columns. */\n comparator?: string\n /** Which split to read scores from. Default 'holdout'. */\n split?: 'search' | 'holdout'\n /** Confidence level for the bootstrap CI on the mean. Default 0.95. */\n confidence?: number\n /** FDR for BH adjustment of the comparison p-values. Default 0.05. */\n fdr?: number\n}\n\nexport interface SummaryTableRow {\n candidateId: string\n n: number\n mean: number\n ciLow: number\n ciHigh: number\n /** BH-adjusted q-value vs comparator, or null when unavailable. */\n qValue: number | null\n /** Paired Cohen's dz vs comparator, or null when the paired variance is zero. */\n cohensD: number | null\n /** Matched observations used for paired comparison, or null on the comparator row. */\n pairedN: number | null\n /** Candidate observations without a comparator match. */\n unpairedCandidateN: number | null\n /** Comparator observations without a candidate match. */\n unpairedComparatorN: number | null\n}\n\nexport interface SummaryTable {\n rows: SummaryTableRow[]\n comparator: string | null\n split: 'search' | 'holdout'\n /** Pre-rendered markdown — drop into a paper or PR. */\n markdown: string\n}\n\n/**\n * Table 1 helper. Buckets runs by `candidateId`, computes mean +\n * bootstrap CI on the chosen split, and (when a comparator is given)\n * BH-adjusted Wilcoxon p + paired Cohen's dz versus that comparator.\n */\nexport function summaryTable(runs: RunRecord[], opts: SummaryTableOptions = {}): SummaryTable {\n const split = opts.split ?? 'holdout'\n const confidence = opts.confidence ?? 0.95\n const fdr = opts.fdr ?? 0.05\n const comparator = opts.comparator ?? null\n\n const byCandidate = new Map<string, { runs: RunRecord[]; scores: number[] }>()\n for (const r of runs) {\n if (r.splitTag !== split) continue\n // Report raw, exact-split scores so gaming remains visible.\n const v = observedSplitScore(r, split)\n if (typeof v !== 'number' || !Number.isFinite(v)) continue\n const bucket = byCandidate.get(r.candidateId) ?? { runs: [], scores: [] }\n bucket.runs.push(r)\n bucket.scores.push(v)\n byCandidate.set(r.candidateId, bucket)\n }\n\n const compRuns = comparator ? byCandidate.get(comparator) : undefined\n\n const rows: SummaryTableRow[] = [...byCandidate.keys()].sort().map((id) => {\n const bucket = byCandidate.get(id)!\n const ci = confidenceInterval(bucket.scores, confidence)\n const paired =\n comparator && compRuns && id !== comparator\n ? pairScoresByKey(bucket.runs, compRuns.runs, split)\n : null\n return {\n candidateId: id,\n n: bucket.scores.length,\n mean: ci.mean,\n ciLow: ci.lower,\n ciHigh: ci.upper,\n qValue:\n paired && paired.before.length >= 6\n ? wilcoxonSignedRank(paired.before, paired.after).p\n : null,\n cohensD: paired ? pairedCohensDz(paired.before, paired.after) : null,\n pairedN: paired?.before.length ?? null,\n unpairedCandidateN: paired?.unpairedCandidateN ?? null,\n unpairedComparatorN: paired?.unpairedComparatorN ?? null,\n }\n })\n if (comparator) {\n const comparisons = rows.filter(\n (row) => row.candidateId !== comparator && row.qValue !== null && Number.isFinite(row.qValue),\n )\n if (comparisons.length > 0) {\n const { qValues } = benjaminiHochberg(\n comparisons.map((row) => row.qValue!),\n fdr,\n )\n comparisons.forEach((row, index) => {\n row.qValue = qValues[index]!\n })\n }\n }\n\n const markdown = renderSummaryTableMarkdown(rows, comparator, split)\n return { rows, comparator, split, markdown }\n}\n\nfunction renderSummaryTableMarkdown(\n rows: SummaryTableRow[],\n comparator: string | null,\n split: 'search' | 'holdout',\n): string {\n return [\n `Summary Table — ${split} split${comparator ? ` (vs ${comparator})` : ''}`,\n '',\n \"| Candidate | N | Pairs | Unpaired | Mean | 95% CI | q (BH) | Cohen's dz |\",\n '|---|---:|---:|---:|---:|---|---:|---:|',\n ...rows.map(\n (r) =>\n `| ${[\n r.candidateId,\n r.n,\n r.pairedN ?? '—',\n r.unpairedCandidateN === null || r.unpairedComparatorN === null\n ? '—'\n : `${r.unpairedCandidateN}/${r.unpairedComparatorN}`,\n fmt(r.mean),\n `[${fmt(r.ciLow)}, ${fmt(r.ciHigh)}]`,\n r.qValue?.toFixed(4) ?? '—',\n r.cohensD?.toFixed(3) ?? '—',\n ].join(' | ')} |`,\n ),\n ].join('\\n')\n}\n\n// ── paretoChart ─────────────────────────────────────────────────────\n\nexport interface ParetoPoint {\n candidateId: string\n /** Mean USD cost per run on the chosen split. */\n cost: number\n /** Mean score on the chosen split. */\n quality: number\n /** Number of runs that informed this point. */\n n: number\n /** Whether this candidate is on the Pareto frontier — high\n * quality, low cost, no dominator. */\n onFrontier: boolean\n /** Optional gate verdict for this candidate, if a `HeldOutGateDecision`\n * for it was passed in. */\n gate?: 'promote' | 'reject'\n}\n\nexport interface ParetoFigureSpec {\n kind: 'pareto-cost-quality'\n split: 'search' | 'holdout'\n points: ParetoPoint[]\n axes: { x: 'costUsd'; y: 'score' }\n}\n\n/**\n * Cost vs quality scatter spec. `gateDecisions` is keyed by\n * candidate id; if present, every point picks up the gate verdict\n * for overlay.\n */\nexport function paretoChart(\n runs: RunRecord[],\n opts: {\n split?: 'search' | 'holdout'\n gateDecisions?: Record<string, HeldOutGateDecision>\n } = {},\n): ParetoFigureSpec {\n const split = opts.split ?? 'holdout'\n\n const buckets = new Map<string, { cost: number[]; quality: number[] }>()\n for (const r of runs) {\n if (r.splitTag !== split) continue\n const v = observedSplitScore(r, split)\n if (typeof v !== 'number' || !Number.isFinite(v)) continue\n if (r.costUsd === null) continue\n const bucket = buckets.get(r.candidateId) ?? { cost: [], quality: [] }\n bucket.cost.push(r.costUsd)\n bucket.quality.push(v)\n buckets.set(r.candidateId, bucket)\n }\n\n const points: ParetoPoint[] = [...buckets].map(([candidateId, bucket]) => ({\n candidateId,\n cost: avg(bucket.cost),\n quality: avg(bucket.quality),\n n: bucket.cost.length,\n onFrontier: false,\n gate: opts.gateDecisions?.[candidateId]\n ? gateLabel(opts.gateDecisions[candidateId]!)\n : undefined,\n }))\n\n // Pareto: minimize cost, maximize quality. A point is dominated if\n // some other point has lower-or-equal cost AND higher-or-equal\n // quality with strict inequality somewhere.\n for (const p of points) {\n p.onFrontier = !points.some((q) => q !== p && dominates(q, p))\n }\n\n return {\n kind: 'pareto-cost-quality',\n split,\n axes: { x: 'costUsd', y: 'score' },\n points,\n }\n}\n\nfunction dominates(a: ParetoPoint, b: ParetoPoint): boolean {\n return a.cost <= b.cost && a.quality >= b.quality && (a.cost < b.cost || a.quality > b.quality)\n}\n\nexport function gateLabel(d: HeldOutGateDecision): ParetoPoint['gate'] {\n return d.promote ? 'promote' : 'reject'\n}\n\n// ── gainHistogram ───────────────────────────────────────────\n\nexport interface GainDistributionBin {\n /** Inclusive lower edge. */\n lo: number\n /** Exclusive upper edge (or inclusive if it's the last bin). */\n hi: number\n /** Number of pairs whose delta lands in this bin. */\n count: number\n}\n\nexport interface GainDistributionFigureSpec {\n kind: 'gain-distribution'\n candidateId: string\n comparator: string\n split: 'search' | 'holdout'\n /** Number of pairs used. */\n n: number\n /** Candidate rows without a comparator match. */\n unpairedCandidateN: number\n /** Comparator rows without a candidate match. */\n unpairedComparatorN: number\n bins: GainDistributionBin[]\n median: number | null\n ci: { low: number; high: number } | null\n}\n\nexport interface GainDistributionOptions {\n /** Number of histogram bins. Default 11 (so the centre is exact at 0). */\n bins?: number\n /** Which split to use. Default 'holdout'. */\n split?: 'search' | 'holdout'\n /** Confidence level for the CI. Default 0.95. */\n confidence?: number\n /** Bootstrap resamples. Default 2000. */\n resamples?: number\n /** Deterministic seed. */\n seed?: number\n}\n\n/**\n * Held-out improvement distribution: per-pair delta (candidate −\n * comparator), histogrammed. Includes the bootstrap CI on the median\n * delta — same primitive the promotion gate uses.\n */\nexport function gainHistogram(\n runs: RunRecord[],\n candidateId: string,\n comparator: string,\n opts: GainDistributionOptions = {},\n): GainDistributionFigureSpec {\n const split = opts.split ?? 'holdout'\n const binCount = opts.bins ?? 11\n if (binCount < 1) throw new Error('gainHistogram: bins must be ≥ 1')\n\n const candidate = runs.filter((r) => r.candidateId === candidateId && r.splitTag === split)\n const baseline = runs.filter((r) => r.candidateId === comparator && r.splitTag === split)\n // pairScoresByKey returns before=baseline-score, after=candidate-score\n // for each canonical work-identity pair where both sides recorded a\n // valid score on this split. delta = after - before = candidate - baseline.\n const { before, after, unpairedCandidateN, unpairedComparatorN } = pairScoresByKey(\n candidate,\n baseline,\n split,\n )\n const n = before.length\n\n const deltas = before.map((b, i) => after[i]! - b)\n const sortedDeltas = [...deltas].sort((a, b) => a - b)\n const median = n === 0 ? null : interpolatedQuantile(sortedDeltas, 0.5)\n\n // Symmetric bins around the wider of (|min|, |max|) so the chart\n // visually centres on zero without dropping outliers.\n const bound = Math.max(\n Math.abs(sortedDeltas[0]!),\n Math.abs(sortedDeltas[sortedDeltas.length - 1]!),\n 1e-6,\n )\n const lo = -bound\n const width = (bound - lo) / binCount\n const bins: GainDistributionBin[] = []\n for (let i = 0; n > 0 && i < binCount; i++) {\n bins.push({ lo: lo + i * width, hi: lo + (i + 1) * width, count: 0 })\n }\n for (const d of deltas) {\n let idx = Math.floor((d - lo) / width)\n if (idx < 0) idx = 0\n if (idx >= binCount) idx = binCount - 1\n bins[idx]!.count += 1\n }\n\n const ci =\n n === 0\n ? null\n : pairedBootstrap(before, after, {\n confidence: opts.confidence ?? 0.95,\n resamples: opts.resamples ?? 2000,\n statistic: 'median',\n seed: opts.seed,\n })\n\n return {\n kind: 'gain-distribution',\n candidateId,\n comparator,\n split,\n n,\n unpairedCandidateN,\n unpairedComparatorN,\n bins,\n median,\n ci: ci === null ? null : { low: ci.low, high: ci.high },\n }\n}\n","/** Assemble research report evidence, guidance, figures, and rendered documents. */\n\nimport type { HeldOutGateDecision } from './held-out-gate'\nimport type { FailureClusterReport } from './pipelines/failure-cluster'\nimport { hashJson } from './pre-registration'\nimport { renderResearchHtml } from './reporting-html'\nimport {\n buildExecutiveSummary,\n buildMethodology,\n buildRecommendation,\n classifyCandidate,\n decisionWeight,\n RESEARCH_REPORT_HARD_PAIR_FLOOR,\n} from './research-report-analysis'\nimport { renderResearchMarkdown } from './research-report-render'\nimport type { RunRecord } from './run-record'\nimport { pairedPosterior } from './summary-report-evidence'\nimport {\n type GainDistributionFigureSpec,\n gainHistogram,\n gateLabel,\n type ParetoFigureSpec,\n type ParetoPoint,\n paretoChart,\n type SummaryTable,\n summaryTable,\n} from './summary-report-figures'\n\nexport { RESEARCH_REPORT_HARD_PAIR_FLOOR } from './research-report-analysis'\n\nexport type ResearchReportDecision =\n | 'promote'\n | 'hold'\n | 'reject'\n | 'equivalent'\n | 'needs_more_data'\n\nexport interface ResearchReportOptions {\n /** Human-readable report title. */\n title?: string\n /** Comparator candidate id. Required for statistical decision guidance. */\n comparator?: string\n /** Which split to use for the primary decision. Default 'holdout'. */\n split?: 'search' | 'holdout'\n /** Confidence level used by lower-level report helpers. Default 0.95. */\n confidence?: number\n /** FDR threshold for q-values. Default 0.05. */\n fdr?: number\n /**\n * Soft floor on paired observations before issuing a directional\n * promote / reject. Below this we report `needs_more_data` and surface the\n * minimum detectable effect at the current N. Default 20 — chosen so the\n * Wilcoxon signed-rank approximation is reasonable and so the paired\n * bootstrap CI has non-degenerate coverage. Hard floor is enforced at\n * `RESEARCH_REPORT_HARD_PAIR_FLOOR` (6) regardless of this value.\n */\n minPairs?: number\n /**\n * Region of Practical Equivalence on the paired delta. When a candidate's\n * paired-delta CI is fully contained in `[low, high]`, the decision is\n * `equivalent` rather than `hold`. Sourced from the domain owner — there is\n * no statistically-defensible default.\n */\n rope?: { low: number; high: number }\n /**\n * Power for the minimum detectable effect (MDE) reported on each candidate.\n * Default 0.8.\n */\n mdePower?: number\n /**\n * Two-sided alpha for the MDE. Default matches `fdr` so the reported MDE\n * lines up with the test the report actually runs.\n */\n mdeAlpha?: number\n /** Optional held-out gate decisions keyed by candidate id. */\n gateDecisions?: Record<string, HeldOutGateDecision>\n /** Optional failure clusters from failureClusterView. */\n failureClusters?: FailureClusterReport\n /** Build gain histograms for these candidates. Defaults to all non-comparator candidates. */\n candidateIds?: string[]\n /** Deterministic bootstrap seed passed to gainHistogram and the posterior helper. */\n seed?: number\n /** Report timestamp. Defaults to current time. */\n generatedAt?: string\n /**\n * Hash of a preregistered protocol (e.g. `signManifest({...}).contentHash`).\n * Embedded verbatim in the report so the analysis can be cited as the\n * preregistered one rather than a post-hoc fishing expedition.\n */\n preregistrationHash?: string\n}\n\nexport interface ResearchReportRecommendation {\n decision: ResearchReportDecision\n candidateId: string | null\n rationale: string[]\n risks: string[]\n nextActions: string[]\n}\n\nexport interface ResearchReportCandidate {\n candidateId: string\n n: number\n mean: number\n ciLow: number\n ciHigh: number\n qValue: number | null\n cohensD: number | null\n meanDeltaVsComparator: number | null\n pairedN: number\n medianGain: number | null\n meanGain: number | null\n gainCi: { low: number; high: number } | null\n /**\n * Bayesian-bootstrap posterior summaries on the paired mean delta.\n * Dirichlet(1, ..., 1) weights represent uncertainty over the empirical\n * distribution of matched deltas.\n */\n prGreaterThanZero: number | null\n prInRope: number | null\n /**\n * Minimum detectable effect (in score units) at the candidate's paired N,\n * the configured power, and the configured alpha. Standardised by the\n * observed paired-delta SD and inverted via `requiredSampleSize`. Reported\n * for every candidate so a `needs_more_data` verdict is actionable.\n */\n mde: number | null\n onParetoFrontier: boolean\n gate?: ParetoPoint['gate']\n decision: ResearchReportDecision\n decisionReason: string\n}\n\nexport interface ResearchReportMethodology {\n /**\n * Plain-language assumptions the report depends on. Read these first when\n * deciding whether the verdict is load-bearing for a launch decision.\n */\n assumptions: string[]\n /** Tests and estimators the verdict was computed from. */\n methods: string[]\n /** Alternatives the author considered and why this report didn't take them. */\n alternatives: string[]\n /** Failure modes — when this report should NOT drive a decision. */\n whenNotToApply: string[]\n /** Citations for the methodological choices above. */\n citations: string[]\n}\n\nexport interface ResearchReport {\n kind: 'agent-eval-research-report'\n title: string\n generatedAt: string\n split: 'search' | 'holdout'\n comparator: string | null\n /**\n * SHA-256 over the canonicalised set of `(runId, candidateId, split)` triples\n * the report was computed from, plus the comparator and split. Stable across\n * key insertion order; recomputable by the reader to verify provenance.\n */\n runFingerprint: string\n preregistrationHash: string | null\n rope: { low: number; high: number } | null\n executiveSummary: string[]\n recommendation: ResearchReportRecommendation\n candidates: ResearchReportCandidate[]\n summary: SummaryTable\n charts: {\n pareto: ParetoFigureSpec\n gains: GainDistributionFigureSpec[]\n }\n methodology: ResearchReportMethodology\n failureClusters?: FailureClusterReport\n markdown: string\n html: string\n}\n\n/**\n * Executive research report for CPO / AI-lead / launch-review consumption.\n *\n * Composes:\n * - `summaryTable` marginal stats with BH-FDR-adjusted q-values\n * - `paretoChart` cost-vs-quality frontier with gate overlay\n * - `gainHistogram` per-candidate paired-delta distribution\n * - paired posterior (this file): bootstrap CI on median, Bayesian-bootstrap Pr(Δ>0),\n * Pr(Δ∈ROPE), MDE at the configured power\n *\n * Decisions are made on paired evidence — never on marginal means alone —\n * and respect any held-out gate decision the caller passes through. The\n * report embeds a SHA-256 fingerprint of the input run set and, optionally,\n * the hash of a preregistered protocol so a downstream reader can verify\n * provenance and that the analysis was the preregistered one.\n *\n * Async because the fingerprint uses Web Crypto via `hashJson`; deterministic\n * for any fixed `runs`, `seed`, and ROPE.\n */\nexport async function researchReport(\n runs: RunRecord[],\n opts: ResearchReportOptions = {},\n): Promise<ResearchReport> {\n const split = opts.split ?? 'holdout'\n const comparator = opts.comparator ?? null\n const confidence = opts.confidence ?? 0.95\n const fdr = opts.fdr ?? 0.05\n const minPairs = Math.max(opts.minPairs ?? 20, RESEARCH_REPORT_HARD_PAIR_FLOOR)\n const rope = opts.rope ?? null\n const mdePower = opts.mdePower ?? 0.8\n const mdeAlpha = opts.mdeAlpha ?? fdr\n const title = opts.title ?? 'Agent Evaluation Research Report'\n const generatedAt = opts.generatedAt ?? new Date().toISOString()\n const preregistrationHash = opts.preregistrationHash ?? null\n\n if (rope && !(Number.isFinite(rope.low) && Number.isFinite(rope.high) && rope.low <= rope.high)) {\n throw new Error(\n `researchReport: rope must satisfy low ≤ high with finite bounds, got ${JSON.stringify(rope)}`,\n )\n }\n\n const summary = summaryTable(runs, {\n comparator: comparator ?? undefined,\n split,\n confidence,\n fdr,\n })\n const pareto = paretoChart(runs, { split, gateDecisions: opts.gateDecisions })\n const candidateIds =\n opts.candidateIds ?? summary.rows.map((r) => r.candidateId).filter((id) => id !== comparator)\n const gains = comparator\n ? candidateIds.map((id) =>\n gainHistogram(runs, id, comparator, {\n split,\n confidence,\n seed: opts.seed,\n }),\n )\n : []\n\n const gainByCandidate = new Map(gains.map((g) => [g.candidateId, g]))\n const paretoByCandidate = new Map(pareto.points.map((p) => [p.candidateId, p]))\n const posteriorByCandidate = new Map<string, ReturnType<typeof pairedPosterior>>()\n if (comparator) {\n for (const id of candidateIds) {\n posteriorByCandidate.set(\n id,\n pairedPosterior(runs, id, comparator, {\n split,\n confidence,\n seed: opts.seed,\n rope,\n mdePower,\n mdeAlpha,\n }),\n )\n }\n }\n\n const candidates = summary.rows\n .map((row) => {\n const gain = gainByCandidate.get(row.candidateId)\n const point = paretoByCandidate.get(row.candidateId)\n const posterior = posteriorByCandidate.get(row.candidateId) ?? null\n const gateDecision = opts.gateDecisions?.[row.candidateId]\n const classified = classifyCandidate(row, {\n comparator,\n posterior,\n point,\n gateDecision,\n split,\n fdr,\n minPairs,\n rope,\n })\n return {\n candidateId: row.candidateId,\n n: row.n,\n mean: row.mean,\n ciLow: row.ciLow,\n ciHigh: row.ciHigh,\n qValue: row.qValue,\n cohensD: row.cohensD,\n meanDeltaVsComparator: posterior ? posterior.meanDelta : null,\n pairedN: posterior?.n ?? gain?.n ?? 0,\n medianGain: posterior ? posterior.medianDelta : gain ? gain.median : null,\n meanGain: posterior ? posterior.meanDelta : null,\n gainCi: posterior ? posterior.ci : gain ? gain.ci : null,\n prGreaterThanZero: posterior ? posterior.prGreaterThanZero : null,\n prInRope: posterior ? posterior.prInRope : null,\n mde: posterior ? posterior.mde : null,\n onParetoFrontier: point?.onFrontier ?? false,\n gate: gateDecision ? gateLabel(gateDecision) : undefined,\n decision: classified.decision,\n decisionReason: classified.reason,\n } satisfies ResearchReportCandidate\n })\n .sort((a, b) => {\n const decisionRank = decisionWeight(b.decision) - decisionWeight(a.decision)\n if (decisionRank !== 0) return decisionRank\n return b.mean - a.mean\n })\n\n const recommendation = buildRecommendation(candidates, {\n comparator,\n failureClusters: opts.failureClusters,\n rope,\n minPairs,\n preregistrationHash,\n })\n const executiveSummary = buildExecutiveSummary(candidates, recommendation, {\n comparator,\n split,\n failureClusters: opts.failureClusters,\n preregistrationHash,\n })\n const methodology = buildMethodology({\n split,\n comparator,\n fdr,\n minPairs,\n rope,\n confidence,\n mdePower,\n mdeAlpha,\n })\n\n const runFingerprint = await hashJson({\n triples: runs\n .filter((r) => r.splitTag === split)\n .map((r) => ({ runId: r.runId, candidateId: r.candidateId, splitTag: r.splitTag }))\n .sort((a, b) => a.runId.localeCompare(b.runId)),\n comparator,\n split,\n })\n\n const markdown = renderResearchMarkdown({\n title,\n generatedAt,\n split,\n comparator,\n rope,\n runFingerprint,\n preregistrationHash,\n executiveSummary,\n recommendation,\n candidates,\n summary,\n pareto,\n gains,\n methodology,\n failureClusters: opts.failureClusters,\n })\n const html = renderResearchHtml(markdown, title)\n\n return {\n kind: 'agent-eval-research-report',\n title,\n generatedAt,\n split,\n comparator,\n runFingerprint,\n preregistrationHash,\n rope,\n executiveSummary,\n recommendation,\n candidates,\n summary,\n charts: { pareto, gains },\n methodology,\n failureClusters: opts.failureClusters,\n markdown,\n html,\n }\n}\n"],"mappings":";;;;;;;AAcA,SAAgB,uBAAuB,QAgB5B;CACT,MAAM,QAAkB,CAAC;CACzB,MAAM,KAAK,KAAK,OAAO,OAAO;CAC9B,MAAM,KAAK,EAAE;CACb,MAAM,KAAK,kBAAkB,OAAO,aAAa;CACjD,MAAM,KAAK,sBAAsB,OAAO,OAAO;CAC/C,MAAM,KAAK,mBAAmB,OAAO,cAAc,kBAAkB;CACrE,MAAM,KAAK,aAAa,OAAO,OAAO,WAAW,OAAO,IAAI,IAAI,kBAAkB;C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AO;EACL,MAAM;EACN;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA,QAAQ;GAAE;GAAQ;EAAM;EACxB;EACA,iBAAiB,KAAK;EACtB;EACA;CACF;AACF"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"systemone-DzY-2Zri.d.ts","names":["_$__meta_eval0.calibrationFromPairs"],"sources":["../src/analyst/findings-store.ts","../src/analyst/findings-ledger.ts","../src/decision-point-records.ts","../src/decision-point.ts","../src/systemone-domain-match.ts","../src/systemone.ts"],"mappings":";;;;;;;;;;;;;;;UA8BiB,yBAAyB;EACxC;;cAGW;WAGiB;mBAFX;EAEW,YAAA;EAItB,OAAO,eAAe,UAAU,mBAAmB;;EAQzD,WAAW;;EAkBX,QAAQ,gBAAgB;;UAOT;;EAEf,UAAU;;EAEV,aAAa;;EAEb,WAAW;;;;;EAKX,SAAS;IAAQ,UAAU;IAAkB,SAAS;;;UAGvC;;;;;;;;EAQf,cAAc,UAAU,gBAAgB,SAAS;;;;;;iBAkBnC,aACd,UAAU,oBACV,SAAS,oBACT,SAAQ,aACP;;UC9Dc,sBAAsB;;EAErC;EACA,WAAW;;UAGI;EACf,UAAU;;EAEV,YAAY;;KAGF,sBAAsB;EAC5B;EAAiB,OAAO;;EAExB;EACA;IAAS;IAA8C;;;UAG5C;WACN;EACT,OACE,eACA,mBAAmB,mBAClB,QAAQ;IAAwB;IAAkB;;EACrD,QAAQ,QAAQ,sBAAsB;;;iBAwFxB,mBAAmB;EAAW;IAAiB;UA0C9C;EACf,QAAQ,wBAAwB;EAChC;EACA;EACA;EACA;;;;;EAKA;;;iBAIc,cAAc,UAAU;EAAmB;GACzD,eAAe,KACf,OAAO,gBACN;UAoBc;EACf;EACA;EACA,MAAM;;;;;;;iBAQQ,qBACd,eAAe,iBACf,SAAQ,aACP;cCpOU,qBAAmB,EAAA,uBAAA,EAAA;;;;;;;GAI9B,EAAA,KAAA;;KAGU,gBAAgB,EAAE,aAAa;cA4BrC,s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UACE,QAAQ,iBAAiB,gBAAgB,KACzC,OAAO,GACP,SAAS,0BACC;;iBAGE,iBAAiB,GAAG,UAAU,qBAAqB,oBACjE,SAAS,wBAAwB,GAAG,KACnC,QAAQ"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"tool-groups-DF6OqhoG.d.ts","names":[],"sources":["../src/analyst/tool-groups.ts"],"mappings":";;KAmBY;;;;;;;;;;;;;;;;;;;;iBAyDI,wBACd,OAAO,oBACP,OAAO,qBACN"}
@@ -1,217 +0,0 @@
1
- import { S as TraceEvent, _ as Span, r as BudgetSpec, x as ToolSpan } from "./schema-CkIvnmLU.js";
2
- import { s as TraceStore } from "./store-CMs5wGXP.js";
3
- import { a as llmSpans } from "./query-UD0B08Sb.js";
4
- interface BaselineOptions {
5
- /** Effect size threshold for meaningful delta (default 0.5 — medium effect). */
6
- effectThreshold?: number;
7
- /** p-value threshold for statistical significance (default 0.05). */
8
- alpha?: number;
9
- /** IQR/mean ratio above which samples are flagged unstable (default 0.30). */
10
- unstableCvThreshold?: number;
11
- }
12
- type WelchTestStatus = 'ok' | 'insufficient-sample' | 'zero-variance';
13
- /** Independent b − a effects; insufficient counts or zero variance have no confidence interval. */
14
- interface WelchTestResultBase {
15
- meanA: number;
16
- meanB: number;
17
- delta: number;
18
- }
19
- type WelchTestResult = (WelchTestResultBase & {
20
- status: 'ok';
21
- standardError: number;
22
- t: number;
23
- df: number;
24
- p: number;
25
- ci95: [number, number];
26
- cohensD: number;
27
- }) | (WelchTestResultBase & {
28
- status: 'insufficient-sample' | 'zero-variance';
29
- standardError: number;
30
- t: number;
31
- df: number;
32
- p: number;
33
- ci95: null;
34
- cohensD: null;
35
- });
36
- /** Inter-quartile range; 0 when the sample has no spread. */
37
- declare function iqr(xs: number[]): number;
38
- /** Use Student-t at finite df; unavailable inference is NaN with a null interval and explicit status. */
39
- declare function welchsTTest(a: number[], b: number[]): WelchTestResult;
40
- interface ToolUseMetrics {
41
- runId: string;
42
- totalCalls: number;
43
- /** Calls whose arguments were captured and can be compared for duplication. */
44
- callsWithCapturedArgs: number;
45
- byTool: Record<string, ToolStats>;
46
- errorRate: number;
47
- /** Ratio of captured-argument calls already seen with the same tool name and arguments. */
48
- duplicateRate: number;
49
- /** Ratio of error calls followed by ≥1 retry on same tool. */
50
- retryRate: number;
51
- /** Optional: of the calls agent made, fraction the evaluator marked as "correct selection". */
52
- selectionAccuracy?: number;
53
- }
54
- interface ToolStats {
55
- calls: number;
56
- callsWithCapturedArgs: number;
57
- errors: number;
58
- avgLatencyMs: number;
59
- duplicates: number;
60
- }
61
- interface ToolUseOptions {
62
- /** Map of spanId → whether the evaluator judged the tool selection correct. Optional. */
63
- selectionLabels?: Record<string, boolean>;
64
- }
65
- declare function computeToolUseMetrics(store: TraceStore, runId: string, options?: ToolUseOptions): Promise<ToolUseMetrics>;
66
- /**
67
- * Containment order: the one traversal that turns a flat list of spans into a
68
- * depth-first walk of their parent tree. `buildTrajectory` and
69
- * `diffStepsFromSpans` both order through it, each with its own comparator.
70
- *
71
- * Every input item is returned exactly once, with its depth. A root is an item
72
- * that names no parent, or names a parent id no input item has; roots are
73
- * ordered by `compare`, and so are the children of each parent. Items whose
74
- * ancestry loops without reaching a root are walked after every root: each one
75
- * not yet visited, in `compare` order, starts a subtree of its own. Ties in
76
- * `compare` keep input order.
77
- *
78
- * Containment order is not time order. A depth-first walk lists a whole branch
79
- * before its next sibling, so when branches run in parallel an item late in the
80
- * list can have started before an item early in it.
81
- */
82
- /** Why an item sits at depth 0 although it names a parent. */
83
- type DetachedCause =
84
- /** No input item has the parent id. */
85
- 'absent' |
86
- /** The parent is present, but its ancestry loops back without reaching a root. */
87
- 'cycle';
88
- interface TrajectoryStep {
89
- index: number;
90
- span: Span;
91
- /** Depth in the span tree from the root. 0 = top-level. */
92
- depth: number;
93
- /** Events attached to this span. */
94
- events: TraceEvent[];
95
- }
96
- /** A captured span placed at the root although it names a parent. */
97
- interface TrajectoryMissingParent {
98
- /** The span's step index in `Trajectory.steps`. */
99
- index: number;
100
- spanId: string;
101
- /** The parent id the span names. */
102
- parentSpanId: string;
103
- /**
104
- * `absent`: no captured span has `parentSpanId`. `cycle`: the parent is
105
- * captured, but its ancestry loops back to this span, so no captured root
106
- * holds it.
107
- */
108
- cause: DetachedCause;
109
- }
110
- interface Trajectory {
111
- runId: string;
112
- /** Every captured span once, in containment order; never a time order. */
113
- steps: TrajectoryStep[];
114
- /** Spans whose ancestry does not reach a captured root, in step order. Empty when there are none. */
115
- missingParents: TrajectoryMissingParent[];
116
- llmTurns: number;
117
- toolCalls: number;
118
- judgeVerdicts: number;
119
- retrievals: number;
120
- totalDurationMs: number;
121
- }
122
- declare function buildTrajectory(store: TraceStore, runId: string): Promise<Trajectory>;
123
- /** A step of a trajectory: its index in `steps`, or the id of its span. */
124
- type TrajectoryStepRef = number | {
125
- spanId: string;
126
- };
127
- /** What had settled, and what was still running, when one step started. */
128
- interface TrajectoryTimingBoundary {
129
- /** The step the boundary is drawn at. */
130
- target: TrajectoryStep;
131
- /** The target's ancestors and every step that ended before it started, in containment order. */
132
- prefix: TrajectoryStep[];
133
- /** Steps that started before the target and had not ended when it started, or never ended, in containment order. Ancestors are never listed here. */
134
- inFlight: TrajectoryStep[];
135
- }
136
- /**
137
- * The boundary at one step, read from span timing.
138
- *
139
- * `prefix` holds the target's ancestors plus every step that ended before the
140
- * target started. `inFlight` holds the steps, other than ancestors, that started
141
- * before the target and had not ended when it started, or never ended. Steps
142
- * that started after the target, and the target's own descendants, are in
143
- * neither. When a step's end equals the target's start exactly, or two steps
144
- * start at the same instant, the step counts as earlier only if it precedes the
145
- * target in containment order. Ancestry is read from the step tree (depths), so
146
- * duplicate span ids cannot confuse it.
147
- *
148
- * For a sequential trace, where every step before the target in `steps` is an
149
- * ancestor or had ended by the time the target started, and no later step
150
- * outside the target's subtree started before it, `prefix` equals
151
- * `steps.slice(0, target.index)` and `inFlight` is empty.
152
- *
153
- * Throws a ValidationError when `at` is out of range, names no span, or names a
154
- * span id that more than one step carries.
155
- *
156
- * Timing is necessary, not sufficient: a step in `prefix` had finished, but
157
- * nothing here proves the target consumed its output. Environment state at the
158
- * boundary, including the partial effects of `inFlight` steps, is the
159
- * executor's to restore.
160
- */
161
- declare function trajectoryTimingBoundary(trajectory: Trajectory, at: TrajectoryStepRef): TrajectoryTimingBoundary;
162
- interface BudgetBreachFinding {
163
- runId: string;
164
- scenarioId: string;
165
- variantId?: string;
166
- dimension: keyof BudgetSpec;
167
- limit: number;
168
- consumed: number;
169
- excessRatio: number;
170
- timestamp: number;
171
- }
172
- interface BudgetBreachReport {
173
- findings: BudgetBreachFinding[];
174
- byDimension: Record<string, number>;
175
- byScenario: Record<string, number>;
176
- byVariant: Record<string, number>;
177
- totalRuns: number;
178
- breachedRunRatio: number;
179
- }
180
- declare function budgetBreachView(store: TraceStore, options?: {
181
- scenarioId?: string;
182
- variantId?: string;
183
- }): Promise<BudgetBreachReport>;
184
- interface JudgePair {
185
- judgeA: string;
186
- judgeB: string;
187
- dimension: string;
188
- /** Number of (targetSpanId, dimension) tuples both judges scored. */
189
- commonItems: number;
190
- pearson: number;
191
- krippendorff: number;
192
- }
193
- interface JudgeAgreementReport {
194
- pairs: JudgePair[];
195
- dimensions: string[];
196
- judgeIds: string[];
197
- }
198
- declare function judgeAgreementView(store: TraceStore): Promise<JudgeAgreementReport>;
199
- interface ToolWasteFinding {
200
- runId: string;
201
- wastedCalls: number;
202
- totalCalls: number;
203
- wasteRate: number;
204
- }
205
- interface ToolWasteReport {
206
- byRun: ToolWasteFinding[];
207
- overallWasteRate: number;
208
- }
209
- interface ToolWasteOptions {
210
- runId?: string;
211
- usageOracle?: (tool: ToolSpan, later: {
212
- llm: Awaited<ReturnType<typeof llmSpans>>;
213
- }) => boolean;
214
- }
215
- declare function toolWasteView(store: TraceStore, options?: ToolWasteOptions): Promise<ToolWasteReport>;
216
- export { WelchTestResult as C, welchsTTest as E, BaselineOptions as S, iqr as T, trajectoryTimingBoundary as _, JudgeAgreementReport as a, ToolUseOptions as b, BudgetBreachFinding as c, Trajectory as d, TrajectoryMissingParent as f, buildTrajectory as g, TrajectoryTimingBoundary as h, toolWasteView as i, BudgetBreachReport as l, TrajectoryStepRef as m, ToolWasteOptions as n, JudgePair as o, TrajectoryStep as p, ToolWasteReport as r, judgeAgreementView as s, ToolWasteFinding as t, budgetBreachView as u, ToolStats as v, WelchTestStatus as w, computeToolUseMetrics as x, ToolUseMetrics as y };
217
- //# sourceMappingURL=tool-waste-CIhtU1ad.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tool-waste-CIhtU1ad.d.ts","names":[],"sources":["../src/baseline.ts","../src/tool-use-metrics.ts","../src/trace/containment-order.ts","../src/trajectory.ts","../src/pipelines/budget-breach.ts","../src/pipelines/judge-agreement.ts","../src/pipelines/tool-waste.ts"],"mappings":";;;UAwCiB;;EAEf;;EAEA;;EAEA;;KAGU;;UAGF;EACR;EACA;EACA;;KAGU,mBACP;EACC;EACA;EACA;EACA;EACA;EACA;EACA;MAED;EACC;EACA;EACA;EACA;EACA;EACA;EACA;;;iBAkEU,IAAI;;iBAOJ,YAAY,aAAa,cAAc;UCvItC;EACf;EACA;;EAEA;EACA,QAAQ,eAAe;EACvB;;EAEA;;EAEA;;EAEA;;UAGe;EACf;EACA;EACA;EACA;EACA;;UAGe;;EAEf,kBAAkB;;iBAGE,sBACpB,OAAO,YACP,eACA,UAAS,iBACR,QAAQ;;;;;;;;;;;;;;;;;;KC3BC;;;;;UCIK;EACf;EACA,MAAM;;EAEN;;EAEA,QAAQ;;;UAIO;;EAEf;EACA;;EAEA;;;;;;EAMA,OAAO;;UAGQ;EACf;;EAEA,OAAO;;EAEP,gBAAgB;EAChB;EACA;EACA;EACA;EACA;;iBAGoB,gBAAgB,OAAO,YAAY,gBAAgB,QAAQ;;KAyDrE;EAA+B;;;UAG1B;;EAEf,QAAQ;;EAER,QAAQ;;EAER,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAqDI,yBACd,YAAY,YACZ,IAAI,oBACH;UC3Kc;EACf;EACA;EACA;EACA,iBAAiB;EACjB;EACA;EACA;EACA;;UAGe;EACf,UAAU;EACV,aAAa;EACb,YAAY;EACZ,WAAW;EACX;EACA;;iBAGoB,iBACpB,OAAO,YACP;EAAW;EAAqB;IAC/B,QAAQ;UCnBM;EACf;EACA;EACA;;EAEA;EACA;EACA;;UAGe;EACf,OAAO;EACP;EACA;;iBAGoB,mBAAmB,OAAO,aAAa,QAAQ;UCbpD;EACf;EACA;EACA;EACA;;UAGe;EACf,OAAO;EACP;;UAGe;EACf;EACA,eAAe,MAAM,UAAU;IAAS,KAAK,QAAQ,kBAAkB;;;iBAGnD,cACpB,OAAO,YACP,UAAS,mBACR,QAAQ"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"types-fuOwNq1C.d.ts","names":[],"sources":["../src/trace-analyst/types.ts","../src/trace-analyst/store-contract.ts","../src/trace-analyst/store-boundary.ts","../src/eval-tools.ts","../src/trace-analyst/tools.ts","../src/analyst/finding-signature.ts","../src/analyst/engine.ts","../src/analyst/finding-composition.ts","../src/analyst/finding-scope.ts","../src/analyst/types.ts"],"mappings":";;;;;;;;;;;KAsBY,uBAAuB;KAEvB;;;;UAKK;EACf;EACA;EACA;EACA;EACA,MAAM;EACN;EACA;EACA;EACA,QAAQ;EACR;EACA;EACA;EACA;EACA;;;EAGA,YAAY;;UAGG;EACf;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;UAGe;;EAEf;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;;EAGA;;;;;;;UAQe;;EAEf;;EAEA;;EAEA;;EAEA;EACA;EACA;;EAEA;;EAEA;;EAEA;;UAGe;EACf;EACA;EACA;EACA;EACA;EACA;;EAEA;EACA;IAAU;IAAqB;;;;;;EAK/B,gBAAgB;EAChB;IAAc;IAAkB;;;UAGjB;EACf,QAAQ;EACR;EACA;;;;;UAMe;EACf;EACA,QAAQ;EACR,YAAY;;UAGG;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