@tangle-network/agent-eval 1.0.12 → 1.0.13

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 (227) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/adapters/http.d.ts +2 -2
  3. package/dist/{agent-profile-CoD1Dotf.d.ts → agent-profile-CPv4tENR.d.ts} +2 -2
  4. package/dist/{agent-profile-CoD1Dotf.d.ts.map → agent-profile-CPv4tENR.d.ts.map} +1 -1
  5. package/dist/{agreement-irr-w-t3XUTD.js → agreement-irr-DXcXEt4I.js} +20 -23
  6. package/dist/agreement-irr-DXcXEt4I.js.map +1 -0
  7. package/dist/analyst/index.d.ts +59 -13
  8. package/dist/analyst/index.d.ts.map +1 -1
  9. package/dist/analyst/index.js +144 -57
  10. package/dist/analyst/index.js.map +1 -1
  11. package/dist/{analyze-runs-dGYmYNtb.js → analyze-runs-C7vWBDhl.js} +11 -11
  12. package/dist/{analyze-runs-dGYmYNtb.js.map → analyze-runs-C7vWBDhl.js.map} +1 -1
  13. package/dist/{analyze-runs-BYyMShsj.d.ts → analyze-runs-pJ4fhnYg.d.ts} +2 -2
  14. package/dist/{analyze-runs-BYyMShsj.d.ts.map → analyze-runs-pJ4fhnYg.d.ts.map} +1 -1
  15. package/dist/{benchmark-command-DZQrxqUL.js → benchmark-command-BRRhjX2k.js} +12 -14
  16. package/dist/benchmark-command-BRRhjX2k.js.map +1 -0
  17. package/dist/benchmarks/index.d.ts +4 -4
  18. package/dist/benchmarks/index.js +5 -5
  19. package/dist/builder-eval/index.js +1 -1
  20. package/dist/{calibration-DLzckXnn.js → calibration-CbZPApIO.js} +2 -2
  21. package/dist/{calibration-DLzckXnn.js.map → calibration-CbZPApIO.js.map} +1 -1
  22. package/dist/campaign/index.d.ts +6 -6
  23. package/dist/campaign/index.js +12 -12
  24. package/dist/{campaign-VKtf8HRr.js → campaign-DzLlT0So.js} +17 -17
  25. package/dist/{campaign-VKtf8HRr.js.map → campaign-DzLlT0So.js.map} +1 -1
  26. package/dist/{campaign-evidence-BICB3a9Z.js → campaign-evidence-CcA7a67m.js} +3 -3
  27. package/dist/{campaign-evidence-BICB3a9Z.js.map → campaign-evidence-CcA7a67m.js.map} +1 -1
  28. package/dist/cli.js +16 -10
  29. package/dist/cli.js.map +1 -1
  30. package/dist/{cluster-bootstrap-hNXESoc1.js → cluster-bootstrap-BteuR1hg.js} +2 -2
  31. package/dist/{cluster-bootstrap-hNXESoc1.js.map → cluster-bootstrap-BteuR1hg.js.map} +1 -1
  32. package/dist/contract/index.d.ts +9 -9
  33. package/dist/contract/index.js +14 -14
  34. package/dist/{decision-point-CErE7GnP.js → decision-point-CNyoKOkz.js} +13 -7
  35. package/dist/{decision-point-CErE7GnP.js.map → decision-point-CNyoKOkz.js.map} +1 -1
  36. package/dist/{default-registry-DKlKVXMx.d.ts → default-registry-BNv7eB1C.d.ts} +10 -7
  37. package/dist/default-registry-BNv7eB1C.d.ts.map +1 -0
  38. package/dist/{default-registry-gmDeN0KT.js → default-registry-eCkZFfuF.js} +6 -6
  39. package/dist/default-registry-eCkZFfuF.js.map +1 -0
  40. package/dist/{define-agent-eval-DyzJ0wOo.js → define-agent-eval-CjF2nTA3.js} +8 -8
  41. package/dist/{define-agent-eval-DyzJ0wOo.js.map → define-agent-eval-CjF2nTA3.js.map} +1 -1
  42. package/dist/{define-agent-eval-B9zPWFSK.d.ts → define-agent-eval-DKVYlm-T.d.ts} +7 -7
  43. package/dist/{define-agent-eval-B9zPWFSK.d.ts.map → define-agent-eval-DKVYlm-T.d.ts.map} +1 -1
  44. package/dist/{descriptive-BTzLL-aj.js → descriptive-B3Eb7tX0.js} +2 -2
  45. package/dist/{descriptive-BTzLL-aj.js.map → descriptive-B3Eb7tX0.js.map} +1 -1
  46. package/dist/diagnosis/index.d.ts +2 -2
  47. package/dist/diagnosis/index.js +1 -1
  48. package/dist/{dspy-rlm-engine-Xt3znknf.js → dspy-rlm-engine-_MEe2jIO.js} +3 -3
  49. package/dist/{dspy-rlm-engine-Xt3znknf.js.map → dspy-rlm-engine-_MEe2jIO.js.map} +1 -1
  50. package/dist/{engine-CaHaCc3W.d.ts → engine-rfV8Ff8V.d.ts} +2 -2
  51. package/dist/{engine-CaHaCc3W.d.ts.map → engine-rfV8Ff8V.d.ts.map} +1 -1
  52. package/dist/{eval-campaign-B-dQl_lA.js → eval-campaign-CZSCjxVb.js} +3 -3
  53. package/dist/{eval-campaign-B-dQl_lA.js.map → eval-campaign-CZSCjxVb.js.map} +1 -1
  54. package/dist/{evaluation-B0-KVXaV.d.ts → evaluation-DYAIkPQB.d.ts} +4 -4
  55. package/dist/{evaluation-B0-KVXaV.d.ts.map → evaluation-DYAIkPQB.d.ts.map} +1 -1
  56. package/dist/evaluation.d.ts +1 -1
  57. package/dist/{exact-types-CIViGj98.d.ts → exact-types-CaLLU1Pz.d.ts} +2 -2
  58. package/dist/{exact-types-CIViGj98.d.ts.map → exact-types-CaLLU1Pz.d.ts.map} +1 -1
  59. package/dist/experiment/index.d.ts +1 -1
  60. package/dist/experiment/index.js +9 -9
  61. package/dist/{external-optimizer-process-BgitfZ-Q.js → external-optimizer-process-za-SsIap.js} +2 -2
  62. package/dist/{external-optimizer-process-BgitfZ-Q.js.map → external-optimizer-process-za-SsIap.js.map} +1 -1
  63. package/dist/{external-optimizer-subprocess-CeHuAaMJ.js → external-optimizer-subprocess-B44kOfZb.js} +3 -3
  64. package/dist/external-optimizer-subprocess-B44kOfZb.js.map +1 -0
  65. package/dist/{feedback-trajectory-BgomnFOe.d.ts → feedback-trajectory-P37ju-gW.d.ts} +3 -3
  66. package/dist/{feedback-trajectory-BgomnFOe.d.ts.map → feedback-trajectory-P37ju-gW.d.ts.map} +1 -1
  67. package/dist/{finding-composition-DlvE1Qul.js → finding-composition-Belh_qU3.js} +12 -3
  68. package/dist/finding-composition-Belh_qU3.js.map +1 -0
  69. package/dist/{findings-store-Bp-0Guuv.js → findings-store-DWiBvJVM.js} +22 -5
  70. package/dist/findings-store-DWiBvJVM.js.map +1 -0
  71. package/dist/fuzz.js +1 -1
  72. package/dist/hosted/index.js +1 -1
  73. package/dist/{index-BwutH5i7.d.ts → index-BJM4rwP2.d.ts} +6 -6
  74. package/dist/{index-BwutH5i7.d.ts.map → index-BJM4rwP2.d.ts.map} +1 -1
  75. package/dist/{index-DAk2quYu.d.ts → index-C3t17kHu.d.ts} +16 -21
  76. package/dist/index-C3t17kHu.d.ts.map +1 -0
  77. package/dist/{index-Bn-P_XAl.d.ts → index-Dt6E4BHX.d.ts} +6 -6
  78. package/dist/{index-Bn-P_XAl.d.ts.map → index-Dt6E4BHX.d.ts.map} +1 -1
  79. package/dist/{index-ByJ20lyu.d.ts → index-chNyKroE.d.ts} +8 -8
  80. package/dist/{index-ByJ20lyu.d.ts.map → index-chNyKroE.d.ts.map} +1 -1
  81. package/dist/{index-CtcCSO1Y.d.ts → index-f09MX_H_.d.ts} +2 -2
  82. package/dist/{index-CtcCSO1Y.d.ts.map → index-f09MX_H_.d.ts.map} +1 -1
  83. package/dist/index.d.ts +52 -146
  84. package/dist/index.d.ts.map +1 -1
  85. package/dist/index.js +80 -204
  86. package/dist/index.js.map +1 -1
  87. package/dist/{integrity-B1V6klyO.js → integrity-Vx5xgn3s.js} +2 -2
  88. package/dist/{integrity-B1V6klyO.js.map → integrity-Vx5xgn3s.js.map} +1 -1
  89. package/dist/{judge-calibration-D93UCm1k.js → judge-calibration-DKR6Xi-w.js} +13 -36
  90. package/dist/judge-calibration-DKR6Xi-w.js.map +1 -0
  91. package/dist/judge-calibration-DnrbQaXI.d.ts.map +1 -1
  92. package/dist/{judge-gate-DMlX38B7.js → judge-gate-CIlBrn6q.js} +2 -2
  93. package/dist/{judge-gate-DMlX38B7.js.map → judge-gate-CIlBrn6q.js.map} +1 -1
  94. package/dist/{kind-factory-VKysp1ds.js → kind-factory-Cfz8DUCc.js} +2 -2
  95. package/dist/{kind-factory-VKysp1ds.js.map → kind-factory-Cfz8DUCc.js.map} +1 -1
  96. package/dist/{llm-judge-CyDyqb6V.js → llm-judge-CHLvjbVR.js} +14 -14
  97. package/dist/{llm-judge-CyDyqb6V.js.map → llm-judge-CHLvjbVR.js.map} +1 -1
  98. package/dist/{matrix-4DcRFJ7Q.d.ts → matrix-Cy3oy7Rq.d.ts} +2 -2
  99. package/dist/{matrix-4DcRFJ7Q.d.ts.map → matrix-Cy3oy7Rq.d.ts.map} +1 -1
  100. package/dist/{mean-DDFhslBt.js → mean-D1d6gedE.js} +28 -2
  101. package/dist/{mean-DDFhslBt.js.map → mean-D1d6gedE.js.map} +1 -1
  102. package/dist/meta-eval/index.d.ts +1 -1
  103. package/dist/meta-eval/index.js +6 -6
  104. package/dist/{mint-D9ZysYtY.js → mint-BH_3Ak2x.js} +3 -3
  105. package/dist/{mint-D9ZysYtY.js.map → mint-BH_3Ak2x.js.map} +1 -1
  106. package/dist/multishot/golden/index.d.ts +1 -1
  107. package/dist/multishot/index.d.ts +2 -2
  108. package/dist/openapi.json +1 -1
  109. package/dist/{outcome-observations-ahbNtxuP.js → outcome-observations-DZu5hLYF.js} +3 -3
  110. package/dist/{outcome-observations-ahbNtxuP.js.map → outcome-observations-DZu5hLYF.js.map} +1 -1
  111. package/dist/{paired-arms-C0Vd9bGG.js → paired-arms-3-tsXvvC.js} +5 -5
  112. package/dist/{paired-arms-C0Vd9bGG.js.map → paired-arms-3-tsXvvC.js.map} +1 -1
  113. package/dist/{paired-binary-B477lksS.js → paired-binary-CMzmSSd5.js} +2 -2
  114. package/dist/{paired-binary-B477lksS.js.map → paired-binary-CMzmSSd5.js.map} +1 -1
  115. package/dist/{paired-promotion-decision-5Pl_qJLX.js → paired-promotion-decision-CiueaTTj.js} +3 -3
  116. package/dist/{paired-promotion-decision-5Pl_qJLX.js.map → paired-promotion-decision-CiueaTTj.js.map} +1 -1
  117. package/dist/{paired-tests-kASEKpc-.js → paired-tests-Buh6feJ4.js} +2 -2
  118. package/dist/{paired-tests-kASEKpc-.js.map → paired-tests-Buh6feJ4.js.map} +1 -1
  119. package/dist/{pareto-DY_x3HHg.js → pareto-B34N-vnn.js} +7 -7
  120. package/dist/{pareto-DY_x3HHg.js.map → pareto-B34N-vnn.js.map} +1 -1
  121. package/dist/pipelines/index.js +1 -1
  122. package/dist/{power-and-mde-CRxepy8y.js → power-and-mde-g3vOn0XK.js} +3 -3
  123. package/dist/{power-and-mde-CRxepy8y.js.map → power-and-mde-g3vOn0XK.js.map} +1 -1
  124. package/dist/{prime-protocol-COFkxas6.d.ts → prime-protocol-DKRk4l4U.d.ts} +2 -2
  125. package/dist/{prime-protocol-COFkxas6.d.ts.map → prime-protocol-DKRk4l4U.d.ts.map} +1 -1
  126. package/dist/{promotion-policy-f79oklG_.js → promotion-policy-DLPcEnCf.js} +4 -4
  127. package/dist/{promotion-policy-f79oklG_.js.map → promotion-policy-DLPcEnCf.js.map} +1 -1
  128. package/dist/{proposal-findings-BclX0PFh.js → proposal-findings-CZJkS_GY.js} +2 -2
  129. package/dist/{proposal-findings-BclX0PFh.js.map → proposal-findings-CZJkS_GY.js.map} +1 -1
  130. package/dist/{registry-CMtGAxOw.d.ts → registry-Ck7w-rr5.d.ts} +3 -3
  131. package/dist/{registry-CMtGAxOw.d.ts.map → registry-Ck7w-rr5.d.ts.map} +1 -1
  132. package/dist/{release-confidence--1iP-d3x.js → release-confidence-nfQNh3eb.js} +4 -4
  133. package/dist/{release-confidence--1iP-d3x.js.map → release-confidence-nfQNh3eb.js.map} +1 -1
  134. package/dist/{render-CFrJ7M0o.js → render-BVPfP7dc.js} +52 -36
  135. package/dist/{render-CFrJ7M0o.js.map → render-BVPfP7dc.js.map} +1 -1
  136. package/dist/reporting.js +5 -5
  137. package/dist/{reward-P0VD_Aft.js → reward-DqMfaEax.js} +10 -2
  138. package/dist/{reward-P0VD_Aft.js.map → reward-DqMfaEax.js.map} +1 -1
  139. package/dist/{reward-hacking-D-Vi9-fE.js → reward-hacking-B88f-Kh7.js} +4 -4
  140. package/dist/{reward-hacking-D-Vi9-fE.js.map → reward-hacking-B88f-Kh7.js.map} +1 -1
  141. package/dist/rl.d.ts +3 -3
  142. package/dist/rl.js +12 -12
  143. package/dist/rollout/index.d.ts +2 -2
  144. package/dist/rollout/index.js +3 -3
  145. package/dist/{rollout-BC4u-d_I.js → rollout-CbOGxuHl.js} +2 -2
  146. package/dist/{rollout-BC4u-d_I.js.map → rollout-CbOGxuHl.js.map} +1 -1
  147. package/dist/{rollout-nodes-BHR9Q5jP.js → rollout-nodes-DKZ3vAYY.js} +2 -2
  148. package/dist/{rollout-nodes-BHR9Q5jP.js.map → rollout-nodes-DKZ3vAYY.js.map} +1 -1
  149. package/dist/{rubric-predictive-validity-BdxXDN6h.js → rubric-predictive-validity-D_6ZPTNR.js} +2 -2
  150. package/dist/{rubric-predictive-validity-BdxXDN6h.js.map → rubric-predictive-validity-D_6ZPTNR.js.map} +1 -1
  151. package/dist/{run-record-B-G2Tu11.js → run-record-CbUi2adH.js} +3 -3
  152. package/dist/{run-record-B-G2Tu11.js.map → run-record-CbUi2adH.js.map} +1 -1
  153. package/dist/{run-record-DEjx43cI.js → run-record-CpLS4Uid.js} +2 -2
  154. package/dist/{run-record-DEjx43cI.js.map → run-record-CpLS4Uid.js.map} +1 -1
  155. package/dist/search/index.d.ts +2 -2
  156. package/dist/search/index.js +2 -2
  157. package/dist/{search-kernel-BjR2Sr7w.d.ts → search-kernel-kwO-sgCq.d.ts} +2 -2
  158. package/dist/{search-kernel-BjR2Sr7w.d.ts.map → search-kernel-kwO-sgCq.d.ts.map} +1 -1
  159. package/dist/{search-ledger-BsVi-Ngv.js → search-ledger-CV_bQQed.js} +2 -2
  160. package/dist/{search-ledger-BsVi-Ngv.js.map → search-ledger-CV_bQQed.js.map} +1 -1
  161. package/dist/{search-shipper-pdg4viK7.js → search-shipper-CA3ooBbC.js} +2 -2
  162. package/dist/{search-shipper-pdg4viK7.js.map → search-shipper-CA3ooBbC.js.map} +1 -1
  163. package/dist/{search-summary-DedyTdiM.js → search-summary-DBMjdecs.js} +4 -4
  164. package/dist/{search-summary-DedyTdiM.js.map → search-summary-DBMjdecs.js.map} +1 -1
  165. package/dist/{sequential-Zp1tsxqI.js → sequential-BPbvgzfe.js} +2 -2
  166. package/dist/{sequential-Zp1tsxqI.js.map → sequential-BPbvgzfe.js.map} +1 -1
  167. package/dist/{skillopt-optimization-method-O35aMdxU.js → skillopt-optimization-method-D72XZZfR.js} +9 -9
  168. package/dist/{skillopt-optimization-method-O35aMdxU.js.map → skillopt-optimization-method-D72XZZfR.js.map} +1 -1
  169. package/dist/{statistical-heldout-DYF5f10K.js → statistical-heldout-NBxC7jGo.js} +3 -3
  170. package/dist/{statistical-heldout-DYF5f10K.js.map → statistical-heldout-NBxC7jGo.js.map} +1 -1
  171. package/dist/{statistical-heldout-bU7FBNjR.d.ts → statistical-heldout-_dXihc9T.d.ts} +3 -3
  172. package/dist/{statistical-heldout-bU7FBNjR.d.ts.map → statistical-heldout-_dXihc9T.d.ts.map} +1 -1
  173. package/dist/{store-otlp-DmLm65XW.js → store-otlp-BfPRa2p8.js} +2 -2
  174. package/dist/{store-otlp-DmLm65XW.js.map → store-otlp-BfPRa2p8.js.map} +1 -1
  175. package/dist/{store-tool-spans-lWf6INTH.d.ts → store-tool-spans-BgwVHXma.d.ts} +4 -4
  176. package/dist/{store-tool-spans-lWf6INTH.d.ts.map → store-tool-spans-BgwVHXma.d.ts.map} +1 -1
  177. package/dist/{store-tool-spans-GGaCijFy.js → store-tool-spans-BrSWHB9O.js} +3 -3
  178. package/dist/{store-tool-spans-GGaCijFy.js.map → store-tool-spans-BrSWHB9O.js.map} +1 -1
  179. package/dist/{summary-report-B4BLQb88.js → summary-report-C3IJvp0i.js} +7 -7
  180. package/dist/{summary-report-B4BLQb88.js.map → summary-report-C3IJvp0i.js.map} +1 -1
  181. package/dist/supervisor-run/index.d.ts +6 -0
  182. package/dist/supervisor-run/index.d.ts.map +1 -1
  183. package/dist/supervisor-run/index.js +3 -3
  184. package/dist/{systemone-BDVgb6XV.d.ts → systemone-CBvL1gx-.d.ts} +14 -8
  185. package/dist/systemone-CBvL1gx-.d.ts.map +1 -0
  186. package/dist/{systemone-review-S49gsy_y.js → systemone-review-BusEIzsg.js} +2 -2
  187. package/dist/{systemone-review-S49gsy_y.js.map → systemone-review-BusEIzsg.js.map} +1 -1
  188. package/dist/{systemone-review-BLgxt-4Q.d.ts → systemone-review-nbuMxxmi.d.ts} +2 -2
  189. package/dist/{systemone-review-BLgxt-4Q.d.ts.map → systemone-review-nbuMxxmi.d.ts.map} +1 -1
  190. package/dist/systemone.d.ts +4 -4
  191. package/dist/systemone.js +3 -3
  192. package/dist/{tool-groups-C3K-d3gd.d.ts → tool-groups-BQsjZD9F.d.ts} +3 -3
  193. package/dist/tool-groups-BQsjZD9F.d.ts.map +1 -0
  194. package/dist/{tool-waste-CRJqOASv.js → tool-waste-Czt3aWID.js} +3 -3
  195. package/dist/{tool-waste-CRJqOASv.js.map → tool-waste-Czt3aWID.js.map} +1 -1
  196. package/dist/{trace-questions-ej5AEJ5X.d.ts → trace-questions-CpTrtEcm.d.ts} +3 -3
  197. package/dist/{trace-questions-ej5AEJ5X.d.ts.map → trace-questions-CpTrtEcm.d.ts.map} +1 -1
  198. package/dist/trace-repair/index.d.ts +1 -1
  199. package/dist/trace-repair/index.js +2 -2
  200. package/dist/traces.d.ts +3 -3
  201. package/dist/traces.js +4 -4
  202. package/dist/{tree-C2N31CoI.js → tree-DPwgM2LX.js} +6 -6
  203. package/dist/{tree-C2N31CoI.js.map → tree-DPwgM2LX.js.map} +1 -1
  204. package/dist/{types-DzCO-S1m.d.ts → types-B9s9Xo5_.d.ts} +24 -2
  205. package/dist/types-B9s9Xo5_.d.ts.map +1 -0
  206. package/dist/{types-BF-xQGQn.d.ts → types-CBkDo7ja.d.ts} +2 -2
  207. package/dist/{types-BF-xQGQn.d.ts.map → types-CBkDo7ja.d.ts.map} +1 -1
  208. package/dist/{types-BK0blWhe.js → types-CL1_N7AZ.js} +2 -2
  209. package/dist/{types-BK0blWhe.js.map → types-CL1_N7AZ.js.map} +1 -1
  210. package/dist/{types-yofaDmQa.d.ts → types-D91tnhzf.d.ts} +2 -2
  211. package/dist/{types-yofaDmQa.d.ts.map → types-D91tnhzf.d.ts.map} +1 -1
  212. package/dist/wire/index.d.ts +1 -1
  213. package/docs/behavioral-trace-questions.md +23 -0
  214. package/docs/public-api.md +1 -1
  215. package/package.json +2 -2
  216. package/dist/agreement-irr-w-t3XUTD.js.map +0 -1
  217. package/dist/benchmark-command-DZQrxqUL.js.map +0 -1
  218. package/dist/default-registry-DKlKVXMx.d.ts.map +0 -1
  219. package/dist/default-registry-gmDeN0KT.js.map +0 -1
  220. package/dist/external-optimizer-subprocess-CeHuAaMJ.js.map +0 -1
  221. package/dist/finding-composition-DlvE1Qul.js.map +0 -1
  222. package/dist/findings-store-Bp-0Guuv.js.map +0 -1
  223. package/dist/index-DAk2quYu.d.ts.map +0 -1
  224. package/dist/judge-calibration-D93UCm1k.js.map +0 -1
  225. package/dist/systemone-BDVgb6XV.d.ts.map +0 -1
  226. package/dist/tool-groups-C3K-d3gd.d.ts.map +0 -1
  227. package/dist/types-DzCO-S1m.d.ts.map +0 -1
