@tangle-network/agent-eval 0.118.2 → 0.119.0

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 (67) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/README.md +26 -0
  3. package/dist/analyst/index.d.ts +143 -21
  4. package/dist/analyst/index.js +46 -12
  5. package/dist/analyst/index.js.map +1 -1
  6. package/dist/benchmarks/index.d.ts +50 -40
  7. package/dist/benchmarks/index.js +9 -9
  8. package/dist/campaign/index.d.ts +231 -156
  9. package/dist/campaign/index.js +8 -8
  10. package/dist/{chunk-JTMFT5QZ.js → chunk-4I2E3LLO.js} +2 -2
  11. package/dist/{chunk-BUBU3YHT.js → chunk-6QIM2EAP.js} +6 -116
  12. package/dist/chunk-6QIM2EAP.js.map +1 -0
  13. package/dist/{chunk-DZBCDDIE.js → chunk-7A4LIMMY.js} +846 -253
  14. package/dist/chunk-7A4LIMMY.js.map +1 -0
  15. package/dist/{chunk-KK2O4VWA.js → chunk-D7AEXSM5.js} +2 -2
  16. package/dist/{chunk-GCT3DQWU.js → chunk-F6YUH3L4.js} +41 -30
  17. package/dist/{chunk-GCT3DQWU.js.map → chunk-F6YUH3L4.js.map} +1 -1
  18. package/dist/{chunk-63KG3ASG.js → chunk-FIUFRXP3.js} +2 -2
  19. package/dist/{chunk-J23QK2U5.js → chunk-GERDAIAL.js} +8 -8
  20. package/dist/{chunk-J23QK2U5.js.map → chunk-GERDAIAL.js.map} +1 -1
  21. package/dist/{chunk-TVXPJJ7H.js → chunk-H5UD2323.js} +2 -2
  22. package/dist/{chunk-MLHRFWQK.js → chunk-JHOJHHU7.js} +85 -16
  23. package/dist/chunk-JHOJHHU7.js.map +1 -0
  24. package/dist/chunk-K4DBDHLK.js +158 -0
  25. package/dist/chunk-K4DBDHLK.js.map +1 -0
  26. package/dist/{chunk-DRSFTBKU.js → chunk-LMJ2TGWJ.js} +3 -15
  27. package/dist/chunk-LMJ2TGWJ.js.map +1 -0
  28. package/dist/{chunk-EGNRE7VA.js → chunk-PAHNGS65.js} +2 -2
  29. package/dist/{chunk-I42AAGHL.js → chunk-RLCJQ6VZ.js} +5 -5
  30. package/dist/{chunk-7V3QDWNL.js → chunk-XJ7JVCHB.js} +2 -2
  31. package/dist/{chunk-6JQE3YVE.js → chunk-ZYHJNKI3.js} +6 -6
  32. package/dist/cli.js +2 -2
  33. package/dist/contract/index.d.ts +257 -160
  34. package/dist/contract/index.js +11 -11
  35. package/dist/fuzz.d.ts +19 -1
  36. package/dist/fuzz.js +1 -1
  37. package/dist/index.d.ts +170 -64
  38. package/dist/index.js +30 -28
  39. package/dist/index.js.map +1 -1
  40. package/dist/openapi.json +1 -1
  41. package/dist/primeintellect/index.d.ts +311 -0
  42. package/dist/primeintellect/index.js +348 -0
  43. package/dist/primeintellect/index.js.map +1 -0
  44. package/dist/rl.d.ts +4 -0
  45. package/dist/{run-campaign-DWC67KJP.js → run-campaign-OBXSN5WK.js} +3 -3
  46. package/dist/trace-attributes.d.ts +17 -1
  47. package/dist/trace-attributes.js +27 -3
  48. package/dist/traces.d.ts +16 -16
  49. package/dist/traces.js +18 -18
  50. package/dist/wire/index.d.ts +19 -1
  51. package/dist/wire/index.js +2 -2
  52. package/package.json +6 -1
  53. package/dist/chunk-BUBU3YHT.js.map +0 -1
  54. package/dist/chunk-DRSFTBKU.js.map +0 -1
  55. package/dist/chunk-DZBCDDIE.js.map +0 -1
  56. package/dist/chunk-MLHRFWQK.js.map +0 -1
  57. package/dist/chunk-NW4AQBXD.js +0 -53
  58. package/dist/chunk-NW4AQBXD.js.map +0 -1
  59. /package/dist/{chunk-JTMFT5QZ.js.map → chunk-4I2E3LLO.js.map} +0 -0
  60. /package/dist/{chunk-KK2O4VWA.js.map → chunk-D7AEXSM5.js.map} +0 -0
  61. /package/dist/{chunk-63KG3ASG.js.map → chunk-FIUFRXP3.js.map} +0 -0
  62. /package/dist/{chunk-TVXPJJ7H.js.map → chunk-H5UD2323.js.map} +0 -0
  63. /package/dist/{chunk-EGNRE7VA.js.map → chunk-PAHNGS65.js.map} +0 -0
  64. /package/dist/{chunk-I42AAGHL.js.map → chunk-RLCJQ6VZ.js.map} +0 -0
  65. /package/dist/{chunk-7V3QDWNL.js.map → chunk-XJ7JVCHB.js.map} +0 -0
  66. /package/dist/{chunk-6JQE3YVE.js.map → chunk-ZYHJNKI3.js.map} +0 -0
  67. /package/dist/{run-campaign-DWC67KJP.js.map → run-campaign-OBXSN5WK.js.map} +0 -0
