fascicle 0.10.2 → 0.11.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/dist/index.d.ts CHANGED
@@ -1,7 +1,1103 @@
1
- import { A as fallback, B as describe, C as checkpoint, D as LoopResult, E as LoopGuardResult, F as parallel, G as Step, H as run, I as sequence, J as TrajectoryLogger, K as StepMetadata, L as DescribeOptions, M as pipe, N as map, O as loop, P as branch, R as FlowNode, S as suspend, T as LoopConfig, U as CheckpointStore, V as step, W as RunContext, Y as __json_default_export, _ as suspended_error, a as SpanStartEvent, b as stash, c as span_end_event_schema, d as STEP_KINDS, f as StepKind, g as resume_validation_error, h as describe_cycle_error, i as SpanEndEvent, j as retry, k as timeout, l as span_start_event_schema, m as aborted_error, n as EmitEvent, o as custom_event_schema, p as is_step_kind, q as TrajectoryEvent, r as ParsedTrajectoryEvent, s as emit_event_schema, t as CustomTrajectoryEvent, u as trajectory_event_schema, v as timeout_error, w as compose, x as use, y as scope, z as FlowValue } from "./index-C2ayBpzS.js";
2
- import { $ as ProviderCapability, A as Pricing, B as ToolApprovalHandler, C as FinishReason, D as PrepareStepContext, E as Message, F as RetryFailureKind, G as TurnResult, H as ToolCallRecord, I as RetryPolicy, J as AiSdkProviderAdapter, K as UsageTotals, L as StepRecord, M as ProviderConfigMap, N as ProviderInit, O as PrepareStepHook, P as ResolvedModel, Q as ProviderAdapter, R as StreamChunk, S as EngineDefaults, T as GenerateResult, U as ToolExecContext, V as ToolApprovalRequest, W as TurnRequest, X as ExternalAgentAdapter, Y as EffortTranslation, Z as NativeProviderAdapter, _ as AssistantContentPart, a as model_required_error, b as Engine, c as provider_capability_error, d as rate_limit_error, et as ProviderFactory, f as schema_validation_error, g as AiSdkTelemetrySettings, h as create_engine, i as incomplete_generation_error, j as PricingTable, k as PrepareStepResult, l as provider_error, m as tool_error, n as engine_config_error, nt as RawProviderUsage, o as on_chunk_error, p as tool_approval_denied_error, q as UserContentPart, r as engine_disposed_error, rt as default_normalize_usage, s as provider_auth_error, t as claude_cli_error, tt as ProviderTransport, u as provider_not_configured_error, v as CostBreakdown, w as GenerateOptions, x as EngineConfig, y as EffortLevel, z as Tool } from "./index-CHtfOfEF.js";
3
- import { z } from "zod";
1
+ import { a as StepMetadata, i as StepFn, n as RunContext, o as TrajectoryEvent, r as Step, s as TrajectoryLogger, t as CheckpointStore } from "./types-BDSbSUAO.js";
2
+ import { n as SchemaIssue, r as ToolSchema, t as AnySchema } from "./types-BCtKsxrX.js";
3
+ import { A as TurnResult, B as ProviderTransport, C as StreamChunk, D as ToolCallRecord, E as ToolApprovalRequest, F as ExternalAgentAdapter, H as default_normalize_usage, I as NativeProviderAdapter, L as ProviderAdapter, M as UserContentPart, N as AiSdkProviderAdapter, O as ToolExecContext, P as EffortTranslation, R as ProviderCapability, S as StepRecord, T as ToolApprovalHandler, V as RawProviderUsage, _ as ProviderConfigMap, a as Engine, b as RetryFailureKind, c as FinishReason, d as Message, f as PrepareStepContext, g as PricingTable, h as Pricing, i as EffortLevel, j as UsageTotals, k as TurnRequest, l as GenerateOptions, m as PrepareStepResult, n as AssistantContentPart, o as EngineConfig, p as PrepareStepHook, r as CostBreakdown, s as EngineDefaults, t as AiSdkTelemetrySettings, u as GenerateResult, v as ProviderInit, w as Tool, x as RetryPolicy, y as ResolvedModel, z as ProviderFactory } from "./types-B3HIsBBD.js";
4
4
 
