@leostera/evalkit 0.9.0 → 0.10.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.
package/dist/runner.d.mts CHANGED
@@ -141,6 +141,8 @@ type AutEventInput = {
141
141
  timestamp?: string;
142
142
  latencyMs?: number;
143
143
  usage?: Usage;
144
+ /** The model that answered this turn, when the agent knows it. */
145
+ model?: string;
144
146
  } | {
145
147
  kind: 'completed';
146
148
  output?: unknown;
@@ -162,8 +164,69 @@ type TurnResult = string | {
162
164
  reply?: unknown;
163
165
  toolCalls?: readonly TurnToolCall[];
164
166
  usage?: Usage;
167
+ /** The model that answered, recorded with the usage. */
168
+ model?: string;
165
169
  };
166
170
  //#endregion
171
+ //#region ../core/src/judge.d.ts
172
+ /**
173
+ * How a judge must answer, and how EvalKit turns the answer into a score.
174
+ *
175
+ * - `verdict` (the default): a value from 0 to 1 and a reason, as JSON.
176
+ * - `choices`: one of a fixed set of answers, such as A/B/C, each worth a value.
177
+ * - `criteria`: a value from 0 to 1 per criterion; the score is their weighted mean.
178
+ */
179
+ type JudgeAnswer = {
180
+ kind: 'verdict';
181
+ } | {
182
+ kind: 'choices';
183
+ choices: JudgeChoice[];
184
+ } | {
185
+ kind: 'criteria';
186
+ criteria: JudgeCriterion[];
187
+ };
188
+ /** One answer a `choices` judge can give. Keys are matched case-insensitively. */
189
+ type JudgeChoice = {
190
+ key: string;
191
+ label: string;
192
+ value: number;
193
+ };
194
+ /** One thing a `criteria` judge scores. */
195
+ type JudgeCriterion = {
196
+ name: string;
197
+ weight: number;
198
+ description?: string;
199
+ };
200
+ /**
201
+ * One criterion's result, as a scorer returns it and as results record it:
202
+ * a value with what it saw, or `reached: false` when the check never got to
203
+ * run, because something before it failed (say, the app would not start).
204
+ * A criterion not reached counts as 0; the score's `explanation` says why,
205
+ * once, instead of every criterion repeating it.
206
+ */
207
+ type CriterionResult = ReachedCriterion | UnreachedCriterion;
208
+ type ReachedCriterion = {
209
+ name: string;
210
+ /** From 0 to 1. */
211
+ value: number;
212
+ /** Default 1, or the declared weight. */
213
+ weight?: number;
214
+ /** Why this value. */
215
+ explanation?: string;
216
+ /** What the check observed, as plain data. */
217
+ evidence?: JsonValue;
218
+ };
219
+ type UnreachedCriterion = {
220
+ name: string;
221
+ reached: false;
222
+ weight?: number;
223
+ explanation?: string;
224
+ };
225
+ /** A criterion as a scorer returns it: its evidence may be any plain value. */
226
+ type CriterionInput = (Omit<ReachedCriterion, 'evidence'> & {
227
+ evidence?: unknown;
228
+ }) | UnreachedCriterion;
229
+ //#endregion
167
230
  //#region ../core/src/catalog.d.ts
168
231
  type EvalCatalogAgent = {
169
232
  name?: string;
@@ -215,10 +278,20 @@ type EvalCatalogDataset = {
215
278
  type EvalCatalogScorer = {
216
279
  name: string;
217
280
  kind: ScoringRule['kind'];
281
+ /** What it checks, in the author's words. */
282
+ description?: string;
218
283
  passAt?: number;
219
284
  supportsPartial?: boolean;
220
285
  /** Judges only. */
221
286
  rubric?: string;
287
+ /** Judges only: the agent that judges (its own, or the project's default). */
288
+ agent?: EvalCatalogAgent;
289
+ /** Judges only: the names of the inputs it sees. */
290
+ inputs?: string[];
291
+ /** Judges only: how it answers. */
292
+ answer?: JudgeAnswer;
293
+ /** Judges only: the prompt it receives, with `{input}` placeholders. */
294
+ prompt?: string;
222
295
  definedAt?: string;
223
296
  };
224
297
  type EvalCatalogStep =
@@ -383,6 +456,8 @@ type AutEvent = {
383
456
  timestamp: string;
384
457
  latencyMs?: number;
385
458
  usage?: Usage;
459
+ /** The model that answered this turn, when the agent knows it. */
460
+ model?: string;
386
461
  } | {
387
462
  kind: 'completed';
388
463
  output?: JsonValue;
@@ -553,9 +628,23 @@ type ExpectToolCallStep = {
553
628
  };
554
629
  };
555
630
  type TranscriptStep = UserStep | AgentStep | ScoringRule | ExpectToolCallStep;
631
+ /**
632
+ * What a judge saw and said. The built-in `judge()` records all of it; a
633
+ * predicate that calls a model itself can report `model`, `prompt` and
634
+ * `reply` so the dashboard shows them the same way.
635
+ */
556
636
  type JudgeRunInfo = {
557
637
  agent?: AutIdentity;
638
+ /** The model the judge reported using (`turn-completed` `model`). */
639
+ model?: string;
640
+ /** Tokens the judge used: never counted in the agent's `tokens`. */
558
641
  usage?: Usage;
642
+ /** The exact prompt the judge received. */
643
+ prompt?: string;
644
+ /** Its reply, as text or JSON. */
645
+ reply?: JsonValue;
646
+ /** 2 when its first reply was not in the format asked for and it was asked again. */
647
+ attempts?: number;
559
648
  /** Judge-agent observations; never attributed to the AUT trajectory. */
560
649
  events?: JsonValue[];
561
650
  };
@@ -565,7 +654,8 @@ type SkippedScore = {
565
654
  reason: string;
566
655
  };
567
656
  type ScoreValue<Evidence = unknown> = number | SkippedScore | {
568
- value: number;
657
+ /** From 0 to 1. Without it, the weighted mean of `criteria`. */
658
+ value?: number;
569
659
  passed?: boolean;
570
660
  explanation?: string;
571
661
  /**
@@ -573,7 +663,12 @@ type ScoreValue<Evidence = unknown> = number | SkippedScore | {
573
663
  * evidence reaches later scorers through `checkpoint(rule)`.
574
664
  */
575
665
  evidence?: Evidence;
576
- /** Judge-agent evidence, never inferred from AUT usage. */
666
+ /**
667
+ * Per-criterion results, each shown on its own; see `CriterionResult`.
668
+ * Return `{ name, reached: false }` for a check that never ran.
669
+ */
670
+ criteria?: CriterionInput[];
671
+ /** What a model-backed scorer saw and said; never counted as AUT usage. */
577
672
  judge?: JudgeRunInfo;
578
673
  };
579
674
  type ScoreResult = {
@@ -581,8 +676,15 @@ type ScoreResult = {
581
676
  kind: 'predicate' | 'judge';
582
677
  value?: number;
583
678
  passed?: boolean;
679
+ /** The pass mark the value was held to (1 unless the rule set `passAt`). */
680
+ passAt?: number;
584
681
  explanation?: string;
585
682
  evidence?: JsonValue;
683
+ /** A `choices` judge's answer, such as `B`. */
684
+ choice?: string;
685
+ criteria?: CriterionResult[];
686
+ /** Files its scorer saved with `attach()`, by name. */
687
+ attachments?: string[];
586
688
  judge?: JudgeRunInfo;
587
689
  durationMs: number;
588
690
  error?: RecordedError;
@@ -637,15 +739,48 @@ type CheckpointOutcome<Evidence> = Omit<CheckpointResult, 'evidence'> & {
637
739
  type PredicateScorer<Evidence = unknown> = {
638
740
  kind: 'predicate';
639
741
  name: string;
742
+ /** What it checks, in a sentence, shown wherever the scorer is. */
743
+ description?: string;
640
744
  supportsPartial?: boolean;
641
745
  /** A numeric result passes when it is at least this value. Default: only 1 passes. */
642
746
  passAt?: number;
747
+ /**
748
+ * The checks it reports, declared up front so they show before a run.
749
+ * A declared criterion it leaves out is recorded as not reached; one it
750
+ * did not declare is an error.
751
+ */
752
+ criteria?: JudgeCriterion[];
643
753
  run(context: ScoringContext): boolean | ScoreValue<Evidence> | Promise<boolean | ScoreValue<Evidence>>;
644
754
  };
755
+ /** What a judge sees: one named input, read from the run. */
756
+ type JudgeInput = (scoring: ScoringContext) => JsonValue | undefined | Promise<JsonValue | undefined>;
757
+ /**
758
+ * A rubric-graded scorer. EvalKit builds the prompt from the rubric, the
759
+ * inputs and the answer format, runs the judge agent, checks its answer
760
+ * (asking once more if it is not in the format asked for), and records
761
+ * what it saw and said.
762
+ */
645
763
  type JudgeRule = {
646
764
  kind: 'judge';
647
765
  name: string;
648
766
  rubric: string;
767
+ /** What it checks, in a sentence, shown wherever the judge is. */
768
+ description?: string;
769
+ /**
770
+ * The agent that judges, made with `defineAgent()`. Default: `judge` in
771
+ * evalkit.config.ts. It gets the run's parameters, so a matrix axis can
772
+ * choose its model.
773
+ */
774
+ agent?: AutAdapter;
775
+ /**
776
+ * What the judge sees, by name. Default: `conversation` (this turn at a
777
+ * checkpoint, the whole run in final scoring) and `reply` (the last reply).
778
+ */
779
+ inputs?: Readonly<Record<string, JudgeInput>>;
780
+ /** How it answers. Default `verdict`: a value from 0 to 1 and a reason. */
781
+ answer: JudgeAnswer;
782
+ /** A value passes when it is at least this. Default: only 1 passes. */
783
+ passAt?: number;
649
784
  /** Run even when the scenario stopped early or execution failed. */
650
785
  supportsPartial?: boolean;
651
786
  };
@@ -684,8 +819,6 @@ type EvalDefinition<TAgent extends AutAdapter = AutAdapter> = {
684
819
  id: string;
685
820
  name?: string;
686
821
  agent: TAgent;
687
- /** Separate judge agent; its model and tools are never inherited from the AUT. */
688
- judge?: AutAdapter;
689
822
  /** Data and files the scenario uses; each run gets its own copy. */
690
823
  datasets?: readonly Dataset[];
691
824
  transcript: TranscriptStep[];
@@ -806,8 +939,13 @@ type CheckpointResult = {
806
939
  status: 'passed' | 'failed' | 'error' | 'skipped';
807
940
  value?: number;
808
941
  passed?: boolean;
942
+ passAt?: number;
809
943
  explanation?: string;
810
944
  evidence?: JsonValue;
945
+ choice?: string;
946
+ criteria?: CriterionResult[];
947
+ /** Files its scorer saved with `attach()`, by name. */
948
+ attachments?: string[];
811
949
  judge?: JudgeRunInfo;
812
950
  durationMs?: number;
813
951
  error?: RecordedError;
@@ -826,7 +964,7 @@ type CheckpointResult = {
826
964
  * usage, cached input included. Absent when no turn reported any.
827
965
  * - `tool calls`: the agent's `tool-call` events.
828
966
  */
829
- declare const BUILT_IN_METRICS: readonly ['agent time', 'tokens', 'tool calls'];
967
+ declare const BUILT_IN_METRICS: readonly ['agent time', 'tokens', 'tool calls', 'judge tokens'];
830
968
  type BuiltInMetricName = (typeof BUILT_IN_METRICS)[number];
831
969
  /** A built-in metric's name (suggested by editors), or a scenario's own. */
832
970
  type MetricName = BuiltInMetricName | (string & {});
@@ -964,6 +1102,21 @@ export declare const readRunSummary: (root: string, runId: string) => Promise<{
964
1102
  readonly durationMs?: number | undefined;
965
1103
  readonly scoring?: {
966
1104
  readonly results: {
1105
+ readonly passAt?: number | undefined;
1106
+ readonly choice?: string | undefined;
1107
+ readonly criteria?: ({
1108
+ readonly name: string;
1109
+ readonly value: number;
1110
+ readonly weight?: number | undefined;
1111
+ readonly explanation?: string | undefined;
1112
+ readonly evidence?: JsonValue | undefined;
1113
+ } | {
1114
+ readonly name: string;
1115
+ readonly reached: false;
1116
+ readonly weight?: number | undefined;
1117
+ readonly explanation?: string | undefined;
1118
+ })[] | undefined;
1119
+ readonly attachments?: string[] | undefined;
967
1120
  readonly name: string;
968
1121
  readonly kind: "judge" | "predicate";
969
1122
  readonly value?: number | undefined;
@@ -977,12 +1130,16 @@ export declare const readRunSummary: (root: string, runId: string) => Promise<{
977
1130
  readonly name?: string | undefined;
978
1131
  readonly version?: string | undefined;
979
1132
  } | undefined;
1133
+ readonly model?: string | undefined;
980
1134
  readonly usage?: {
981
1135
  readonly inputTokens?: number | undefined;
982
1136
  readonly outputTokens?: number | undefined;
983
1137
  readonly cachedInputTokens?: number | undefined;
984
1138
  readonly totalTokens?: number | undefined;
985
1139
  } | undefined;
1140
+ readonly prompt?: string | undefined;
1141
+ readonly reply?: JsonValue | undefined;
1142
+ readonly attempts?: number | undefined;
986
1143
  readonly events?: JsonValue[] | undefined;
987
1144
  } | undefined;
988
1145
  readonly durationMs: number;
@@ -1006,6 +1163,21 @@ export declare const readRunSummary: (root: string, runId: string) => Promise<{
1006
1163
  } | undefined;
1007
1164
  }[] | undefined;
1008
1165
  readonly checkpoints?: {
1166
+ readonly passAt?: number | undefined;
1167
+ readonly choice?: string | undefined;
1168
+ readonly criteria?: ({
1169
+ readonly name: string;
1170
+ readonly value: number;
1171
+ readonly weight?: number | undefined;
1172
+ readonly explanation?: string | undefined;
1173
+ readonly evidence?: JsonValue | undefined;
1174
+ } | {
1175
+ readonly name: string;
1176
+ readonly reached: false;
1177
+ readonly weight?: number | undefined;
1178
+ readonly explanation?: string | undefined;
1179
+ })[] | undefined;
1180
+ readonly attachments?: string[] | undefined;
1009
1181
  readonly step: number;
1010
1182
  readonly kind: "expect-tool-call" | "judge" | "predicate";
1011
1183
  readonly name: string;
@@ -1021,12 +1193,16 @@ export declare const readRunSummary: (root: string, runId: string) => Promise<{
1021
1193
  readonly name?: string | undefined;
1022
1194
  readonly version?: string | undefined;
1023
1195
  } | undefined;
1196
+ readonly model?: string | undefined;
1024
1197
  readonly usage?: {
1025
1198
  readonly inputTokens?: number | undefined;
1026
1199
  readonly outputTokens?: number | undefined;
1027
1200
  readonly cachedInputTokens?: number | undefined;
1028
1201
  readonly totalTokens?: number | undefined;
1029
1202
  } | undefined;
1203
+ readonly prompt?: string | undefined;
1204
+ readonly reply?: JsonValue | undefined;
1205
+ readonly attempts?: number | undefined;
1030
1206
  readonly events?: JsonValue[] | undefined;
1031
1207
  } | undefined;
1032
1208
  readonly durationMs?: number | undefined;
@@ -1062,6 +1238,21 @@ export declare const readRunSummary: (root: string, runId: string) => Promise<{
1062
1238
  }>;
1063
1239
  export declare const readRunScoring: (root: string, runId: string) => Promise<{
1064
1240
  readonly results: {
1241
+ readonly passAt?: number | undefined;
1242
+ readonly choice?: string | undefined;
1243
+ readonly criteria?: ({
1244
+ readonly name: string;
1245
+ readonly value: number;
1246
+ readonly weight?: number | undefined;
1247
+ readonly explanation?: string | undefined;
1248
+ readonly evidence?: JsonValue | undefined;
1249
+ } | {
1250
+ readonly name: string;
1251
+ readonly reached: false;
1252
+ readonly weight?: number | undefined;
1253
+ readonly explanation?: string | undefined;
1254
+ })[] | undefined;
1255
+ readonly attachments?: string[] | undefined;
1065
1256
  readonly name: string;
1066
1257
  readonly kind: "judge" | "predicate";
1067
1258
  readonly value?: number | undefined;
@@ -1075,12 +1266,16 @@ export declare const readRunScoring: (root: string, runId: string) => Promise<{
1075
1266
  readonly name?: string | undefined;
1076
1267
  readonly version?: string | undefined;
1077
1268
  } | undefined;
1269
+ readonly model?: string | undefined;
1078
1270
  readonly usage?: {
1079
1271
  readonly inputTokens?: number | undefined;
1080
1272
  readonly outputTokens?: number | undefined;
1081
1273
  readonly cachedInputTokens?: number | undefined;
1082
1274
  readonly totalTokens?: number | undefined;
1083
1275
  } | undefined;
1276
+ readonly prompt?: string | undefined;
1277
+ readonly reply?: JsonValue | undefined;
1278
+ readonly attempts?: number | undefined;
1084
1279
  readonly events?: JsonValue[] | undefined;
1085
1280
  } | undefined;
1086
1281
  readonly durationMs: number;
@@ -1104,6 +1299,21 @@ export declare const readRunScoring: (root: string, runId: string) => Promise<{
1104
1299
  } | undefined;
1105
1300
  }[] | undefined;
1106
1301
  readonly checkpoints?: {
1302
+ readonly passAt?: number | undefined;
1303
+ readonly choice?: string | undefined;
1304
+ readonly criteria?: ({
1305
+ readonly name: string;
1306
+ readonly value: number;
1307
+ readonly weight?: number | undefined;
1308
+ readonly explanation?: string | undefined;
1309
+ readonly evidence?: JsonValue | undefined;
1310
+ } | {
1311
+ readonly name: string;
1312
+ readonly reached: false;
1313
+ readonly weight?: number | undefined;
1314
+ readonly explanation?: string | undefined;
1315
+ })[] | undefined;
1316
+ readonly attachments?: string[] | undefined;
1107
1317
  readonly step: number;
1108
1318
  readonly kind: "expect-tool-call" | "judge" | "predicate";
1109
1319
  readonly name: string;
@@ -1119,12 +1329,16 @@ export declare const readRunScoring: (root: string, runId: string) => Promise<{
1119
1329
  readonly name?: string | undefined;
1120
1330
  readonly version?: string | undefined;
1121
1331
  } | undefined;
1332
+ readonly model?: string | undefined;
1122
1333
  readonly usage?: {
1123
1334
  readonly inputTokens?: number | undefined;
1124
1335
  readonly outputTokens?: number | undefined;
1125
1336
  readonly cachedInputTokens?: number | undefined;
1126
1337
  readonly totalTokens?: number | undefined;
1127
1338
  } | undefined;
1339
+ readonly prompt?: string | undefined;
1340
+ readonly reply?: JsonValue | undefined;
1341
+ readonly attempts?: number | undefined;
1128
1342
  readonly events?: JsonValue[] | undefined;
1129
1343
  } | undefined;
1130
1344
  readonly durationMs?: number | undefined;
@@ -1207,8 +1421,10 @@ export type RunEvalOptions = {
1207
1421
  suiteId?: string;
1208
1422
  /** Overrides the scenario's `repeat`: how many runs to start, as one batch. */
1209
1423
  repeat?: number;
1210
- /** Parameters made available to the AUT for this invocation. */
1424
+ /** Parameters made available to the AUT, and to judges, for this invocation. */
1211
1425
  parameters?: JsonObject;
1426
+ /** The agent for judges that name none (`judge` in evalkit.config.ts). */
1427
+ judge?: AutAdapter;
1212
1428
  /** Matrix provenance recorded in every run's manifest. */
1213
1429
  matrix?: RunMetadata['matrix'];
1214
1430
  /** Selects a declared AUT runtime such as local, sandbox, or remote. */
@@ -1 +1 @@
1
- {"version":3,"file":"runner.d.mts","names":["_$_evalkit_core0.JsonValue","_$_evalkit_core0.TrajectoryEvent"],"sources":["../../runner/src/errors.ts","../../core/src/identity.ts","../../core/src/dataset.ts","../../core/src/aut-events.ts","../../core/src/catalog.ts","../../core/src/matrix.ts","../../core/src/config.ts","../../core/src/usage.ts","../../core/src/index.ts","../../runner/src/local-report-store.ts","../../runner/src/datasets.ts","../../runner/src/local-report-reader.ts","../../runner/src/matrix.ts","../../runner/src/upgrade.ts","../../runner/src/workspace.ts","../../runner/src/index.ts"],"mappings":";;;;;;qBAEa,0BAA0B;EACrC;EACA;;;;;qBAGW,qBAAqB;EAChC;EACA;;;;;qBAGW,oBAAoB;EAC/B;EACA;;;;;qBAGW,qBAAqB;EAChC;EACA;;;;;qBASW,iCAAiC;EAG5C;EACA;EACA;EACA;;;;;;qBAIW,uBAAuB;EAClC;;;;cCrCW,oBAAkB,OAAA;KACnB,sBAAsB,mBAAmB;KAiBzC,YAAY,cAAc,eAAe,2BACxC;;;;KCdD;;KAGA,6BAA6B;EAAe;;;;;;KAM5C,wBAAwB,SAAS,eAAe;;KAGhD;EACV,QAAQ;;EAER;;KAGU;;EAEV;EACA,QAAQ;;KAGE;EACV;EACA;;EAEA,QAAQ;;EAER;;EAEA,YAAY;EACZ,QAAQ;;KAoCE;EAEN;EACA,QAAQ;EACR;EACA;;EAGA;EACA,SACE,MAAM,uBACH,iBAAiB,QAAQ;EAC9B,SACE,QAAQ,gBACR,KAAK,sBACF,iBAAiB,QAAQ;;;KAIxB;WACD;WACA;WACA;WACA,YAAY;;WAEZ;WACA,QAAQ;;;;;;;;KC/FP;EACN;EAAiB;;EAEjB;EACA;EACA;EACA;;EAGA;EACA;EACA;EACA;EACA;;EAGA;EACA;EACA;EACA;EACA;;EAEA;EAAsB;EAAc;;EAEpC;EACA;E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;;;;;;;wBAES,cAAc,cAAc,gBAAa,QAAzCC;;;;;wBAUN,YAAY,OAAO;;;;KC3BvB;EACV;EACA;EACA;EACA;EACA;;;wBAIc,UACd,QAAQ,YACR,SAAS,KAAK;EACZ,YAAY;;EAEZ,YAAY,MAAM;EAClB,YACE,MAAM,gBACN,eAAe,uBACL;IAEb,OAAO,OAAO;;;;KCTL;;EAEV;;EAEA;;EAEA;;EAEA;;;;;;;;;;;;;;;wBAsBoB,eACpB,cACA;EAAW;IACV,QAAQ;;;;wBCtCK,iBAAiB,cAAc;;;YC8DnC;EACV,QAAQ;;EAER;EACA;;EAEA;;EAEA,aAAa;;EAEb,SAAS;;EAET,UAAU;;EAEV;;EAEA,YAAY,OAAO;;EAEnB;;EAEA,iBAAiB;;;;;EAKjB;;EAEA,mBAAmB;;EAEnB,SAAS;;EAET,UAAU;;EAEV;;;;;EAKA,SAAS;;;;;EAKT,WAAW,KAAK,QAAQ,OAAO;EAC/B,YAAY;;;YAIF;EACV;EACA,QAAQ;EACR;EACA;EACA,aAAa;;;;;;;wBAUC,QACd,YAAY,gBACZ,SAAS,iBACR,OAAO,OAAO"}
1
+ {"version":3,"file":"runner.d.mts","names":["_$_evalkit_core0.JsonValue","_$_evalkit_core0.TrajectoryEvent"],"sources":["../../runner/src/errors.ts","../../core/src/identity.ts","../../core/src/dataset.ts","../../core/src/aut-events.ts","../../core/src/judge.ts","../../core/src/catalog.ts","../../core/src/matrix.ts","../../core/src/config.ts","../../core/src/usage.ts","../../core/src/index.ts","../../runner/src/local-report-store.ts","../../runner/src/datasets.ts","../../runner/src/local-report-reader.ts","../../runner/src/matrix.ts","../../runner/src/upgrade.ts","../../runner/src/workspace.ts","../../runner/src/index.ts"],"mappings":";;;;;;qBAEa,0BAA0B;EACrC;EACA;;;;;qBAGW,qBAAqB;EAChC;EACA;;;;;qBAGW,oBAAoB;EAC/B;EACA;;;;;qBAGW,qBAAqB;EAChC;EACA;;;;;qBASW,iCAAiC;EAG5C;EACA;E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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAES,cAAc,cAAc,gBAAa,QAAzCC;;;;;wBAUN,YAAY,OAAO;;;;KC3BvB;EACV;EACA;EACA;EACA;EACA;;;wBAIc,UACd,QAAQ,YACR,SAAS,KAAK;EACZ,YAAY;;EAEZ,YAAY,MAAM;EAClB,YACE,MAAM,gBACN,eAAe,uBACL;IAEb,OAAO,OAAO;;;;KCTL;;EAEV;;EAEA;;EAEA;;EAEA;;;;;;;;;;;;;;;wBAsBoB,eACpB,cACA;EAAW;IACV,QAAQ;;;;wBCtCK,iBAAiB,cAAc;;;YCgEnC;EACV,QAAQ;;EAER;EACA;;EAEA;;EAEA,aAAa;;EAEb,QAAQ;;EAER,SAAS;;EAET,UAAU;;EAEV;;EAEA,YAAY,OAAO;;EAEnB;;EAEA,iBAAiB;;;;;EAKjB;;EAEA,mBAAmB;;EAEnB,SAAS;;EAET,UAAU;;EAEV;;;;;EAKA,SAAS;;;;;EAKT,WAAW,KAAK,QAAQ,OAAO;EAC/B,YAAY;;;YAIF;EACV;EACA,QAAQ;EACR;EACA;EACA,aAAa;;;;;;;wBAUC,QACd,YAAY,gBACZ,SAAS,iBACR,OAAO,OAAO"}
package/dist/runner.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import { _ as DatasetError, a as readRunEvents, c as readRunSummary, d as staticDatasetFile, f as staticDatasetFiles, g as CheckpointExecutionError, h as CancelledError, i as ownerIsGone, l as localReportStore, m as AutExecutionError, n as upgradeReports, o as readRunManifest, r as runMatrix, s as readRunScoring, t as runEval, u as runWorkspacePath, v as ReportError, y as ScoringError } from "./src-CcdLZqFk.mjs";
1
+ import { _ as DatasetError, a as readRunEvents, c as readRunSummary, d as staticDatasetFile, f as staticDatasetFiles, g as CheckpointExecutionError, h as CancelledError, i as ownerIsGone, l as localReportStore, m as AutExecutionError, n as upgradeReports, o as readRunManifest, r as runMatrix, s as readRunScoring, t as runEval, u as runWorkspacePath, v as ReportError, y as ScoringError } from "./src-BfSQKOJP.mjs";
2
2
  export { AutExecutionError, CancelledError, CheckpointExecutionError, DatasetError, ReportError, ScoringError, localReportStore, ownerIsGone, readRunEvents, readRunManifest, readRunScoring, readRunSummary, runEval, runMatrix, runWorkspacePath, staticDatasetFile, staticDatasetFiles, upgradeReports };
@@ -1,4 +1,4 @@
1
- import { r as createShareApp, t as ShareIndexDb } from "./index-db-BbVblaHz.mjs";
1
+ import { r as createShareApp, t as ShareIndexDb } from "./index-db-B1FeXzmS.mjs";
2
2
  import { t as r2Files } from "./files-DkDQs2JL.mjs";
3
3
  //#region ../share/src/index-do.ts
4
4
  const METHODS = [
package/dist/share.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { a as parseUpload, c as validRepoKey, d as decodeBundle, f as encodeBundle, i as normalizeBasePath, l as dashboardIndex, n as asyncIndex, o as allowedRunPath, r as createShareApp, s as repoKey, t as ShareIndexDb, u as BUNDLE_FORMAT } from "./index-db-BbVblaHz.mjs";
1
+ import { a as parseUpload, c as validRepoKey, d as decodeBundle, f as encodeBundle, i as normalizeBasePath, l as dashboardIndex, n as asyncIndex, o as allowedRunPath, r as createShareApp, s as repoKey, t as ShareIndexDb, u as BUNDLE_FORMAT } from "./index-db-B1FeXzmS.mjs";
2
2
  import { t as r2Files } from "./files-DkDQs2JL.mjs";
3
- import { i as directoryFiles, n as directoryAssets, r as sqliteIndex, t as createDirectoryShareApp } from "./src-Bn6fnZnF.mjs";
3
+ import { i as directoryFiles, n as directoryAssets, r as sqliteIndex, t as createDirectoryShareApp } from "./src-Bccv9igQ.mjs";
4
4
  export { BUNDLE_FORMAT, ShareIndexDb, allowedRunPath, asyncIndex, createDirectoryShareApp, createShareApp, dashboardIndex, decodeBundle, directoryAssets, directoryFiles, encodeBundle, normalizeBasePath, parseUpload, r2Files, repoKey, sqliteIndex, validRepoKey };
@@ -22,11 +22,11 @@ For a cross-cutting change, use all relevant subskills; for a focused task, load
22
22
 
23
23
  ## Invariants
24
24
 
25
- - Work from the eval project's directory (for the included project, `examples/starter`). By default the CLI discovers default-exported `scenarios/**/*.eval.ts` without a config or registry, and each directory directly below `scenarios/` is a suite. The starter demonstrates this zero-config discovery path; `examples/configured-matrix` demonstrates optional config and a runnable sweep. An optional `evalkit.config.js`/`.ts` customizes discovery and execution, or can supply an explicit registry/eval list. Dataset paths and `_evalkit-results` / `_evalkit-sandbox` resolve relative to the config directory or project root.
25
+ - Work from the eval project's directory (for the included project, `examples/starter`). By default the CLI discovers default-exported `scenarios/**/*.eval.ts` without a config or registry, and each directory directly below `scenarios/` is a suite. The starter demonstrates this zero-config discovery path; `examples/configured-matrix` demonstrates optional config and a runnable sweep. An optional `evalkit.config.js`/`.ts` customizes discovery and execution, or can supply an explicit registry/eval list. Dataset paths and `_evalkit-results` resolve relative to the config directory or project root; run workspaces live outside the project in `$TMPDIR/evalkit/<project>-<hash>/` unless `sandboxDir` is set.
26
26
  - A scenario is one concrete conversation in its own small file. Share agents (`agents/`), judges (`judges/`) and datasets (`datasets/`) by importing them; never generate scenarios in loops or from datasets.
27
27
  - Authored suites, scenarios, datasets, agents, and matrices use stable lowercase kebab-case IDs. Only runs and runs receive generated runtime URIs.
28
28
  - Keep evaluator datasets/answers private from the AUT and model unless a trusted adapter deliberately reads them and includes selected content in its prompt. Such inclusion is a deliberate treatment (for example, a memory-on condition), not a live retrieval test. Local sandboxes retain evaluator files; review reports and sandboxes before sharing.
29
- - Executable transcript steps are `user(...)`, `predicate(...)`, `judge(...)`, and `expectToolCall(...)`. Final scoring supports both `predicate(...)` and `judge(...)`; `judge(...)` requires a separate eval-level judge adapter. `agent(...)` transcript steps are not executable. `agentsSdk()` is unimplemented, `judgeScorer(...)` is not part of the current API, and `policy.timeoutMs` is not enforced. Verify current code/docs before proposing capabilities.
29
+ - Executable transcript steps are `user(...)`, `predicate(...)`, `judge(...)`, and `expectToolCall(...)`. Final scoring supports both `predicate(...)` and `judge(...)`; `judge(...)` uses its own `agent` or the project's `judge` in `evalkit.config.ts`, never the AUT. `agent(...)` transcript steps are not executable. `agentsSdk()` is unimplemented, `judgeScorer(...)` is not part of the current API, and `policy.timeoutMs` is not enforced. Verify current code/docs before proposing capabilities.
30
30
  - The built-in `piAgent()` invokes Pi with `--no-tools`, once per user message, and does not preserve conversational state. It cannot test live MCP retrieval/tool use. For that, implement a custom AUT adapter that explicitly enables the desired tools and emits observed `tool-call`/`tool-result` events; do not claim a tool was used unless the adapter records it.
31
31
  - For an intervention/A-B eval, hold task, model, and other settings constant; vary only the intervention parameter, use repeated runs and a negative control, and report exactly what was varied. A memory snapshot injected into the prompt tests memory-content usefulness, not retrieval quality. Start with a dry run and narrow smoke test; Pi-backed evaluations can incur provider costs.
32
32
  - Run `bun run check` and relevant `bun test` suites when changing code. Check `git status --short` first and preserve unrelated changes.
@@ -8,7 +8,7 @@ description: Define or modify EvalKit scenarios (evals) and suites. Use when add
8
8
  Read `../evalkit/SKILL.md`, `../../../sites/evalkit.leostera.dev/src/content/docs/manual/project-structure.md` and `../../../sites/evalkit.leostera.dev/src/content/docs/manual/scoring-and-evals.md`, `../../../examples/starter/scenarios/greeting.eval.ts`, and `../../../examples/configured-matrix/evalkit.config.ts`.
9
9
 
10
10
  1. Default-export one scenario per file from `scenarios/**/*.eval.ts` using `defineEval({ id: 'my-scenario', name, agent, transcript, scoring, datasets?, repeat?, policy? })`. The CLI discovers these files automatically; no registry or config is required. Choose a stable lowercase kebab-case ID. `metadata` is optional; `name` is a display label. Import shared agents, judges and datasets; keep each scenario short and concrete (a suite of a hundred cases is a hundred files), and never generate scenarios in a loop.
11
- 2. Executable transcript steps are `user('message')`, inline `predicate(...)`, `judge(...)`, and `expectToolCall(...)`. User messages call `session.send` in order on one fresh session per run; predicates/judges/tool-call assertions run at checkpoints. `judge(...)` requires a separate eval-level `judge` adapter. `agent(...)` transcript steps are not executable. `user(({ parameters, data, seed, batch }) => ...)` computes a message per run, so one scenario can vary its prompt by matrix axis or candidate dataset instead of being copied per variant; `repeat: n` starts `n` independent runs as one batch (default 1, positive integer; `--repeat` and `execution.repeat` override it); `policy.timeoutMs` is not enforced.
11
+ 2. Executable transcript steps are `user('message')`, inline `predicate(...)`, `judge(...)`, and `expectToolCall(...)`. User messages call `session.send` in order on one fresh session per run; predicates/judges/tool-call assertions run at checkpoints. A `judge(...)` names its judge `agent`, or uses `judge` in `evalkit.config.ts`; it is never the AUT. `agent(...)` transcript steps are not executable. `user(({ parameters, data, seed, batch }) => ...)` computes a message per run, so one scenario can vary its prompt by matrix axis or candidate dataset instead of being copied per variant; `repeat: n` starts `n` independent runs as one batch (default 1, positive integer; `--repeat` and `execution.repeat` override it); `policy.timeoutMs` is not enforced.
12
12
  3. Suites are directories: every file below `scenarios/billing/` is in suite `billing` (kebab-case directory names; deeper directories stay in the top one). Files directly in `scenarios/` have no suite; `discovery.suites: false` turns this off. Only use an explicit registry (`registry: registerEvals([defineSuite({ id, evals })])` in the config) when you need full control; it replaces discovery, and duplicate eval IDs throw.
13
13
  4. For an intervention comparison, hold task/model/prompt constant and vary one explicit matrix axis (for example `memory: ['off', 'on']`). Repeat runs and include a negative control where possible. Record whether the treatment injects a saved memory or performs live retrieval: those answer different questions. A memory dataset can be evaluator-visible to the trusted adapter, but do not expose evaluator roots or reference answers to the AUT unless revealing the chosen treatment is intentional.
14
14
  5. From the project directory run `bun run evalkit run <eval-id>`. Use `bun run evalkit run --suite <suite-id>` for a suite directory. IDs are exact human-defined strings. Inspect per-run `scoring.json` and the run `summary.json`; completed execution is not the same as passing scores.
@@ -5,13 +5,13 @@ description: Write or debug EvalKit scoring rules and judges. Use for predicate
5
5
 
6
6
  # Score EvalKit runs
7
7
 
8
- Read `../evalkit/SKILL.md`, `../../../sites/evalkit.leostera.dev/src/content/docs/manual/scoring-and-evals.md` and `../../../sites/evalkit.leostera.dev/src/content/docs/manual/results.md`, `../../../packages/runner/src/index.ts` (`normalizeScore`, `scoreSummary`, `runPredicate`), and `../../../examples/starter/judges/greeting.ts`.
8
+ Read `../evalkit/SKILL.md`, `../../../sites/evalkit.leostera.dev/src/content/docs/manual/scoring-and-evals.md` and `../../../sites/evalkit.leostera.dev/src/content/docs/manual/results.md`, `../../../packages/runner/src/score.ts` (`normalizeScore`), `../../../packages/runner/src/judge-agent.ts` (prompt, retry, recorded fields), `../../../packages/core/src/judge.ts` (`choices`, `criteria`, `judgePrompt`), `../../../examples/starter/judges/greeting.ts`, and `../../../examples/judges/` (choices, criteria and evidence predicates with a matrix-chosen judge model).
9
9
 
10
- EvalKit currently executes deterministic `predicate(name, callback)` scorers and agent-backed `judge(name, { rubric })` rules. A judge rule requires a **separate eval-level `judge` adapter**; it is not inferred from or shared with the AUT. The `judgeScorer(...)` API is not implemented—do not suggest it.
10
+ EvalKit currently executes deterministic `predicate(name, callback)` scorers and agent-backed `judge(name, { rubric })` rules. A judge rule runs on its own `agent` or the project's `judge` (`defineConfig({ judge })`); it is never the AUT. Give every rule a `description` saying what it checks: the dashboard, `--dry-run` and failure lines show it. The `judgeScorer(...)` API is not implemented—do not suggest it.
11
11
 
12
12
  1. Add a named `predicate(...)` for deterministic checks or a `judge(...)` descriptor for rubric-based LLM assessment, then reference it from the eval's `scoring` array or supported transcript checkpoint. The predicate callback receives `{ context, output, data, trajectory, artifacts, checkpoints, turn? }`; `checkpoints` are earlier checkpoint results (all of them in final scoring), so a checkpoint that inspects live state before the session closes can hand its `evidence` to final scorers. Use `output` for the final assistant reply and `data[id]` for dataset values (expected answers belong in an evaluator dataset); only filter `trajectory.events` (by `source: 'aut'` and `kind`) for tool calls or intermediate messages. `context` includes per-run IDs, metadata, random seed and optional parameters; workspace roots are absolute local paths.
13
13
  2. A predicate returns a boolean, a finite score from 0 to 1, `{ value, passed?, explanation?, evidence? }` (evidence may be any plain value), or `skip(reason)` when the check does not apply. Without `passed`, only `value === 1` passes; give `predicate(name, fn, { passAt: 0.8 })` for a threshold. A skipped result neither passes nor fails and is left out of averages; never fake "not applicable" as a pass. Use clear evidence for debugging.
14
- 3. A `judge(...)` rule sends a rubric plus the current turn or trajectory to the separate judge adapter, which must emit a JSON verdict. Validate that the judge is independent from the AUT, runs in an appropriate workspace, and does not receive secrets. Judge events/prompts may contain sensitive data and incur model cost; cost is not inferred unless the adapter emits usage.
14
+ 3. A `judge(...)` rule: EvalKit builds the prompt from `rubric`, `inputs` (`{ name: (ctx) => value }`, default `conversation` and `reply`) and `answer` (`choices({ A: [label, value] })`, `criteria({ name: weight })`, or the default 0–1 verdict), reads the reply, and asks once more if it cannot. Set `passAt` (default only 1). The judge agent receives `context.parameters`, so a matrix axis such as `judgeModel` can choose its model; it should return `{ reply, usage, model }`. Results save the prompt, reply, conversation, usage, model and `passAt`; judging tokens are the built-in `judge tokens` metric, apart from `tokens`. A predicate may return `criteria` instead of `value`; the score is their weighted mean. Validate that the judge is independent from the AUT, runs in an appropriate workspace, and does not receive secrets. Judge events/prompts may contain sensitive data and incur model cost; cost is not inferred unless the adapter emits usage.
15
15
  4. Normal scorers are skipped after primary execution errors unless declared with `{ supportsPartial: true }` and the required context/workspace exists. Scorer exceptions and invalid scores become recorded failures; never mask them as passes.
16
16
  5. Scorers run after the AUT closes; use `node:fs/promises` to inspect candidate/evaluator files before workspace cleanup. Keep evaluator references and secrets out of AUT events, evidence, and exported reports. Reading one evaluator dataset in a trusted adapter and deliberately injecting it as an experiment treatment is valid, but measures injected context—not whether the AUT retrieved it itself.
17
17
  6. Numbers to compare rather than gate on (tokens, time, retries, mistakes, web searches) are **metrics**, not scorers: `metric(name, (context) => number | undefined, { unit?, better? })` in the eval's `metrics` array. Never fake one as a predicate that always passes. Agent time, tokens (when the adapter reports usage) and tool calls are recorded automatically; have the adapter emit `turn-completed` usage so tokens appear. Means show on the run page and scoreboard.
@@ -11,4 +11,4 @@ Read `../evalkit/SKILL.md` and `../../../sites/evalkit.leostera.dev/src/content/
11
11
  2. Each `_evalkit-results/<run-uuid>/` is one run (one execution): `manifest.json`, `catalog.json`, `trajectory.jsonl`, `scoring.json`, `summary.json`, and `artifacts/{candidate,attachments}/`. `trajectory.jsonl` contains one JSON event per line. `repeat: n` starts `n` runs sharing `manifest.batch: { id, index, size }`. Results saved before EvalKit 0.9 (a run holding `runs/`) are skipped until `bun run evalkit upgrade` converts them; it only reads the config, so run it first when updating.
12
12
  3. A run's `summary.json` `status` is `passed`, `failed` (finished, but a score or checkpoint did not pass), `errored` (could not finish), or `cancelled` (never a failure). `scoring.overall` is an unweighted mean of valid values, not a pass rate. For a batch, count how many of its runs passed. For CI, use `jq -e '.status == "passed"' "_evalkit-results/<run-uuid>/summary.json"` after replacing the placeholder; the CLI exits nonzero when any selected run does not pass.
13
13
  4. `--json` emits one JSON object per finished run with its cell key, eval ID, effective parameters, and run result (including `batch`). Read the saved run trajectory for adapter-emitted turn latency or token usage; EvalKit does not infer provider cost, latency, or token counts. Compare matrix conditions at both cell and run level and avoid claiming significance from a small pilot.
14
- 5. The dashboard can start runs and inspect events, scoring, and candidate files. `_evalkit-sandbox/<run-uuid>/{candidate,evaluator}/` retains **both** local workspaces; evaluator secrets can live there. Treat reports and sandboxes as sensitive, apply Git ignore/retention rules, and don't share raw data without review. They may be deleted after inspection.
14
+ 5. The dashboard can start runs and inspect events, scoring, and candidate files. Run workspaces live outside the project, in `$TMPDIR/evalkit/<project>-<hash>/`<run-uuid>/{candidate,evaluator}/ (`sandboxDir` overrides it; inside the project, agents can read its source and other runs, and `run` warns), and kept ones retain **both** workspaces; evaluator secrets can live there. Treat reports and sandboxes as sensitive, apply Git ignore/retention rules, and don't share raw data without review. They may be deleted after inspection.