@wix/evalforge-types 0.71.0 → 0.72.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/index.js +14 -1
- package/build/index.js.map +2 -2
- package/build/index.mjs +13 -1
- package/build/index.mjs.map +2 -2
- package/build/types/agent/adapter.d.ts +3 -1
- package/build/types/scenario/test-scenario.d.ts +42 -0
- package/package.json +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { SkillWithLatestVersion } from '../target/skill.js';
|
|
2
|
-
import type { TestScenario } from '../scenario/test-scenario.js';
|
|
2
|
+
import type { TestScenario, TriggerPromptImage } from '../scenario/test-scenario.js';
|
|
3
3
|
import type { ModelConfig } from '../common/models.js';
|
|
4
4
|
import type { LLMTrace } from '../evaluation/metrics.js';
|
|
5
5
|
import type { ConversationMessage } from '../evaluation/conversation.js';
|
|
@@ -68,6 +68,8 @@ export interface AgentExecutionContext {
|
|
|
68
68
|
* - string: custom system prompt text
|
|
69
69
|
*/
|
|
70
70
|
systemPrompt?: string | null;
|
|
71
|
+
/** Base64-encoded images attached to the trigger prompt (from scenario.triggerPromptImages) */
|
|
72
|
+
triggerPromptImages?: TriggerPromptImage[];
|
|
71
73
|
}
|
|
72
74
|
/**
|
|
73
75
|
* Token usage statistics from agent execution.
|
|
@@ -1,4 +1,15 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
export declare const TriggerPromptImageSchema: z.ZodObject<{
|
|
3
|
+
base64: z.ZodString;
|
|
4
|
+
mediaType: z.ZodEnum<{
|
|
5
|
+
"image/jpeg": "image/jpeg";
|
|
6
|
+
"image/png": "image/png";
|
|
7
|
+
"image/gif": "image/gif";
|
|
8
|
+
"image/webp": "image/webp";
|
|
9
|
+
}>;
|
|
10
|
+
name: z.ZodString;
|
|
11
|
+
}, z.core.$strip>;
|
|
12
|
+
export type TriggerPromptImage = z.infer<typeof TriggerPromptImageSchema>;
|
|
2
13
|
/**
|
|
3
14
|
* Expected file schema - a file the agent is expected to create or modify.
|
|
4
15
|
* Used by eval results; not persisted on test_scenarios table.
|
|
@@ -14,6 +25,7 @@ export type ExpectedFile = z.infer<typeof ExpectedFileSchema>;
|
|
|
14
25
|
* Persisted shape matches test_scenarios table:
|
|
15
26
|
* id, project_id, name, description, trigger_prompt, template_id, created_at, updated_at, deleted.
|
|
16
27
|
* Linked assertions stored in scenario_assertions junction table.
|
|
28
|
+
* Trigger prompt images stored as JSON in trigger_prompt_images column.
|
|
17
29
|
*/
|
|
18
30
|
export declare const TestScenarioSchema: z.ZodObject<{
|
|
19
31
|
id: z.ZodString;
|
|
@@ -87,6 +99,16 @@ export declare const TestScenarioSchema: z.ZodObject<{
|
|
|
87
99
|
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>;
|
|
88
100
|
}, z.core.$strip>>>;
|
|
89
101
|
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
102
|
+
triggerPromptImages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
103
|
+
base64: z.ZodString;
|
|
104
|
+
mediaType: z.ZodEnum<{
|
|
105
|
+
"image/jpeg": "image/jpeg";
|
|
106
|
+
"image/png": "image/png";
|
|
107
|
+
"image/gif": "image/gif";
|
|
108
|
+
"image/webp": "image/webp";
|
|
109
|
+
}>;
|
|
110
|
+
name: z.ZodString;
|
|
111
|
+
}, z.core.$strip>>>;
|
|
90
112
|
}, z.core.$strip>;
|
|
91
113
|
export type TestScenario = z.infer<typeof TestScenarioSchema>;
|
|
92
114
|
/**
|
|
@@ -160,6 +182,16 @@ export declare const CreateTestScenarioInputSchema: z.ZodObject<{
|
|
|
160
182
|
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>;
|
|
161
183
|
}, z.core.$strip>>>;
|
|
162
184
|
tags: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
185
|
+
triggerPromptImages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
186
|
+
base64: z.ZodString;
|
|
187
|
+
mediaType: z.ZodEnum<{
|
|
188
|
+
"image/jpeg": "image/jpeg";
|
|
189
|
+
"image/png": "image/png";
|
|
190
|
+
"image/gif": "image/gif";
|
|
191
|
+
"image/webp": "image/webp";
|
|
192
|
+
}>;
|
|
193
|
+
name: z.ZodString;
|
|
194
|
+
}, z.core.$strip>>>;
|
|
163
195
|
}, z.core.$strip>;
|
|
164
196
|
export type CreateTestScenarioInput = z.infer<typeof CreateTestScenarioInputSchema>;
|
|
165
197
|
/**
|
|
@@ -233,5 +265,15 @@ export declare const UpdateTestScenarioInputSchema: z.ZodObject<{
|
|
|
233
265
|
params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodNull]>>>;
|
|
234
266
|
}, z.core.$strip>>>>;
|
|
235
267
|
tags: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodString>>>;
|
|
268
|
+
triggerPromptImages: z.ZodOptional<z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
269
|
+
base64: z.ZodString;
|
|
270
|
+
mediaType: z.ZodEnum<{
|
|
271
|
+
"image/jpeg": "image/jpeg";
|
|
272
|
+
"image/png": "image/png";
|
|
273
|
+
"image/gif": "image/gif";
|
|
274
|
+
"image/webp": "image/webp";
|
|
275
|
+
}>;
|
|
276
|
+
name: z.ZodString;
|
|
277
|
+
}, z.core.$strip>>>>;
|
|
236
278
|
}, z.core.$strip>;
|
|
237
279
|
export type UpdateTestScenarioInput = z.infer<typeof UpdateTestScenarioInputSchema>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/evalforge-types",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.72.0",
|
|
4
4
|
"description": "Unified types for EvalForge agent evaluation system",
|
|
5
5
|
"files": [
|
|
6
6
|
"build"
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"artifactId": "evalforge-types"
|
|
47
47
|
}
|
|
48
48
|
},
|
|
49
|
-
"falconPackageHash": "
|
|
49
|
+
"falconPackageHash": "b6e85b3584dc3e5bb7ba967eb144e0054537240f1b95a0a468f3e662"
|
|
50
50
|
}
|