@wix/evalforge-types 0.48.0 → 0.49.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/README.md +1 -1
- package/build/index.js +42 -23
- package/build/index.js.map +3 -3
- package/build/index.mjs +39 -20
- package/build/index.mjs.map +3 -3
- package/build/types/evaluation/eval-run.d.ts +8 -6
- package/build/types/target/index.d.ts +1 -1
- package/build/types/target/preset.d.ts +54 -0
- package/package.json +2 -2
- package/build/types/target/skills-group.d.ts +0 -37
package/build/index.mjs
CHANGED
|
@@ -1136,34 +1136,51 @@ var SkillWithLatestVersionSchema = SkillSchema.extend({
|
|
|
1136
1136
|
latestVersion: SkillVersionSchema.optional()
|
|
1137
1137
|
});
|
|
1138
1138
|
|
|
1139
|
-
// src/target/
|
|
1139
|
+
// src/target/sub-agent.ts
|
|
1140
1140
|
import { z as z8 } from "zod";
|
|
1141
|
-
var
|
|
1142
|
-
/**
|
|
1143
|
-
|
|
1141
|
+
var SubAgentSchema = TargetSchema.extend({
|
|
1142
|
+
/** The full sub-agent markdown content (YAML frontmatter + body) */
|
|
1143
|
+
subAgentMd: z8.string()
|
|
1144
1144
|
});
|
|
1145
|
-
var
|
|
1145
|
+
var SubAgentInputBaseSchema = SubAgentSchema.omit({
|
|
1146
1146
|
id: true,
|
|
1147
1147
|
createdAt: true,
|
|
1148
1148
|
updatedAt: true,
|
|
1149
1149
|
deleted: true
|
|
1150
1150
|
});
|
|
1151
|
-
var
|
|
1151
|
+
var CreateSubAgentInputSchema = SubAgentInputBaseSchema;
|
|
1152
|
+
var UpdateSubAgentInputSchema = SubAgentInputBaseSchema.partial();
|
|
1152
1153
|
|
|
1153
|
-
// src/target/
|
|
1154
|
+
// src/target/preset.ts
|
|
1154
1155
|
import { z as z9 } from "zod";
|
|
1155
|
-
var
|
|
1156
|
-
/**
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1156
|
+
var PresetSchema = TenantEntitySchema.extend({
|
|
1157
|
+
/** Agent ID for this preset */
|
|
1158
|
+
agentId: z9.string(),
|
|
1159
|
+
/** Skill IDs included in this preset */
|
|
1160
|
+
skillIds: z9.array(z9.string()).default([]),
|
|
1161
|
+
/** Optional map of skillId → skillVersionId for version pinning */
|
|
1162
|
+
skillVersions: z9.record(z9.string(), z9.string()).optional(),
|
|
1163
|
+
/** MCP server IDs included in this preset */
|
|
1164
|
+
mcpIds: z9.array(z9.string()).default([]),
|
|
1165
|
+
/** Sub-agent IDs included in this preset */
|
|
1166
|
+
subAgentIds: z9.array(z9.string()).default([]),
|
|
1167
|
+
/** Rule IDs included in this preset */
|
|
1168
|
+
ruleIds: z9.array(z9.string()).default([])
|
|
1169
|
+
});
|
|
1170
|
+
var atLeastOneEntity = (data) => (data.skillIds?.length ?? 0) > 0 || (data.mcpIds?.length ?? 0) > 0 || (data.subAgentIds?.length ?? 0) > 0 || (data.ruleIds?.length ?? 0) > 0;
|
|
1171
|
+
var AT_LEAST_ONE_ENTITY_MESSAGE = "At least one of skillIds, mcpIds, subAgentIds, or ruleIds must be non-empty";
|
|
1172
|
+
var CreatePresetInputSchema = PresetSchema.omit({
|
|
1160
1173
|
id: true,
|
|
1161
1174
|
createdAt: true,
|
|
1162
1175
|
updatedAt: true,
|
|
1163
1176
|
deleted: true
|
|
1164
|
-
});
|
|
1165
|
-
var
|
|
1166
|
-
|
|
1177
|
+
}).refine(atLeastOneEntity, { message: AT_LEAST_ONE_ENTITY_MESSAGE });
|
|
1178
|
+
var UpdatePresetInputSchema = PresetSchema.omit({
|
|
1179
|
+
id: true,
|
|
1180
|
+
createdAt: true,
|
|
1181
|
+
updatedAt: true,
|
|
1182
|
+
deleted: true
|
|
1183
|
+
}).partial();
|
|
1167
1184
|
|
|
1168
1185
|
// src/test/index.ts
|
|
1169
1186
|
import { z as z20 } from "zod";
|
|
@@ -1868,8 +1885,10 @@ var FailureAnalysisSchema = z28.object({
|
|
|
1868
1885
|
var EvalRunSchema = TenantEntitySchema.extend({
|
|
1869
1886
|
/** Agent ID for this run */
|
|
1870
1887
|
agentId: z28.string().optional(),
|
|
1871
|
-
/**
|
|
1872
|
-
|
|
1888
|
+
/** Preset ID that originated this run (optional) */
|
|
1889
|
+
presetId: z28.string().optional(),
|
|
1890
|
+
/** Skill IDs for this run */
|
|
1891
|
+
skillIds: z28.array(z28.string()).optional(),
|
|
1873
1892
|
/** Map of skillId to skillVersionId for this run */
|
|
1874
1893
|
skillVersions: z28.record(z28.string(), z28.string()).optional(),
|
|
1875
1894
|
/** Scenario IDs to run (always present — resolved server-side from tags when needed) */
|
|
@@ -2314,11 +2333,11 @@ export {
|
|
|
2314
2333
|
CreateCustomAssertionInputSchema,
|
|
2315
2334
|
CreateEvalRunInputSchema,
|
|
2316
2335
|
CreateMcpInputSchema,
|
|
2336
|
+
CreatePresetInputSchema,
|
|
2317
2337
|
CreateProjectInputSchema,
|
|
2318
2338
|
CreateRuleInputSchema,
|
|
2319
2339
|
CreateSkillInputSchema,
|
|
2320
2340
|
CreateSkillVersionInputSchema,
|
|
2321
|
-
CreateSkillsGroupInputSchema,
|
|
2322
2341
|
CreateSubAgentInputSchema,
|
|
2323
2342
|
CreateTemplateInputSchema,
|
|
2324
2343
|
CreateTestScenarioInputSchema,
|
|
@@ -2370,6 +2389,7 @@ export {
|
|
|
2370
2389
|
Model as OpenAIModel,
|
|
2371
2390
|
OpenAIModelSchema,
|
|
2372
2391
|
PlaywrightNLTestSchema,
|
|
2392
|
+
PresetSchema,
|
|
2373
2393
|
ProjectSchema,
|
|
2374
2394
|
PromptResultSchema,
|
|
2375
2395
|
RUN_COMMAND_LABELS,
|
|
@@ -2390,7 +2410,6 @@ export {
|
|
|
2390
2410
|
SkillWasCalledAssertionSchema,
|
|
2391
2411
|
SkillWasCalledConfigSchema,
|
|
2392
2412
|
SkillWithLatestVersionSchema,
|
|
2393
|
-
SkillsGroupSchema,
|
|
2394
2413
|
SubAgentSchema,
|
|
2395
2414
|
TRACE_EVENT_PREFIX,
|
|
2396
2415
|
TargetSchema,
|
|
@@ -2421,10 +2440,10 @@ export {
|
|
|
2421
2440
|
UpdateAgentInputSchema,
|
|
2422
2441
|
UpdateCustomAssertionInputSchema,
|
|
2423
2442
|
UpdateMcpInputSchema,
|
|
2443
|
+
UpdatePresetInputSchema,
|
|
2424
2444
|
UpdateProjectInputSchema,
|
|
2425
2445
|
UpdateRuleInputSchema,
|
|
2426
2446
|
UpdateSkillInputSchema,
|
|
2427
|
-
UpdateSkillsGroupInputSchema,
|
|
2428
2447
|
UpdateSubAgentInputSchema,
|
|
2429
2448
|
UpdateTemplateInputSchema,
|
|
2430
2449
|
UpdateTestScenarioInputSchema,
|