Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

types.ts 18 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
  1. import type logger from './logger';
  2. import type { fetchWithCache, getCache } from './cache';
  3. export type FilePath = string;
  4. export interface CommandLineOptions {
  5. // Shared with TestSuite
  6. prompts?: FilePath[];
  7. providers: FilePath[];
  8. output: FilePath[];
  9. // Shared with EvaluateOptions
  10. maxConcurrency: string;
  11. repeat: string;
  12. delay: string;
  13. // Command line only
  14. vars?: FilePath;
  15. tests?: FilePath;
  16. config?: FilePath[];
  17. assertions?: FilePath;
  18. modelOutputs?: FilePath;
  19. verbose?: boolean;
  20. grader?: string;
  21. tableCellMaxLength?: string;
  22. write?: boolean;
  23. cache?: boolean;
  24. table?: boolean;
  25. share?: boolean;
  26. progressBar?: boolean;
  27. watch?: boolean;
  28. interactiveProviders?: boolean;
  29. filterFailing?: string;
  30. filterFirstN?: string;
  31. filterPattern?: string;
  32. var?: Record<string, string>;
  33. generateSuggestions?: boolean;
  34. promptPrefix?: string;
  35. promptSuffix?: string;
  36. envFile?: FilePath;
  37. }
  38. export interface EnvOverrides {
  39. ANTHROPIC_API_KEY?: string;
  40. BAM_API_KEY?: string;
  41. BAM_API_HOST?: string;
  42. AZURE_OPENAI_API_HOST?: string;
  43. AZURE_OPENAI_API_KEY?: string;
  44. AZURE_OPENAI_API_BASE_URL?: string;
  45. AZURE_OPENAI_BASE_URL?: string;
  46. AWS_BEDROCK_REGION?: string;
  47. COHERE_API_KEY?: string;
  48. OPENAI_API_KEY?: string;
  49. OPENAI_API_HOST?: string;
  50. OPENAI_API_BASE_URL?: string;
  51. OPENAI_BASE_URL?: string;
  52. OPENAI_ORGANIZATION?: string;
  53. REPLICATE_API_KEY?: string;
  54. REPLICATE_API_TOKEN?: string;
  55. LOCALAI_BASE_URL?: string;
  56. MISTRAL_API_HOST?: string;
  57. MISTRAL_API_BASE_URL?: string;
  58. PALM_API_KEY?: string;
  59. PALM_API_HOST?: string;
  60. GOOGLE_API_KEY?: string;
  61. GOOGLE_API_HOST?: string;
  62. VERTEX_API_KEY?: string;
  63. VERTEX_API_HOST?: string;
  64. VERTEX_PROJECT_ID?: string;
  65. VERTEX_REGION?: string;
  66. VERTEX_PUBLISHER?: string;
  67. MISTRAL_API_KEY?: string;
  68. }
  69. export interface ProviderOptions {
  70. id?: ProviderId;
  71. label?: ProviderLabel;
  72. config?: any;
  73. prompts?: string[]; // List of prompt display strings
  74. transform?: string;
  75. delay?: number;
  76. env?: EnvOverrides;
  77. }
  78. export function isProviderOptions(provider: any): provider is ProviderOptions {
  79. return !isApiProvider(provider) && typeof provider === 'object';
  80. }
  81. export interface CallApiContextParams {
  82. vars: Record<string, string | object>;
  83. logger?: typeof logger;
  84. fetchWithCache?: typeof fetchWithCache;
  85. getCache?: typeof getCache;
  86. }
  87. export interface CallApiOptionsParams {
  88. includeLogProbs?: boolean;
  89. originalProvider?: ApiProvider;
  90. }
  91. export interface ApiProvider {
  92. // Unique identifier for the provider
  93. id: () => string;
  94. // Text generation function
  95. callApi: (
  96. prompt: string,
  97. context?: CallApiContextParams,
  98. options?: CallApiOptionsParams,
  99. ) => Promise<ProviderResponse>;
  100. // Embedding function
  101. callEmbeddingApi?: (prompt: string) => Promise<ProviderEmbeddingResponse>;
  102. // Classification function
  103. callClassificationApi?: (prompt: string) => Promise<ProviderClassificationResponse>;
  104. // Shown on output
  105. label?: ProviderLabel;
  106. // Applied by the evaluator on provider response
  107. transform?: string;
  108. // Custom delay for the provider.
  109. delay?: number;
  110. }
  111. export function isApiProvider(provider: any): provider is ApiProvider {
  112. return typeof provider === 'object' && 'id' in provider && typeof provider.id === 'function';
  113. }
  114. export interface ApiEmbeddingProvider extends ApiProvider {
  115. callEmbeddingApi: (input: string) => Promise<ProviderEmbeddingResponse>;
  116. }
  117. export interface ApiSimilarityProvider extends ApiProvider {
  118. callSimilarityApi: (reference: string, input: string) => Promise<ProviderSimilarityResponse>;
  119. }
  120. export interface ApiClassificationProvider extends ApiProvider {
  121. callClassificationApi: (prompt: string) => Promise<ProviderClassificationResponse>;
  122. }
  123. export interface ApiModerationProvider extends ApiProvider {
  124. callModerationApi: (prompt: string, response: string) => Promise<ProviderModerationResponse>;
  125. }
  126. export interface TokenUsage {
  127. total: number;
  128. prompt: number;
  129. completion: number;
  130. cached?: number;
  131. }
  132. export interface ProviderResponse {
  133. error?: string;
  134. output?: string | object;
  135. tokenUsage?: Partial<TokenUsage>;
  136. cost?: number;
  137. cached?: boolean;
  138. logProbs?: number[];
  139. }
  140. export interface ProviderEmbeddingResponse {
  141. error?: string;
  142. embedding?: number[];
  143. tokenUsage?: Partial<TokenUsage>;
  144. }
  145. export interface ProviderSimilarityResponse {
  146. error?: string;
  147. similarity?: number;
  148. tokenUsage?: Partial<TokenUsage>;
  149. }
  150. export interface ProviderClassificationResponse {
  151. error?: string;
  152. classification?: Record<string, number>;
  153. }
  154. export interface ModerationFlag {
  155. code: string;
  156. description: string;
  157. confidence: number;
  158. }
  159. export interface ProviderModerationResponse {
  160. error?: string;
  161. flags?: ModerationFlag[];
  162. }
  163. export interface CsvRow {
  164. [key: string]: string;
  165. }
  166. export type VarMapping = Record<string, string>;
  167. export type ProviderType = 'embedding' | 'classification' | 'text' | 'moderation';
  168. export type ProviderTypeMap = Partial<Record<ProviderType, string | ProviderOptions | ApiProvider>>;
  169. export interface GradingConfig {
  170. rubricPrompt?: string | string[];
  171. provider?: string | ProviderOptions | ApiProvider | ProviderTypeMap;
  172. factuality?: {
  173. subset?: number;
  174. superset?: number;
  175. agree?: number;
  176. disagree?: number;
  177. differButFactual?: number;
  178. };
  179. }
  180. export interface PromptConfig {
  181. prefix?: string;
  182. suffix?: string;
  183. }
  184. export interface OutputConfig {
  185. /**
  186. * @deprecated in > 0.38.0. Use `transform` instead.
  187. */
  188. postprocess?: string;
  189. transform?: string;
  190. // The name of the variable to store the output of this test case
  191. storeOutputAs?: string;
  192. }
  193. export interface RunEvalOptions {
  194. provider: ApiProvider;
  195. prompt: Prompt;
  196. delay: number;
  197. test: AtomicTestCase;
  198. nunjucksFilters?: NunjucksFilterMap;
  199. evaluateOptions: EvaluateOptions;
  200. rowIndex: number;
  201. colIndex: number;
  202. repeatIndex: number;
  203. }
  204. export interface EvaluateOptions {
  205. maxConcurrency?: number;
  206. showProgressBar?: boolean;
  207. progressCallback?: (
  208. progress: number,
  209. total: number,
  210. index: number,
  211. evalStep: RunEvalOptions,
  212. ) => void;
  213. generateSuggestions?: boolean;
  214. repeat?: number;
  215. delay?: number;
  216. cache?: boolean;
  217. eventSource?: string;
  218. interactiveProviders?: boolean;
  219. }
  220. export interface Prompt {
  221. id?: string;
  222. raw: string;
  223. /**
  224. * @deprecated in > 0.59.0. Use `label` instead.
  225. */
  226. display?: string;
  227. label: string;
  228. function?: (context: {
  229. vars: Record<string, string | object>;
  230. provider?: ApiProvider;
  231. }) => Promise<string | object>;
  232. }
  233. // Used for final prompt display
  234. export type CompletedPrompt = Prompt & {
  235. provider: string;
  236. metrics?: {
  237. score: number;
  238. testPassCount: number;
  239. testFailCount: number;
  240. assertPassCount: number;
  241. assertFailCount: number;
  242. totalLatencyMs: number;
  243. tokenUsage: TokenUsage;
  244. namedScores: Record<string, number>;
  245. cost: number;
  246. };
  247. };
  248. // Used when building prompts index from files.
  249. export interface PromptWithMetadata {
  250. id: string;
  251. prompt: Prompt;
  252. recentEvalDate: Date;
  253. recentEvalId: string;
  254. evals: {
  255. id: string;
  256. datasetId: string;
  257. metrics: CompletedPrompt['metrics'];
  258. }[];
  259. count: number;
  260. }
  261. export interface EvaluateResult {
  262. provider: Pick<ProviderOptions, 'id' | 'label'>;
  263. prompt: Prompt;
  264. vars: Record<string, string | object>;
  265. response?: ProviderResponse;
  266. error?: string;
  267. success: boolean;
  268. score: number;
  269. latencyMs: number;
  270. gradingResult?: GradingResult;
  271. namedScores: Record<string, number>;
  272. cost?: number;
  273. }
  274. export interface EvaluateTableOutput {
  275. pass: boolean;
  276. score: number;
  277. namedScores: Record<string, number>;
  278. text: string;
  279. prompt: string;
  280. latencyMs: number;
  281. provider?: string;
  282. tokenUsage?: Partial<TokenUsage>;
  283. gradingResult?: GradingResult;
  284. cost: number;
  285. }
  286. export interface EvaluateTableRow {
  287. description?: string;
  288. outputs: EvaluateTableOutput[];
  289. vars: string[];
  290. test: AtomicTestCase;
  291. }
  292. export interface EvaluateTable {
  293. head: {
  294. prompts: CompletedPrompt[];
  295. vars: string[];
  296. };
  297. body: EvaluateTableRow[];
  298. }
  299. export interface EvaluateStats {
  300. successes: number;
  301. failures: number;
  302. tokenUsage: Required<TokenUsage>;
  303. }
  304. export interface EvaluateSummary {
  305. version: number;
  306. timestamp: string;
  307. results: EvaluateResult[];
  308. table: EvaluateTable;
  309. stats: EvaluateStats;
  310. }
  311. export interface GradingResult {
  312. // Whether the test passed or failed
  313. pass: boolean;
  314. // Test score, typically between 0 and 1
  315. score: number;
  316. // Plain text reason for the result
  317. reason: string;
  318. // Map of labeled metrics to values
  319. namedScores?: Record<string, number>;
  320. // Record of tokens usage for this assertion
  321. tokensUsed?: TokenUsage;
  322. // List of results for each component of the assertion
  323. componentResults?: GradingResult[];
  324. // The assertion that was evaluated
  325. assertion?: Assertion | null;
  326. // User comment
  327. comment?: string;
  328. }
  329. export function isGradingResult(result: any): result is GradingResult {
  330. return (
  331. typeof result === 'object' &&
  332. result !== null &&
  333. typeof result.pass === 'boolean' &&
  334. typeof result.score === 'number' &&
  335. typeof result.reason === 'string' &&
  336. (typeof result.namedScores === 'undefined' || typeof result.namedScores === 'object') &&
  337. (typeof result.tokensUsed === 'undefined' || typeof result.tokensUsed === 'object') &&
  338. (typeof result.componentResults === 'undefined' || Array.isArray(result.componentResults)) &&
  339. (typeof result.assertion === 'undefined' ||
  340. result.assertion === null ||
  341. typeof result.assertion === 'object') &&
  342. (typeof result.comment === 'undefined' || typeof result.comment === 'string')
  343. );
  344. }
  345. type BaseAssertionTypes =
  346. | 'equals'
  347. | 'contains'
  348. | 'icontains'
  349. | 'contains-all'
  350. | 'contains-any'
  351. | 'icontains-all'
  352. | 'icontains-any'
  353. | 'starts-with'
  354. | 'regex'
  355. | 'is-json'
  356. | 'contains-json'
  357. | 'javascript'
  358. | 'python'
  359. | 'similar'
  360. | 'answer-relevance'
  361. | 'context-faithfulness'
  362. | 'context-recall'
  363. | 'context-relevance'
  364. | 'llm-rubric'
  365. | 'model-graded-closedqa'
  366. | 'factuality'
  367. | 'model-graded-factuality'
  368. | 'webhook'
  369. | 'rouge-n'
  370. | 'rouge-s'
  371. | 'rouge-l'
  372. | 'levenshtein'
  373. | 'is-valid-openai-function-call'
  374. | 'is-valid-openai-tools-call'
  375. | 'latency'
  376. | 'perplexity'
  377. | 'perplexity-score'
  378. | 'cost'
  379. | 'select-best'
  380. | 'moderation';
  381. type NotPrefixed<T extends string> = `not-${T}`;
  382. export type AssertionType = BaseAssertionTypes | NotPrefixed<BaseAssertionTypes>;
  383. export interface AssertionSet {
  384. type: 'assert-set';
  385. // Sub assertions to be run for this assertion set
  386. assert: Assertion[];
  387. // The weight of this assertion compared to other assertions in the test case. Defaults to 1.
  388. weight?: number;
  389. // Tag this assertion result as a named metric
  390. metric?: string;
  391. // The required score for this assert set. If not provided, the test case is graded pass/fail.
  392. threshold?: number;
  393. }
  394. // TODO(ian): maybe Assertion should support {type: config} to make the yaml cleaner
  395. export interface Assertion {
  396. // Type of assertion
  397. type: AssertionType;
  398. // The expected value, if applicable
  399. value?: AssertionValue;
  400. // The threshold value, only applicable for similarity (cosine distance)
  401. threshold?: number;
  402. // The weight of this assertion compared to other assertions in the test case. Defaults to 1.
  403. weight?: number;
  404. // Some assertions (similarity, llm-rubric) require an LLM provider
  405. provider?: GradingConfig['provider'];
  406. // Override the grading rubric
  407. rubricPrompt?: GradingConfig['rubricPrompt'];
  408. // Tag this assertion result as a named metric
  409. metric?: string;
  410. // Process the output before running the assertion
  411. transform?: string;
  412. }
  413. export type AssertionValue = string | string[] | object | AssertionValueFunction;
  414. export type AssertionValueFunction = (
  415. output: string,
  416. context: AssertionValueFunctionContext,
  417. ) => AssertionValueFunctionResult | Promise<AssertionValueFunctionResult>;
  418. export interface AssertionValueFunctionContext {
  419. prompt: string | undefined;
  420. vars: Record<string, string | object>;
  421. test: AtomicTestCase<Record<string, string | object>>;
  422. }
  423. export type AssertionValueFunctionResult = boolean | number | GradingResult;
  424. // Used when building prompts index from files.
  425. export interface TestCasesWithMetadataPrompt {
  426. prompt: CompletedPrompt;
  427. id: string;
  428. evalId: string;
  429. }
  430. export interface TestCasesWithMetadata {
  431. id: string;
  432. testCases: FilePath | (FilePath | TestCase)[];
  433. recentEvalDate: Date;
  434. recentEvalId: string;
  435. count: number;
  436. prompts: TestCasesWithMetadataPrompt[];
  437. }
  438. // Each test case is graded pass/fail with a score. A test case represents a unique input to the LLM after substituting `vars` in the prompt.
  439. export interface TestCase<Vars = Record<string, string | string[] | object>> {
  440. // Optional description of what you're testing
  441. description?: string;
  442. // Key-value pairs to substitute in the prompt
  443. vars?: Vars;
  444. // Override the provider.
  445. provider?: string | ProviderOptions | ApiProvider;
  446. // Output related from running values in Vars with provider. Having this value would skip running the prompt through the provider, and go straight to the assertions
  447. providerOutput?: string | object;
  448. // Optional list of automatic checks to run on the LLM output
  449. assert?: (AssertionSet | Assertion)[];
  450. // Additional configuration settings for the prompt
  451. options?: PromptConfig &
  452. OutputConfig &
  453. GradingConfig & {
  454. // If true, do not expand arrays of variables into multiple eval cases.
  455. disableVarExpansion?: boolean;
  456. // If true, do not include an implicit `_conversation` variable in the prompt.
  457. disableConversationVar?: boolean;
  458. };
  459. // The required score for this test case. If not provided, the test case is graded pass/fail.
  460. threshold?: number;
  461. }
  462. export interface Scenario {
  463. // Optional description of what you're testing
  464. description?: string;
  465. // Default test case config
  466. config: Partial<TestCase>[];
  467. // Optional list of automatic checks to run on the LLM output
  468. tests: TestCase[];
  469. }
  470. // Same as a TestCase, except the `vars` object has been flattened into its final form.
  471. export interface AtomicTestCase<Vars = Record<string, string | object>> extends TestCase {
  472. vars?: Record<string, string | object>;
  473. }
  474. export type NunjucksFilterMap = Record<string, (...args: any[]) => string>;
  475. export type DerivedMetric = {
  476. // The name of this metric
  477. name: string;
  478. // The function to calculate the metric - either a mathematical expression or a function that takes the results and returns a number
  479. value: string | ((scores: Record<string, number>, context: RunEvalOptions) => number);
  480. };
  481. // The test suite defines the "knobs" that we are tuning in prompt engineering: providers and prompts
  482. export interface TestSuite {
  483. // Optional description of what your LLM is trying to do
  484. description?: string;
  485. // One or more LLM APIs to use
  486. providers: ApiProvider[];
  487. // One or more prompt strings
  488. prompts: Prompt[];
  489. // Optional mapping of provider to prompt display strings. If not provided,
  490. // all prompts are used for all providers.
  491. providerPromptMap?: Record<string, string[]>;
  492. // Test cases
  493. tests?: TestCase[];
  494. // scenarios
  495. scenarios?: Scenario[];
  496. // Default test case config
  497. defaultTest?: Partial<TestCase>;
  498. // Nunjucks filters
  499. nunjucksFilters?: NunjucksFilterMap;
  500. // Envar overrides
  501. env?: EnvOverrides;
  502. // Metrics to calculate after the eval has been completed
  503. derivedMetrics?: DerivedMetric[];
  504. }
  505. export type ProviderId = string;
  506. export type ProviderLabel = string;
  507. export type ProviderFunction = ApiProvider['callApi'];
  508. export type ProviderOptionsMap = Record<ProviderId, ProviderOptions>;
  509. // TestSuiteConfig = Test Suite, but before everything is parsed and resolved. Providers are just strings, prompts are filepaths, tests can be filepath or inline.
  510. export interface TestSuiteConfig {
  511. // Optional description of what you're trying to test
  512. description?: string;
  513. // One or more LLM APIs to use, for example: openai:gpt-3.5-turbo, openai:gpt-4, localai:chat:vicuna
  514. providers: ProviderId | ProviderFunction | (ProviderId | ProviderOptionsMap | ProviderOptions)[];
  515. // One or more prompt files to load
  516. prompts: FilePath | (FilePath | Prompt)[] | Record<FilePath, string>;
  517. // Path to a test file, OR list of LLM prompt variations (aka "test case")
  518. tests: FilePath | (FilePath | TestCase)[];
  519. // Scenarios, groupings of data and tests to be evaluated
  520. scenarios?: Scenario[];
  521. // Sets the default properties for each test case. Useful for setting an assertion, on all test cases, for example.
  522. defaultTest?: Omit<TestCase, 'description'>;
  523. // Path to write output. Writes to console/web viewer if not set.
  524. outputPath?: FilePath | FilePath[];
  525. // Determines whether or not sharing is enabled.
  526. sharing?:
  527. | boolean
  528. | {
  529. apiBaseUrl?: string;
  530. appBaseUrl?: string;
  531. };
  532. // Nunjucks filters
  533. nunjucksFilters?: Record<string, FilePath>;
  534. // Envar overrides
  535. env?: EnvOverrides;
  536. }
  537. export type UnifiedConfig = TestSuiteConfig & {
  538. evaluateOptions: EvaluateOptions;
  539. commandLineOptions: Partial<CommandLineOptions>;
  540. };
  541. export interface EvalWithMetadata {
  542. id: string;
  543. date: Date;
  544. config: Partial<UnifiedConfig>;
  545. results: EvaluateSummary;
  546. description?: string;
  547. }
  548. export type PromptFunction = (context: {
  549. vars: Record<string, string | object>;
  550. }) => Promise<string | object>;
  551. // node.js package interface
  552. export type EvaluateTestSuite = {
  553. prompts: (string | object | PromptFunction)[];
  554. writeLatestResults?: boolean;
  555. } & TestSuiteConfig;
  556. export interface SharedResults {
  557. data: ResultsFile;
  558. }
  559. // promptfoo's internal results format
  560. export interface ResultsFile {
  561. version: number;
  562. createdAt: string;
  563. results: EvaluateSummary;
  564. config: Partial<UnifiedConfig>;
  565. }
  566. // File exported as --output option
  567. export interface OutputFile {
  568. results: EvaluateSummary;
  569. config: Partial<UnifiedConfig>;
  570. shareableUrl: string | null;
  571. }
  572. // Live eval job state
  573. export interface Job {
  574. status: 'in-progress' | 'complete';
  575. progress: number;
  576. total: number;
  577. result: EvaluateSummary | null;
  578. }
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...