peerbench 0.0.7 → 0.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 (93) hide show
  1. package/dist/aggregators/abstract.d.ts +10 -0
  2. package/dist/aggregators/index.d.ts +2 -67
  3. package/dist/aggregators/llm/avg.d.ts +26 -0
  4. package/dist/benchmarks/examples/echo-basic/index.d.ts +4 -0
  5. package/dist/benchmarks/examples/echo-basic/runner.d.ts +273 -0
  6. package/dist/benchmarks/examples/echo-basic/schema-sets/echo.v1.d.ts +241 -0
  7. package/dist/benchmarks/examples/echo-basic/storages/json.d.ts +14 -0
  8. package/dist/benchmarks/examples/echo-basic/storages/text.d.ts +24 -0
  9. package/dist/benchmarks/examples/exact-match-scorer/index.d.ts +4 -0
  10. package/dist/benchmarks/examples/exact-match-scorer/runner.d.ts +428 -0
  11. package/dist/benchmarks/examples/exact-match-scorer/schema-sets/exact-match.v1.d.ts +287 -0
  12. package/dist/benchmarks/examples/exact-match-scorer/scorer.d.ts +30 -0
  13. package/dist/benchmarks/examples/exact-match-scorer/storages/json.d.ts +8 -0
  14. package/dist/benchmarks/examples/text-transform/index.d.ts +4 -0
  15. package/dist/benchmarks/examples/text-transform/runner.d.ts +524 -0
  16. package/dist/benchmarks/examples/text-transform/schema-sets/echo.v1.d.ts +211 -0
  17. package/dist/benchmarks/examples/text-transform/schema-sets/namespace.d.ts +1 -0
  18. package/dist/benchmarks/examples/text-transform/schema-sets/reverse.v1.d.ts +216 -0
  19. package/dist/benchmarks/examples/text-transform/storages/json.d.ts +9 -0
  20. package/dist/benchmarks/index.d.ts +1 -1667
  21. package/dist/benchmarks/index.js +14 -14
  22. package/dist/benchmarks/peerbench/index.d.ts +5 -0
  23. package/dist/benchmarks/peerbench/runner.d.ts +754 -0
  24. package/dist/benchmarks/peerbench/schema-sets/mcq.v1.d.ts +261 -0
  25. package/dist/benchmarks/peerbench/schema-sets/multi-turn.v1.d.ts +351 -0
  26. package/dist/benchmarks/peerbench/schema-sets/qa.v1.d.ts +256 -0
  27. package/dist/benchmarks/peerbench/storages/json.d.ts +10 -0
  28. package/dist/{chunk-ZXTQJFGL.js → chunk-Q6GSOHOP.js} +4 -4
  29. package/dist/{chunk-JFLUJLGT.js → chunk-WBCMV445.js} +22 -2
  30. package/dist/chunk-WBCMV445.js.map +1 -0
  31. package/dist/constants.d.ts +4 -0
  32. package/dist/errors/index.d.ts +2 -0
  33. package/dist/errors/peerbench.d.ts +6 -0
  34. package/dist/errors/polyfill.d.ts +1 -0
  35. package/dist/examples/basic.d.ts +1 -0
  36. package/dist/helpers/define-runner.d.ts +45 -0
  37. package/dist/helpers/index.d.ts +1 -0
  38. package/dist/index.d.ts +6 -101
  39. package/dist/index.js +3 -3
  40. package/dist/providers/abstract/llm.d.ts +20 -0
  41. package/dist/{provider-DnEBdl1n.d.ts → providers/abstract/provider.d.ts} +2 -4
  42. package/dist/providers/example/echo.d.ts +12 -0
  43. package/dist/providers/example/restapi.d.ts +37 -0
  44. package/dist/providers/index.d.ts +5 -96
  45. package/dist/providers/mastra.d.ts +40 -0
  46. package/dist/providers/openai.d.ts +29 -0
  47. package/dist/providers/openrouter.d.ts +27 -0
  48. package/dist/schemas/extensions/index.d.ts +18 -22
  49. package/dist/schemas/extensions/response/llm.d.ts +14 -0
  50. package/dist/schemas/extensions/score/llm-as-a-judge-scorer.d.ts +15 -0
  51. package/dist/schemas/id.d.ts +2 -0
  52. package/dist/schemas/index.d.ts +4 -200
  53. package/dist/schemas/llm/index.d.ts +2 -116
  54. package/dist/schemas/llm/index.js +2 -2
  55. package/dist/schemas/llm/simple-system-prompt.d.ts +51 -0
  56. package/dist/schemas/llm/system-prompt.d.ts +59 -0
  57. package/dist/schemas/response.d.ts +63 -0
  58. package/dist/schemas/schema-definer.d.ts +47 -0
  59. package/dist/schemas/score.d.ts +73 -0
  60. package/dist/schemas/test-case.d.ts +57 -0
  61. package/dist/{abstract-BdgLjkNC.d.ts → scorers/abstract.d.ts} +2 -4
  62. package/dist/scorers/index.d.ts +4 -68
  63. package/dist/scorers/llm-judge.d.ts +55 -0
  64. package/dist/scorers/mcq.d.ts +19 -0
  65. package/dist/scorers/mcq.test.d.ts +1 -0
  66. package/dist/scorers/regex.d.ts +58 -0
  67. package/dist/scorers/regex.test.d.ts +1 -0
  68. package/dist/storages/abstract.d.ts +7 -0
  69. package/dist/storages/examples/http.d.ts +1 -0
  70. package/dist/storages/examples/sqlite.d.ts +1 -0
  71. package/dist/storages/file.d.ts +43 -0
  72. package/dist/storages/http.d.ts +22 -0
  73. package/dist/storages/index.d.ts +5 -69
  74. package/dist/storages/index.js +1 -1
  75. package/dist/storages/json-file.d.ts +21 -0
  76. package/dist/storages/sqlite.d.ts +41 -0
  77. package/dist/types/index.d.ts +17 -0
  78. package/dist/types/runner.d.ts +18 -0
  79. package/dist/utilities.d.ts +9 -0
  80. package/dist/utils/id-generator.d.ts +2 -0
  81. package/dist/utils/index.d.ts +5 -0
  82. package/dist/utils/json.d.ts +17 -0
  83. package/dist/utils/llm.d.ts +7 -0
  84. package/dist/{rate-limiter-CSmVIRsM.d.ts → utils/rate-limiter.d.ts} +3 -5
  85. package/dist/utils/sleep.d.ts +1 -0
  86. package/dist/utils/string.d.ts +8 -0
  87. package/package.json +3 -3
  88. package/dist/chunk-JFLUJLGT.js.map +0 -1
  89. package/dist/index-Cn20kPrz.d.ts +0 -27
  90. package/dist/json-file-Bgv9TLcX.d.ts +0 -74
  91. package/dist/llm-8ecJmwKJ.d.ts +0 -23
  92. package/dist/llm-judge-BuF80-5-.d.ts +0 -75
  93. /package/dist/{chunk-ZXTQJFGL.js.map → chunk-Q6GSOHOP.js.map} +0 -0
