@oneharness/sdk 0.26.0 → 0.27.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/dist/generated/capabilities.d.ts +113 -0
- package/dist/generated/capabilities.js +134 -0
- package/dist/generated/compact-options.d.ts +26 -0
- package/dist/generated/compact-options.js +2 -0
- package/dist/generated/compact-outcome.d.ts +72 -0
- package/dist/generated/compact-outcome.js +2 -0
- package/dist/generated/config-report.d.ts +42 -24
- package/dist/generated/contracts.d.ts +74 -6
- package/dist/generated/history-line.d.ts +29 -23
- package/dist/generated/history-show-entries.d.ts +26 -20
- package/dist/generated/history-stream-envelope.d.ts +27 -21
- package/dist/generated/history.d.ts +26 -20
- package/dist/generated/options.d.ts +30 -0
- package/dist/generated/registry.d.ts +32 -0
- package/dist/generated/run-stream-envelope.d.ts +73 -5
- package/dist/generated/schemas.json +1004 -100
- package/dist/generated/zod.d.ts +12 -3
- package/dist/generated/zod.js +202 -27
- package/dist/index.d.ts +13 -0
- package/dist/index.js +12 -1
- package/package.json +2 -2
package/dist/generated/zod.js
CHANGED
|
@@ -46,6 +46,42 @@ export const BatchReportSchema = z.looseObject({
|
|
|
46
46
|
strategy: z.lazy(() => BatchStrategySchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
47
47
|
});
|
|
48
48
|
export const BatchStrategySchema = z.union([z.literal("speed"), z.literal("min-tokens")]);
|
|
49
|
+
export const CompactOptionsSchema = z.strictObject({
|
|
50
|
+
bins: z.record(z.string(), z.string()).optional(),
|
|
51
|
+
config: z.array(z.string()).optional(),
|
|
52
|
+
cwd: z.string().optional(),
|
|
53
|
+
env: z.record(z.string(), z.string()).optional(),
|
|
54
|
+
harness: z.string().optional(),
|
|
55
|
+
model: z.string().optional(),
|
|
56
|
+
noConfig: z.boolean().optional(),
|
|
57
|
+
session: z
|
|
58
|
+
.string()
|
|
59
|
+
.min(1)
|
|
60
|
+
.refine((value) => value !== undefined, { message: "Required" }),
|
|
61
|
+
sessionDir: z.string().optional(),
|
|
62
|
+
timeoutSeconds: z.int().gte(0).optional(),
|
|
63
|
+
});
|
|
64
|
+
export const CompactOutcomeSchema = z.looseObject({
|
|
65
|
+
context_tokens_after: z
|
|
66
|
+
.union([z.int().gte(0), z.null()])
|
|
67
|
+
.refine((value) => value !== undefined, { message: "Required" }),
|
|
68
|
+
context_tokens_before: z
|
|
69
|
+
.union([z.int().gte(0), z.null()])
|
|
70
|
+
.refine((value) => value !== undefined, { message: "Required" }),
|
|
71
|
+
error: z.union([z.string(), z.null()]).optional(),
|
|
72
|
+
harness: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
73
|
+
schema_version: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
74
|
+
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
75
|
+
status: z.lazy(() => CompactStatusSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
76
|
+
token: z.union([z.string(), z.null()]).optional(),
|
|
77
|
+
usage: z.lazy(() => UsageSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
78
|
+
});
|
|
79
|
+
export const CompactStatusSchema = z.union([
|
|
80
|
+
z.literal("completed"),
|
|
81
|
+
z.literal("cancelled"),
|
|
82
|
+
z.literal("unsupported"),
|
|
83
|
+
z.literal("failed"),
|
|
84
|
+
]);
|
|
49
85
|
export const ConfigOptionsSchema = z.strictObject({
|
|
50
86
|
config: z.array(z.string()).optional(),
|
|
51
87
|
cwd: z.string().optional(),
|
|
@@ -54,6 +90,7 @@ export const ConfigOptionsSchema = z.strictObject({
|
|
|
54
90
|
export const ConfigReportSchema = z.looseObject({
|
|
55
91
|
all: z.lazy(() => FieldSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
56
92
|
allowed_tools: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
93
|
+
auto_compact_tokens: z.lazy(() => Field5Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
57
94
|
bypass: z.lazy(() => FieldSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
58
95
|
config_files: z.array(z.string()).refine((value) => value !== undefined, { message: "Required" }),
|
|
59
96
|
denied_tools: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -71,24 +108,27 @@ export const ConfigReportSchema = z.looseObject({
|
|
|
71
108
|
.record(z.string(), z.lazy(() => Field3Schema))
|
|
72
109
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
73
110
|
history_pointer_file: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
74
|
-
hooks: z.lazy(() =>
|
|
75
|
-
|
|
111
|
+
hooks: z.lazy(() => Field11Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
112
|
+
load_mcp: z.lazy(() => FieldSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
113
|
+
load_skills: z.lazy(() => FieldSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
114
|
+
max_parallel: z.lazy(() => Field9Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
76
115
|
mode: z.lazy(() => Field4Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
77
116
|
model: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
78
117
|
models: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
79
|
-
output_format: z.lazy(() =>
|
|
118
|
+
output_format: z.lazy(() => Field7Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
80
119
|
reasoning: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
81
120
|
require_available: z.lazy(() => FieldSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
82
|
-
run_mode: z.lazy(() =>
|
|
121
|
+
run_mode: z.lazy(() => Field10Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
83
122
|
schema_file: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
84
|
-
schema_max_retries: z.lazy(() =>
|
|
123
|
+
schema_max_retries: z.lazy(() => Field8Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
85
124
|
schema_version: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
86
125
|
server_overloaded_max_retries: z
|
|
87
|
-
.lazy(() =>
|
|
126
|
+
.lazy(() => Field8Schema)
|
|
88
127
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
89
128
|
stream: z.lazy(() => FieldSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
90
129
|
system: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
91
130
|
timeout: z.lazy(() => Field5Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
131
|
+
tool_set: z.lazy(() => Field6Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
92
132
|
});
|
|
93
133
|
export const ControlEventSchema = z.union([
|
|
94
134
|
z.looseObject({
|
|
@@ -143,6 +183,11 @@ export const DetectReportSchema = z.looseObject({
|
|
|
143
183
|
detected: z.array(z.lazy(() => DetectInfoSchema)).refine((value) => value !== undefined, { message: "Required" }),
|
|
144
184
|
schema_version: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
145
185
|
});
|
|
186
|
+
export const DiagnosticSchema = z.looseObject({
|
|
187
|
+
harness: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
188
|
+
message: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
189
|
+
setting: z.lazy(() => SettingSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
190
|
+
});
|
|
146
191
|
export const ExecutionTelemetrySchema = z.union([
|
|
147
192
|
z.looseObject({
|
|
148
193
|
finished_at: z
|
|
@@ -192,6 +237,7 @@ export const FailureKindSchema = z.union([
|
|
|
192
237
|
z.literal("model_mismatch"),
|
|
193
238
|
z.literal("server_overloaded"),
|
|
194
239
|
z.literal("app_server_lost"),
|
|
240
|
+
z.literal("unsupported_input"),
|
|
195
241
|
]);
|
|
196
242
|
export const FallThroughSchema = z.looseObject({
|
|
197
243
|
detail: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -211,6 +257,7 @@ export const FallThroughReasonSchema = z.union([
|
|
|
211
257
|
z.literal("rate-limit"),
|
|
212
258
|
z.literal("server-overloaded"),
|
|
213
259
|
z.literal("app-server-lost"),
|
|
260
|
+
z.literal("unsupported-input"),
|
|
214
261
|
]);
|
|
215
262
|
export const FallbackReportSchema = z.looseObject({
|
|
216
263
|
fell_through: z
|
|
@@ -226,10 +273,16 @@ export const FieldSchema = z.looseObject({
|
|
|
226
273
|
export const Field10Schema = z.looseObject({
|
|
227
274
|
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
228
275
|
value: z
|
|
229
|
-
.union([z.
|
|
276
|
+
.union([z.lazy(() => RunModeSchema), z.null()])
|
|
230
277
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
231
278
|
});
|
|
232
279
|
export const Field11Schema = z.looseObject({
|
|
280
|
+
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
281
|
+
value: z
|
|
282
|
+
.union([z.array(z.lazy(() => HookEntrySchema)), z.null()])
|
|
283
|
+
.refine((value) => value !== undefined, { message: "Required" }),
|
|
284
|
+
});
|
|
285
|
+
export const Field12Schema = z.looseObject({
|
|
233
286
|
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
234
287
|
value: z
|
|
235
288
|
.union([z.lazy(() => AppServerModeSchema), z.null()])
|
|
@@ -256,12 +309,14 @@ export const Field5Schema = z.looseObject({
|
|
|
256
309
|
export const Field6Schema = z.looseObject({
|
|
257
310
|
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
258
311
|
value: z
|
|
259
|
-
.union([z.lazy(() =>
|
|
312
|
+
.union([z.array(z.lazy(() => ToolClassSchema)), z.null()])
|
|
260
313
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
261
314
|
});
|
|
262
315
|
export const Field7Schema = z.looseObject({
|
|
263
316
|
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
264
|
-
value: z
|
|
317
|
+
value: z
|
|
318
|
+
.union([z.lazy(() => OutputFormatSchema), z.null()])
|
|
319
|
+
.refine((value) => value !== undefined, { message: "Required" }),
|
|
265
320
|
});
|
|
266
321
|
export const Field8Schema = z.looseObject({
|
|
267
322
|
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -269,9 +324,7 @@ export const Field8Schema = z.looseObject({
|
|
|
269
324
|
});
|
|
270
325
|
export const Field9Schema = z.looseObject({
|
|
271
326
|
source: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
272
|
-
value: z
|
|
273
|
-
.union([z.lazy(() => RunModeSchema), z.null()])
|
|
274
|
-
.refine((value) => value !== undefined, { message: "Required" }),
|
|
327
|
+
value: z.union([z.int().gte(0), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
275
328
|
});
|
|
276
329
|
export const FileStatusSchema = z.union([
|
|
277
330
|
z.literal("created"),
|
|
@@ -302,22 +355,29 @@ export const HarnessInfoSchema = z.looseObject({
|
|
|
302
355
|
output_format: z.lazy(() => OutputFormatSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
303
356
|
session_capable: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
304
357
|
supports_allowed_tools: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
358
|
+
supports_auto_compact: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
359
|
+
supports_call_usage: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
360
|
+
supports_compact_now: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
305
361
|
supports_denied_tools: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
306
362
|
supports_fork: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
307
363
|
supports_hooks: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
364
|
+
supports_images: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
365
|
+
supports_mcp_off: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
308
366
|
supports_mock_deny: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
309
367
|
supports_native_schema: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
310
368
|
supports_prompt_stdin: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
311
369
|
supports_reasoning: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
312
370
|
supports_resume: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
371
|
+
supports_skills_off: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
313
372
|
supports_system_file: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
373
|
+
supports_tool_set: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
314
374
|
sync_file: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
315
375
|
variants: z.array(z.lazy(() => VariantInfoSchema)).refine((value) => value !== undefined, { message: "Required" }),
|
|
316
376
|
});
|
|
317
377
|
export const HarnessReportSchema = z.looseObject({
|
|
318
378
|
allowed_tools: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
319
379
|
analytics: z.union([z.lazy(() => FieldSchema), z.null()]).optional(),
|
|
320
|
-
app_server: z.union([z.lazy(() =>
|
|
380
|
+
app_server: z.union([z.lazy(() => Field12Schema), z.null()]).optional(),
|
|
321
381
|
apps: z.union([z.lazy(() => FieldSchema), z.null()]).optional(),
|
|
322
382
|
args: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
323
383
|
bin: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -388,6 +448,7 @@ export const HistoryEventLineSchema = z.union([
|
|
|
388
448
|
z.literal("1.9"),
|
|
389
449
|
z.literal("1.10"),
|
|
390
450
|
z.literal("1.11"),
|
|
451
|
+
z.literal("1.12"),
|
|
391
452
|
])
|
|
392
453
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
393
454
|
session_name: z
|
|
@@ -463,7 +524,9 @@ export const HistoryLineSchema = z.union([
|
|
|
463
524
|
.refine((value) => [...value].length <= 36, { message: "Too long: expected at most 36 characters" })
|
|
464
525
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
465
526
|
prompt: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
466
|
-
schema_version: z
|
|
527
|
+
schema_version: z
|
|
528
|
+
.union([z.literal("1.11"), z.literal("1.12")])
|
|
529
|
+
.refine((value) => value !== undefined, { message: "Required" }),
|
|
467
530
|
started: z.lazy(() => UtcInstantSchema).refine((value) => value !== undefined, { message: "Required" }),
|
|
468
531
|
type: z.literal("run-started").refine((value) => value !== undefined, { message: "Required" }),
|
|
469
532
|
}),
|
|
@@ -490,6 +553,7 @@ export const HistoryLineSchema = z.union([
|
|
|
490
553
|
z.literal("1.9"),
|
|
491
554
|
z.literal("1.10"),
|
|
492
555
|
z.literal("1.11"),
|
|
556
|
+
z.literal("1.12"),
|
|
493
557
|
])
|
|
494
558
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
495
559
|
session_name: z
|
|
@@ -596,6 +660,7 @@ export const HistoryLineSchema = z.union([
|
|
|
596
660
|
z.literal("1.9"),
|
|
597
661
|
z.literal("1.10"),
|
|
598
662
|
z.literal("1.11"),
|
|
663
|
+
z.literal("1.12"),
|
|
599
664
|
])
|
|
600
665
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
601
666
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -683,6 +748,7 @@ export const HistoryLineSchema = z.union([
|
|
|
683
748
|
z.literal("1.9"),
|
|
684
749
|
z.literal("1.10"),
|
|
685
750
|
z.literal("1.11"),
|
|
751
|
+
z.literal("1.12"),
|
|
686
752
|
])
|
|
687
753
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
688
754
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -772,6 +838,7 @@ export const HistoryLineSchema = z.union([
|
|
|
772
838
|
z.literal("1.9"),
|
|
773
839
|
z.literal("1.10"),
|
|
774
840
|
z.literal("1.11"),
|
|
841
|
+
z.literal("1.12"),
|
|
775
842
|
])
|
|
776
843
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
777
844
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -845,6 +912,7 @@ export const HistoryLineSchema = z.union([
|
|
|
845
912
|
z.literal("1.9"),
|
|
846
913
|
z.literal("1.10"),
|
|
847
914
|
z.literal("1.11"),
|
|
915
|
+
z.literal("1.12"),
|
|
848
916
|
])
|
|
849
917
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
850
918
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -924,6 +992,7 @@ export const HistoryLineSchema = z.union([
|
|
|
924
992
|
z.literal("1.9"),
|
|
925
993
|
z.literal("1.10"),
|
|
926
994
|
z.literal("1.11"),
|
|
995
|
+
z.literal("1.12"),
|
|
927
996
|
])
|
|
928
997
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
929
998
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -1008,6 +1077,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1008
1077
|
z.literal("1.9"),
|
|
1009
1078
|
z.literal("1.10"),
|
|
1010
1079
|
z.literal("1.11"),
|
|
1080
|
+
z.literal("1.12"),
|
|
1011
1081
|
])
|
|
1012
1082
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
1013
1083
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -1047,6 +1117,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1047
1117
|
z.literal("1.9"),
|
|
1048
1118
|
z.literal("1.10"),
|
|
1049
1119
|
z.literal("1.11"),
|
|
1120
|
+
z.literal("1.12"),
|
|
1050
1121
|
])
|
|
1051
1122
|
.optional(),
|
|
1052
1123
|
}), z.union([
|
|
@@ -1073,7 +1144,14 @@ export const HistoryLineSchema = z.union([
|
|
|
1073
1144
|
}),
|
|
1074
1145
|
z.looseObject({
|
|
1075
1146
|
schema_version: z
|
|
1076
|
-
.union([
|
|
1147
|
+
.union([
|
|
1148
|
+
z.literal("1.7"),
|
|
1149
|
+
z.literal("1.8"),
|
|
1150
|
+
z.literal("1.9"),
|
|
1151
|
+
z.literal("1.10"),
|
|
1152
|
+
z.literal("1.11"),
|
|
1153
|
+
z.literal("1.12"),
|
|
1154
|
+
])
|
|
1077
1155
|
.optional(),
|
|
1078
1156
|
status: z.union([z.literal("nonzero"), z.literal("timeout"), z.literal("cancelled")]).optional(),
|
|
1079
1157
|
work: z
|
|
@@ -1087,7 +1165,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1087
1165
|
z.looseObject({
|
|
1088
1166
|
observed_model: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
1089
1167
|
schema_version: z
|
|
1090
|
-
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11")])
|
|
1168
|
+
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11"), z.literal("1.12")])
|
|
1091
1169
|
.optional(),
|
|
1092
1170
|
}),
|
|
1093
1171
|
])), z.union([
|
|
@@ -1114,10 +1192,11 @@ export const HistoryLineSchema = z.union([
|
|
|
1114
1192
|
z.literal("1.9"),
|
|
1115
1193
|
z.literal("1.10"),
|
|
1116
1194
|
z.literal("1.11"),
|
|
1195
|
+
z.literal("1.12"),
|
|
1117
1196
|
])
|
|
1118
1197
|
.optional(),
|
|
1119
1198
|
}),
|
|
1120
|
-
])), z.intersection(z.intersection(z.intersection(z.intersection(z.union([
|
|
1199
|
+
])), z.intersection(z.intersection(z.intersection(z.intersection(z.intersection(z.union([
|
|
1121
1200
|
z.looseObject({
|
|
1122
1201
|
failure_kind: z
|
|
1123
1202
|
.union([
|
|
@@ -1131,6 +1210,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1131
1210
|
z.literal("model_mismatch"),
|
|
1132
1211
|
z.literal("server_overloaded"),
|
|
1133
1212
|
z.literal("app_server_lost"),
|
|
1213
|
+
z.literal("unsupported_input"),
|
|
1134
1214
|
z.literal(null),
|
|
1135
1215
|
])
|
|
1136
1216
|
.optional(),
|
|
@@ -1145,6 +1225,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1145
1225
|
z.literal("1.9"),
|
|
1146
1226
|
z.literal("1.10"),
|
|
1147
1227
|
z.literal("1.11"),
|
|
1228
|
+
z.literal("1.12"),
|
|
1148
1229
|
])
|
|
1149
1230
|
.optional(),
|
|
1150
1231
|
}),
|
|
@@ -1161,6 +1242,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1161
1242
|
z.literal("model_mismatch"),
|
|
1162
1243
|
z.literal("server_overloaded"),
|
|
1163
1244
|
z.literal("app_server_lost"),
|
|
1245
|
+
z.literal("unsupported_input"),
|
|
1164
1246
|
z.literal(null),
|
|
1165
1247
|
])
|
|
1166
1248
|
.optional(),
|
|
@@ -1174,6 +1256,7 @@ export const HistoryLineSchema = z.union([
|
|
|
1174
1256
|
z.literal("1.9"),
|
|
1175
1257
|
z.literal("1.10"),
|
|
1176
1258
|
z.literal("1.11"),
|
|
1259
|
+
z.literal("1.12"),
|
|
1177
1260
|
])
|
|
1178
1261
|
.optional(),
|
|
1179
1262
|
}),
|
|
@@ -1191,13 +1274,14 @@ export const HistoryLineSchema = z.union([
|
|
|
1191
1274
|
z.literal("input_too_large"),
|
|
1192
1275
|
z.literal("server_overloaded"),
|
|
1193
1276
|
z.literal("app_server_lost"),
|
|
1277
|
+
z.literal("unsupported_input"),
|
|
1194
1278
|
z.literal(null),
|
|
1195
1279
|
])
|
|
1196
1280
|
.optional(),
|
|
1197
1281
|
}),
|
|
1198
1282
|
z.looseObject({
|
|
1199
1283
|
schema_version: z
|
|
1200
|
-
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11")])
|
|
1284
|
+
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11"), z.literal("1.12")])
|
|
1201
1285
|
.optional(),
|
|
1202
1286
|
}),
|
|
1203
1287
|
])), z.union([
|
|
@@ -1214,12 +1298,37 @@ export const HistoryLineSchema = z.union([
|
|
|
1214
1298
|
z.literal("input_too_large"),
|
|
1215
1299
|
z.literal("model_mismatch"),
|
|
1216
1300
|
z.literal("app_server_lost"),
|
|
1301
|
+
z.literal("unsupported_input"),
|
|
1302
|
+
z.literal(null),
|
|
1303
|
+
])
|
|
1304
|
+
.optional(),
|
|
1305
|
+
}),
|
|
1306
|
+
z.looseObject({
|
|
1307
|
+
schema_version: z
|
|
1308
|
+
.union([z.literal("1.9"), z.literal("1.10"), z.literal("1.11"), z.literal("1.12")])
|
|
1309
|
+
.optional(),
|
|
1310
|
+
}),
|
|
1311
|
+
])), z.union([
|
|
1312
|
+
z.looseObject({
|
|
1313
|
+
failure_kind: z
|
|
1314
|
+
.union([
|
|
1315
|
+
z.literal("auth"),
|
|
1316
|
+
z.literal("rate_limit"),
|
|
1317
|
+
z.literal("model_not_found"),
|
|
1318
|
+
z.literal("quota"),
|
|
1319
|
+
z.literal("session_not_found"),
|
|
1320
|
+
z.literal("tool_deferred"),
|
|
1321
|
+
z.literal("untrusted_directory"),
|
|
1322
|
+
z.literal("input_too_large"),
|
|
1323
|
+
z.literal("model_mismatch"),
|
|
1324
|
+
z.literal("server_overloaded"),
|
|
1325
|
+
z.literal("unsupported_input"),
|
|
1217
1326
|
z.literal(null),
|
|
1218
1327
|
])
|
|
1219
1328
|
.optional(),
|
|
1220
1329
|
}),
|
|
1221
1330
|
z.looseObject({
|
|
1222
|
-
schema_version: z.union([z.literal("1.
|
|
1331
|
+
schema_version: z.union([z.literal("1.10"), z.literal("1.11"), z.literal("1.12")]).optional(),
|
|
1223
1332
|
}),
|
|
1224
1333
|
])), z.union([
|
|
1225
1334
|
z.looseObject({
|
|
@@ -1235,12 +1344,13 @@ export const HistoryLineSchema = z.union([
|
|
|
1235
1344
|
z.literal("input_too_large"),
|
|
1236
1345
|
z.literal("model_mismatch"),
|
|
1237
1346
|
z.literal("server_overloaded"),
|
|
1347
|
+
z.literal("app_server_lost"),
|
|
1238
1348
|
z.literal(null),
|
|
1239
1349
|
])
|
|
1240
1350
|
.optional(),
|
|
1241
1351
|
}),
|
|
1242
1352
|
z.looseObject({
|
|
1243
|
-
schema_version: z.
|
|
1353
|
+
schema_version: z.literal("1.12").optional(),
|
|
1244
1354
|
}),
|
|
1245
1355
|
]))),
|
|
1246
1356
|
]);
|
|
@@ -1449,6 +1559,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
1449
1559
|
z.literal("1.9"),
|
|
1450
1560
|
z.literal("1.10"),
|
|
1451
1561
|
z.literal("1.11"),
|
|
1562
|
+
z.literal("1.12"),
|
|
1452
1563
|
])
|
|
1453
1564
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
1454
1565
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -1695,6 +1806,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
1695
1806
|
z.literal("1.9"),
|
|
1696
1807
|
z.literal("1.10"),
|
|
1697
1808
|
z.literal("1.11"),
|
|
1809
|
+
z.literal("1.12"),
|
|
1698
1810
|
])
|
|
1699
1811
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
1700
1812
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -1774,6 +1886,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
1774
1886
|
z.literal("1.9"),
|
|
1775
1887
|
z.literal("1.10"),
|
|
1776
1888
|
z.literal("1.11"),
|
|
1889
|
+
z.literal("1.12"),
|
|
1777
1890
|
])
|
|
1778
1891
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
1779
1892
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -1847,6 +1960,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
1847
1960
|
z.literal("1.9"),
|
|
1848
1961
|
z.literal("1.10"),
|
|
1849
1962
|
z.literal("1.11"),
|
|
1963
|
+
z.literal("1.12"),
|
|
1850
1964
|
])
|
|
1851
1965
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
1852
1966
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -1928,6 +2042,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
1928
2042
|
z.literal("1.9"),
|
|
1929
2043
|
z.literal("1.10"),
|
|
1930
2044
|
z.literal("1.11"),
|
|
2045
|
+
z.literal("1.12"),
|
|
1931
2046
|
])
|
|
1932
2047
|
.refine((value) => value !== undefined, { message: "Required" }),
|
|
1933
2048
|
session: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
@@ -2215,6 +2330,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2215
2330
|
z.literal("1.9"),
|
|
2216
2331
|
z.literal("1.10"),
|
|
2217
2332
|
z.literal("1.11"),
|
|
2333
|
+
z.literal("1.12"),
|
|
2218
2334
|
])
|
|
2219
2335
|
.optional(),
|
|
2220
2336
|
}), z.union([
|
|
@@ -2241,7 +2357,14 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2241
2357
|
}),
|
|
2242
2358
|
z.looseObject({
|
|
2243
2359
|
schema_version: z
|
|
2244
|
-
.union([
|
|
2360
|
+
.union([
|
|
2361
|
+
z.literal("1.7"),
|
|
2362
|
+
z.literal("1.8"),
|
|
2363
|
+
z.literal("1.9"),
|
|
2364
|
+
z.literal("1.10"),
|
|
2365
|
+
z.literal("1.11"),
|
|
2366
|
+
z.literal("1.12"),
|
|
2367
|
+
])
|
|
2245
2368
|
.optional(),
|
|
2246
2369
|
status: z.union([z.literal("nonzero"), z.literal("timeout"), z.literal("cancelled")]).optional(),
|
|
2247
2370
|
work: z
|
|
@@ -2255,7 +2378,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2255
2378
|
z.looseObject({
|
|
2256
2379
|
observed_model: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
2257
2380
|
schema_version: z
|
|
2258
|
-
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11")])
|
|
2381
|
+
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11"), z.literal("1.12")])
|
|
2259
2382
|
.optional(),
|
|
2260
2383
|
}),
|
|
2261
2384
|
])), z.union([
|
|
@@ -2282,10 +2405,11 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2282
2405
|
z.literal("1.9"),
|
|
2283
2406
|
z.literal("1.10"),
|
|
2284
2407
|
z.literal("1.11"),
|
|
2408
|
+
z.literal("1.12"),
|
|
2285
2409
|
])
|
|
2286
2410
|
.optional(),
|
|
2287
2411
|
}),
|
|
2288
|
-
])), z.intersection(z.intersection(z.intersection(z.intersection(z.union([
|
|
2412
|
+
])), z.intersection(z.intersection(z.intersection(z.intersection(z.intersection(z.union([
|
|
2289
2413
|
z.looseObject({
|
|
2290
2414
|
failure_kind: z
|
|
2291
2415
|
.union([
|
|
@@ -2299,6 +2423,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2299
2423
|
z.literal("model_mismatch"),
|
|
2300
2424
|
z.literal("server_overloaded"),
|
|
2301
2425
|
z.literal("app_server_lost"),
|
|
2426
|
+
z.literal("unsupported_input"),
|
|
2302
2427
|
z.literal(null),
|
|
2303
2428
|
])
|
|
2304
2429
|
.optional(),
|
|
@@ -2313,6 +2438,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2313
2438
|
z.literal("1.9"),
|
|
2314
2439
|
z.literal("1.10"),
|
|
2315
2440
|
z.literal("1.11"),
|
|
2441
|
+
z.literal("1.12"),
|
|
2316
2442
|
])
|
|
2317
2443
|
.optional(),
|
|
2318
2444
|
}),
|
|
@@ -2329,6 +2455,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2329
2455
|
z.literal("model_mismatch"),
|
|
2330
2456
|
z.literal("server_overloaded"),
|
|
2331
2457
|
z.literal("app_server_lost"),
|
|
2458
|
+
z.literal("unsupported_input"),
|
|
2332
2459
|
z.literal(null),
|
|
2333
2460
|
])
|
|
2334
2461
|
.optional(),
|
|
@@ -2342,6 +2469,7 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2342
2469
|
z.literal("1.9"),
|
|
2343
2470
|
z.literal("1.10"),
|
|
2344
2471
|
z.literal("1.11"),
|
|
2472
|
+
z.literal("1.12"),
|
|
2345
2473
|
])
|
|
2346
2474
|
.optional(),
|
|
2347
2475
|
}),
|
|
@@ -2359,13 +2487,14 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2359
2487
|
z.literal("input_too_large"),
|
|
2360
2488
|
z.literal("server_overloaded"),
|
|
2361
2489
|
z.literal("app_server_lost"),
|
|
2490
|
+
z.literal("unsupported_input"),
|
|
2362
2491
|
z.literal(null),
|
|
2363
2492
|
])
|
|
2364
2493
|
.optional(),
|
|
2365
2494
|
}),
|
|
2366
2495
|
z.looseObject({
|
|
2367
2496
|
schema_version: z
|
|
2368
|
-
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11")])
|
|
2497
|
+
.union([z.literal("1.8"), z.literal("1.9"), z.literal("1.10"), z.literal("1.11"), z.literal("1.12")])
|
|
2369
2498
|
.optional(),
|
|
2370
2499
|
}),
|
|
2371
2500
|
])), z.union([
|
|
@@ -2382,12 +2511,15 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2382
2511
|
z.literal("input_too_large"),
|
|
2383
2512
|
z.literal("model_mismatch"),
|
|
2384
2513
|
z.literal("app_server_lost"),
|
|
2514
|
+
z.literal("unsupported_input"),
|
|
2385
2515
|
z.literal(null),
|
|
2386
2516
|
])
|
|
2387
2517
|
.optional(),
|
|
2388
2518
|
}),
|
|
2389
2519
|
z.looseObject({
|
|
2390
|
-
schema_version: z
|
|
2520
|
+
schema_version: z
|
|
2521
|
+
.union([z.literal("1.9"), z.literal("1.10"), z.literal("1.11"), z.literal("1.12")])
|
|
2522
|
+
.optional(),
|
|
2391
2523
|
}),
|
|
2392
2524
|
])), z.union([
|
|
2393
2525
|
z.looseObject({
|
|
@@ -2403,12 +2535,35 @@ export const HistoryRecordSchema = z.intersection(z.intersection(z.intersection(
|
|
|
2403
2535
|
z.literal("input_too_large"),
|
|
2404
2536
|
z.literal("model_mismatch"),
|
|
2405
2537
|
z.literal("server_overloaded"),
|
|
2538
|
+
z.literal("unsupported_input"),
|
|
2406
2539
|
z.literal(null),
|
|
2407
2540
|
])
|
|
2408
2541
|
.optional(),
|
|
2409
2542
|
}),
|
|
2410
2543
|
z.looseObject({
|
|
2411
|
-
schema_version: z.union([z.literal("1.10"), z.literal("1.11")]).optional(),
|
|
2544
|
+
schema_version: z.union([z.literal("1.10"), z.literal("1.11"), z.literal("1.12")]).optional(),
|
|
2545
|
+
}),
|
|
2546
|
+
])), z.union([
|
|
2547
|
+
z.looseObject({
|
|
2548
|
+
failure_kind: z
|
|
2549
|
+
.union([
|
|
2550
|
+
z.literal("auth"),
|
|
2551
|
+
z.literal("rate_limit"),
|
|
2552
|
+
z.literal("model_not_found"),
|
|
2553
|
+
z.literal("quota"),
|
|
2554
|
+
z.literal("session_not_found"),
|
|
2555
|
+
z.literal("tool_deferred"),
|
|
2556
|
+
z.literal("untrusted_directory"),
|
|
2557
|
+
z.literal("input_too_large"),
|
|
2558
|
+
z.literal("model_mismatch"),
|
|
2559
|
+
z.literal("server_overloaded"),
|
|
2560
|
+
z.literal("app_server_lost"),
|
|
2561
|
+
z.literal(null),
|
|
2562
|
+
])
|
|
2563
|
+
.optional(),
|
|
2564
|
+
}),
|
|
2565
|
+
z.looseObject({
|
|
2566
|
+
schema_version: z.literal("1.12").optional(),
|
|
2412
2567
|
}),
|
|
2413
2568
|
])));
|
|
2414
2569
|
export const HistoryReindexOptionsSchema = z.strictObject({
|
|
@@ -2684,6 +2839,7 @@ export const RuleListSchema = z.union([z.literal("allowed_tools"), z.literal("de
|
|
|
2684
2839
|
export const RunModeSchema = z.union([z.literal("parallel"), z.literal("fallback")]);
|
|
2685
2840
|
export const RunOptionsSchema = z.strictObject({
|
|
2686
2841
|
all: z.boolean().optional(),
|
|
2842
|
+
autoCompactTokens: z.int().gte(1).optional(),
|
|
2687
2843
|
batchPrompts: z.array(z.string()).optional(),
|
|
2688
2844
|
batchStrategy: z.lazy(() => BatchStrategySchema).optional(),
|
|
2689
2845
|
bins: z.record(z.string(), z.string()).optional(),
|
|
@@ -2700,6 +2856,7 @@ export const RunOptionsSchema = z.strictObject({
|
|
|
2700
2856
|
historyLabels: z.lazy(() => HistoryLabelsSchema).optional(),
|
|
2701
2857
|
historyName: z.string().optional(),
|
|
2702
2858
|
historyPointerFile: z.string().min(1).optional(),
|
|
2859
|
+
images: z.array(z.string()).optional(),
|
|
2703
2860
|
maxParallel: z.int().gte(0).optional(),
|
|
2704
2861
|
mockHarnesses: z.array(z.string()).optional(),
|
|
2705
2862
|
mockRules: z.string().optional(),
|
|
@@ -2707,6 +2864,8 @@ export const RunOptionsSchema = z.strictObject({
|
|
|
2707
2864
|
models: z.array(z.string()).optional(),
|
|
2708
2865
|
noConfig: z.boolean().optional(),
|
|
2709
2866
|
noHistory: z.boolean().optional(),
|
|
2867
|
+
noMcp: z.boolean().optional(),
|
|
2868
|
+
noSkills: z.boolean().optional(),
|
|
2710
2869
|
outputDir: z.string().optional(),
|
|
2711
2870
|
outputFormat: z.lazy(() => OutputFormatSchema).optional(),
|
|
2712
2871
|
passthrough: z.array(z.string()).optional(),
|
|
@@ -2730,6 +2889,10 @@ export const RunOptionsSchema = z.strictObject({
|
|
|
2730
2889
|
system: z.string().optional(),
|
|
2731
2890
|
systemFile: z.string().optional(),
|
|
2732
2891
|
timeoutSeconds: z.int().gte(0).optional(),
|
|
2892
|
+
toolSet: z
|
|
2893
|
+
.array(z.lazy(() => ToolClassSchema))
|
|
2894
|
+
.min(1)
|
|
2895
|
+
.optional(),
|
|
2733
2896
|
});
|
|
2734
2897
|
export const RunReportSchema = z.looseObject({
|
|
2735
2898
|
batch: z
|
|
@@ -2767,7 +2930,9 @@ export const RunReportSchema = z.looseObject({
|
|
|
2767
2930
|
export const RunResultSchema = z.looseObject({
|
|
2768
2931
|
available: z.boolean().refine((value) => value !== undefined, { message: "Required" }),
|
|
2769
2932
|
bin: z.string().refine((value) => value !== undefined, { message: "Required" }),
|
|
2933
|
+
calls: z.union([z.array(z.lazy(() => UsageSchema)), z.null()]).optional(),
|
|
2770
2934
|
command: z.array(z.string()).refine((value) => value !== undefined, { message: "Required" }),
|
|
2935
|
+
diagnostics: z.array(z.lazy(() => DiagnosticSchema)).optional(),
|
|
2771
2936
|
duration_ms: z.union([z.int().gte(0), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
2772
2937
|
error: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
2773
2938
|
events: z
|
|
@@ -2868,6 +3033,15 @@ export const SessionReportSchema = z.looseObject({
|
|
|
2868
3033
|
store_file: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
2869
3034
|
token: z.union([z.string(), z.null()]).refine((value) => value !== undefined, { message: "Required" }),
|
|
2870
3035
|
});
|
|
3036
|
+
export const SettingSchema = z.union([
|
|
3037
|
+
z.literal("auto_compact_tokens"),
|
|
3038
|
+
z.literal("compact_now"),
|
|
3039
|
+
z.literal("tool_set"),
|
|
3040
|
+
z.literal("load_skills"),
|
|
3041
|
+
z.literal("load_mcp"),
|
|
3042
|
+
z.literal("images"),
|
|
3043
|
+
z.literal("calls"),
|
|
3044
|
+
]);
|
|
2871
3045
|
export const StatusSchema = z.union([
|
|
2872
3046
|
z.literal("ok"),
|
|
2873
3047
|
z.literal("nonzero"),
|
|
@@ -2919,6 +3093,7 @@ export const ToolCallStatusSchema = z.union([
|
|
|
2919
3093
|
z.literal("timeout"),
|
|
2920
3094
|
z.literal("interrupted"),
|
|
2921
3095
|
]);
|
|
3096
|
+
export const ToolClassSchema = z.union([z.literal("shell"), z.literal("read")]);
|
|
2922
3097
|
export const UnavailableReasonSchema = z.union([
|
|
2923
3098
|
z.literal("api_key_auth"),
|
|
2924
3099
|
z.literal("not_logged_in"),
|
|
@@ -3043,7 +3218,7 @@ export const VariantInfoSchema = z.looseObject({
|
|
|
3043
3218
|
export const VariantReportSchema = z.looseObject({
|
|
3044
3219
|
allowed_tools: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
3045
3220
|
analytics: z.union([z.lazy(() => FieldSchema), z.null()]).optional(),
|
|
3046
|
-
app_server: z.union([z.lazy(() =>
|
|
3221
|
+
app_server: z.union([z.lazy(() => Field12Schema), z.null()]).optional(),
|
|
3047
3222
|
apps: z.union([z.lazy(() => FieldSchema), z.null()]).optional(),
|
|
3048
3223
|
args: z.lazy(() => Field2Schema).refine((value) => value !== undefined, { message: "Required" }),
|
|
3049
3224
|
bin: z.lazy(() => Field3Schema).refine((value) => value !== undefined, { message: "Required" }),
|