5
+ //#region src/core/flow-schema.json.d.ts
6
+ declare let $schema: string;
7
+ declare let $id: string;
8
+ declare let title: string;
9
+ declare let description: string;
10
+ declare let type: string;
11
+ declare namespace items {
12
+ let $ref: string;
13
+ }
14
+ declare namespace $defs {
15
+ namespace compose_entry {
16
+ let type_1: string;
17
+ export { type_1 as type };
18
+ export let required: string[];
19
+ export namespace properties {
20
+ namespace compose {
21
+ let type_2: string;
22
+ export { type_2 as type };
23
+ }
24
+ }
25
+ export let allOf: {
26
+ $ref: string;
27
+ }[];
28
+ }
29
+ namespace node {
30
+ let type_3: string;
31
+ export { type_3 as type };
32
+ export let anyOf: {
33
+ required: string[];
34
+ }[];
35
+ export namespace properties_1 {
36
+ namespace step {
37
+ let $ref_1: string;
38
+ export { $ref_1 as $ref };
39
+ }
40
+ namespace sequence {
41
+ let $ref_2: string;
42
+ export { $ref_2 as $ref };
43
+ }
44
+ namespace parallel {
45
+ let $ref_3: string;
46
+ export { $ref_3 as $ref };
47
+ }
48
+ namespace branch {
49
+ let $ref_4: string;
50
+ export { $ref_4 as $ref };
51
+ }
52
+ namespace map {
53
+ let $ref_5: string;
54
+ export { $ref_5 as $ref };
55
+ }
56
+ namespace pipe {
57
+ let $ref_6: string;
58
+ export { $ref_6 as $ref };
59
+ }
60
+ namespace retry {
61
+ let $ref_7: string;
62
+ export { $ref_7 as $ref };
63
+ }
64
+ namespace fallback {
65
+ let $ref_8: string;
66
+ export { $ref_8 as $ref };
67
+ }
68
+ namespace timeout {
69
+ let $ref_9: string;
70
+ export { $ref_9 as $ref };
71
+ }
72
+ namespace loop {
73
+ let $ref_10: string;
74
+ export { $ref_10 as $ref };
75
+ }
76
+ namespace compose_node {
77
+ let $ref_11: string;
78
+ export { $ref_11 as $ref };
79
+ }
80
+ namespace adversarial {
81
+ let $ref_12: string;
82
+ export { $ref_12 as $ref };
83
+ }
84
+ namespace ensemble {
85
+ let $ref_13: string;
86
+ export { $ref_13 as $ref };
87
+ }
88
+ namespace tournament {
89
+ let $ref_14: string;
90
+ export { $ref_14 as $ref };
91
+ }
92
+ namespace consensus {
93
+ let $ref_15: string;
94
+ export { $ref_15 as $ref };
95
+ }
96
+ namespace checkpoint {
97
+ let $ref_16: string;
98
+ export { $ref_16 as $ref };
99
+ }
100
+ namespace suspend {
101
+ let $ref_17: string;
102
+ export { $ref_17 as $ref };
103
+ }
104
+ namespace scope {
105
+ let $ref_18: string;
106
+ export { $ref_18 as $ref };
107
+ }
108
+ namespace ref {
109
+ let type_4: string;
110
+ export { type_4 as type };
111
+ }
112
+ }
113
+ export { properties_1 as properties };
114
+ }
115
+ namespace step_config {
116
+ let type_5: string;
117
+ export { type_5 as type };
118
+ let required_1: string[];
119
+ export { required_1 as required };
120
+ export namespace properties_2 {
121
+ namespace id {
122
+ let type_6: string;
123
+ export { type_6 as type };
124
+ }
125
+ namespace fn {
126
+ let type_7: string;
127
+ export { type_7 as type };
128
+ }
129
+ }
130
+ export { properties_2 as properties };
131
+ }
132
+ namespace sequence_config {
133
+ let type_8: string;
134
+ export { type_8 as type };
135
+ export namespace items_1 {
136
+ let $ref_19: string;
137
+ export { $ref_19 as $ref };
138
+ }
139
+ export { items_1 as items };
140
+ }
141
+ namespace parallel_config {
142
+ let type_9: string;
143
+ export { type_9 as type };
144
+ export namespace additionalProperties {
145
+ let $ref_20: string;
146
+ export { $ref_20 as $ref };
147
+ }
148
+ }
149
+ namespace branch_config {
150
+ let type_10: string;
151
+ export { type_10 as type };
152
+ let required_2: string[];
153
+ export { required_2 as required };
154
+ export namespace properties_3 {
155
+ namespace when {
156
+ let type_11: string;
157
+ export { type_11 as type };
158
+ }
159
+ namespace then {
160
+ let $ref_21: string;
161
+ export { $ref_21 as $ref };
162
+ }
163
+ namespace otherwise {
164
+ let $ref_22: string;
165
+ export { $ref_22 as $ref };
166
+ }
167
+ }
168
+ export { properties_3 as properties };
169
+ }
170
+ namespace map_config {
171
+ let type_12: string;
172
+ export { type_12 as type };
173
+ let required_3: string[];
174
+ export { required_3 as required };
175
+ export namespace properties_4 {
176
+ export namespace items_2 {
177
+ let type_13: string;
178
+ export { type_13 as type };
179
+ }
180
+ export { items_2 as items };
181
+ export namespace _do {
182
+ let $ref_23: string;
183
+ export { $ref_23 as $ref };
184
+ }
185
+ export { _do as do };
186
+ export namespace concurrency {
187
+ let type_14: string;
188
+ export { type_14 as type };
189
+ export let minimum: number;
190
+ }
191
+ }
192
+ export { properties_4 as properties };
193
+ }
194
+ namespace pipe_config {
195
+ let type_15: string;
196
+ export { type_15 as type };
197
+ let required_4: string[];
198
+ export { required_4 as required };
199
+ export namespace properties_5 {
200
+ export namespace of {
201
+ let $ref_24: string;
202
+ export { $ref_24 as $ref };
203
+ }
204
+ export namespace fn_1 {
205
+ let type_16: string;
206
+ export { type_16 as type };
207
+ }
208
+ export { fn_1 as fn };
209
+ }
210
+ export { properties_5 as properties };
211
+ }
212
+ namespace retry_config {
213
+ let type_17: string;
214
+ export { type_17 as type };
215
+ let required_5: string[];
216
+ export { required_5 as required };
217
+ export namespace properties_6 {
218
+ export namespace _do_1 {
219
+ let $ref_25: string;
220
+ export { $ref_25 as $ref };
221
+ }
222
+ export { _do_1 as do };
223
+ export namespace max_attempts {
224
+ let type_18: string;
225
+ export { type_18 as type };
226
+ let minimum_1: number;
227
+ export { minimum_1 as minimum };
228
+ }
229
+ export namespace backoff_ms {
230
+ let type_19: string;
231
+ export { type_19 as type };
232
+ let minimum_2: number;
233
+ export { minimum_2 as minimum };
234
+ }
235
+ }
236
+ export { properties_6 as properties };
237
+ }
238
+ namespace fallback_config {
239
+ let type_20: string;
240
+ export { type_20 as type };
241
+ let required_6: string[];
242
+ export { required_6 as required };
243
+ export namespace properties_7 {
244
+ namespace primary {
245
+ let $ref_26: string;
246
+ export { $ref_26 as $ref };
247
+ }
248
+ namespace backup {
249
+ let $ref_27: string;
250
+ export { $ref_27 as $ref };
251
+ }
252
+ }
253
+ export { properties_7 as properties };
254
+ }
255
+ namespace timeout_config {
256
+ let type_21: string;
257
+ export { type_21 as type };
258
+ let required_7: string[];
259
+ export { required_7 as required };
260
+ export namespace properties_8 {
261
+ export namespace _do_2 {
262
+ let $ref_28: string;
263
+ export { $ref_28 as $ref };
264
+ }
265
+ export { _do_2 as do };
266
+ export namespace ms {
267
+ let type_22: string;
268
+ export { type_22 as type };
269
+ let minimum_3: number;
270
+ export { minimum_3 as minimum };
271
+ }
272
+ }
273
+ export { properties_8 as properties };
274
+ }
275
+ namespace compose_node_config {
276
+ let type_23: string;
277
+ export { type_23 as type };
278
+ let required_8: string[];
279
+ export { required_8 as required };
280
+ export namespace properties_9 {
281
+ export namespace name {
282
+ let type_24: string;
283
+ export { type_24 as type };
284
+ export let minLength: number;
285
+ }
286
+ export namespace _do_3 {
287
+ let $ref_29: string;
288
+ export { $ref_29 as $ref };
289
+ }
290
+ export { _do_3 as do };
291
+ }
292
+ export { properties_9 as properties };
293
+ }
294
+ namespace loop_config {
295
+ let type_25: string;
296
+ export { type_25 as type };
297
+ let required_9: string[];
298
+ export { required_9 as required };
299
+ export namespace properties_10 {
300
+ export namespace name_1 {
301
+ let type_26: string;
302
+ export { type_26 as type };
303
+ let minLength_1: number;
304
+ export { minLength_1 as minLength };
305
+ }
306
+ export { name_1 as name };
307
+ export namespace init {
308
+ let type_27: string;
309
+ export { type_27 as type };
310
+ }
311
+ export namespace body {
312
+ let $ref_30: string;
313
+ export { $ref_30 as $ref };
314
+ }
315
+ export namespace guard {
316
+ let $ref_31: string;
317
+ export { $ref_31 as $ref };
318
+ }
319
+ export namespace finish {
320
+ let type_28: string;
321
+ export { type_28 as type };
322
+ }
323
+ export namespace max_rounds {
324
+ let type_29: string;
325
+ export { type_29 as type };
326
+ let minimum_4: number;
327
+ export { minimum_4 as minimum };
328
+ }
329
+ }
330
+ export { properties_10 as properties };
331
+ }
332
+ namespace adversarial_config {
333
+ let type_30: string;
334
+ export { type_30 as type };
335
+ let required_10: string[];
336
+ export { required_10 as required };
337
+ export namespace properties_11 {
338
+ export namespace build {
339
+ let $ref_32: string;
340
+ export { $ref_32 as $ref };
341
+ }
342
+ export namespace critique {
343
+ let $ref_33: string;
344
+ export { $ref_33 as $ref };
345
+ }
346
+ export namespace accept {
347
+ let type_31: string;
348
+ export { type_31 as type };
349
+ }
350
+ export namespace max_rounds_1 {
351
+ let type_32: string;
352
+ export { type_32 as type };
353
+ let minimum_5: number;
354
+ export { minimum_5 as minimum };
355
+ }
356
+ export { max_rounds_1 as max_rounds };
357
+ }
358
+ export { properties_11 as properties };
359
+ }
360
+ namespace ensemble_config {
361
+ let type_33: string;
362
+ export { type_33 as type };
363
+ let required_11: string[];
364
+ export { required_11 as required };
365
+ export namespace properties_12 {
366
+ namespace members {
367
+ let type_34: string;
368
+ export { type_34 as type };
369
+ export namespace additionalProperties_1 {
370
+ let $ref_34: string;
371
+ export { $ref_34 as $ref };
372
+ }
373
+ export { additionalProperties_1 as additionalProperties };
374
+ }
375
+ namespace score {
376
+ let type_35: string;
377
+ export { type_35 as type };
378
+ }
379
+ namespace select {
380
+ let type_36: string;
381
+ export { type_36 as type };
382
+ let _enum: string[];
383
+ export { _enum as enum };
384
+ }
385
+ }
386
+ export { properties_12 as properties };
387
+ }
388
+ namespace tournament_config {
389
+ let type_37: string;
390
+ export { type_37 as type };
391
+ let required_12: string[];
392
+ export { required_12 as required };
393
+ export namespace properties_13 {
394
+ export namespace members_1 {
395
+ let type_38: string;
396
+ export { type_38 as type };
397
+ export namespace additionalProperties_2 {
398
+ let $ref_35: string;
399
+ export { $ref_35 as $ref };
400
+ }
401
+ export { additionalProperties_2 as additionalProperties };
402
+ }
403
+ export { members_1 as members };
404
+ export namespace compare {
405
+ let type_39: string;
406
+ export { type_39 as type };
407
+ }
408
+ }
409
+ export { properties_13 as properties };
410
+ }
411
+ namespace consensus_config {
412
+ let type_40: string;
413
+ export { type_40 as type };
414
+ let required_13: string[];
415
+ export { required_13 as required };
416
+ export namespace properties_14 {
417
+ export namespace members_2 {
418
+ let type_41: string;
419
+ export { type_41 as type };
420
+ export namespace additionalProperties_3 {
421
+ let $ref_36: string;
422
+ export { $ref_36 as $ref };
423
+ }
424
+ export { additionalProperties_3 as additionalProperties };
425
+ }
426
+ export { members_2 as members };
427
+ export namespace agree {
428
+ let type_42: string;
429
+ export { type_42 as type };
430
+ }
431
+ export namespace max_rounds_2 {
432
+ let type_43: string;
433
+ export { type_43 as type };
434
+ let minimum_6: number;
435
+ export { minimum_6 as minimum };
436
+ }
437
+ export { max_rounds_2 as max_rounds };
438
+ }
439
+ export { properties_14 as properties };
440
+ }
441
+ namespace checkpoint_config {
442
+ let type_44: string;
443
+ export { type_44 as type };
444
+ let required_14: string[];
445
+ export { required_14 as required };
446
+ export namespace properties_15 {
447
+ export namespace _do_4 {
448
+ let $ref_37: string;
449
+ export { $ref_37 as $ref };
450
+ }
451
+ export { _do_4 as do };
452
+ export namespace key {
453
+ let type_45: string;
454
+ export { type_45 as type };
455
+ }
456
+ }
457
+ export { properties_15 as properties };
458
+ }
459
+ namespace suspend_config {
460
+ let type_46: string;
461
+ export { type_46 as type };
462
+ let required_15: string[];
463
+ export { required_15 as required };
464
+ export namespace properties_16 {
465
+ export namespace id_1 {
466
+ let type_47: string;
467
+ export { type_47 as type };
468
+ }
469
+ export { id_1 as id };
470
+ export namespace on {
471
+ let type_48: string;
472
+ export { type_48 as type };
473
+ }
474
+ export namespace resume_schema {
475
+ let type_49: string;
476
+ export { type_49 as type };
477
+ }
478
+ export namespace combine {
479
+ let type_50: string;
480
+ export { type_50 as type };
481
+ }
482
+ }
483
+ export { properties_16 as properties };
484
+ }
485
+ namespace scope_config {
486
+ let type_51: string;
487
+ export { type_51 as type };
488
+ export namespace items_3 {
489
+ let $ref_38: string;
490
+ export { $ref_38 as $ref };
491
+ }
492
+ export { items_3 as items };
493
+ }
494
+ namespace scope_entry {
495
+ let type_52: string;
496
+ export { type_52 as type };
497
+ export let oneOf: ({
498
+ type: string;
499
+ required: string[];
500
+ properties: {
501
+ stash: {
502
+ type: string;
503
+ };
504
+ do: {
505
+ $ref: string;
506
+ };
507
+ use?: never;
508
+ };
509
+ } | {
510
+ type: string;
511
+ required: string[];
512
+ properties: {
513
+ use: {
514
+ type: string;
515
+ items: {
516
+ type: string;
517
+ };
518
+ };
519
+ do: {
520
+ $ref: string;
521
+ };
522
+ stash?: never;
523
+ };
524
+ })[];
525
+ }
526
+ }
527
+ declare namespace __json_default_export {
528
+ export { $schema, $id, title, description, type, items, $defs };
529
+ }
530
+ //#endregion
531
+ //#region src/core/runner.d.ts
532
+ type RunOptions = {
533
+ readonly install_signal_handlers?: boolean;
534
+ readonly trajectory?: TrajectoryLogger;
535
+ readonly checkpoint_store?: CheckpointStore;
536
+ readonly resume_data?: Readonly<Record<string, unknown>>;
537
+ readonly abort?: AbortSignal;
538
+ };
539
+ type StreamingRunHandle<o> = {
540
+ readonly events: AsyncIterable<TrajectoryEvent>;
541
+ readonly result: Promise<o>;
542
+ };
543
+ /**
544
+ * Execute a flow and resolve with its final output.
545
+ */
546
+ declare function run_impl<i, o>(flow: Step<i, o>, input: i, options?: RunOptions): Promise<o>;
547
+ /**
548
+ * Execute a flow while exposing its trajectory events as an async iterable.
549
+ */
550
+ declare function run_stream<i, o>(flow: Step<i, o>, input: i, options?: RunOptions): StreamingRunHandle<o>;
551
+ /**
552
+ * The public entry point for executing a flow.
553
+ *
554
+ * Callable as `run(flow, input, options?)` for a plain result, or
555
+ * `run.stream(flow, input, options?)` for `{ events, result }`. Both share
556
+ * one implementation, so a streamed run and a plain run of the same flow
557
+ * produce identical output.
558
+ */
559
+ declare const run: typeof run_impl & {
560
+ stream: typeof run_stream;
561
+ };
562
+ //#endregion
563
+ //#region src/core/step.d.ts
564
+ /**
565
+ * Wrap a plain function as a `Step`, named or anonymous.
566
+ *
567
+ * The named form takes an explicit id (and optional descriptive `meta`); the
568
+ * anonymous form generates an `anon_<n>` id and marks the step so checkpoint
569
+ * rejects it at construction time.
570
+ */
571
+ declare function step<i, o>(id: string, fn: StepFn<i, o>, meta?: StepMetadata): Step<i, o>;
572
+ declare function step<i, o>(fn: StepFn<i, o>): Step<i, o>;
573
+ //#endregion
574
+ //#region src/core/describe.d.ts
575
+ type FlowValue = string | number | boolean | null | ReadonlyArray<FlowValue> | Readonly<{
576
+ [key: string]: FlowValue;
577
+ }> | {
578
+ readonly kind: '<fn>';
579
+ readonly name?: string;
580
+ } | {
581
+ readonly kind: '<schema>';
582
+ } | {
583
+ readonly kind: string;
584
+ readonly id: string;
585
+ };
586
+ type FlowNode = {
587
+ readonly kind: string;
588
+ readonly id: string;
589
+ readonly config?: Readonly<{
590
+ [key: string]: FlowValue;
591
+ }>;
592
+ readonly children?: ReadonlyArray<FlowNode>;
593
+ readonly meta?: StepMetadata;
594
+ };
595
+ type DescribeOptions = {
596
+ readonly strict?: boolean;
597
+ };
598
+ /**
599
+ * Public entry point: `describe(step)` for text, `describe.json(step)` for
600
+ * the `FlowNode` tree.
601
+ */
602
+ declare const describe: {
603
+ <i, o>(root: Step<i, o>, options?: DescribeOptions): string;
604
+ json: <i, o>(root: Step<i, o>, options?: DescribeOptions) => FlowNode;
605
+ };
606
+ //#endregion
607
+ //#region src/core/sequence.d.ts
608
+ type AnyStep$2 = Step<unknown, unknown>;
609
+ type FirstInput<children> = children extends readonly [Step<infer i, unknown>, ...unknown[]] ? i : unknown;
610
+ type LastOutput$1<children> = children extends readonly [...unknown[], Step<unknown, infer o>] ? o : children extends readonly [Step<unknown, infer o>] ? o : unknown;
611
+ type SequenceOptions = {
612
+ readonly name?: string;
613
+ };
614
+ /**
615
+ * Build a step that chains children, each feeding the next.
616
+ *
617
+ * Validates every element up front so a non-Step (usually a bare function)
618
+ * fails at construction with a pointed message rather than at run time.
619
+ * Checks `ctx.abort` before each child so aborts land on step boundaries.
620
+ */
621
+ declare function sequence<const children extends readonly AnyStep$2[]>(children: children, options?: SequenceOptions): Step<FirstInput<children>, LastOutput$1<children>>;
622
+ //#endregion
623
+ //#region src/core/parallel.d.ts
624
+ type AnyStep$1 = Step<unknown, unknown>;
625
+ type OutputOf<s> = s extends Step<unknown, infer o> ? o : unknown;
626
+ type ParallelOutputs<children extends Record<string, AnyStep$1>> = { [k in keyof children]: OutputOf<children[k]> };
627
+ type ParallelOptions = {
628
+ readonly name?: string;
629
+ };
630
+ /**
631
+ * Build a step that runs named children concurrently on the same input.
632
+ *
633
+ * Returns an object keyed by child name. All children settle before any
634
+ * error propagates; a `suspended_error` wins over application errors so a
635
+ * human-approval gate stays resumable instead of being masked by a sibling's
636
+ * failure.
637
+ */
638
+ declare function parallel<i, children extends Record<string, Step<i, unknown>>>(members: children, options?: ParallelOptions): Step<i, ParallelOutputs<children>>;
639
+ //#endregion
640
+ //#region src/core/branch.d.ts
641
+ type BranchConfig<i, o> = {
642
+ readonly name?: string;
643
+ readonly when: (input: i) => boolean | Promise<boolean>;
644
+ readonly then: Step<i, o>;
645
+ readonly otherwise: Step<i, o>;
646
+ };
647
+ /**
648
+ * Build a conditional-routing step.
649
+ *
650
+ * Evaluates `when(input)` at run time and dispatches to `then` or `otherwise`.
651
+ * Both branches appear as children so `describe()` renders the full tree even
652
+ * though only one branch runs.
653
+ */
654
+ declare function branch<i, o>(config: BranchConfig<i, o>): Step<i, o>;
655
+ //#endregion
656
+ //#region src/core/map.d.ts
657
+ type MapConfig<input, item, result> = {
658
+ readonly name?: string;
659
+ readonly items: (input: input) => ReadonlyArray<item> | Promise<ReadonlyArray<item>>;
660
+ readonly do: Step<item, result>;
661
+ readonly concurrency?: number;
662
+ };
663
+ /**
664
+ * Build a per-item execution step.
665
+ *
666
+ * Extracts an array via `items(input)`, runs `do` once per element through a
667
+ * bounded worker pool, and returns results in input order. The first item
668
+ * failure stops new work and propagates after in-flight items settle.
669
+ */
670
+ declare function map<input, item, result>(config: MapConfig<input, item, result>): Step<input, result[]>;
671
+ //#endregion
672
+ //#region src/core/pipe.d.ts
673
+ type PipeOptions = {
674
+ readonly name?: string;
675
+ };
676
+ /**
677
+ * Build an output-transforming step around `inner`.
678
+ *
679
+ * The argument checks reject Steps passed where functions belong: `pipe` is
680
+ * not variadic, and the early `TypeError`s point misuse at `step(fn)` or
681
+ * `sequence([...])` instead of failing obscurely at run time.
682
+ */
683
+ declare function pipe<i, a, b>(inner: Step<i, a>, fn: (value: a) => b | Promise<b>, options?: PipeOptions): Step<i, b>;
684
+ //#endregion
685
+ //#region src/core/retry.d.ts
686
+ type RetryConfig = {
687
+ readonly name?: string;
688
+ readonly max_attempts: number;
689
+ readonly backoff_ms?: number;
690
+ readonly max_delay_ms?: number;
691
+ readonly jitter?: boolean;
692
+ readonly on_error?: (err: unknown, attempt: number) => void;
693
+ };
694
+ /**
695
+ * Build a retrying step around `inner`.
696
+ *
697
+ * Runs `inner` up to `max_attempts` times with exponential backoff between
698
+ * failures. Application errors consume an attempt and fire `on_error`;
699
+ * control-flow signals propagate untouched.
700
+ */
701
+ declare function retry<i, o>(inner: Step<i, o>, config: RetryConfig): Step<i, o>;
702
+ //#endregion
703
+ //#region src/core/fallback.d.ts
704
+ type FallbackOptions<i = unknown> = {
705
+ readonly name?: string;
706
+ readonly handoff?: (input: i, err: unknown) => i;
707
+ };
708
+ /**
709
+ * Build a primary-or-backup step.
710
+ *
711
+ * Runs `primary`; on an application error runs `backup` with the same input,
712
+ * or with `handoff(input, err)` when the option is set. Control-flow signals
713
+ * propagate without triggering the backup or the handoff.
714
+ */
715
+ declare function fallback<i, o>(primary: Step<i, o>, backup: Step<i, o>, options?: FallbackOptions<i>): Step<i, o>;
716
+ //#endregion
717
+ //#region src/core/timeout.d.ts
718
+ type TimeoutOptions = {
719
+ readonly name?: string;
720
+ };
721
+ /**
722
+ * Build a deadline-bounded step around `inner`.
723
+ *
724
+ * Races the inner dispatch against a timer that aborts the composed signal
725
+ * with `timeout_error`. The `timed_out` flag distinguishes timer expiry from
726
+ * a parent abort so the right error propagates.
727
+ */
728
+ declare function timeout<i, o>(inner: Step<i, o>, ms: number, options?: TimeoutOptions): Step<i, o>;
729
+ //#endregion
730
+ //#region src/core/loop.d.ts
731
+ type LoopGuardResult<state> = {
732
+ readonly stop: boolean;
733
+ readonly state: state;
734
+ };
735
+ type LoopOutcome = {
736
+ readonly converged: boolean;
737
+ readonly rounds: number;
738
+ };
739
+ type LoopConfig<i, state, o> = {
740
+ readonly name?: string;
741
+ readonly init: (input: i) => state;
742
+ readonly body: Step<state, state>;
743
+ readonly guard?: Step<state, LoopGuardResult<state>>;
744
+ readonly finish: (state: state, outcome: LoopOutcome) => o;
745
+ readonly max_rounds: number;
746
+ };
747
+ /**
748
+ * Build a bounded iteration step with carry-state.
749
+ *
750
+ * Threads `state` through up to `max_rounds` runs of `body`, lets the
751
+ * optional `guard` stop early, then projects the final state through
752
+ * `finish`. `finish` also receives `{ converged, rounds }`, so a projection
753
+ * can tell a converged run from an exhausted one without the loop wrapping
754
+ * its output.
755
+ */
756
+ declare function loop<i, state, o>(config: LoopConfig<i, state, o>): Step<i, o>;
757
+ //#endregion
758
+ //#region src/core/compose.d.ts
759
+ /**
760
+ * Wrap `inner` in a named composite step.
761
+ *
762
+ * The step's `kind` is always `'compose'`; `name` becomes the
763
+ * `display_name` used as the span label. Throws a `TypeError` when `name`
764
+ * is not a non-empty string, catching the mistake at construction time.
765
+ */
766
+ declare function compose<i, o>(name: string, inner: Step<i, o>): Step<i, o>;
767
+ //#endregion
768
+ //#region src/core/checkpoint.d.ts
769
+ type CheckpointConfig<i> = {
770
+ readonly name?: string;
771
+ readonly key: string | ((input: i) => string);
772
+ };
773
+ /**
774
+ * Wrap `inner` with persist-and-resume behavior keyed by `config.key`.
775
+ *
776
+ * `key` is a fixed string or a function of the input. Without a
777
+ * `checkpoint_store` on the run context, the wrapper runs `inner` directly.
778
+ * A stored `null` or `undefined` counts as a miss, so those values are
779
+ * re-computed rather than replayed. Throws at construction time when `inner`
780
+ * is anonymous.
781
+ */
782
+ declare function checkpoint<i, o>(inner: Step<i, o>, config: CheckpointConfig<i>): Step<i, o>;
783
+ //#endregion
784
+ //#region src/core/suspend.d.ts
785
+ type SuspendConfig<i, o, resume> = {
786
+ readonly id: string;
787
+ readonly name?: string;
788
+ readonly on: (input: i, ctx: RunContext) => Promise<void> | void;
789
+ readonly resume_schema: AnySchema<resume>;
790
+ readonly combine: (input: i, resume: resume, ctx: RunContext) => Promise<o> | o | Step<unknown, o>;
791
+ };
792
+ /**
793
+ * Build a human-in-the-loop pause step.
794
+ *
795
+ * First run fires the `on` side effect and throws `suspended_error`; a resume
796
+ * run validates `resume_data[id]` against `resume_schema` and feeds it to
797
+ * `combine`. The step's id is the user-supplied suspend id so resume data can
798
+ * be addressed to it.
799
+ */
800
+ declare function suspend<i, o, resume>(config: SuspendConfig<i, o, resume>): Step<i, o>;
801
+ //#endregion
802
+ //#region src/core/scope.d.ts
803
+ type AnyStep = Step<unknown, unknown>;
804
+ type LastOutput<children> = children extends readonly [...unknown[], Step<unknown, infer o>] ? o : children extends readonly [Step<unknown, infer o>] ? o : unknown;
805
+ type ScopeOptions = {
806
+ readonly name?: string;
807
+ };
808
+ type StashOptions = {
809
+ readonly name?: string;
810
+ };
811
+ type UseOptions = {
812
+ readonly name?: string;
813
+ };
814
+ /**
815
+ * Build a step that runs children in sequence under a fresh state map.
816
+ *
817
+ * The local map is seeded from the parent state (inner scopes read outer
818
+ * values) and registered so `stash`/`use` inside recognize it; writes stay
819
+ * local to this scope. Outputs chain like `sequence`.
820
+ */
821
+ declare function scope<const children extends readonly AnyStep[]>(children: children, options?: ScopeOptions): Step<unknown, LastOutput<children>>;
822
+ /**
823
+ * Build a step that stores its source's output in scope state at `key`.
824
+ *
825
+ * Passes the value through unchanged so it composes mid-chain. Throws when
826
+ * run outside a `scope`.
827
+ */
828
+ declare function stash<i, v>(key: string, source: Step<i, v>, options?: StashOptions): Step<i, v>;
829
+ /**
830
+ * Build a step that projects named scope values into a function call.
831
+ *
832
+ * Reads `keys` from scope state (missing keys project as `undefined`) and
833
+ * invokes `fn(projection, input, ctx)`. Throws when run outside a `scope`.
834
+ */
835
+ declare function use<const keys extends readonly string[], i, o>(keys: keys, fn: (state: { [k in keys[number]]: unknown }, input: i, ctx: RunContext) => Promise<o> | o, options?: UseOptions): Step<i, o>;
836
+ //#endregion
837
+ //#region src/core/errors.d.ts
838
+ declare class timeout_error extends Error {
839
+ readonly kind: "timeout_error";
840
+ readonly timeout_ms: number;
841
+ constructor(message: string, timeout_ms: number);
842
+ }
843
+ declare class suspended_error extends Error {
844
+ readonly kind: "suspended_error";
845
+ readonly suspend_id: string;
846
+ readonly payload: unknown;
847
+ constructor(suspend_id: string, payload: unknown, message?: string);
848
+ }
849
+ declare class resume_validation_error extends Error {
850
+ readonly kind: "resume_validation_error";
851
+ readonly issues: ReadonlyArray<SchemaIssue>;
852
+ constructor(message: string, issues: ReadonlyArray<SchemaIssue>);
853
+ }
854
+ declare class describe_cycle_error extends Error {
855
+ readonly kind: "describe_cycle_error";
856
+ readonly step_id: string;
857
+ constructor(step_id: string, message?: string);
858
+ }
859
+ declare class aborted_error extends Error {
860
+ readonly kind: "aborted_error";
861
+ readonly reason?: unknown;
862
+ readonly step_index: number;
863
+ readonly tool_call_in_flight?: {
864
+ id: string;
865
+ name: string;
866
+ };
867
+ constructor(message?: string, metadata?: {
868
+ reason?: unknown;
869
+ step_index?: number;
870
+ tool_call_in_flight?: {
871
+ id: string;
872
+ name: string;
873
+ };
874
+ });
875
+ }
876
+ //#endregion
877
+ //#region src/core/step_kinds.d.ts
878
+ /**
879
+ * Closed registry of every `Step.kind` produced by the composition layer.
880
+ *
881
+ * Studio (and any other consumer that needs to enumerate primitives: palette,
882
+ * docs, code generation) can rely on this being the exhaustive set. New
883
+ * primitives must add their kind here. The `step_kinds_cover_runner` contract
884
+ * test in `step_kinds.test.ts` asserts every dispatch handler corresponds to a
885
+ * kind listed here.
886
+ */
887
+ declare const STEP_KINDS: readonly ["step", "sequence", "parallel", "branch", "map", "pipe", "retry", "fallback", "timeout", "loop", "compose", "adversarial", "ensemble", "tournament", "consensus", "checkpoint", "suspend", "scope", "stash", "use"];
888
+ type StepKind = (typeof STEP_KINDS)[number];
889
+ /**
890
+ * Check whether a value is one of the registered `Step.kind` strings.
891
+ */
892
+ declare function is_step_kind(value: unknown): value is StepKind;
893
+ //#endregion
894
+ //#region src/core/trajectory.d.ts
895
+ /**
896
+ * Wire-format guards for trajectory events.
897
+ *
898
+ * `TrajectoryEvent` (in `types.ts`) is the loose internal type — any code that
899
+ * calls `trajectory.record(event)` or `start_span(name, meta)` produces values
900
+ * conforming to it. This file defines the *narrower* shapes that the studio
901
+ * (and any other downstream consumer) can recognize in the wire stream:
902
+ *
903
+ * span_start — composer span open
904
+ * span_end — composer span close
905
+ * emit — user-emitted event from inside a step (ctx.emit)
906
+ * <other> — anything else, recognized by `is_custom_trajectory_event`,
907
+ * which only requires a string `kind`
908
+ *
909
+ * `parse_trajectory_event` is the wire gate, and it is deliberately permissive:
910
+ * a value is a trajectory event iff it is a non-array object carrying a string
911
+ * `kind`. The well-known guards layered on top are *recognizers*, not gates — a
912
+ * `{ kind: 'span_start' }` line missing its `span_id` is still a valid event on
913
+ * the wire, just not a `SpanStartEvent`. Anything stricter would have a viewer
914
+ * drop lines a newer producer emits, which is the opposite of what a
915
+ * forward-compatible wire format is for. `is_custom_trajectory_event` therefore
916
+ * answers `true` for well-known kinds too: it is the fallback shape, not a
917
+ * fifth disjoint case.
918
+ *
919
+ * Extra fields (`run_id`, `id`, provider-specific metadata) are neither
920
+ * required nor stripped: a successful parse hands the value straight back, so a
921
+ * parse / re-serialize round trip is lossless.
922
+ */
923
+ type SpanStartEvent = {
924
+ readonly kind: 'span_start';
925
+ readonly span_id: string;
926
+ readonly name: string;
927
+ } & {
928
+ readonly [key: string]: unknown;
929
+ };
930
+ type SpanEndEvent = {
931
+ readonly kind: 'span_end';
932
+ readonly span_id: string;
933
+ } & {
934
+ readonly [key: string]: unknown;
935
+ };
936
+ type EmitEvent = {
937
+ readonly kind: 'emit';
938
+ } & {
939
+ readonly [key: string]: unknown;
940
+ };
941
+ type CustomTrajectoryEvent = {
942
+ readonly kind: string;
943
+ } & {
944
+ readonly [key: string]: unknown;
945
+ };
946
+ type ParsedTrajectoryEvent = SpanStartEvent | SpanEndEvent | EmitEvent | CustomTrajectoryEvent;
947
+ type TrajectoryParseResult = {
948
+ readonly success: true;
949
+ readonly data: ParsedTrajectoryEvent;
950
+ } | {
951
+ readonly success: false;
952
+ readonly error: Error;
953
+ };
954
+ /**
955
+ * The wire gate: a non-array object carrying a string `kind`.
956
+ *
957
+ * True for every well-known kind as well, since `custom` is the fallback shape
958
+ * rather than a disjoint case.
959
+ */
960
+ declare function is_custom_trajectory_event(value: unknown): value is CustomTrajectoryEvent;
961
+ /** A composer span open: both `span_id` and `name` must be present as strings. */
962
+ declare function is_span_start_event(value: unknown): value is SpanStartEvent;
963
+ /** A composer span close: `span_id` must be present as a string, `name` need not be. */
964
+ declare function is_span_end_event(value: unknown): value is SpanEndEvent;
965
+ /** A `ctx.emit` event: the kind alone identifies it, the payload is the caller's. */
966
+ declare function is_emit_event(value: unknown): value is EmitEvent;
967
+ /**
968
+ * Parse one wire value into a trajectory event, `safeParse`-shaped.
969
+ *
970
+ * On success `data` is the value itself, not a copy, so nothing on the line is
971
+ * dropped or reordered on the way through.
972
+ */
973
+ declare function parse_trajectory_event(value: unknown): TrajectoryParseResult;
974
+ //#endregion
975
+ //#region src/engine/create_engine.d.ts
976
+ /**
977
+ * Validate `config` and construct an `Engine`.
978
+ *
979
+ * Provider entries are validated synchronously via `build_provider_adapters`.
980
+ * A `generate` call that names a provider absent from `config.providers`
981
+ * still throws `provider_not_configured_error`, but only at call time.
982
+ */
983
+ declare function create_engine(config: EngineConfig): Engine;
984
+ //#endregion
985
+ //#region src/engine/errors.d.ts
986
+ declare class rate_limit_error extends Error {
987
+ readonly kind: "rate_limit_error";
988
+ readonly retry_after_ms: number | undefined;
989
+ readonly attempts: number;
990
+ readonly status: number | undefined;
991
+ constructor(message: string, metadata?: {
992
+ retry_after_ms?: number;
993
+ attempts?: number;
994
+ status?: number;
995
+ });
996
+ }
997
+ declare class provider_error extends Error {
998
+ readonly kind: "provider_error";
999
+ readonly status: number | undefined;
1000
+ readonly body: string | undefined;
1001
+ readonly cause_kind: 'provider_5xx' | 'network' | 'unknown' | undefined;
1002
+ constructor(message: string, metadata?: {
1003
+ status?: number;
1004
+ body?: string;
1005
+ cause_kind?: 'provider_5xx' | 'network' | 'unknown';
1006
+ });
1007
+ }
1008
+ declare class schema_validation_error extends Error {
1009
+ readonly kind: "schema_validation_error";
1010
+ readonly schema_issues: ReadonlyArray<SchemaIssue>;
1011
+ readonly raw_text: string;
1012
+ constructor(message: string, schema_issues: ReadonlyArray<SchemaIssue>, raw_text: string);
1013
+ }
1014
+ declare class tool_error extends Error {
1015
+ readonly kind: "tool_error";
1016
+ readonly tool_name: string;
1017
+ readonly tool_call_id: string;
1018
+ readonly cause: unknown;
1019
+ constructor(message: string, metadata: {
1020
+ tool_name: string;
1021
+ tool_call_id: string;
1022
+ cause: unknown;
1023
+ });
1024
+ }
1025
+ declare class tool_approval_denied_error extends Error {
1026
+ readonly kind: "tool_approval_denied_error";
1027
+ readonly tool_name: string;
1028
+ readonly step_index: number;
1029
+ readonly tool_call_id: string;
1030
+ constructor(message: string, metadata: {
1031
+ tool_name: string;
1032
+ step_index: number;
1033
+ tool_call_id: string;
1034
+ });
1035
+ }
1036
+ declare class model_required_error extends Error {
1037
+ readonly kind: "model_required_error";
1038
+ constructor(message?: string);
1039
+ }
1040
+ declare class provider_not_configured_error extends Error {
1041
+ readonly kind: "provider_not_configured_error";
1042
+ readonly provider: string;
1043
+ constructor(provider: string);
1044
+ }
1045
+ declare class engine_config_error extends Error {
1046
+ readonly kind: "engine_config_error";
1047
+ readonly provider: string | undefined;
1048
+ constructor(message: string, provider?: string);
1049
+ }
1050
+ declare class on_chunk_error extends Error {
1051
+ readonly kind: "on_chunk_error";
1052
+ readonly cause: unknown;
1053
+ constructor(message: string, cause: unknown);
1054
+ }
1055
+ declare class provider_capability_error extends Error {
1056
+ readonly kind: "provider_capability_error";
1057
+ readonly provider: string;
1058
+ readonly capability: string;
1059
+ constructor(provider: string, capability: string, detail?: string);
1060
+ }
1061
+ declare class engine_disposed_error extends Error {
1062
+ readonly kind: "engine_disposed_error";
1063
+ constructor(message?: string);
1064
+ }
1065
+ type ClaudeCliErrorReason = 'binary_not_found' | 'auth_missing' | 'auth_expired' | 'api_key_missing' | 'startup_timeout' | 'stall_timeout' | 'no_result_event' | 'result_error' | 'subprocess_exit' | 'sandbox_unavailable' | 'engine_disposed' | 'parse_error';
1066
+ declare class claude_cli_error extends Error {
1067
+ readonly kind: "claude_cli_error";
1068
+ readonly reason: ClaudeCliErrorReason;
1069
+ readonly status: number | undefined;
1070
+ readonly stderr_snippet: string | undefined;
1071
+ constructor(reason: ClaudeCliErrorReason, message: string, metadata?: {
1072
+ status?: number;
1073
+ stderr_snippet?: string;
1074
+ });
1075
+ }
1076
+ declare class provider_auth_error extends Error {
1077
+ readonly kind: "provider_auth_error";
1078
+ readonly provider: string;
1079
+ readonly refresh_command: string | undefined;
1080
+ constructor(provider: string, message: string, metadata?: {
1081
+ refresh_command?: string;
1082
+ });
1083
+ }
1084
+ /**
1085
+ * A generate call that set a schema finished for a reason other than 'stop'
1086
+ * (content_filter, length, max_steps, tool_calls), so no schema-validated
1087
+ * value exists and validation was never attempted. Carries the raw model text
1088
+ * and the last provider-reported payload, so a guardrail trace or other
1089
+ * block detail stays reachable from the catch. Distinct from
1090
+ * schema_validation_error, which covers a response that completed normally
1091
+ * and then failed validation after its repair attempts ran out.
1092
+ */
1093
+ declare class incomplete_generation_error extends Error {
1094
+ readonly kind: "incomplete_generation_error";
1095
+ readonly finish_reason: FinishReason;
1096
+ readonly raw_text: string;
1097
+ readonly provider_reported: Record<string, unknown> | undefined;
1098
+ constructor(finish_reason: FinishReason, raw_text: string, provider_reported?: Record<string, unknown>);
1099
+ }
1100
+ //#endregion
5
1101
  //#region src/composites/adversarial.d.ts