@@ -1,12 +1,13 @@
1
1
  import { a as hashCanonical } from "./canonical-CicJlINA.js";
2
- import { c as unscreenedRewardFields } from "./reward-P0VD_Aft.js";
3
- import { c as summarizeNumberSeries } from "./descriptive-BTzLL-aj.js";
2
+ import { l as unscreenedRewardFields, o as screenedRewardFields } from "./reward-DqMfaEax.js";
3
+ import { c as summarizeNumberSeries } from "./descriptive-B3Eb7tX0.js";
4
4
  import { t as roundDecimal } from "./round-decimal-ZmjAQPo1.js";
5
5
  import { S as licenseClassOfName } from "./schema-YUIXT8iW.js";
6
- import { _ as showMeasured, a as readTerminalRecord, c as parseJsonRecord, d as recordOrNull, f as workerSourceKey, g as isUnavailable, h as SUPERVISOR_RUN_SCHEMA, l as parseJsonl, n as supervisorRunRolloutLinesFromFacts, o as asRecord, p as NO_SOURCE_LIMITS, s as nonEmptyString, u as parseSupervisorTree, v as unavailable, y as expandJournalEventGroup } from "./rollout-nodes-BHR9Q5jP.js";
6
+ import { _ as showMeasured, a as readTerminalRecord, c as parseJsonRecord, d as recordOrNull, f as workerSourceKey, g as isUnavailable, h as SUPERVISOR_RUN_SCHEMA, l as parseJsonl, n as supervisorRunRolloutLinesFromFacts, o as asRecord, p as NO_SOURCE_LIMITS, s as nonEmptyString, u as parseSupervisorTree, v as unavailable, y as expandJournalEventGroup } from "./rollout-nodes-DKZ3vAYY.js";
7
7
  import { basename, join } from "node:path";