package/dist/fuzz.d.ts CHANGED
@@ -1,8 +1,14 @@
1
1
  type CostChannel = 'agent' | 'judge' | 'verifier' | 'analyst' | 'driver' | (string & {});
2
2
  interface CostUsage {
3
3
  inputTokens: number;
4
+ /** Includes reasoning tokens when the provider bills them as output. */
4
5
  outputTokens: number;
6
+ /** Reasoning-token subset of outputTokens, when reported. */
7
+ reasoningTokens?: number;
8
+ /** Prompt tokens served from a provider cache. */
5
9
  cachedTokens?: number;
10
+ /** Prompt tokens written into a provider cache. */
11
+ cacheWriteTokens?: number;
6
12
  }
7
13
  interface CostCallBase {
8
14
  callId: string;
@@ -69,7 +75,9 @@ interface ChannelRollup {
69
75
  calls: number;
70
76
  inputTokens: number;
71
77
  outputTokens: number;
78
+ reasoningTokens?: number;
72
79
  cachedTokens: number;
80
+ cacheWriteTokens?: number;
73
81
  costUsd: number;
74
82
  unpricedCalls: number;
75
83
  unknownUsageCalls: number;
@@ -81,7 +89,9 @@ interface CostLedgerSummary {
81
89
  reservedCostUsd: number;
82
90
  inputTokens: number;
83
91
  outputTokens: number;
92
+ reasoningTokens?: number;
84
93
  cachedTokens: number;
94
+ cacheWriteTokens?: number;
85
95
  totalCostUsd: number;
86
96
  byChannel: ChannelRollup[];
87
97
  unpricedModels: string[];
@@ -95,6 +105,10 @@ interface CostLedgerFilter {
95
105
  phase?: string;
96
106
  tags?: Record<string, string>;
97
107
  }
108
+ interface CostLedgerWaitOptions {
109
+ /** Maximum time to wait for active provider calls. Default 5 seconds. */
110
+ timeoutMs?: number;
111
+ }
98
112
  /** Append-only storage. `append` must atomically reject stale revisions. */
99
113
  interface CostLedgerPersistence {
100
114
  read(): {
@@ -114,6 +128,7 @@ declare class CostLedger {
114
128
  private readonly records;
115
129
  private readonly activeCallIds;
116
130
  private readonly lateCallIds;
131
+ private readonly idleWaiters;
117
132
  private completedTasks;
118
133
  private revision;
119
134
  private costLimitPersisted;
@@ -121,6 +136,8 @@ declare class CostLedger {
121
136
  private readonly persistence?;
122
137
  constructor(input?: number | CostLedgerOptions);
123
138
  runPaidCall<T>(input: RunPaidCallInput<T>): Promise<PaidCallResult<T>>;
139
+ /** Wait until every call started by this ledger has produced a durable outcome. */
140
+ waitForIdle(options?: CostLedgerWaitOptions): Promise<boolean>;
124
141
  /** Settle a call left pending by a crashed process after reconciling with the provider. */
125
142
  reconcile(callId: string, observed: CostReceiptInput, options?: {
126
143
  error?: string;
@@ -131,6 +148,7 @@ declare class CostLedger {
131
148
  costPerCompletedTask(): number | null;
132
149
  private execute;
133
150
  private captureLateOutcome;
151
+ private releaseActiveCall;
134
152
  private commitOutcome;
135
153
  private captureFailure;
136
154
  private commitReceipt;
@@ -146,7 +164,7 @@ declare class CostLedger {
146
164
  * Keeping callback contracts structural lets those subpaths compose while the
147
165
  * concrete {@link CostLedger} retains its private durable state.
148
166
  */
149
- type CostLedgerHandle = Pick<CostLedger, keyof CostLedger>;
167
+ type CostLedgerHandle = Pick<CostLedger, Exclude<keyof CostLedger, 'waitForIdle'>> & Partial<Pick<CostLedger, 'waitForIdle'>>;
150
168
 
151
169
  /**
152
170
  * Adversarial mutation contract.
package/dist/fuzz.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  CostLedger,
3
3
  CostReceiptCaptureError
4
- } from "./chunk-MLHRFWQK.js";
4
+ } from "./chunk-JHOJHHU7.js";
5
5
  import "./chunk-VI2UW6B6.js";
6
6
  import {
7
7
  varianceBasedCurriculum