6
1102
  type AdversarialBuildInput<input, candidate> = {
7
1103
  readonly input: input;
@@ -268,6 +1364,21 @@ type TournamentResult<o> = {
268
1364
  */
269
1365
  declare function tournament<i, o>(config: TournamentConfig<i, o>): Step<i, TournamentResult<o>>;
270
1366
  //#endregion
1367
+ //#region src/composites/errors.d.ts
1368
+ /**
1369
+ * Typed errors for the composites layer.
1370
+ *
1371
+ * Listed alongside src/core/errors.ts, src/engine/errors.ts, and
1372
+ * src/mcp/errors.ts in the `no-class` rule ignores: `instanceof` branching is
1373
+ * how a caller tells a benched flow's usage error apart from a case failure.
1374
+ */
1375
+ declare class bench_suspend_error extends Error {
1376
+ readonly kind: "bench_suspend_error";
1377
+ readonly case_id: string;
1378
+ readonly suspend_id: string;
1379
+ constructor(case_id: string, suspend_id: string, message?: string);
1380
+ }
1381
+ //#endregion
271
1382
  //#region src/composites/bench.d.ts
272
1383
  type Score = {
273
1384
  readonly score: number;
@@ -315,6 +1426,7 @@ type BenchOptions = {
315
1426
  readonly live_url?: string;
316
1427
  readonly run_id?: string;
317
1428
  readonly install_signal_handlers?: boolean;
1429
+ readonly abort?: AbortSignal;
318
1430
  };
319
1431
  /**
320
1432
  * Runs `flow` against every case, judges each output, and produces a
@@ -334,6 +1446,13 @@ type BenchOptions = {
334
1446
  * judge spans land in the case's trajectory file (or push). A judge that
335
1447
  * throws or returns undefined abstains: the entry is omitted from
336
1448
  * `case.scores` and the case does not contribute to that judge's mean.
1449
+ *
1450
+ * Control-flow signals are not case failures and never reach a `CaseResult`.
1451
+ * `abort` forwards to every per-case `run` and is re-checked before each case
1452
+ * is claimed, so cancelling rejects the whole bench rather than returning a
1453
+ * report that silently covers fewer cases than it was given. A
1454
+ * `suspended_error` from an approval gate rejects with `bench_suspend_error`:
1455
+ * `bench` has no resume path, so a suspend is a usage error, not a zero score.
337
1456
  */
338
1457
  declare function bench<I, O, S = Score>(flow: Step<I, O>, cases: ReadonlyArray<BenchCase<I>>, judges: Record<string, Judge<I, O, S>>, options?: BenchOptions): Promise<BenchReport<I, O, S>>;
339
1458
  /**
@@ -441,7 +1560,7 @@ type ModelCallConfig<T = string> = {
441
1560
  readonly id?: string;
442
1561
  readonly system?: string;
443
1562
  readonly tools?: ReadonlyArray<Tool>;
444
- readonly schema?: z.ZodType<T>;
1563
+ readonly schema?: ToolSchema<T>;
445
1564
  readonly effort?: EffortLevel;
446
1565
  readonly max_steps?: number;
447
1566
  readonly provider_options?: Record<string, unknown>;
@@ -532,5 +1651,5 @@ declare function start_viewer(options?: StartViewerOptions): Promise<ViewerHandl
532
1651
  */
533
1652
  declare function run_viewer_cli(argv: readonly string[]): Promise<void>;
534
1653
  //#endregion
535
- export { type AdversarialBuildInput, type AdversarialConfig, type AdversarialCritiqueResult, type AdversarialResult, type AiSdkProviderAdapter, type AiSdkTelemetrySettings, type AssistantContentPart, type BenchCase, type BenchOptions, type BenchReport, type BenchSummary, type BracketRecord, type Candidate, type CaseResult, type CheckpointStore, type ConsensusConfig, type ConsensusResult, type CostBreakdown, type CustomTrajectoryEvent, type DescribeOptions, type EffortLevel, type EffortTranslation, type EmitEvent, type Engine, type EngineConfig, type EngineDefaults, type EnsembleConfig, type EnsembleResult, type EnsembleStepConfig, type EnsembleStepResult, type ExternalAgentAdapter, type FinishReason, type FlowNode, type FlowValue, type GenerateOptions, type GenerateResult, type HistoryEntry, type ImproveBudget, type ImproveConfig, type ImproveResult, type ImproveRoundInput, type Improvement, type Judge, type JudgeArgs, type JudgeLlmConfig, type JudgeWithFn, type LearnConfig, type LearnInput, type LearnResult, type Lesson, type LoopConfig, type LoopGuardResult, type LoopResult, type Message, type ModelCallConfig, type ModelCallInput, type NativeProviderAdapter, type ParsedTrajectoryEvent, type PerCaseDelta, type PrepareStepContext, type PrepareStepHook, type PrepareStepResult, type Pricing, type PricingTable, type ProviderAdapter, type ProviderCapability, type ProviderConfigMap, type ProviderFactory, type ProviderInit, type ProviderTransport, type RawProviderUsage, type RegressionCompareOptions, type RegressionDelta, type RegressionReport, type ResolvedModel, type RetryFailureKind, type RetryPolicy, type RunContext, STEP_KINDS, type Score, type ScoredCandidate, type SpanEndEvent, type SpanStartEvent, type StartViewerOptions, type Step, type StepKind, type StepMetadata, type StepRecord, type StreamChunk, type Tool, type ToolApprovalHandler, type ToolApprovalRequest, type ToolCallRecord, type ToolExecContext, type TournamentConfig, type TournamentResult, type TrajectoryEvent, type TrajectoryLogger, type TrajectorySource, type TurnRequest, type TurnResult, type UsageTotals, type UserContentPart, type ViewerHandle, aborted_error, adversarial, bench, branch, checkpoint, claude_cli_error, compose, consensus, create_engine, custom_event_schema, default_normalize_usage, describe, describe_cycle_error, emit_event_schema, engine_config_error, engine_disposed_error, ensemble, ensemble_step, fallback, __json_default_export as flow_schema, forward_standard_env, improve, incomplete_generation_error, is_step_kind, judge_equals, judge_llm, judge_with, learn, loop, map, model_call, model_required_error, normalize_score, on_chunk_error, parallel, pipe, provider_auth_error, provider_capability_error, provider_error, provider_not_configured_error, rate_limit_error, read_baseline, regression_compare, resume_validation_error, retry, run, run_viewer_cli, schema_validation_error, scope, sequence, span_end_event_schema, span_start_event_schema, start_viewer, stash, step, suspend, suspended_error, timeout, timeout_error, tool_approval_denied_error, tool_error, tournament, trajectory_event_schema, use, write_baseline };
1654
+ export { type AdversarialBuildInput, type AdversarialConfig, type AdversarialCritiqueResult, type AdversarialResult, type AiSdkProviderAdapter, type AiSdkTelemetrySettings, type AssistantContentPart, type BenchCase, type BenchOptions, type BenchReport, type BenchSummary, type BracketRecord, type Candidate, type CaseResult, type CheckpointStore, type ConsensusConfig, type ConsensusResult, type CostBreakdown, type CustomTrajectoryEvent, type DescribeOptions, type EffortLevel, type EffortTranslation, type EmitEvent, type Engine, type EngineConfig, type EngineDefaults, type EnsembleConfig, type EnsembleResult, type EnsembleStepConfig, type EnsembleStepResult, type ExternalAgentAdapter, type FinishReason, type FlowNode, type FlowValue, type GenerateOptions, type GenerateResult, type HistoryEntry, type ImproveBudget, type ImproveConfig, type ImproveResult, type ImproveRoundInput, type Improvement, type Judge, type JudgeArgs, type JudgeLlmConfig, type JudgeWithFn, type LearnConfig, type LearnInput, type LearnResult, type Lesson, type LoopConfig, type LoopGuardResult, type LoopOutcome, type Message, type ModelCallConfig, type ModelCallInput, type NativeProviderAdapter, type ParsedTrajectoryEvent, type PerCaseDelta, type PrepareStepContext, type PrepareStepHook, type PrepareStepResult, type Pricing, type PricingTable, type ProviderAdapter, type ProviderCapability, type ProviderConfigMap, type ProviderFactory, type ProviderInit, type ProviderTransport, type RawProviderUsage, type RegressionCompareOptions, type RegressionDelta, type RegressionReport, type ResolvedModel, type RetryFailureKind, type RetryPolicy, type RunContext, STEP_KINDS, type Score, type ScoredCandidate, type SpanEndEvent, type SpanStartEvent, type StartViewerOptions, type Step, type StepKind, type StepMetadata, type StepRecord, type StreamChunk, type Tool, type ToolApprovalHandler, type ToolApprovalRequest, type ToolCallRecord, type ToolExecContext, type TournamentConfig, type TournamentResult, type TrajectoryEvent, type TrajectoryLogger, type TrajectoryParseResult, type TrajectorySource, type TurnRequest, type TurnResult, type UsageTotals, type UserContentPart, type ViewerHandle, aborted_error, adversarial, bench, bench_suspend_error, branch, checkpoint, claude_cli_error, compose, consensus, create_engine, default_normalize_usage, describe, describe_cycle_error, engine_config_error, engine_disposed_error, ensemble, ensemble_step, fallback, __json_default_export as flow_schema, forward_standard_env, improve, incomplete_generation_error, is_custom_trajectory_event, is_emit_event, is_span_end_event, is_span_start_event, is_step_kind, judge_equals, judge_llm, judge_with, learn, loop, map, model_call, model_required_error, normalize_score, on_chunk_error, parallel, parse_trajectory_event, pipe, provider_auth_error, provider_capability_error, provider_error, provider_not_configured_error, rate_limit_error, read_baseline, regression_compare, resume_validation_error, retry, run, run_viewer_cli, schema_validation_error, scope, sequence, start_viewer, stash, step, suspend, suspended_error, timeout, timeout_error, tool_approval_denied_error, tool_error, tournament, use, write_baseline };
536
1655
  //# sourceMappingURL=index.d.ts.map