8
8
  import { execFile } from "node:child_process";
9
9
  import { readFile, readdir, stat } from "node:fs/promises";
10
+ import { sandboxEventsSession, toChatMessages, toOtlpSpans } from "@tangle-network/harness-sessions";
10
11
  import { promisify } from "node:util";
11
12
  // src/supervisor-run/analyze-context.ts
12
13
  /** The parsed sources and shared lookups every metric group reads. `gap` records an unavailable measurement on the report. */
@@ -1378,16 +1379,18 @@ async function isFile(path) {
1378
1379
  * - Producer: each node's `materialized` receipt names the model it ran on
1379
1380
  * (`opencode/zai-coding-plan/glm-5.3` → harness, provider, model), and the
1380
1381
  * root's `root-segment` names the root's. The license class follows.
1381
- * - Episode text: the node's task prompt (its `taskDigest` blob) and its
1382
- * final answer (its `outRef` blob), when the run kept both. The tool calls
1383
- * between them are not inlined, so the row stays a lossy projection.
1382
+ * - Episode: the node's task prompt (its `taskDigest` blob) and its settled
1383
+ * result (its `outRef` blob, `{content, events}`), read as a Sandbox session
1384
+ * with every tool call. A result without events stays a lossy projection.
1384
1385
  * - A node respawned under the same id (a reopened run) is one row.
1385
1386
  * - Reward: the run's newest known play-check verdict on the root row
1386
1387
  * (`solved` → 1, a staged `SCORE` → stages passed / stages), and each
1387
1388
  * agent's own commits on its `workers/<label>` branch of `deliverables.git`.
1389
+ * - Screen: the calibration frozen in the run's receipt, where a fake fixture
1390
+ * failed every stage of the check, and the goal audit, whose `contradiction`
1391
+ * gates the reward. A check nothing calibrated stays unscreened.
1388
1392
  *
1389
- * Every read is of files the run already wrote; nothing in the run dir is
1390
- * changed. Rewards stay unscreened: no realness screen ran on a play-check.
1393
+ * Every read is of files the run already wrote; nothing in the run dir is changed.
1391
1394
  */
1392
1395
  const run = promisify(execFile);
1393
1396
  /** A run's pursuit: its directory name without the `-YYYYMMDD<letter>` date suffix. */
@@ -1413,6 +1416,14 @@ function producerOf(id) {
1413
1416
  model: id
1414
1417
  };
1415
1418
  }
