@wix/evalforge-types 0.91.0 → 0.93.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 +587 -449
- package/build/index.js.map +4 -4
- package/build/index.mjs +573 -448
- package/build/index.mjs.map +4 -4
- package/build/types/common/tool-names.d.ts +1 -1
- package/build/types/scenario/index.d.ts +2 -0
- package/build/types/scenario/site-setup.d.ts +132 -0
- package/build/types/scenario/test-scenario.d.ts +120 -0
- package/build/types/scenario/wix-origin-template-ids.d.ts +5 -0
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const AVAILABLE_TOOL_NAMES: readonly ["Bash", "Edit", "Glob", "Grep", "Read", "Skill", "Write"];
|
|
1
|
+
export declare const AVAILABLE_TOOL_NAMES: readonly ["Bash", "Edit", "Glob", "Grep", "Read", "Skill", "WebFetch", "Write"];
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* HTTP method for a SiteBootstrap step. Lowercase mirrors the discriminator-style
|
|
4
|
+
* enums elsewhere in the domain (`mode: 'none' | 'clone' | 'template'`); the
|
|
5
|
+
* proto layer holds the uppercase variants and the gRPC converter handles the case mapping.
|
|
6
|
+
*/
|
|
7
|
+
export declare const SiteBootstrapHttpMethodSchema: z.ZodEnum<{
|
|
8
|
+
get: "get";
|
|
9
|
+
post: "post";
|
|
10
|
+
put: "put";
|
|
11
|
+
patch: "patch";
|
|
12
|
+
delete: "delete";
|
|
13
|
+
}>;
|
|
14
|
+
export type SiteBootstrapHttpMethod = z.infer<typeof SiteBootstrapHttpMethodSchema>;
|
|
15
|
+
/**
|
|
16
|
+
* A single API call executed against a freshly-provisioned site as part of a
|
|
17
|
+
* scenario's pre-test setup ("DB seeding"). The site id is injected by the
|
|
18
|
+
* server as a header — the URL is taken verbatim, no templating.
|
|
19
|
+
*/
|
|
20
|
+
export declare const SiteBootstrapStepSchema: z.ZodObject<{
|
|
21
|
+
label: z.ZodOptional<z.ZodString>;
|
|
22
|
+
method: z.ZodEnum<{
|
|
23
|
+
get: "get";
|
|
24
|
+
post: "post";
|
|
25
|
+
put: "put";
|
|
26
|
+
patch: "patch";
|
|
27
|
+
delete: "delete";
|
|
28
|
+
}>;
|
|
29
|
+
url: z.ZodString;
|
|
30
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
31
|
+
}, z.core.$strip>;
|
|
32
|
+
export type SiteBootstrapStep = z.infer<typeof SiteBootstrapStepSchema>;
|
|
33
|
+
/**
|
|
34
|
+
* Ordered list of bootstrap steps applied after a site is provisioned. Empty
|
|
35
|
+
* `steps` ≡ no bootstrap. Reserved as a wrapper message so future bootstrap-
|
|
36
|
+
* level options (e.g., continueOnFailure) can be added without proto churn.
|
|
37
|
+
*/
|
|
38
|
+
export declare const SiteBootstrapSchema: z.ZodObject<{
|
|
39
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
40
|
+
label: z.ZodOptional<z.ZodString>;
|
|
41
|
+
method: z.ZodEnum<{
|
|
42
|
+
get: "get";
|
|
43
|
+
post: "post";
|
|
44
|
+
put: "put";
|
|
45
|
+
patch: "patch";
|
|
46
|
+
delete: "delete";
|
|
47
|
+
}>;
|
|
48
|
+
url: z.ZodString;
|
|
49
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
50
|
+
}, z.core.$strip>>>;
|
|
51
|
+
}, z.core.$strip>;
|
|
52
|
+
export type SiteBootstrap = z.infer<typeof SiteBootstrapSchema>;
|
|
53
|
+
/**
|
|
54
|
+
* Per-step result returned by the backend after running a SiteBootstrap.
|
|
55
|
+
*/
|
|
56
|
+
export declare const SiteBootstrapStepResultSchema: z.ZodObject<{
|
|
57
|
+
label: z.ZodOptional<z.ZodString>;
|
|
58
|
+
statusCode: z.ZodNumber;
|
|
59
|
+
ok: z.ZodBoolean;
|
|
60
|
+
error: z.ZodOptional<z.ZodString>;
|
|
61
|
+
}, z.core.$strip>;
|
|
62
|
+
export type SiteBootstrapStepResult = z.infer<typeof SiteBootstrapStepResultSchema>;
|
|
63
|
+
/**
|
|
64
|
+
* Outcome of a SiteBootstrap run. `steps` carries every step that executed,
|
|
65
|
+
* terminating at the first failure ("fail fast"). Absent on the response when
|
|
66
|
+
* no bootstrap was requested.
|
|
67
|
+
*/
|
|
68
|
+
export declare const SiteBootstrapResultSchema: z.ZodObject<{
|
|
69
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
70
|
+
label: z.ZodOptional<z.ZodString>;
|
|
71
|
+
statusCode: z.ZodNumber;
|
|
72
|
+
ok: z.ZodBoolean;
|
|
73
|
+
error: z.ZodOptional<z.ZodString>;
|
|
74
|
+
}, z.core.$strip>>;
|
|
75
|
+
}, z.core.$strip>;
|
|
76
|
+
export type SiteBootstrapResult = z.infer<typeof SiteBootstrapResultSchema>;
|
|
77
|
+
export declare const SiteSetupConfigSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
78
|
+
mode: z.ZodLiteral<"none">;
|
|
79
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
80
|
+
mode: z.ZodLiteral<"clone">;
|
|
81
|
+
sourceSiteId: z.ZodString;
|
|
82
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
83
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
84
|
+
label: z.ZodOptional<z.ZodString>;
|
|
85
|
+
method: z.ZodEnum<{
|
|
86
|
+
get: "get";
|
|
87
|
+
post: "post";
|
|
88
|
+
put: "put";
|
|
89
|
+
patch: "patch";
|
|
90
|
+
delete: "delete";
|
|
91
|
+
}>;
|
|
92
|
+
url: z.ZodString;
|
|
93
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
94
|
+
}, z.core.$strip>>>;
|
|
95
|
+
}, z.core.$strip>>;
|
|
96
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
97
|
+
mode: z.ZodLiteral<"template">;
|
|
98
|
+
templateId: z.ZodString;
|
|
99
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
100
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
101
|
+
label: z.ZodOptional<z.ZodString>;
|
|
102
|
+
method: z.ZodEnum<{
|
|
103
|
+
get: "get";
|
|
104
|
+
post: "post";
|
|
105
|
+
put: "put";
|
|
106
|
+
patch: "patch";
|
|
107
|
+
delete: "delete";
|
|
108
|
+
}>;
|
|
109
|
+
url: z.ZodString;
|
|
110
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
111
|
+
}, z.core.$strip>>>;
|
|
112
|
+
}, z.core.$strip>>;
|
|
113
|
+
}, z.core.$strip>], "mode">;
|
|
114
|
+
export type SiteSetupConfig = z.infer<typeof SiteSetupConfigSchema>;
|
|
115
|
+
/**
|
|
116
|
+
* Summary of a user's Wix site, returned by ListUserSites.
|
|
117
|
+
*/
|
|
118
|
+
export declare const WixSiteSummarySchema: z.ZodObject<{
|
|
119
|
+
id: z.ZodString;
|
|
120
|
+
displayName: z.ZodString;
|
|
121
|
+
url: z.ZodOptional<z.ZodString>;
|
|
122
|
+
}, z.core.$strip>;
|
|
123
|
+
export type WixSiteSummary = z.infer<typeof WixSiteSummarySchema>;
|
|
124
|
+
/**
|
|
125
|
+
* A Wix site provisioned for a single scenario run.
|
|
126
|
+
*/
|
|
127
|
+
export declare const ProvisionedSiteSchema: z.ZodObject<{
|
|
128
|
+
id: z.ZodString;
|
|
129
|
+
url: z.ZodOptional<z.ZodString>;
|
|
130
|
+
editorUrl: z.ZodOptional<z.ZodString>;
|
|
131
|
+
}, z.core.$strip>;
|
|
132
|
+
export type ProvisionedSite = z.infer<typeof ProvisionedSiteSchema>;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { type SiteSetupConfig } from './site-setup.js';
|
|
2
3
|
export declare const TriggerPromptImageSchema: z.ZodObject<{
|
|
3
4
|
base64: z.ZodString;
|
|
4
5
|
mediaType: z.ZodEnum<{
|
|
@@ -114,8 +115,53 @@ export declare const TestScenarioSchema: z.ZodObject<{
|
|
|
114
115
|
}>;
|
|
115
116
|
name: z.ZodString;
|
|
116
117
|
}, z.core.$strip>>>;
|
|
118
|
+
siteSetup: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
119
|
+
mode: z.ZodLiteral<"none">;
|
|
120
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
121
|
+
mode: z.ZodLiteral<"clone">;
|
|
122
|
+
sourceSiteId: z.ZodString;
|
|
123
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
124
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
125
|
+
label: z.ZodOptional<z.ZodString>;
|
|
126
|
+
method: z.ZodEnum<{
|
|
127
|
+
get: "get";
|
|
128
|
+
post: "post";
|
|
129
|
+
put: "put";
|
|
130
|
+
patch: "patch";
|
|
131
|
+
delete: "delete";
|
|
132
|
+
}>;
|
|
133
|
+
url: z.ZodString;
|
|
134
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
135
|
+
}, z.core.$strip>>>;
|
|
136
|
+
}, z.core.$strip>>;
|
|
137
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
138
|
+
mode: z.ZodLiteral<"template">;
|
|
139
|
+
templateId: z.ZodString;
|
|
140
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
141
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
142
|
+
label: z.ZodOptional<z.ZodString>;
|
|
143
|
+
method: z.ZodEnum<{
|
|
144
|
+
get: "get";
|
|
145
|
+
post: "post";
|
|
146
|
+
put: "put";
|
|
147
|
+
patch: "patch";
|
|
148
|
+
delete: "delete";
|
|
149
|
+
}>;
|
|
150
|
+
url: z.ZodString;
|
|
151
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
152
|
+
}, z.core.$strip>>>;
|
|
153
|
+
}, z.core.$strip>>;
|
|
154
|
+
}, z.core.$strip>], "mode">>;
|
|
117
155
|
}, z.core.$strip>;
|
|
118
156
|
export type TestScenario = z.infer<typeof TestScenarioSchema>;
|
|
157
|
+
/** Run-variable names that conflict with automatic site setup provisioning. */
|
|
158
|
+
export declare const SITE_SETUP_EXCLUSIVE_VARIABLES: readonly ["site-id"];
|
|
159
|
+
export declare function extractVariableNamesFromPrompt(prompt: string): string[];
|
|
160
|
+
export declare function promptUsesSiteSetupExclusiveVariables(prompt: string): boolean;
|
|
161
|
+
export declare function validateSiteSetupExclusivity(data: {
|
|
162
|
+
triggerPrompt?: string;
|
|
163
|
+
siteSetup?: SiteSetupConfig;
|
|
164
|
+
}, ctx: z.RefinementCtx): void;
|
|
119
165
|
export declare function validateBuildPassedParamsInAssertionLinks(links: {
|
|
120
166
|
assertionId: string;
|
|
121
167
|
params?: Record<string, unknown>;
|
|
@@ -206,6 +252,43 @@ export declare const CreateTestScenarioInputSchema: z.ZodObject<{
|
|
|
206
252
|
}>;
|
|
207
253
|
name: z.ZodString;
|
|
208
254
|
}, z.core.$strip>>>;
|
|
255
|
+
siteSetup: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
256
|
+
mode: z.ZodLiteral<"none">;
|
|
257
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
258
|
+
mode: z.ZodLiteral<"clone">;
|
|
259
|
+
sourceSiteId: z.ZodString;
|
|
260
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
261
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
262
|
+
label: z.ZodOptional<z.ZodString>;
|
|
263
|
+
method: z.ZodEnum<{
|
|
264
|
+
get: "get";
|
|
265
|
+
post: "post";
|
|
266
|
+
put: "put";
|
|
267
|
+
patch: "patch";
|
|
268
|
+
delete: "delete";
|
|
269
|
+
}>;
|
|
270
|
+
url: z.ZodString;
|
|
271
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
272
|
+
}, z.core.$strip>>>;
|
|
273
|
+
}, z.core.$strip>>;
|
|
274
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
275
|
+
mode: z.ZodLiteral<"template">;
|
|
276
|
+
templateId: z.ZodString;
|
|
277
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
278
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
279
|
+
label: z.ZodOptional<z.ZodString>;
|
|
280
|
+
method: z.ZodEnum<{
|
|
281
|
+
get: "get";
|
|
282
|
+
post: "post";
|
|
283
|
+
put: "put";
|
|
284
|
+
patch: "patch";
|
|
285
|
+
delete: "delete";
|
|
286
|
+
}>;
|
|
287
|
+
url: z.ZodString;
|
|
288
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
289
|
+
}, z.core.$strip>>>;
|
|
290
|
+
}, z.core.$strip>>;
|
|
291
|
+
}, z.core.$strip>], "mode">>;
|
|
209
292
|
}, z.core.$strip>;
|
|
210
293
|
export type CreateTestScenarioInput = z.infer<typeof CreateTestScenarioInputSchema>;
|
|
211
294
|
/**
|
|
@@ -294,5 +377,42 @@ export declare const UpdateTestScenarioInputSchema: z.ZodObject<{
|
|
|
294
377
|
}>;
|
|
295
378
|
name: z.ZodString;
|
|
296
379
|
}, z.core.$strip>>>>;
|
|
380
|
+
siteSetup: z.ZodOptional<z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
381
|
+
mode: z.ZodLiteral<"none">;
|
|
382
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
383
|
+
mode: z.ZodLiteral<"clone">;
|
|
384
|
+
sourceSiteId: z.ZodString;
|
|
385
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
386
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
387
|
+
label: z.ZodOptional<z.ZodString>;
|
|
388
|
+
method: z.ZodEnum<{
|
|
389
|
+
get: "get";
|
|
390
|
+
post: "post";
|
|
391
|
+
put: "put";
|
|
392
|
+
patch: "patch";
|
|
393
|
+
delete: "delete";
|
|
394
|
+
}>;
|
|
395
|
+
url: z.ZodString;
|
|
396
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
397
|
+
}, z.core.$strip>>>;
|
|
398
|
+
}, z.core.$strip>>;
|
|
399
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
400
|
+
mode: z.ZodLiteral<"template">;
|
|
401
|
+
templateId: z.ZodString;
|
|
402
|
+
bootstrap: z.ZodOptional<z.ZodObject<{
|
|
403
|
+
steps: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
404
|
+
label: z.ZodOptional<z.ZodString>;
|
|
405
|
+
method: z.ZodEnum<{
|
|
406
|
+
get: "get";
|
|
407
|
+
post: "post";
|
|
408
|
+
put: "put";
|
|
409
|
+
patch: "patch";
|
|
410
|
+
delete: "delete";
|
|
411
|
+
}>;
|
|
412
|
+
url: z.ZodString;
|
|
413
|
+
body: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
414
|
+
}, z.core.$strip>>>;
|
|
415
|
+
}, z.core.$strip>>;
|
|
416
|
+
}, z.core.$strip>], "mode">>>;
|
|
297
417
|
}, z.core.$strip>;
|
|
298
418
|
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.93.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": "a95e050dce3899b95706e4726fd799f7e0824fba3fe365fb16ab8cf7"
|
|
50
50
|
}
|