@@ -1,1667 +1 @@
1
- import { I as IdGenerator } from '../index-Cn20kPrz.js';
2
- import z__default, { z } from 'zod';
3
- import { A as AbstractLLMProvider } from '../llm-8ecJmwKJ.js';
4
- import { a as MCQScorer, L as LLMAsAJudgeScorer } from '../llm-judge-BuF80-5-.js';
5
- import { J as JSONFileStorage } from '../json-file-Bgv9TLcX.js';
6
- import '../provider-DnEBdl1n.js';
7
- import '../abstract-BdgLjkNC.js';
8
- import 'openai/resources/shared';
9
- import 'openai/resources/chat/completions';
10
- import '../rate-limiter-CSmVIRsM.js';
11
- import 'node:fs/promises';
12
-
13
- declare const MCQKind: "llm/mcq";
14
- declare const MCQTestCaseSchemaV1: z.ZodObject<Omit<{
15
- id: z.ZodString;
16
- namespace: z.ZodString;
17
- schemaVersion: z.ZodNumber;
18
- kind: z.ZodString;
19
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
20
- }, "kind" | "namespace" | "schemaVersion"> & {
21
- question: z.ZodString;
22
- options: z.ZodRecord<z.ZodString, z.ZodString>;
23
- correctAnswerKeys: z.ZodArray<z.ZodString>;
24
- } & {
25
- namespace: z.ZodLiteral<"peerbench.ai">;
26
- kind: z.ZodLiteral<"llm/mcq.tc">;
27
- schemaVersion: z.ZodLiteral<1>;
28
- }, z.core.$strip> & {
29
- new: (input: Omit<{
30
- id: string;
31
- question: string;
32
- options: Record<string, string>;
33
- correctAnswerKeys: string[];
34
- namespace: "peerbench.ai";
35
- kind: "llm/mcq.tc";
36
- schemaVersion: 1;
37
- metadata?: Record<string, unknown> | undefined;
38
- }, "kind" | "namespace" | "schemaVersion">) => {
39
- id: string;
40
- question: string;
41
- options: Record<string, string>;
42
- correctAnswerKeys: string[];
43
- namespace: "peerbench.ai";
44
- kind: "llm/mcq.tc";
45
- schemaVersion: 1;
46
- metadata?: Record<string, unknown> | undefined;
47
- };
48
- newWithId(input: Omit<{
49
- id: string;
50
- question: string;
51
- options: Record<string, string>;
52
- correctAnswerKeys: string[];
53
- namespace: "peerbench.ai";
54
- kind: "llm/mcq.tc";
55
- schemaVersion: 1;
56
- metadata?: Record<string, unknown> | undefined;
57
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
58
- id: string;
59
- question: string;
60
- options: Record<string, string>;
61
- correctAnswerKeys: string[];
62
- namespace: "peerbench.ai";
63
- kind: "llm/mcq.tc";
64
- schemaVersion: 1;
65
- metadata?: Record<string, unknown> | undefined;
66
- }>;
67
- };
68
- type MCQTestCaseV1 = z.infer<typeof MCQTestCaseSchemaV1>;
69
- declare const MCQResponseSchemaV1: z.ZodObject<Omit<{
70
- id: z.ZodString;
71
- namespace: z.ZodString;
72
- schemaVersion: z.ZodNumber;
73
- kind: z.ZodString;
74
- startedAt: z.ZodNumber;
75
- completedAt: z.ZodNumber;
76
- testCaseId: z.ZodString;
77
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
78
- }, "kind" | "namespace" | "schemaVersion"> & {
79
- data: z.ZodString;
80
- modelSlug: z.ZodString;
81
- provider: z.ZodString;
82
- systemPromptId: z.ZodOptional<z.ZodString>;
83
- inputTokensUsed: z.ZodOptional<z.ZodNumber>;
84
- outputTokensUsed: z.ZodOptional<z.ZodNumber>;
85
- inputCost: z.ZodOptional<z.ZodString>;
86
- outputCost: z.ZodOptional<z.ZodString>;
87
- } & {
88
- namespace: z.ZodLiteral<"peerbench.ai">;
89
- kind: z.ZodLiteral<"llm/mcq.rs">;
90
- schemaVersion: z.ZodLiteral<1>;
91
- }, z.core.$strip> & {
92
- new: (input: Omit<{
93
- startedAt: number;
94
- completedAt: number;
95
- id: string;
96
- testCaseId: string;
97
- data: string;
98
- modelSlug: string;
99
- provider: string;
100
- namespace: "peerbench.ai";
101
- kind: "llm/mcq.rs";
102
- schemaVersion: 1;
103
- metadata?: Record<string, unknown> | undefined;
104
- systemPromptId?: string | undefined;
105
- inputTokensUsed?: number | undefined;
106
- outputTokensUsed?: number | undefined;
107
- inputCost?: string | undefined;
108
- outputCost?: string | undefined;
109
- }, "kind" | "namespace" | "schemaVersion">) => {
110
- startedAt: number;
111
- completedAt: number;
112
- id: string;
113
- testCaseId: string;
114
- data: string;
115
- modelSlug: string;
116
- provider: string;
117
- namespace: "peerbench.ai";
118
- kind: "llm/mcq.rs";
119
- schemaVersion: 1;
120
- metadata?: Record<string, unknown> | undefined;
121
- systemPromptId?: string | undefined;
122
- inputTokensUsed?: number | undefined;
123
- outputTokensUsed?: number | undefined;
124
- inputCost?: string | undefined;
125
- outputCost?: string | undefined;
126
- };
127
- newWithId(input: Omit<{
128
- startedAt: number;
129
- completedAt: number;
130
- id: string;
131
- testCaseId: string;
132
- data: string;
133
- modelSlug: string;
134
- provider: string;
135
- namespace: "peerbench.ai";
136
- kind: "llm/mcq.rs";
137
- schemaVersion: 1;
138
- metadata?: Record<string, unknown> | undefined;
139
- systemPromptId?: string | undefined;
140
- inputTokensUsed?: number | undefined;
141
- outputTokensUsed?: number | undefined;
142
- inputCost?: string | undefined;
143
- outputCost?: string | undefined;
144
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
145
- startedAt: number;
146
- completedAt: number;
147
- id: string;
148
- testCaseId: string;
149
- data: string;
150
- modelSlug: string;
151
- provider: string;
152
- namespace: "peerbench.ai";
153
- kind: "llm/mcq.rs";
154
- schemaVersion: 1;
155
- metadata?: Record<string, unknown> | undefined;
156
- systemPromptId?: string | undefined;
157
- inputTokensUsed?: number | undefined;
158
- outputTokensUsed?: number | undefined;
159
- inputCost?: string | undefined;
160
- outputCost?: string | undefined;
161
- }>;
162
- };
163
- type MCQResponseV1 = z.infer<typeof MCQResponseSchemaV1>;
164
- declare const MCQScoreSchemaV1: z.ZodObject<Omit<{
165
- id: z.ZodString;
166
- namespace: z.ZodString;
167
- kind: z.ZodString;
168
- schemaVersion: z.ZodNumber;
169
- value: z.ZodNumber;
170
- responseId: z.ZodString;
171
- explanation: z.ZodOptional<z.ZodString>;
172
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
173
- scoringMethod: z.ZodEnum<{
174
- readonly ai: "ai";
175
- readonly human: "human";
176
- readonly algo: "algo";
177
- }>;
178
- }, "kind" | "namespace" | "schemaVersion"> & {
179
- extractedAnswers: z.ZodArray<z.ZodString>;
180
- scorerAISystemPrompt: z.ZodOptional<z.ZodString>;
181
- scorerAISystemPromptId: z.ZodOptional<z.ZodString>;
182
- scorerAIProvider: z.ZodOptional<z.ZodString>;
183
- scorerAIModelSlug: z.ZodOptional<z.ZodString>;
184
- scorerAIInputTokensUsed: z.ZodOptional<z.ZodNumber>;
185
- scorerAIOutputTokensUsed: z.ZodOptional<z.ZodNumber>;
186
- scorerAIInputCost: z.ZodOptional<z.ZodString>;
187
- scorerAIOutputCost: z.ZodOptional<z.ZodString>;
188
- } & {
189
- namespace: z.ZodLiteral<"peerbench.ai">;
190
- kind: z.ZodLiteral<"llm/mcq.sc">;
191
- schemaVersion: z.ZodLiteral<1>;
192
- }, z.core.$strip> & {
193
- new: (input: Omit<{
194
- id: string;
195
- value: number;
196
- responseId: string;
197
- scoringMethod: "ai" | "human" | "algo";
198
- extractedAnswers: string[];
199
- namespace: "peerbench.ai";
200
- kind: "llm/mcq.sc";
201
- schemaVersion: 1;
202
- metadata?: Record<string, unknown> | undefined;
203
- explanation?: string | undefined;
204
- scorerAISystemPrompt?: string | undefined;
205
- scorerAISystemPromptId?: string | undefined;
206
- scorerAIProvider?: string | undefined;
207
- scorerAIModelSlug?: string | undefined;
208
- scorerAIInputTokensUsed?: number | undefined;
209
- scorerAIOutputTokensUsed?: number | undefined;
210
- scorerAIInputCost?: string | undefined;
211
- scorerAIOutputCost?: string | undefined;
212
- }, "kind" | "namespace" | "schemaVersion">) => {
213
- id: string;
214
- value: number;
215
- responseId: string;
216
- scoringMethod: "ai" | "human" | "algo";
217
- extractedAnswers: string[];
218
- namespace: "peerbench.ai";
219
- kind: "llm/mcq.sc";
220
- schemaVersion: 1;
221
- metadata?: Record<string, unknown> | undefined;
222
- explanation?: string | undefined;
223
- scorerAISystemPrompt?: string | undefined;
224
- scorerAISystemPromptId?: string | undefined;
225
- scorerAIProvider?: string | undefined;
226
- scorerAIModelSlug?: string | undefined;
227
- scorerAIInputTokensUsed?: number | undefined;
228
- scorerAIOutputTokensUsed?: number | undefined;
229
- scorerAIInputCost?: string | undefined;
230
- scorerAIOutputCost?: string | undefined;
231
- };
232
- newWithId(input: Omit<{
233
- id: string;
234
- value: number;
235
- responseId: string;
236
- scoringMethod: "ai" | "human" | "algo";
237
- extractedAnswers: string[];
238
- namespace: "peerbench.ai";
239
- kind: "llm/mcq.sc";
240
- schemaVersion: 1;
241
- metadata?: Record<string, unknown> | undefined;
242
- explanation?: string | undefined;
243
- scorerAISystemPrompt?: string | undefined;
244
- scorerAISystemPromptId?: string | undefined;
245
- scorerAIProvider?: string | undefined;
246
- scorerAIModelSlug?: string | undefined;
247
- scorerAIInputTokensUsed?: number | undefined;
248
- scorerAIOutputTokensUsed?: number | undefined;
249
- scorerAIInputCost?: string | undefined;
250
- scorerAIOutputCost?: string | undefined;
251
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
252
- id: string;
253
- value: number;
254
- responseId: string;
255
- scoringMethod: "ai" | "human" | "algo";
256
- extractedAnswers: string[];
257
- namespace: "peerbench.ai";
258
- kind: "llm/mcq.sc";
259
- schemaVersion: 1;
260
- metadata?: Record<string, unknown> | undefined;
261
- explanation?: string | undefined;
262
- scorerAISystemPrompt?: string | undefined;
263
- scorerAISystemPromptId?: string | undefined;
264
- scorerAIProvider?: string | undefined;
265
- scorerAIModelSlug?: string | undefined;
266
- scorerAIInputTokensUsed?: number | undefined;
267
- scorerAIOutputTokensUsed?: number | undefined;
268
- scorerAIInputCost?: string | undefined;
269
- scorerAIOutputCost?: string | undefined;
270
- }>;
271
- };
272
- type MCQScoreV1 = z.infer<typeof MCQScoreSchemaV1>;
273
-
274
- declare const MultiTurnKind: "llm/multi-turn";
275
- declare const MultiTurnTestCaseSchemaV1: z.ZodObject<Omit<{
276
- id: z.ZodString;
277
- namespace: z.ZodString;
278
- schemaVersion: z.ZodNumber;
279
- kind: z.ZodString;
280
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
281
- }, "kind" | "namespace" | "schemaVersion"> & {
282
- messages: z.ZodArray<z.ZodObject<{
283
- role: z.ZodString;
284
- content: z.ZodString;
285
- goodAnswers: z.ZodOptional<z.ZodArray<z.ZodString>>;
286
- badAnswers: z.ZodOptional<z.ZodArray<z.ZodString>>;
287
- }, z.core.$strip>>;
288
- maxTurns: z.ZodOptional<z.ZodNumber>;
289
- expectedOutcome: z.ZodOptional<z.ZodString>;
290
- } & {
291
- namespace: z.ZodLiteral<"peerbench.ai">;
292
- kind: z.ZodLiteral<"llm/multi-turn.tc">;
293
- schemaVersion: z.ZodLiteral<1>;
294
- }, z.core.$strip> & {
295
- new: (input: Omit<{
296
- id: string;
297
- messages: {
298
- role: string;
299
- content: string;
300
- goodAnswers?: string[] | undefined;
301
- badAnswers?: string[] | undefined;
302
- }[];
303
- namespace: "peerbench.ai";
304
- kind: "llm/multi-turn.tc";
305
- schemaVersion: 1;
306
- metadata?: Record<string, unknown> | undefined;
307
- maxTurns?: number | undefined;
308
- expectedOutcome?: string | undefined;
309
- }, "kind" | "namespace" | "schemaVersion">) => {
310
- id: string;
311
- messages: {
312
- role: string;
313
- content: string;
314
- goodAnswers?: string[] | undefined;
315
- badAnswers?: string[] | undefined;
316
- }[];
317
- namespace: "peerbench.ai";
318
- kind: "llm/multi-turn.tc";
319
- schemaVersion: 1;
320
- metadata?: Record<string, unknown> | undefined;
321
- maxTurns?: number | undefined;
322
- expectedOutcome?: string | undefined;
323
- };
324
- newWithId(input: Omit<{
325
- id: string;
326
- messages: {
327
- role: string;
328
- content: string;
329
- goodAnswers?: string[] | undefined;
330
- badAnswers?: string[] | undefined;
331
- }[];
332
- namespace: "peerbench.ai";
333
- kind: "llm/multi-turn.tc";
334
- schemaVersion: 1;
335
- metadata?: Record<string, unknown> | undefined;
336
- maxTurns?: number | undefined;
337
- expectedOutcome?: string | undefined;
338
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
339
- id: string;
340
- messages: {
341
- role: string;
342
- content: string;
343
- goodAnswers?: string[] | undefined;
344
- badAnswers?: string[] | undefined;
345
- }[];
346
- namespace: "peerbench.ai";
347
- kind: "llm/multi-turn.tc";
348
- schemaVersion: 1;
349
- metadata?: Record<string, unknown> | undefined;
350
- maxTurns?: number | undefined;
351
- expectedOutcome?: string | undefined;
352
- }>;
353
- };
354
- type MultiTurnTestCaseV1 = z.infer<typeof MultiTurnTestCaseSchemaV1>;
355
- declare const MultiTurnResponseSchemaV1: z.ZodObject<Omit<{
356
- id: z.ZodString;
357
- namespace: z.ZodString;
358
- schemaVersion: z.ZodNumber;
359
- kind: z.ZodString;
360
- startedAt: z.ZodNumber;
361
- completedAt: z.ZodNumber;
362
- testCaseId: z.ZodString;
363
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
364
- }, "kind" | "namespace" | "schemaVersion"> & {
365
- replies: z.ZodArray<z.ZodObject<{
366
- messageIndex: z.ZodNumber;
367
- startedAt: z.ZodNumber;
368
- completedAt: z.ZodNumber;
369
- data: z.ZodString;
370
- inputTokensUsed: z.ZodOptional<z.ZodNumber>;
371
- outputTokensUsed: z.ZodOptional<z.ZodNumber>;
372
- inputCost: z.ZodOptional<z.ZodString>;
373
- outputCost: z.ZodOptional<z.ZodString>;
374
- }, z.core.$strip>>;
375
- data: z.ZodString;
376
- modelSlug: z.ZodString;
377
- provider: z.ZodString;
378
- systemPromptId: z.ZodOptional<z.ZodString>;
379
- inputTokensUsed: z.ZodOptional<z.ZodNumber>;
380
- outputTokensUsed: z.ZodOptional<z.ZodNumber>;
381
- inputCost: z.ZodOptional<z.ZodString>;
382
- outputCost: z.ZodOptional<z.ZodString>;
383
- } & {
384
- namespace: z.ZodLiteral<"peerbench.ai">;
385
- kind: z.ZodLiteral<"llm/multi-turn.rs">;
386
- schemaVersion: z.ZodLiteral<1>;
387
- }, z.core.$strip> & {
388
- new: (input: Omit<{
389
- startedAt: number;
390
- completedAt: number;
391
- id: string;
392
- testCaseId: string;
393
- replies: {
394
- messageIndex: number;
395
- startedAt: number;
396
- completedAt: number;
397
- data: string;
398
- inputTokensUsed?: number | undefined;
399
- outputTokensUsed?: number | undefined;
400
- inputCost?: string | undefined;
401
- outputCost?: string | undefined;
402
- }[];
403
- data: string;
404
- modelSlug: string;
405
- provider: string;
406
- namespace: "peerbench.ai";
407
- kind: "llm/multi-turn.rs";
408
- schemaVersion: 1;
409
- metadata?: Record<string, unknown> | undefined;
410
- systemPromptId?: string | undefined;
411
- inputTokensUsed?: number | undefined;
412
- outputTokensUsed?: number | undefined;
413
- inputCost?: string | undefined;
414
- outputCost?: string | undefined;
415
- }, "kind" | "namespace" | "schemaVersion">) => {
416
- startedAt: number;
417
- completedAt: number;
418
- id: string;
419
- testCaseId: string;
420
- replies: {
421
- messageIndex: number;
422
- startedAt: number;
423
- completedAt: number;
424
- data: string;
425
- inputTokensUsed?: number | undefined;
426
- outputTokensUsed?: number | undefined;
427
- inputCost?: string | undefined;
428
- outputCost?: string | undefined;
429
- }[];
430
- data: string;
431
- modelSlug: string;
432
- provider: string;
433
- namespace: "peerbench.ai";
434
- kind: "llm/multi-turn.rs";
435
- schemaVersion: 1;
436
- metadata?: Record<string, unknown> | undefined;
437
- systemPromptId?: string | undefined;
438
- inputTokensUsed?: number | undefined;
439
- outputTokensUsed?: number | undefined;
440
- inputCost?: string | undefined;
441
- outputCost?: string | undefined;
442
- };
443
- newWithId(input: Omit<{
444
- startedAt: number;
445
- completedAt: number;
446
- id: string;
447
- testCaseId: string;
448
- replies: {
449
- messageIndex: number;
450
- startedAt: number;
451
- completedAt: number;
452
- data: string;
453
- inputTokensUsed?: number | undefined;
454
- outputTokensUsed?: number | undefined;
455
- inputCost?: string | undefined;
456
- outputCost?: string | undefined;
457
- }[];
458
- data: string;
459
- modelSlug: string;
460
- provider: string;
461
- namespace: "peerbench.ai";
462
- kind: "llm/multi-turn.rs";
463
- schemaVersion: 1;
464
- metadata?: Record<string, unknown> | undefined;
465
- systemPromptId?: string | undefined;
466
- inputTokensUsed?: number | undefined;
467
- outputTokensUsed?: number | undefined;
468
- inputCost?: string | undefined;
469
- outputCost?: string | undefined;
470
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
471
- startedAt: number;
472
- completedAt: number;
473
- id: string;
474
- testCaseId: string;
475
- replies: {
476
- messageIndex: number;
477
- startedAt: number;
478
- completedAt: number;
479
- data: string;
480
- inputTokensUsed?: number | undefined;
481
- outputTokensUsed?: number | undefined;
482
- inputCost?: string | undefined;
483
- outputCost?: string | undefined;
484
- }[];
485
- data: string;
486
- modelSlug: string;
487
- provider: string;
488
- namespace: "peerbench.ai";
489
- kind: "llm/multi-turn.rs";
490
- schemaVersion: 1;
491
- metadata?: Record<string, unknown> | undefined;
492
- systemPromptId?: string | undefined;
493
- inputTokensUsed?: number | undefined;
494
- outputTokensUsed?: number | undefined;
495
- inputCost?: string | undefined;
496
- outputCost?: string | undefined;
497
- }>;
498
- };
499
- type MultiTurnResponseV1 = z.infer<typeof MultiTurnResponseSchemaV1>;
500
- declare const MultiTurnScoreSchemaV1: z.ZodObject<Omit<{
501
- id: z.ZodString;
502
- namespace: z.ZodString;
503
- kind: z.ZodString;
504
- schemaVersion: z.ZodNumber;
505
- value: z.ZodNumber;
506
- responseId: z.ZodString;
507
- explanation: z.ZodOptional<z.ZodString>;
508
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
509
- scoringMethod: z.ZodEnum<{
510
- readonly ai: "ai";
511
- readonly human: "human";
512
- readonly algo: "algo";
513
- }>;
514
- }, "kind" | "namespace" | "schemaVersion"> & {
515
- individualScores: z.ZodArray<z.ZodObject<{
516
- replyIndex: z.ZodNumber;
517
- value: z.ZodNumber;
518
- }, z.core.$strip>>;
519
- scorerAISystemPrompt: z.ZodOptional<z.ZodString>;
520
- scorerAISystemPromptId: z.ZodOptional<z.ZodString>;
521
- scorerAIProvider: z.ZodOptional<z.ZodString>;
522
- scorerAIModelSlug: z.ZodOptional<z.ZodString>;
523
- scorerAIInputTokensUsed: z.ZodOptional<z.ZodNumber>;
524
- scorerAIOutputTokensUsed: z.ZodOptional<z.ZodNumber>;
525
- scorerAIInputCost: z.ZodOptional<z.ZodString>;
526
- scorerAIOutputCost: z.ZodOptional<z.ZodString>;
527
- } & {
528
- namespace: z.ZodLiteral<"peerbench.ai">;
529
- kind: z.ZodLiteral<"llm/multi-turn.sc">;
530
- schemaVersion: z.ZodLiteral<1>;
531
- }, z.core.$strip> & {
532
- new: (input: Omit<{
533
- id: string;
534
- value: number;
535
- responseId: string;
536
- scoringMethod: "ai" | "human" | "algo";
537
- individualScores: {
538
- replyIndex: number;
539
- value: number;
540
- }[];
541
- namespace: "peerbench.ai";
542
- kind: "llm/multi-turn.sc";
543
- schemaVersion: 1;
544
- metadata?: Record<string, unknown> | undefined;
545
- explanation?: string | undefined;
546
- scorerAISystemPrompt?: string | undefined;
547
- scorerAISystemPromptId?: string | undefined;
548
- scorerAIProvider?: string | undefined;
549
- scorerAIModelSlug?: string | undefined;
550
- scorerAIInputTokensUsed?: number | undefined;
551
- scorerAIOutputTokensUsed?: number | undefined;
552
- scorerAIInputCost?: string | undefined;
553
- scorerAIOutputCost?: string | undefined;
554
- }, "kind" | "namespace" | "schemaVersion">) => {
555
- id: string;
556
- value: number;
557
- responseId: string;
558
- scoringMethod: "ai" | "human" | "algo";
559
- individualScores: {
560
- replyIndex: number;
561
- value: number;
562
- }[];
563
- namespace: "peerbench.ai";
564
- kind: "llm/multi-turn.sc";
565
- schemaVersion: 1;
566
- metadata?: Record<string, unknown> | undefined;
567
- explanation?: string | undefined;
568
- scorerAISystemPrompt?: string | undefined;
569
- scorerAISystemPromptId?: string | undefined;
570
- scorerAIProvider?: string | undefined;
571
- scorerAIModelSlug?: string | undefined;
572
- scorerAIInputTokensUsed?: number | undefined;
573
- scorerAIOutputTokensUsed?: number | undefined;
574
- scorerAIInputCost?: string | undefined;
575
- scorerAIOutputCost?: string | undefined;
576
- };
577
- newWithId(input: Omit<{
578
- id: string;
579
- value: number;
580
- responseId: string;
581
- scoringMethod: "ai" | "human" | "algo";
582
- individualScores: {
583
- replyIndex: number;
584
- value: number;
585
- }[];
586
- namespace: "peerbench.ai";
587
- kind: "llm/multi-turn.sc";
588
- schemaVersion: 1;
589
- metadata?: Record<string, unknown> | undefined;
590
- explanation?: string | undefined;
591
- scorerAISystemPrompt?: string | undefined;
592
- scorerAISystemPromptId?: string | undefined;
593
- scorerAIProvider?: string | undefined;
594
- scorerAIModelSlug?: string | undefined;
595
- scorerAIInputTokensUsed?: number | undefined;
596
- scorerAIOutputTokensUsed?: number | undefined;
597
- scorerAIInputCost?: string | undefined;
598
- scorerAIOutputCost?: string | undefined;
599
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
600
- id: string;
601
- value: number;
602
- responseId: string;
603
- scoringMethod: "ai" | "human" | "algo";
604
- individualScores: {
605
- replyIndex: number;
606
- value: number;
607
- }[];
608
- namespace: "peerbench.ai";
609
- kind: "llm/multi-turn.sc";
610
- schemaVersion: 1;
611
- metadata?: Record<string, unknown> | undefined;
612
- explanation?: string | undefined;
613
- scorerAISystemPrompt?: string | undefined;
614
- scorerAISystemPromptId?: string | undefined;
615
- scorerAIProvider?: string | undefined;
616
- scorerAIModelSlug?: string | undefined;
617
- scorerAIInputTokensUsed?: number | undefined;
618
- scorerAIOutputTokensUsed?: number | undefined;
619
- scorerAIInputCost?: string | undefined;
620
- scorerAIOutputCost?: string | undefined;
621
- }>;
622
- };
623
- type MultiTurnScoreV1 = z.infer<typeof MultiTurnScoreSchemaV1>;
624
-
625
- declare const QAKind: "llm/qa";
626
- declare const QATestCaseSchemaV1: z.ZodObject<Omit<{
627
- id: z.ZodString;
628
- namespace: z.ZodString;
629
- schemaVersion: z.ZodNumber;
630
- kind: z.ZodString;
631
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
632
- }, "kind" | "namespace" | "schemaVersion"> & {
633
- question: z.ZodString;
634
- goodAnswers: z.ZodArray<z.ZodString>;
635
- badAnswers: z.ZodArray<z.ZodString>;
636
- } & {
637
- namespace: z.ZodLiteral<"peerbench.ai">;
638
- kind: z.ZodLiteral<"llm/qa.tc">;
639
- schemaVersion: z.ZodLiteral<1>;
640
- }, z.core.$strip> & {
641
- new: (input: Omit<{
642
- id: string;
643
- question: string;
644
- goodAnswers: string[];
645
- badAnswers: string[];
646
- namespace: "peerbench.ai";
647
- kind: "llm/qa.tc";
648
- schemaVersion: 1;
649
- metadata?: Record<string, unknown> | undefined;
650
- }, "kind" | "namespace" | "schemaVersion">) => {
651
- id: string;
652
- question: string;
653
- goodAnswers: string[];
654
- badAnswers: string[];
655
- namespace: "peerbench.ai";
656
- kind: "llm/qa.tc";
657
- schemaVersion: 1;
658
- metadata?: Record<string, unknown> | undefined;
659
- };
660
- newWithId(input: Omit<{
661
- id: string;
662
- question: string;
663
- goodAnswers: string[];
664
- badAnswers: string[];
665
- namespace: "peerbench.ai";
666
- kind: "llm/qa.tc";
667
- schemaVersion: 1;
668
- metadata?: Record<string, unknown> | undefined;
669
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
670
- id: string;
671
- question: string;
672
- goodAnswers: string[];
673
- badAnswers: string[];
674
- namespace: "peerbench.ai";
675
- kind: "llm/qa.tc";
676
- schemaVersion: 1;
677
- metadata?: Record<string, unknown> | undefined;
678
- }>;
679
- };
680
- type QATestCaseV1 = z.infer<typeof QATestCaseSchemaV1>;
681
- declare const QAResponseSchemaV1: z.ZodObject<Omit<{
682
- id: z.ZodString;
683
- namespace: z.ZodString;
684
- schemaVersion: z.ZodNumber;
685
- kind: z.ZodString;
686
- startedAt: z.ZodNumber;
687
- completedAt: z.ZodNumber;
688
- testCaseId: z.ZodString;
689
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
690
- }, "kind" | "namespace" | "schemaVersion"> & {
691
- data: z.ZodString;
692
- modelSlug: z.ZodString;
693
- provider: z.ZodString;
694
- systemPromptId: z.ZodOptional<z.ZodString>;
695
- inputTokensUsed: z.ZodOptional<z.ZodNumber>;
696
- outputTokensUsed: z.ZodOptional<z.ZodNumber>;
697
- inputCost: z.ZodOptional<z.ZodString>;
698
- outputCost: z.ZodOptional<z.ZodString>;
699
- } & {
700
- namespace: z.ZodLiteral<"peerbench.ai">;
701
- kind: z.ZodLiteral<"llm/qa.rs">;
702
- schemaVersion: z.ZodLiteral<1>;
703
- }, z.core.$strip> & {
704
- new: (input: Omit<{
705
- startedAt: number;
706
- completedAt: number;
707
- id: string;
708
- testCaseId: string;
709
- data: string;
710
- modelSlug: string;
711
- provider: string;
712
- namespace: "peerbench.ai";
713
- kind: "llm/qa.rs";
714
- schemaVersion: 1;
715
- metadata?: Record<string, unknown> | undefined;
716
- systemPromptId?: string | undefined;
717
- inputTokensUsed?: number | undefined;
718
- outputTokensUsed?: number | undefined;
719
- inputCost?: string | undefined;
720
- outputCost?: string | undefined;
721
- }, "kind" | "namespace" | "schemaVersion">) => {
722
- startedAt: number;
723
- completedAt: number;
724
- id: string;
725
- testCaseId: string;
726
- data: string;
727
- modelSlug: string;
728
- provider: string;
729
- namespace: "peerbench.ai";
730
- kind: "llm/qa.rs";
731
- schemaVersion: 1;
732
- metadata?: Record<string, unknown> | undefined;
733
- systemPromptId?: string | undefined;
734
- inputTokensUsed?: number | undefined;
735
- outputTokensUsed?: number | undefined;
736
- inputCost?: string | undefined;
737
- outputCost?: string | undefined;
738
- };
739
- newWithId(input: Omit<{
740
- startedAt: number;
741
- completedAt: number;
742
- id: string;
743
- testCaseId: string;
744
- data: string;
745
- modelSlug: string;
746
- provider: string;
747
- namespace: "peerbench.ai";
748
- kind: "llm/qa.rs";
749
- schemaVersion: 1;
750
- metadata?: Record<string, unknown> | undefined;
751
- systemPromptId?: string | undefined;
752
- inputTokensUsed?: number | undefined;
753
- outputTokensUsed?: number | undefined;
754
- inputCost?: string | undefined;
755
- outputCost?: string | undefined;
756
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
757
- startedAt: number;
758
- completedAt: number;
759
- id: string;
760
- testCaseId: string;
761
- data: string;
762
- modelSlug: string;
763
- provider: string;
764
- namespace: "peerbench.ai";
765
- kind: "llm/qa.rs";
766
- schemaVersion: 1;
767
- metadata?: Record<string, unknown> | undefined;
768
- systemPromptId?: string | undefined;
769
- inputTokensUsed?: number | undefined;
770
- outputTokensUsed?: number | undefined;
771
- inputCost?: string | undefined;
772
- outputCost?: string | undefined;
773
- }>;
774
- };
775
- type QAResponseV1 = z.infer<typeof QAResponseSchemaV1>;
776
- declare const QAScoreSchemaV1: z.ZodObject<Omit<{
777
- id: z.ZodString;
778
- namespace: z.ZodString;
779
- kind: z.ZodString;
780
- schemaVersion: z.ZodNumber;
781
- value: z.ZodNumber;
782
- responseId: z.ZodString;
783
- explanation: z.ZodOptional<z.ZodString>;
784
- metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
785
- scoringMethod: z.ZodEnum<{
786
- readonly ai: "ai";
787
- readonly human: "human";
788
- readonly algo: "algo";
789
- }>;
790
- }, "kind" | "namespace" | "schemaVersion"> & {
791
- scorerAISystemPrompt: z.ZodOptional<z.ZodString>;
792
- scorerAISystemPromptId: z.ZodOptional<z.ZodString>;
793
- scorerAIProvider: z.ZodOptional<z.ZodString>;
794
- scorerAIModelSlug: z.ZodOptional<z.ZodString>;
795
- scorerAIInputTokensUsed: z.ZodOptional<z.ZodNumber>;
796
- scorerAIOutputTokensUsed: z.ZodOptional<z.ZodNumber>;
797
- scorerAIInputCost: z.ZodOptional<z.ZodString>;
798
- scorerAIOutputCost: z.ZodOptional<z.ZodString>;
799
- } & {
800
- namespace: z.ZodLiteral<"peerbench.ai">;
801
- kind: z.ZodLiteral<"llm/qa.sc">;
802
- schemaVersion: z.ZodLiteral<1>;
803
- }, z.core.$strip> & {
804
- new: (input: Omit<{
805
- id: string;
806
- value: number;
807
- responseId: string;
808
- scoringMethod: "ai" | "human" | "algo";
809
- namespace: "peerbench.ai";
810
- kind: "llm/qa.sc";
811
- schemaVersion: 1;
812
- metadata?: Record<string, unknown> | undefined;
813
- explanation?: string | undefined;
814
- scorerAISystemPrompt?: string | undefined;
815
- scorerAISystemPromptId?: string | undefined;
816
- scorerAIProvider?: string | undefined;
817
- scorerAIModelSlug?: string | undefined;
818
- scorerAIInputTokensUsed?: number | undefined;
819
- scorerAIOutputTokensUsed?: number | undefined;
820
- scorerAIInputCost?: string | undefined;
821
- scorerAIOutputCost?: string | undefined;
822
- }, "kind" | "namespace" | "schemaVersion">) => {
823
- id: string;
824
- value: number;
825
- responseId: string;
826
- scoringMethod: "ai" | "human" | "algo";
827
- namespace: "peerbench.ai";
828
- kind: "llm/qa.sc";
829
- schemaVersion: 1;
830
- metadata?: Record<string, unknown> | undefined;
831
- explanation?: string | undefined;
832
- scorerAISystemPrompt?: string | undefined;
833
- scorerAISystemPromptId?: string | undefined;
834
- scorerAIProvider?: string | undefined;
835
- scorerAIModelSlug?: string | undefined;
836
- scorerAIInputTokensUsed?: number | undefined;
837
- scorerAIOutputTokensUsed?: number | undefined;
838
- scorerAIInputCost?: string | undefined;
839
- scorerAIOutputCost?: string | undefined;
840
- };
841
- newWithId(input: Omit<{
842
- id: string;
843
- value: number;
844
- responseId: string;
845
- scoringMethod: "ai" | "human" | "algo";
846
- namespace: "peerbench.ai";
847
- kind: "llm/qa.sc";
848
- schemaVersion: 1;
849
- metadata?: Record<string, unknown> | undefined;
850
- explanation?: string | undefined;
851
- scorerAISystemPrompt?: string | undefined;
852
- scorerAISystemPromptId?: string | undefined;
853
- scorerAIProvider?: string | undefined;
854
- scorerAIModelSlug?: string | undefined;
855
- scorerAIInputTokensUsed?: number | undefined;
856
- scorerAIOutputTokensUsed?: number | undefined;
857
- scorerAIInputCost?: string | undefined;
858
- scorerAIOutputCost?: string | undefined;
859
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
860
- id: string;
861
- value: number;
862
- responseId: string;
863
- scoringMethod: "ai" | "human" | "algo";
864
- namespace: "peerbench.ai";
865
- kind: "llm/qa.sc";
866
- schemaVersion: 1;
867
- metadata?: Record<string, unknown> | undefined;
868
- explanation?: string | undefined;
869
- scorerAISystemPrompt?: string | undefined;
870
- scorerAISystemPromptId?: string | undefined;
871
- scorerAIProvider?: string | undefined;
872
- scorerAIModelSlug?: string | undefined;
873
- scorerAIInputTokensUsed?: number | undefined;
874
- scorerAIOutputTokensUsed?: number | undefined;
875
- scorerAIInputCost?: string | undefined;
876
- scorerAIOutputCost?: string | undefined;
877
- }>;
878
- };
879
- type QAScoreV1 = z.infer<typeof QAScoreSchemaV1>;
880
-
881
- declare const peerbenchRunner: ((params: {
882
- testCase: {
883
- id: string;
884
- question: string;
885
- options: Record<string, string>;
886
- correctAnswerKeys: string[];
887
- namespace: "peerbench.ai";
888
- kind: "llm/mcq.tc";
889
- schemaVersion: 1;
890
- metadata?: Record<string, unknown> | undefined;
891
- } | {
892
- id: string;
893
- question: string;
894
- goodAnswers: string[];
895
- badAnswers: string[];
896
- namespace: "peerbench.ai";
897
- kind: "llm/qa.tc";
898
- schemaVersion: 1;
899
- metadata?: Record<string, unknown> | undefined;
900
- };
901
- provider: AbstractLLMProvider;
902
- scorer?: MCQScorer | LLMAsAJudgeScorer | undefined;
903
- runConfig: {
904
- model: string;
905
- llmJudgeModel?: string | undefined;
906
- llmJudgeSystemPrompt?: {
907
- id: string;
908
- version: number;
909
- content: string;
910
- namespace: "peerbench.ai";
911
- kind: `${string}/simple.sys-prompt`;
912
- schemaVersion: 1;
913
- metadata?: Record<string, unknown> | undefined;
914
- } | undefined;
915
- llmJudgeFieldsToExtract?: Record<string, z__default.ZodType<unknown, unknown, z__default.core.$ZodTypeInternals<unknown, unknown>>> | undefined;
916
- systemPrompt?: {
917
- id: string;
918
- version: number;
919
- content: string;
920
- namespace: "peerbench.ai";
921
- kind: `${string}/simple.sys-prompt`;
922
- schemaVersion: 1;
923
- metadata?: Record<string, unknown> | undefined;
924
- } | undefined;
925
- templateVariables?: Record<string, string> | undefined;
926
- };
927
- idGenerators?: {
928
- response?: IdGenerator;
929
- score?: IdGenerator;
930
- };
931
- }) => Promise<{
932
- response: {
933
- startedAt: number;
934
- completedAt: number;
935
- id: string;
936
- testCaseId: string;
937
- data: string;
938
- modelSlug: string;
939
- provider: string;
940
- namespace: "peerbench.ai";
941
- kind: "llm/mcq.rs";
942
- schemaVersion: 1;
943
- metadata?: Record<string, unknown> | undefined;
944
- systemPromptId?: string | undefined;
945
- inputTokensUsed?: number | undefined;
946
- outputTokensUsed?: number | undefined;
947
- inputCost?: string | undefined;
948
- outputCost?: string | undefined;
949
- } | {
950
- startedAt: number;
951
- completedAt: number;
952
- id: string;
953
- testCaseId: string;
954
- data: string;
955
- modelSlug: string;
956
- provider: string;
957
- namespace: "peerbench.ai";
958
- kind: "llm/qa.rs";
959
- schemaVersion: 1;
960
- metadata?: Record<string, unknown> | undefined;
961
- systemPromptId?: string | undefined;
962
- inputTokensUsed?: number | undefined;
963
- outputTokensUsed?: number | undefined;
964
- inputCost?: string | undefined;
965
- outputCost?: string | undefined;
966
- };
967
- score?: {
968
- id: string;
969
- value: number;
970
- responseId: string;
971
- scoringMethod: "ai" | "human" | "algo";
972
- extractedAnswers: string[];
973
- namespace: "peerbench.ai";
974
- kind: "llm/mcq.sc";
975
- schemaVersion: 1;
976
- metadata?: Record<string, unknown> | undefined;
977
- explanation?: string | undefined;
978
- scorerAISystemPrompt?: string | undefined;
979
- scorerAISystemPromptId?: string | undefined;
980
- scorerAIProvider?: string | undefined;
981
- scorerAIModelSlug?: string | undefined;
982
- scorerAIInputTokensUsed?: number | undefined;
983
- scorerAIOutputTokensUsed?: number | undefined;
984
- scorerAIInputCost?: string | undefined;
985
- scorerAIOutputCost?: string | undefined;
986
- } | {
987
- id: string;
988
- value: number;
989
- responseId: string;
990
- scoringMethod: "ai" | "human" | "algo";
991
- namespace: "peerbench.ai";
992
- kind: "llm/qa.sc";
993
- schemaVersion: 1;
994
- metadata?: Record<string, unknown> | undefined;
995
- explanation?: string | undefined;
996
- scorerAISystemPrompt?: string | undefined;
997
- scorerAISystemPromptId?: string | undefined;
998
- scorerAIProvider?: string | undefined;
999
- scorerAIModelSlug?: string | undefined;
1000
- scorerAIInputTokensUsed?: number | undefined;
1001
- scorerAIOutputTokensUsed?: number | undefined;
1002
- scorerAIInputCost?: string | undefined;
1003
- scorerAIOutputCost?: string | undefined;
1004
- } | undefined;
1005
- }>) & {
1006
- config: {
1007
- runConfigSchema: z__default.ZodObject<{
1008
- model: z__default.ZodString;
1009
- llmJudgeModel: z__default.ZodOptional<z__default.ZodString>;
1010
- llmJudgeSystemPrompt: z__default.ZodOptional<z__default.ZodObject<Omit<{
1011
- id: z__default.ZodString;
1012
- namespace: z__default.ZodString;
1013
- kind: z__default.ZodString;
1014
- schemaVersion: z__default.ZodNumber;
1015
- version: z__default.ZodNumber;
1016
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1017
- }, "kind" | "namespace" | "schemaVersion"> & {
1018
- content: z__default.ZodString;
1019
- } & {
1020
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1021
- kind: z__default.ZodLiteral<`${string}/simple.sys-prompt`>;
1022
- schemaVersion: z__default.ZodLiteral<1>;
1023
- }, z__default.core.$strip> & {
1024
- new: (input: Omit<{
1025
- id: string;
1026
- version: number;
1027
- content: string;
1028
- namespace: "peerbench.ai";
1029
- kind: `${string}/simple.sys-prompt`;
1030
- schemaVersion: 1;
1031
- metadata?: Record<string, unknown> | undefined;
1032
- }, "kind" | "namespace" | "schemaVersion">) => {
1033
- id: string;
1034
- version: number;
1035
- content: string;
1036
- namespace: "peerbench.ai";
1037
- kind: `${string}/simple.sys-prompt`;
1038
- schemaVersion: 1;
1039
- metadata?: Record<string, unknown> | undefined;
1040
- };
1041
- newWithId(input: Omit<{
1042
- id: string;
1043
- version: number;
1044
- content: string;
1045
- namespace: "peerbench.ai";
1046
- kind: `${string}/simple.sys-prompt`;
1047
- schemaVersion: 1;
1048
- metadata?: Record<string, unknown> | undefined;
1049
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1050
- id: string;
1051
- version: number;
1052
- content: string;
1053
- namespace: "peerbench.ai";
1054
- kind: `${string}/simple.sys-prompt`;
1055
- schemaVersion: 1;
1056
- metadata?: Record<string, unknown> | undefined;
1057
- }>;
1058
- }>;
1059
- llmJudgeFieldsToExtract: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodCustom<z__default.ZodType<unknown, unknown, z__default.core.$ZodTypeInternals<unknown, unknown>>, z__default.ZodType<unknown, unknown, z__default.core.$ZodTypeInternals<unknown, unknown>>>>>;
1060
- systemPrompt: z__default.ZodOptional<z__default.ZodObject<Omit<{
1061
- id: z__default.ZodString;
1062
- namespace: z__default.ZodString;
1063
- kind: z__default.ZodString;
1064
- schemaVersion: z__default.ZodNumber;
1065
- version: z__default.ZodNumber;
1066
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1067
- }, "kind" | "namespace" | "schemaVersion"> & {
1068
- content: z__default.ZodString;
1069
- } & {
1070
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1071
- kind: z__default.ZodLiteral<`${string}/simple.sys-prompt`>;
1072
- schemaVersion: z__default.ZodLiteral<1>;
1073
- }, z__default.core.$strip> & {
1074
- new: (input: Omit<{
1075
- id: string;
1076
- version: number;
1077
- content: string;
1078
- namespace: "peerbench.ai";
1079
- kind: `${string}/simple.sys-prompt`;
1080
- schemaVersion: 1;
1081
- metadata?: Record<string, unknown> | undefined;
1082
- }, "kind" | "namespace" | "schemaVersion">) => {
1083
- id: string;
1084
- version: number;
1085
- content: string;
1086
- namespace: "peerbench.ai";
1087
- kind: `${string}/simple.sys-prompt`;
1088
- schemaVersion: 1;
1089
- metadata?: Record<string, unknown> | undefined;
1090
- };
1091
- newWithId(input: Omit<{
1092
- id: string;
1093
- version: number;
1094
- content: string;
1095
- namespace: "peerbench.ai";
1096
- kind: `${string}/simple.sys-prompt`;
1097
- schemaVersion: 1;
1098
- metadata?: Record<string, unknown> | undefined;
1099
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1100
- id: string;
1101
- version: number;
1102
- content: string;
1103
- namespace: "peerbench.ai";
1104
- kind: `${string}/simple.sys-prompt`;
1105
- schemaVersion: 1;
1106
- metadata?: Record<string, unknown> | undefined;
1107
- }>;
1108
- }>;
1109
- templateVariables: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodString>>;
1110
- }, z__default.core.$strip>;
1111
- schemaSets: [{
1112
- readonly testCase: z__default.ZodObject<Omit<{
1113
- id: z__default.ZodString;
1114
- namespace: z__default.ZodString;
1115
- schemaVersion: z__default.ZodNumber;
1116
- kind: z__default.ZodString;
1117
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1118
- }, "kind" | "namespace" | "schemaVersion"> & {
1119
- question: z__default.ZodString;
1120
- options: z__default.ZodRecord<z__default.ZodString, z__default.ZodString>;
1121
- correctAnswerKeys: z__default.ZodArray<z__default.ZodString>;
1122
- } & {
1123
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1124
- kind: z__default.ZodLiteral<"llm/mcq.tc">;
1125
- schemaVersion: z__default.ZodLiteral<1>;
1126
- }, z__default.core.$strip> & {
1127
- new: (input: Omit<{
1128
- id: string;
1129
- question: string;
1130
- options: Record<string, string>;
1131
- correctAnswerKeys: string[];
1132
- namespace: "peerbench.ai";
1133
- kind: "llm/mcq.tc";
1134
- schemaVersion: 1;
1135
- metadata?: Record<string, unknown> | undefined;
1136
- }, "kind" | "namespace" | "schemaVersion">) => {
1137
- id: string;
1138
- question: string;
1139
- options: Record<string, string>;
1140
- correctAnswerKeys: string[];
1141
- namespace: "peerbench.ai";
1142
- kind: "llm/mcq.tc";
1143
- schemaVersion: 1;
1144
- metadata?: Record<string, unknown> | undefined;
1145
- };
1146
- newWithId(input: Omit<{
1147
- id: string;
1148
- question: string;
1149
- options: Record<string, string>;
1150
- correctAnswerKeys: string[];
1151
- namespace: "peerbench.ai";
1152
- kind: "llm/mcq.tc";
1153
- schemaVersion: 1;
1154
- metadata?: Record<string, unknown> | undefined;
1155
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1156
- id: string;
1157
- question: string;
1158
- options: Record<string, string>;
1159
- correctAnswerKeys: string[];
1160
- namespace: "peerbench.ai";
1161
- kind: "llm/mcq.tc";
1162
- schemaVersion: 1;
1163
- metadata?: Record<string, unknown> | undefined;
1164
- }>;
1165
- };
1166
- readonly response: z__default.ZodObject<Omit<{
1167
- id: z__default.ZodString;
1168
- namespace: z__default.ZodString;
1169
- schemaVersion: z__default.ZodNumber;
1170
- kind: z__default.ZodString;
1171
- startedAt: z__default.ZodNumber;
1172
- completedAt: z__default.ZodNumber;
1173
- testCaseId: z__default.ZodString;
1174
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1175
- }, "kind" | "namespace" | "schemaVersion"> & {
1176
- data: z__default.ZodString;
1177
- modelSlug: z__default.ZodString;
1178
- provider: z__default.ZodString;
1179
- systemPromptId: z__default.ZodOptional<z__default.ZodString>;
1180
- inputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1181
- outputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1182
- inputCost: z__default.ZodOptional<z__default.ZodString>;
1183
- outputCost: z__default.ZodOptional<z__default.ZodString>;
1184
- } & {
1185
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1186
- kind: z__default.ZodLiteral<"llm/mcq.rs">;
1187
- schemaVersion: z__default.ZodLiteral<1>;
1188
- }, z__default.core.$strip> & {
1189
- new: (input: Omit<{
1190
- startedAt: number;
1191
- completedAt: number;
1192
- id: string;
1193
- testCaseId: string;
1194
- data: string;
1195
- modelSlug: string;
1196
- provider: string;
1197
- namespace: "peerbench.ai";
1198
- kind: "llm/mcq.rs";
1199
- schemaVersion: 1;
1200
- metadata?: Record<string, unknown> | undefined;
1201
- systemPromptId?: string | undefined;
1202
- inputTokensUsed?: number | undefined;
1203
- outputTokensUsed?: number | undefined;
1204
- inputCost?: string | undefined;
1205
- outputCost?: string | undefined;
1206
- }, "kind" | "namespace" | "schemaVersion">) => {
1207
- startedAt: number;
1208
- completedAt: number;
1209
- id: string;
1210
- testCaseId: string;
1211
- data: string;
1212
- modelSlug: string;
1213
- provider: string;
1214
- namespace: "peerbench.ai";
1215
- kind: "llm/mcq.rs";
1216
- schemaVersion: 1;
1217
- metadata?: Record<string, unknown> | undefined;
1218
- systemPromptId?: string | undefined;
1219
- inputTokensUsed?: number | undefined;
1220
- outputTokensUsed?: number | undefined;
1221
- inputCost?: string | undefined;
1222
- outputCost?: string | undefined;
1223
- };
1224
- newWithId(input: Omit<{
1225
- startedAt: number;
1226
- completedAt: number;
1227
- id: string;
1228
- testCaseId: string;
1229
- data: string;
1230
- modelSlug: string;
1231
- provider: string;
1232
- namespace: "peerbench.ai";
1233
- kind: "llm/mcq.rs";
1234
- schemaVersion: 1;
1235
- metadata?: Record<string, unknown> | undefined;
1236
- systemPromptId?: string | undefined;
1237
- inputTokensUsed?: number | undefined;
1238
- outputTokensUsed?: number | undefined;
1239
- inputCost?: string | undefined;
1240
- outputCost?: string | undefined;
1241
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1242
- startedAt: number;
1243
- completedAt: number;
1244
- id: string;
1245
- testCaseId: string;
1246
- data: string;
1247
- modelSlug: string;
1248
- provider: string;
1249
- namespace: "peerbench.ai";
1250
- kind: "llm/mcq.rs";
1251
- schemaVersion: 1;
1252
- metadata?: Record<string, unknown> | undefined;
1253
- systemPromptId?: string | undefined;
1254
- inputTokensUsed?: number | undefined;
1255
- outputTokensUsed?: number | undefined;
1256
- inputCost?: string | undefined;
1257
- outputCost?: string | undefined;
1258
- }>;
1259
- };
1260
- readonly score: z__default.ZodObject<Omit<{
1261
- id: z__default.ZodString;
1262
- namespace: z__default.ZodString;
1263
- kind: z__default.ZodString;
1264
- schemaVersion: z__default.ZodNumber;
1265
- value: z__default.ZodNumber;
1266
- responseId: z__default.ZodString;
1267
- explanation: z__default.ZodOptional<z__default.ZodString>;
1268
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1269
- scoringMethod: z__default.ZodEnum<{
1270
- readonly ai: "ai";
1271
- readonly human: "human";
1272
- readonly algo: "algo";
1273
- }>;
1274
- }, "kind" | "namespace" | "schemaVersion"> & {
1275
- extractedAnswers: z__default.ZodArray<z__default.ZodString>;
1276
- scorerAISystemPrompt: z__default.ZodOptional<z__default.ZodString>;
1277
- scorerAISystemPromptId: z__default.ZodOptional<z__default.ZodString>;
1278
- scorerAIProvider: z__default.ZodOptional<z__default.ZodString>;
1279
- scorerAIModelSlug: z__default.ZodOptional<z__default.ZodString>;
1280
- scorerAIInputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1281
- scorerAIOutputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1282
- scorerAIInputCost: z__default.ZodOptional<z__default.ZodString>;
1283
- scorerAIOutputCost: z__default.ZodOptional<z__default.ZodString>;
1284
- } & {
1285
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1286
- kind: z__default.ZodLiteral<"llm/mcq.sc">;
1287
- schemaVersion: z__default.ZodLiteral<1>;
1288
- }, z__default.core.$strip> & {
1289
- new: (input: Omit<{
1290
- id: string;
1291
- value: number;
1292
- responseId: string;
1293
- scoringMethod: "ai" | "human" | "algo";
1294
- extractedAnswers: string[];
1295
- namespace: "peerbench.ai";
1296
- kind: "llm/mcq.sc";
1297
- schemaVersion: 1;
1298
- metadata?: Record<string, unknown> | undefined;
1299
- explanation?: string | undefined;
1300
- scorerAISystemPrompt?: string | undefined;
1301
- scorerAISystemPromptId?: string | undefined;
1302
- scorerAIProvider?: string | undefined;
1303
- scorerAIModelSlug?: string | undefined;
1304
- scorerAIInputTokensUsed?: number | undefined;
1305
- scorerAIOutputTokensUsed?: number | undefined;
1306
- scorerAIInputCost?: string | undefined;
1307
- scorerAIOutputCost?: string | undefined;
1308
- }, "kind" | "namespace" | "schemaVersion">) => {
1309
- id: string;
1310
- value: number;
1311
- responseId: string;
1312
- scoringMethod: "ai" | "human" | "algo";
1313
- extractedAnswers: string[];
1314
- namespace: "peerbench.ai";
1315
- kind: "llm/mcq.sc";
1316
- schemaVersion: 1;
1317
- metadata?: Record<string, unknown> | undefined;
1318
- explanation?: string | undefined;
1319
- scorerAISystemPrompt?: string | undefined;
1320
- scorerAISystemPromptId?: string | undefined;
1321
- scorerAIProvider?: string | undefined;
1322
- scorerAIModelSlug?: string | undefined;
1323
- scorerAIInputTokensUsed?: number | undefined;
1324
- scorerAIOutputTokensUsed?: number | undefined;
1325
- scorerAIInputCost?: string | undefined;
1326
- scorerAIOutputCost?: string | undefined;
1327
- };
1328
- newWithId(input: Omit<{
1329
- id: string;
1330
- value: number;
1331
- responseId: string;
1332
- scoringMethod: "ai" | "human" | "algo";
1333
- extractedAnswers: string[];
1334
- namespace: "peerbench.ai";
1335
- kind: "llm/mcq.sc";
1336
- schemaVersion: 1;
1337
- metadata?: Record<string, unknown> | undefined;
1338
- explanation?: string | undefined;
1339
- scorerAISystemPrompt?: string | undefined;
1340
- scorerAISystemPromptId?: string | undefined;
1341
- scorerAIProvider?: string | undefined;
1342
- scorerAIModelSlug?: string | undefined;
1343
- scorerAIInputTokensUsed?: number | undefined;
1344
- scorerAIOutputTokensUsed?: number | undefined;
1345
- scorerAIInputCost?: string | undefined;
1346
- scorerAIOutputCost?: string | undefined;
1347
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1348
- id: string;
1349
- value: number;
1350
- responseId: string;
1351
- scoringMethod: "ai" | "human" | "algo";
1352
- extractedAnswers: string[];
1353
- namespace: "peerbench.ai";
1354
- kind: "llm/mcq.sc";
1355
- schemaVersion: 1;
1356
- metadata?: Record<string, unknown> | undefined;
1357
- explanation?: string | undefined;
1358
- scorerAISystemPrompt?: string | undefined;
1359
- scorerAISystemPromptId?: string | undefined;
1360
- scorerAIProvider?: string | undefined;
1361
- scorerAIModelSlug?: string | undefined;
1362
- scorerAIInputTokensUsed?: number | undefined;
1363
- scorerAIOutputTokensUsed?: number | undefined;
1364
- scorerAIInputCost?: string | undefined;
1365
- scorerAIOutputCost?: string | undefined;
1366
- }>;
1367
- };
1368
- }, {
1369
- readonly testCase: z__default.ZodObject<Omit<{
1370
- id: z__default.ZodString;
1371
- namespace: z__default.ZodString;
1372
- schemaVersion: z__default.ZodNumber;
1373
- kind: z__default.ZodString;
1374
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1375
- }, "kind" | "namespace" | "schemaVersion"> & {
1376
- question: z__default.ZodString;
1377
- goodAnswers: z__default.ZodArray<z__default.ZodString>;
1378
- badAnswers: z__default.ZodArray<z__default.ZodString>;
1379
- } & {
1380
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1381
- kind: z__default.ZodLiteral<"llm/qa.tc">;
1382
- schemaVersion: z__default.ZodLiteral<1>;
1383
- }, z__default.core.$strip> & {
1384
- new: (input: Omit<{
1385
- id: string;
1386
- question: string;
1387
- goodAnswers: string[];
1388
- badAnswers: string[];
1389
- namespace: "peerbench.ai";
1390
- kind: "llm/qa.tc";
1391
- schemaVersion: 1;
1392
- metadata?: Record<string, unknown> | undefined;
1393
- }, "kind" | "namespace" | "schemaVersion">) => {
1394
- id: string;
1395
- question: string;
1396
- goodAnswers: string[];
1397
- badAnswers: string[];
1398
- namespace: "peerbench.ai";
1399
- kind: "llm/qa.tc";
1400
- schemaVersion: 1;
1401
- metadata?: Record<string, unknown> | undefined;
1402
- };
1403
- newWithId(input: Omit<{
1404
- id: string;
1405
- question: string;
1406
- goodAnswers: string[];
1407
- badAnswers: string[];
1408
- namespace: "peerbench.ai";
1409
- kind: "llm/qa.tc";
1410
- schemaVersion: 1;
1411
- metadata?: Record<string, unknown> | undefined;
1412
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1413
- id: string;
1414
- question: string;
1415
- goodAnswers: string[];
1416
- badAnswers: string[];
1417
- namespace: "peerbench.ai";
1418
- kind: "llm/qa.tc";
1419
- schemaVersion: 1;
1420
- metadata?: Record<string, unknown> | undefined;
1421
- }>;
1422
- };
1423
- readonly response: z__default.ZodObject<Omit<{
1424
- id: z__default.ZodString;
1425
- namespace: z__default.ZodString;
1426
- schemaVersion: z__default.ZodNumber;
1427
- kind: z__default.ZodString;
1428
- startedAt: z__default.ZodNumber;
1429
- completedAt: z__default.ZodNumber;
1430
- testCaseId: z__default.ZodString;
1431
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1432
- }, "kind" | "namespace" | "schemaVersion"> & {
1433
- data: z__default.ZodString;
1434
- modelSlug: z__default.ZodString;
1435
- provider: z__default.ZodString;
1436
- systemPromptId: z__default.ZodOptional<z__default.ZodString>;
1437
- inputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1438
- outputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1439
- inputCost: z__default.ZodOptional<z__default.ZodString>;
1440
- outputCost: z__default.ZodOptional<z__default.ZodString>;
1441
- } & {
1442
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1443
- kind: z__default.ZodLiteral<"llm/qa.rs">;
1444
- schemaVersion: z__default.ZodLiteral<1>;
1445
- }, z__default.core.$strip> & {
1446
- new: (input: Omit<{
1447
- startedAt: number;
1448
- completedAt: number;
1449
- id: string;
1450
- testCaseId: string;
1451
- data: string;
1452
- modelSlug: string;
1453
- provider: string;
1454
- namespace: "peerbench.ai";
1455
- kind: "llm/qa.rs";
1456
- schemaVersion: 1;
1457
- metadata?: Record<string, unknown> | undefined;
1458
- systemPromptId?: string | undefined;
1459
- inputTokensUsed?: number | undefined;
1460
- outputTokensUsed?: number | undefined;
1461
- inputCost?: string | undefined;
1462
- outputCost?: string | undefined;
1463
- }, "kind" | "namespace" | "schemaVersion">) => {
1464
- startedAt: number;
1465
- completedAt: number;
1466
- id: string;
1467
- testCaseId: string;
1468
- data: string;
1469
- modelSlug: string;
1470
- provider: string;
1471
- namespace: "peerbench.ai";
1472
- kind: "llm/qa.rs";
1473
- schemaVersion: 1;
1474
- metadata?: Record<string, unknown> | undefined;
1475
- systemPromptId?: string | undefined;
1476
- inputTokensUsed?: number | undefined;
1477
- outputTokensUsed?: number | undefined;
1478
- inputCost?: string | undefined;
1479
- outputCost?: string | undefined;
1480
- };
1481
- newWithId(input: Omit<{
1482
- startedAt: number;
1483
- completedAt: number;
1484
- id: string;
1485
- testCaseId: string;
1486
- data: string;
1487
- modelSlug: string;
1488
- provider: string;
1489
- namespace: "peerbench.ai";
1490
- kind: "llm/qa.rs";
1491
- schemaVersion: 1;
1492
- metadata?: Record<string, unknown> | undefined;
1493
- systemPromptId?: string | undefined;
1494
- inputTokensUsed?: number | undefined;
1495
- outputTokensUsed?: number | undefined;
1496
- inputCost?: string | undefined;
1497
- outputCost?: string | undefined;
1498
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1499
- startedAt: number;
1500
- completedAt: number;
1501
- id: string;
1502
- testCaseId: string;
1503
- data: string;
1504
- modelSlug: string;
1505
- provider: string;
1506
- namespace: "peerbench.ai";
1507
- kind: "llm/qa.rs";
1508
- schemaVersion: 1;
1509
- metadata?: Record<string, unknown> | undefined;
1510
- systemPromptId?: string | undefined;
1511
- inputTokensUsed?: number | undefined;
1512
- outputTokensUsed?: number | undefined;
1513
- inputCost?: string | undefined;
1514
- outputCost?: string | undefined;
1515
- }>;
1516
- };
1517
- readonly score: z__default.ZodObject<Omit<{
1518
- id: z__default.ZodString;
1519
- namespace: z__default.ZodString;
1520
- kind: z__default.ZodString;
1521
- schemaVersion: z__default.ZodNumber;
1522
- value: z__default.ZodNumber;
1523
- responseId: z__default.ZodString;
1524
- explanation: z__default.ZodOptional<z__default.ZodString>;
1525
- metadata: z__default.ZodOptional<z__default.ZodRecord<z__default.ZodString, z__default.ZodUnknown>>;
1526
- scoringMethod: z__default.ZodEnum<{
1527
- readonly ai: "ai";
1528
- readonly human: "human";
1529
- readonly algo: "algo";
1530
- }>;
1531
- }, "kind" | "namespace" | "schemaVersion"> & {
1532
- scorerAISystemPrompt: z__default.ZodOptional<z__default.ZodString>;
1533
- scorerAISystemPromptId: z__default.ZodOptional<z__default.ZodString>;
1534
- scorerAIProvider: z__default.ZodOptional<z__default.ZodString>;
1535
- scorerAIModelSlug: z__default.ZodOptional<z__default.ZodString>;
1536
- scorerAIInputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1537
- scorerAIOutputTokensUsed: z__default.ZodOptional<z__default.ZodNumber>;
1538
- scorerAIInputCost: z__default.ZodOptional<z__default.ZodString>;
1539
- scorerAIOutputCost: z__default.ZodOptional<z__default.ZodString>;
1540
- } & {
1541
- namespace: z__default.ZodLiteral<"peerbench.ai">;
1542
- kind: z__default.ZodLiteral<"llm/qa.sc">;
1543
- schemaVersion: z__default.ZodLiteral<1>;
1544
- }, z__default.core.$strip> & {
1545
- new: (input: Omit<{
1546
- id: string;
1547
- value: number;
1548
- responseId: string;
1549
- scoringMethod: "ai" | "human" | "algo";
1550
- namespace: "peerbench.ai";
1551
- kind: "llm/qa.sc";
1552
- schemaVersion: 1;
1553
- metadata?: Record<string, unknown> | undefined;
1554
- explanation?: string | undefined;
1555
- scorerAISystemPrompt?: string | undefined;
1556
- scorerAISystemPromptId?: string | undefined;
1557
- scorerAIProvider?: string | undefined;
1558
- scorerAIModelSlug?: string | undefined;
1559
- scorerAIInputTokensUsed?: number | undefined;
1560
- scorerAIOutputTokensUsed?: number | undefined;
1561
- scorerAIInputCost?: string | undefined;
1562
- scorerAIOutputCost?: string | undefined;
1563
- }, "kind" | "namespace" | "schemaVersion">) => {
1564
- id: string;
1565
- value: number;
1566
- responseId: string;
1567
- scoringMethod: "ai" | "human" | "algo";
1568
- namespace: "peerbench.ai";
1569
- kind: "llm/qa.sc";
1570
- schemaVersion: 1;
1571
- metadata?: Record<string, unknown> | undefined;
1572
- explanation?: string | undefined;
1573
- scorerAISystemPrompt?: string | undefined;
1574
- scorerAISystemPromptId?: string | undefined;
1575
- scorerAIProvider?: string | undefined;
1576
- scorerAIModelSlug?: string | undefined;
1577
- scorerAIInputTokensUsed?: number | undefined;
1578
- scorerAIOutputTokensUsed?: number | undefined;
1579
- scorerAIInputCost?: string | undefined;
1580
- scorerAIOutputCost?: string | undefined;
1581
- };
1582
- newWithId(input: Omit<{
1583
- id: string;
1584
- value: number;
1585
- responseId: string;
1586
- scoringMethod: "ai" | "human" | "algo";
1587
- namespace: "peerbench.ai";
1588
- kind: "llm/qa.sc";
1589
- schemaVersion: 1;
1590
- metadata?: Record<string, unknown> | undefined;
1591
- explanation?: string | undefined;
1592
- scorerAISystemPrompt?: string | undefined;
1593
- scorerAISystemPromptId?: string | undefined;
1594
- scorerAIProvider?: string | undefined;
1595
- scorerAIModelSlug?: string | undefined;
1596
- scorerAIInputTokensUsed?: number | undefined;
1597
- scorerAIOutputTokensUsed?: number | undefined;
1598
- scorerAIInputCost?: string | undefined;
1599
- scorerAIOutputCost?: string | undefined;
1600
- }, "kind" | "id" | "namespace" | "schemaVersion">, generator: IdGenerator): Promise<{
1601
- id: string;
1602
- value: number;
1603
- responseId: string;
1604
- scoringMethod: "ai" | "human" | "algo";
1605
- namespace: "peerbench.ai";
1606
- kind: "llm/qa.sc";
1607
- schemaVersion: 1;
1608
- metadata?: Record<string, unknown> | undefined;
1609
- explanation?: string | undefined;
1610
- scorerAISystemPrompt?: string | undefined;
1611
- scorerAISystemPromptId?: string | undefined;
1612
- scorerAIProvider?: string | undefined;
1613
- scorerAIModelSlug?: string | undefined;
1614
- scorerAIInputTokensUsed?: number | undefined;
1615
- scorerAIOutputTokensUsed?: number | undefined;
1616
- scorerAIInputCost?: string | undefined;
1617
- scorerAIOutputCost?: string | undefined;
1618
- }>;
1619
- };
1620
- }];
1621
- providers: [typeof AbstractLLMProvider];
1622
- scorers: [typeof LLMAsAJudgeScorer, typeof MCQScorer];
1623
- parseRunConfig?: boolean;
1624
- defaults?: {
1625
- scorer?: MCQScorer | LLMAsAJudgeScorer | undefined;
1626
- responseIdGenerator?: IdGenerator;
1627
- scoreIdGenerator?: IdGenerator;
1628
- } | undefined;
1629
- };
1630
- };
1631
-
1632
- declare class PeerbenchJSONStorage extends JSONFileStorage<MCQTestCaseV1 | MCQResponseV1 | MCQScoreV1 | QATestCaseV1 | QAResponseV1 | QAScoreV1 | MultiTurnTestCaseV1 | MultiTurnResponseV1 | MultiTurnScoreV1> {
1633
- constructor(config: {
1634
- path: string;
1635
- chunkSize?: number;
1636
- });
1637
- }
1638
-
1639
- declare const index_MCQKind: typeof MCQKind;
1640
- declare const index_MCQResponseSchemaV1: typeof MCQResponseSchemaV1;
1641
- type index_MCQResponseV1 = MCQResponseV1;
1642
- declare const index_MCQScoreSchemaV1: typeof MCQScoreSchemaV1;
1643
- type index_MCQScoreV1 = MCQScoreV1;
1644
- declare const index_MCQTestCaseSchemaV1: typeof MCQTestCaseSchemaV1;
1645
- type index_MCQTestCaseV1 = MCQTestCaseV1;
1646
- declare const index_MultiTurnKind: typeof MultiTurnKind;
1647
- declare const index_MultiTurnResponseSchemaV1: typeof MultiTurnResponseSchemaV1;
1648
- type index_MultiTurnResponseV1 = MultiTurnResponseV1;
1649
- declare const index_MultiTurnScoreSchemaV1: typeof MultiTurnScoreSchemaV1;
1650
- type index_MultiTurnScoreV1 = MultiTurnScoreV1;
1651
- declare const index_MultiTurnTestCaseSchemaV1: typeof MultiTurnTestCaseSchemaV1;
1652
- type index_MultiTurnTestCaseV1 = MultiTurnTestCaseV1;
1653
- type index_PeerbenchJSONStorage = PeerbenchJSONStorage;
1654
- declare const index_PeerbenchJSONStorage: typeof PeerbenchJSONStorage;
1655
- declare const index_QAKind: typeof QAKind;
1656
- declare const index_QAResponseSchemaV1: typeof QAResponseSchemaV1;
1657
- type index_QAResponseV1 = QAResponseV1;
1658
- declare const index_QAScoreSchemaV1: typeof QAScoreSchemaV1;
1659
- type index_QAScoreV1 = QAScoreV1;
1660
- declare const index_QATestCaseSchemaV1: typeof QATestCaseSchemaV1;
1661
- type index_QATestCaseV1 = QATestCaseV1;
1662
- declare const index_peerbenchRunner: typeof peerbenchRunner;
1663
- declare namespace index {
1664
- export { index_MCQKind as MCQKind, index_MCQResponseSchemaV1 as MCQResponseSchemaV1, type index_MCQResponseV1 as MCQResponseV1, index_MCQScoreSchemaV1 as MCQScoreSchemaV1, type index_MCQScoreV1 as MCQScoreV1, index_MCQTestCaseSchemaV1 as MCQTestCaseSchemaV1, type index_MCQTestCaseV1 as MCQTestCaseV1, index_MultiTurnKind as MultiTurnKind, index_MultiTurnResponseSchemaV1 as MultiTurnResponseSchemaV1, type index_MultiTurnResponseV1 as MultiTurnResponseV1, index_MultiTurnScoreSchemaV1 as MultiTurnScoreSchemaV1, type index_MultiTurnScoreV1 as MultiTurnScoreV1, index_MultiTurnTestCaseSchemaV1 as MultiTurnTestCaseSchemaV1, type index_MultiTurnTestCaseV1 as MultiTurnTestCaseV1, index_PeerbenchJSONStorage as PeerbenchJSONStorage, index_QAKind as QAKind, index_QAResponseSchemaV1 as QAResponseSchemaV1, type index_QAResponseV1 as QAResponseV1, index_QAScoreSchemaV1 as QAScoreSchemaV1, type index_QAScoreV1 as QAScoreV1, index_QATestCaseSchemaV1 as QATestCaseSchemaV1, type index_QATestCaseV1 as QATestCaseV1, index_peerbenchRunner as peerbenchRunner };
1665
- }
1666
-
1667
- export { index as peerbench };
1
+ export * as peerbench from "./peerbench";