1419
+ /** A row holding the agent's whole stream is no longer lossy; a workspace capture gap still stands. */
1420
+ function wholeEpisode({ lossy_projection: _, gap, ...kept }) {
1421
+ const workspace = gap?.match(/workspace capture evidence \w+/u)?.[0];
1422
+ return workspace === void 0 ? kept : {
1423
+ ...kept,
1424
+ gap: workspace
1425
+ };
1426
+ }
1416
1427
  const record = (v) => v !== null && typeof v === "object" && !Array.isArray(v) ? v : null;
1417
1428
  const text = (v) => typeof v === "string" && v.length > 0 ? v : void 0;
1418
1429
  async function journalFacts(runDir) {
@@ -1423,15 +1434,7 @@ async function journalFacts(runDir) {
1423
1434
  facts.set(id, fact);
1424
1435
  return fact;
1425
1436
  };
1426
- for (const line of raw.split("\n")) {
1427
- if (!line.trim()) continue;
1428
- let row;
1429
- try {
1430
- row = record(JSON.parse(line));
1431
- } catch {
1432
- continue;
1433
- }
1434
- if (row === null) continue;
1437
+ for (const row of parseJsonl(raw)) {
1435
1438
  const expanded = expandJournalEventGroup(row);
1436
1439
  if (!expanded.succeeded) continue;
1437
1440
  for (const entry of expanded.value) {
@@ -1455,16 +1458,17 @@ async function journalFacts(runDir) {
1455
1458
  }
1456
1459
  return facts;
1457
1460
  }
1458
- async function blobText(runDir, ref) {
1461
+ async function blobValue(runDir, ref) {
1459
1462
  if (ref === void 0 || !/^sha256:[0-9a-f]{64}$/u.test(ref)) return void 0;
1460
1463
  const raw = await readFile(join(runDir, "blobs", `${ref.replace(":", "-")}.json`), "utf8").catch(() => void 0);
1461
1464
  if (raw === void 0) return void 0;
1462
1465
  try {
1463
- return text(JSON.parse(raw));
1466
+ return JSON.parse(raw);
1464
1467
  } catch {
1465
1468
  return;
1466
1469
  }
1467
1470
  }
1471
+ const jsonlRows = async (path) => parseJsonl(await readFile(path, "utf8").catch(() => null));
1468
1472
  /**
1469
1473
  * The newest play-check row whose verdict is known. A staged check
1470
1474
  * (`SCORE {"reached": r, "of": n}`) that is not solved failed at stage r, so it
@@ -1472,12 +1476,7 @@ async function blobText(runDir, ref) {
1472
1476
  * Only the SCORE line itself is parsed; the check prints more lines after it.
1473
1477
  */
1474
1478
  async function discoveryPlayCheckReward(runDir) {
1475
- const rows = [];
1476
- const lines = await readFile(join(runDir, "play-checks.jsonl"), "utf8").catch(() => "");
1477
- for (const line of lines.split("\n")) try {
1478
- const row = record(JSON.parse(line));
1479
- if (row) rows.push(row);
1480
- } catch {}
1479
+ const rows = await jsonlRows(join(runDir, "play-checks.jsonl"));
1481
1480
  if (rows.length === 0) {
1482
1481
  const single = await readFile(join(runDir, "play-check.json"), "utf8").catch(() => null);
1483
1482
  try {
@@ -1496,8 +1495,15 @@ async function discoveryPlayCheckReward(runDir) {
1496
1495
  const of = staged?.of;
1497
1496
  if (Number.isSafeInteger(reached) && Number.isSafeInteger(of) && 1 <= reached && reached <= of) reward = (reached - 1) / of;
1498
1497
  } catch {}
1498
+ const key = last.contentHash ?? last.commit ?? last.at;
1499
+ const ruling = (await jsonlRows(join(runDir, "goal-audits.jsonl"))).filter((a) => a.key === key && a.verdict !== "unavailable").at(-1);
1500
+ const receipt = await readFile(join(runDir, "RECEIPT.json"), "utf8").then(JSON.parse, () => null);
1501
+ const calibration = record(record(record(receipt)?.check)?.calibration);
1502
+ const stages = Object.values(record(calibration?.stages) ?? {});
1499
1503
  return {
1500
1504
  reward,
1505
+ calibrated: stages.length > 0 && stages.every((state) => state === "calibrated"),
1506
+ contradicted: (ruling?.verdict ?? record(last.goalAudit)?.verdict) === "contradiction",
1501
1507
  at: String(last.at ?? ""),
1502
1508
  commit: typeof last.commit === "string" ? last.commit : null,
1503
1509
  detail: detail.slice(0, 500)
@@ -1559,16 +1565,28 @@ async function discoveryRunRolloutLines(runDir, options = {}) {
1559
1565
  const check = await discoveryPlayCheckReward(runDir);
1560
1566
  const commits = await deliverableCommits(runDir);
1561
1567
  const lines = [];
1568
+ const otlp = /* @__PURE__ */ new Map();
1562
1569
  for (const node of tree.nodes) {
1563
1570
  const fact = facts.get(node.rollout_id) ?? {};
1564
1571
  const producer = fact.model === void 0 ? null : producerOf(fact.model);
1565
1572
  const license = licenseClassOfName(producer?.model) ?? licenseClassOfName(producer?.harness);
1566
- const [task, answer] = await Promise.all([blobText(runDir, fact.taskRef), blobText(runDir, fact.outRef)]);
1573
+ const [taskBlob, result] = await Promise.all([blobValue(runDir, fact.taskRef), blobValue(runDir, fact.outRef)]);
1574
+ const task = text(taskBlob);
1575
+ const answer = text(result) ?? text(record(result)?.content);
1576
+ const events = record(result)?.events;
1577
+ const stream = Array.isArray(events) ? events : [];
1578
+ const session = task === void 0 || answer === void 0 ? null : sandboxEventsSession({
1579
+ harness: producer?.harness ?? node.policy.harness ?? "sandbox",
1580
+ nativeSessionId: node.rollout_id,
1581
+ task,
1582
+ answer,
1583
+ events: stream
1584
+ });
1567
1585
  const label = typeof node.outcome.metrics.label === "string" ? node.outcome.metrics.label : null;
1568
1586
  const isRoot = node.parent_rollout_id === null;
1569
1587
  const outcome = isRoot && check !== null ? {
1570
1588
  ...node.outcome,
1571
- ...unscreenedRewardFields(check.reward),
1589
+ ...check.calibrated || check.contradicted ? screenedRewardFields(check.reward, check.contradicted) : unscreenedRewardFields(check.reward),
1572
1590
  reward_source: "discovery/play-check",
1573
1591
  verdict: {
1574
1592
  at: check.at,
@@ -1576,6 +1594,8 @@ async function discoveryRunRolloutLines(runDir, options = {}) {
1576
1594
  detail: check.detail
1577
1595
  }
1578
1596
  } : node.outcome;
1597
+ const spans = session === null ? [] : toOtlpSpans(session);
1598
+ otlp.set(node.rollout_id, spans.map((span) => `${JSON.stringify(span)}\n`).join(""));
1579
1599
  lines.push({
1580
1600
  ...node,
1581
1601
  policy: {
@@ -1587,13 +1607,8 @@ async function discoveryRunRolloutLines(runDir, options = {}) {
1587
1607
  },
1588
1608
  ...license === null ? {} : { license_class: license }
1589
1609
  },
1590
- messages: task !== void 0 && answer !== void 0 ? [{
1591
- role: "user",
1592
- content: task
1593
- }, {
1594
- role: "assistant",
1595
- content: answer
1596
- }] : node.messages,
1610
+ messages: session === null ? node.messages : toChatMessages(session),
1611
+ provenance: stream.length === 0 ? node.provenance : wholeEpisode(node.provenance),
1597
1612
  outcome: {
1598
1613
  ...outcome,
1599
1614
  metrics: {
@@ -1609,7 +1624,8 @@ async function discoveryRunRolloutLines(runDir, options = {}) {
1609
1624
  pursuit,
1610
1625
  lines,
1611
1626
  gaps: tree.gaps.filter((gap) => check === null || gap.code !== "root-reward-unavailable"),
1612
- notes
1627
+ notes,
1628
+ otlp
1613
1629
  };
1614
1630
  }
1615
1631
  // src/supervisor-run/reader.ts
@@ -1866,4 +1882,4 @@ function renderSupervisorRollupMarkdown(rollup, title = "Round rollup") {
1866
1882
  }
1867
1883
  export { findSupervisorRunDirs as a, discoveryRunRolloutLines as c, analyzeSupervisorRunSources as d, parsePatch as f, analyzeSupervisorRun as i, isRuntimeSupervisorRunDir as l, renderSupervisorRunHeadline as n, discoveryPlayCheckReward as o, renderSupervisorRunMarkdown as r, discoveryPursuitOf as s, renderSupervisorRollupMarkdown as t, readRuntimeSupervisorRun as u };
1868
1884
 
1869
- //# sourceMappingURL=render-CFrJ7M0o.js.map
1885
+ //# sourceMappingURL=render-BVPfP7dc.js.map