@basou/core 0.29.0 → 0.31.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
@@ -2,6 +2,13 @@ import { z } from 'zod';
2
2
  import { SimpleGit } from 'simple-git';
3
3
  import { ChildProcess } from 'node:child_process';
4
4
 
5
+ /**
6
+ * Predicate deciding whether a candidate executable is reachable on PATH.
7
+ * Exposed as a parameter on the per-tool `resolve*Command` helpers so tests can
8
+ * substitute a deterministic mock; production callers rely on {@link isOnPath}.
9
+ */
10
+ type CommandLookup = (command: string) => Promise<boolean>;
11
+
5
12
  /**
6
13
  * Static metadata identifying the claude-code adapter as the session source.
7
14
  * Consumed by the CLI orchestration when populating `session.yaml.source`
@@ -13,13 +20,6 @@ declare const claudeCodeAdapterMetadata: {
13
20
  readonly kind: "claude-code-adapter";
14
21
  readonly version: "0.1.0";
15
22
  };
16
- /**
17
- * Lookup predicate used by {@link resolveClaudeCodeCommand} to decide
18
- * whether a candidate executable is reachable on PATH. Exposed as a
19
- * parameter so tests can substitute a deterministic mock; production
20
- * callers should omit it and rely on the default `which`-based lookup.
21
- */
22
- type CommandLookup = (command: string) => Promise<boolean>;
23
23
  /**
24
24
  * Resolve the Claude Code CLI executable name. Tries `claude-code` first
25
25
  * and falls back to `claude`; the first candidate found on PATH wins.
@@ -63,6 +63,8 @@ type BuildStopHookCommandOptions = {
63
63
  cliEntry: string;
64
64
  /** Register the blocking (opt-in enforcement) form. */
65
65
  block?: boolean;
66
+ /** Enable the opt-in review gate (adds `--require-review`). */
67
+ requireReview?: boolean;
66
68
  /** Override the file-edit threshold passed to `hook stop`. */
67
69
  minEdits?: number;
68
70
  };
@@ -122,8 +124,8 @@ declare function findBasouStopHookCommand(settings: unknown): string | null;
122
124
  * unrecognized top-level keys so preservation is not silent.
123
125
  */
124
126
  declare const ManifestSchema: z.ZodObject<{
125
- schema_version: z.ZodLiteral<"0.1.0">;
126
- basou_version: z.ZodLiteral<"0.1.0">;
127
+ schema_version: z.ZodString;
128
+ basou_version: z.ZodString;
127
129
  workspace: z.ZodObject<{
128
130
  id: z.ZodString & z.ZodType<`ws_${string}`, string, z.core.$ZodTypeInternals<`ws_${string}`, string>>;
129
131
  name: z.ZodString;
@@ -134,7 +136,6 @@ declare const ManifestSchema: z.ZodObject<{
134
136
  project: z.ZodObject<{
135
137
  name: z.ZodOptional<z.ZodString>;
136
138
  description: z.ZodOptional<z.ZodString>;
137
- repository_url: z.ZodOptional<z.ZodNullable<z.ZodString>>;
138
139
  }, z.core.$loose>;
139
140
  capabilities: z.ZodObject<{
140
141
  enabled: z.ZodArray<z.ZodString>;
@@ -219,6 +220,7 @@ declare const SessionInnerImportSchema: z.ZodObject<{
219
220
  "claude-code-adapter": "claude-code-adapter";
220
221
  import: "import";
221
222
  "claude-code-import": "claude-code-import";
223
+ "codex-adapter": "codex-adapter";
222
224
  "codex-import": "codex-import";
223
225
  human: "human";
224
226
  terminal: "terminal";
@@ -257,11 +259,11 @@ declare const SessionInnerImportSchema: z.ZodObject<{
257
259
  active_intervals: z.ZodOptional<z.ZodArray<z.ZodObject<{
258
260
  start: z.ZodString;
259
261
  end: z.ZodString;
260
- }, z.core.$strip>>>;
262
+ }, z.core.$loose>>>;
261
263
  active_gap_cap_ms: z.ZodOptional<z.ZodNumber>;
262
264
  active_time_method: z.ZodOptional<z.ZodString>;
263
265
  machine_active_time_ms: z.ZodOptional<z.ZodNumber>;
264
- }, z.core.$strip>>;
266
+ }, z.core.$loose>>;
265
267
  integrity: z.ZodOptional<z.ZodObject<{
266
268
  head_hash: z.ZodString;
267
269
  event_count: z.ZodNumber;
@@ -284,6 +286,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
284
286
  "claude-code-adapter": "claude-code-adapter";
285
287
  import: "import";
286
288
  "claude-code-import": "claude-code-import";
289
+ "codex-adapter": "codex-adapter";
287
290
  "codex-import": "codex-import";
288
291
  human: "human";
289
292
  terminal: "terminal";
@@ -322,18 +325,18 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
322
325
  active_intervals: z.ZodOptional<z.ZodArray<z.ZodObject<{
323
326
  start: z.ZodString;
324
327
  end: z.ZodString;
325
- }, z.core.$strip>>>;
328
+ }, z.core.$loose>>>;
326
329
  active_gap_cap_ms: z.ZodOptional<z.ZodNumber>;
327
330
  active_time_method: z.ZodOptional<z.ZodString>;
328
331
  machine_active_time_ms: z.ZodOptional<z.ZodNumber>;
329
- }, z.core.$strip>>;
332
+ }, z.core.$loose>>;
330
333
  integrity: z.ZodOptional<z.ZodObject<{
331
334
  head_hash: z.ZodString;
332
335
  event_count: z.ZodNumber;
333
336
  }, z.core.$strict>>;
334
337
  }, z.core.$strict>;
335
338
  events: z.ZodArray<z.ZodDiscriminatedUnion<[z.ZodObject<{
336
- schema_version: z.ZodLiteral<"0.1.0">;
339
+ schema_version: z.ZodString;
337
340
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
338
341
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
339
342
  occurred_at: z.ZodString;
@@ -341,7 +344,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
341
344
  prev_hash: z.ZodOptional<z.ZodString>;
342
345
  type: z.ZodLiteral<"session_started">;
343
346
  }, z.core.$strip>, z.ZodObject<{
344
- schema_version: z.ZodLiteral<"0.1.0">;
347
+ schema_version: z.ZodString;
345
348
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
346
349
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
347
350
  occurred_at: z.ZodString;
@@ -350,7 +353,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
350
353
  type: z.ZodLiteral<"session_ended">;
351
354
  exit_code: z.ZodOptional<z.ZodNumber>;
352
355
  }, z.core.$strip>, z.ZodObject<{
353
- schema_version: z.ZodLiteral<"0.1.0">;
356
+ schema_version: z.ZodString;
354
357
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
355
358
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
356
359
  occurred_at: z.ZodString;
@@ -360,7 +363,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
360
363
  from: z.ZodString;
361
364
  to: z.ZodString;
362
365
  }, z.core.$strip>, z.ZodObject<{
363
- schema_version: z.ZodLiteral<"0.1.0">;
366
+ schema_version: z.ZodString;
364
367
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
365
368
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
366
369
  occurred_at: z.ZodString;
@@ -381,7 +384,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
381
384
  reason: z.ZodString;
382
385
  status: z.ZodLiteral<"pending">;
383
386
  }, z.core.$strip>, z.ZodObject<{
384
- schema_version: z.ZodLiteral<"0.1.0">;
387
+ schema_version: z.ZodString;
385
388
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
386
389
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
387
390
  occurred_at: z.ZodString;
@@ -392,7 +395,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
392
395
  resolver: z.ZodOptional<z.ZodString>;
393
396
  note: z.ZodOptional<z.ZodNullable<z.ZodString>>;
394
397
  }, z.core.$strip>, z.ZodObject<{
395
- schema_version: z.ZodLiteral<"0.1.0">;
398
+ schema_version: z.ZodString;
396
399
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
397
400
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
398
401
  occurred_at: z.ZodString;
@@ -403,7 +406,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
403
406
  resolver: z.ZodOptional<z.ZodString>;
404
407
  reason: z.ZodString;
405
408
  }, z.core.$strip>, z.ZodObject<{
406
- schema_version: z.ZodLiteral<"0.1.0">;
409
+ schema_version: z.ZodString;
407
410
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
408
411
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
409
412
  occurred_at: z.ZodString;
@@ -412,7 +415,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
412
415
  type: z.ZodLiteral<"approval_expired">;
413
416
  approval_id: z.ZodString & z.ZodType<`appr_${string}`, string, z.core.$ZodTypeInternals<`appr_${string}`, string>>;
414
417
  }, z.core.$strip>, z.ZodObject<{
415
- schema_version: z.ZodLiteral<"0.1.0">;
418
+ schema_version: z.ZodString;
416
419
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
417
420
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
418
421
  occurred_at: z.ZodString;
@@ -427,7 +430,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
427
430
  received_signal: z.ZodOptional<z.ZodNullable<z.ZodString>>;
428
431
  duration_ms: z.ZodNumber;
429
432
  }, z.core.$strip>, z.ZodObject<{
430
- schema_version: z.ZodLiteral<"0.1.0">;
433
+ schema_version: z.ZodString;
431
434
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
432
435
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
433
436
  occurred_at: z.ZodString;
@@ -443,7 +446,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
443
446
  ahead: z.ZodOptional<z.ZodNumber>;
444
447
  behind: z.ZodOptional<z.ZodNumber>;
445
448
  }, z.core.$strip>, z.ZodObject<{
446
- schema_version: z.ZodLiteral<"0.1.0">;
449
+ schema_version: z.ZodString;
447
450
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
448
451
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
449
452
  occurred_at: z.ZodString;
@@ -459,7 +462,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
459
462
  }>;
460
463
  old_path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
461
464
  }, z.core.$strip>, z.ZodObject<{
462
- schema_version: z.ZodLiteral<"0.1.0">;
465
+ schema_version: z.ZodString;
463
466
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
464
467
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
465
468
  occurred_at: z.ZodString;
@@ -478,7 +481,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
478
481
  track: "track";
479
482
  }>>;
480
483
  }, z.core.$strip>, z.ZodObject<{
481
- schema_version: z.ZodLiteral<"0.1.0">;
484
+ schema_version: z.ZodString;
482
485
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
483
486
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
484
487
  occurred_at: z.ZodString;
@@ -489,7 +492,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
489
492
  reason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
490
493
  superseded_by: z.ZodOptional<z.ZodString & z.ZodType<`decision_${string}`, string, z.core.$ZodTypeInternals<`decision_${string}`, string>>>;
491
494
  }, z.core.$strip>, z.ZodObject<{
492
- schema_version: z.ZodLiteral<"0.1.0">;
495
+ schema_version: z.ZodString;
493
496
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
494
497
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
495
498
  occurred_at: z.ZodString;
@@ -499,7 +502,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
499
502
  task_id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
500
503
  title: z.ZodString;
501
504
  }, z.core.$strip>, z.ZodObject<{
502
- schema_version: z.ZodLiteral<"0.1.0">;
505
+ schema_version: z.ZodString;
503
506
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
504
507
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
505
508
  occurred_at: z.ZodString;
@@ -510,7 +513,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
510
513
  from: z.ZodString;
511
514
  to: z.ZodString;
512
515
  }, z.core.$strip>, z.ZodObject<{
513
- schema_version: z.ZodLiteral<"0.1.0">;
516
+ schema_version: z.ZodString;
514
517
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
515
518
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
516
519
  occurred_at: z.ZodString;
@@ -522,7 +525,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
522
525
  created_in_session_replacement: z.ZodDefault<z.ZodNullable<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
523
526
  removed_linked_sessions: z.ZodDefault<z.ZodArray<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
524
527
  }, z.core.$strict>, z.ZodObject<{
525
- schema_version: z.ZodLiteral<"0.1.0">;
528
+ schema_version: z.ZodString;
526
529
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
527
530
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
528
531
  occurred_at: z.ZodString;
@@ -534,7 +537,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
534
537
  removed_linked_sessions: z.ZodDefault<z.ZodArray<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
535
538
  final_count: z.ZodOptional<z.ZodNumber>;
536
539
  }, z.core.$strict>, z.ZodObject<{
537
- schema_version: z.ZodLiteral<"0.1.0">;
540
+ schema_version: z.ZodString;
538
541
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
539
542
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
540
543
  occurred_at: z.ZodString;
@@ -544,7 +547,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
544
547
  task_id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
545
548
  title: z.ZodString;
546
549
  }, z.core.$strict>, z.ZodObject<{
547
- schema_version: z.ZodLiteral<"0.1.0">;
550
+ schema_version: z.ZodString;
548
551
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
549
552
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
550
553
  occurred_at: z.ZodString;
@@ -554,7 +557,7 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
554
557
  task_id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
555
558
  title: z.ZodString;
556
559
  }, z.core.$strict>, z.ZodObject<{
557
- schema_version: z.ZodLiteral<"0.1.0">;
560
+ schema_version: z.ZodString;
558
561
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
559
562
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
560
563
  occurred_at: z.ZodString;
@@ -567,7 +570,40 @@ declare const SessionImportPayloadSchema: z.ZodObject<{
567
570
  next_step: "next_step";
568
571
  }>>;
569
572
  }, z.core.$strip>, z.ZodObject<{
570
- schema_version: z.ZodLiteral<"0.1.0">;
573
+ schema_version: z.ZodString;
574
+ id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
575
+ session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
576
+ occurred_at: z.ZodString;
577
+ source: z.ZodString;
578
+ prev_hash: z.ZodOptional<z.ZodString>;
579
+ type: z.ZodLiteral<"review_recorded">;
580
+ reviewer: z.ZodString;
581
+ target: z.ZodString;
582
+ verdict: z.ZodOptional<z.ZodEnum<{
583
+ pass: "pass";
584
+ "needs-attention": "needs-attention";
585
+ fail: "fail";
586
+ }>>;
587
+ findings: z.ZodOptional<z.ZodArray<z.ZodObject<{
588
+ title: z.ZodString;
589
+ severity: z.ZodOptional<z.ZodEnum<{
590
+ low: "low";
591
+ medium: "medium";
592
+ high: "high";
593
+ }>>;
594
+ location: z.ZodOptional<z.ZodString>;
595
+ summary: z.ZodOptional<z.ZodString>;
596
+ }, z.core.$strip>>>;
597
+ blocked: z.ZodOptional<z.ZodArray<z.ZodObject<{
598
+ title: z.ZodString;
599
+ reason: z.ZodEnum<{
600
+ "spec-deviation": "spec-deviation";
601
+ "design-reversal": "design-reversal";
602
+ }>;
603
+ why: z.ZodOptional<z.ZodString>;
604
+ }, z.core.$strip>>>;
605
+ }, z.core.$strip>, z.ZodObject<{
606
+ schema_version: z.ZodString;
571
607
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
572
608
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
573
609
  occurred_at: z.ZodString;
@@ -682,6 +718,31 @@ type StopHookEvaluationInput = {
682
718
  };
683
719
  /** Why the hook stayed silent (useful for tests and `--json` introspection). */
684
720
  type StopHookSilentReason = "stop_hook_active" | "not_substantive" | "already_captured";
721
+ /**
722
+ * Why the review gate stayed silent. The gate fires only when a SHIP act, a
723
+ * substantive-code edit, and the ABSENCE of a review record all hold; each
724
+ * reason names the first of those three that did not.
725
+ * - `stop_hook_active`: loop guard — a continuation turn never fires.
726
+ * - `no_ship_act`: nothing was shipped this turn (review is a pre-ship act, so
727
+ * a turn that did not push / open / merge owes no review).
728
+ * - `not_substantive_code`: shipped, but fewer than `minEdits` file edits.
729
+ * - `already_reviewed`: a `basou review record` ran this session.
730
+ */
731
+ type ReviewGateSilentReason = "stop_hook_active" | "no_ship_act" | "not_substantive_code" | "already_reviewed";
732
+ /**
733
+ * The review gate's verdict, computed INDEPENDENTLY of the capture gate in the
734
+ * same transcript pass: a session can have captured its decisions yet still owe
735
+ * a review (it shipped code without recording one), and vice versa. Returned
736
+ * alongside the capture verdict; no caller renders it yet — a follow-on slice
737
+ * will have the CLI compose it with the capture signal into the nudge / block.
738
+ */
739
+ type ReviewGateResult = {
740
+ fires: false;
741
+ reason: ReviewGateSilentReason;
742
+ } | {
743
+ fires: true;
744
+ additionalContext: string;
745
+ };
685
746
  type StopHookCounts = {
686
747
  /** Bash tool uses (informational — does NOT drive the trigger). */
687
748
  commandCount: number;
@@ -693,9 +754,11 @@ type StopHookCounts = {
693
754
  type StopHookEvaluation = ({
694
755
  kind: "silent";
695
756
  reason: StopHookSilentReason;
757
+ review: ReviewGateResult;
696
758
  } & StopHookCounts) | ({
697
759
  kind: "nudge";
698
760
  additionalContext: string;
761
+ review: ReviewGateResult;
699
762
  } & StopHookCounts);
700
763
  /**
701
764
  * Decide whether a finished turn warrants a non-blocking capture nudge.
@@ -717,9 +780,42 @@ type StopHookEvaluation = ({
717
780
  * - no capture verb (`basou decision capture` / `decision record` / `note`)
718
781
  * was run this session, so a session that already recorded its intent is
719
782
  * left alone.
783
+ *
784
+ * It ALSO computes a second, independent verdict: the {@link ReviewGateResult}
785
+ * (whether a substantive-code session shipped — push / PR / merge — without
786
+ * recording a review). The two are computed in one transcript pass and returned
787
+ * together; the CLI composes them. The review verdict is purely additive here —
788
+ * the capture `kind` / `additionalContext` / `reason` are byte-identical to
789
+ * before, so consumers that read only the capture signal are unaffected.
720
790
  */
721
791
  declare function evaluateStopHook(input: StopHookEvaluationInput): StopHookEvaluation;
722
792
 
793
+ /** Alias kept for API symmetry with the claude-code adapter's `CommandLookup`. */
794
+ type CodexCommandLookup = CommandLookup;
795
+ /**
796
+ * Static metadata identifying a live `basou run codex` session source. The twin
797
+ * of {@link import("../claude-code/claude-code-adapter.js").claudeCodeAdapterMetadata};
798
+ * `kind` is part of the wire format defined by the session schema
799
+ * (`SessionSourceKindSchema`), so do not change it without a coordinated schema
800
+ * migration. Distinct from `codex-import` (the after-the-fact rollout importer).
801
+ */
802
+ declare const codexAdapterMetadata: {
803
+ readonly kind: "codex-adapter";
804
+ readonly version: "0.1.0";
805
+ };
806
+ /**
807
+ * Resolve the Codex CLI executable name. Only `codex` is a candidate (unlike
808
+ * claude-code's `claude-code`/`claude` pair, Codex ships a single binary name).
809
+ *
810
+ * Throws a fixed-message Error when it is not reachable, so callers can present
811
+ * a single user-facing prompt to install the CLI.
812
+ *
813
+ * @throws Error("Codex CLI not found in PATH. Install codex first.")
814
+ */
815
+ declare function resolveCodexCommand(lookup?: CommandLookup): Promise<{
816
+ command: string;
817
+ }>;
818
+
723
819
  /**
724
820
  * The `source` string stamped on every event derived from an OpenAI Codex
725
821
  * native rollout log, and the matching session `source.kind`.
@@ -820,7 +916,7 @@ type ApprovalStatus = z.infer<typeof ApprovalStatusSchema>;
820
916
  * event variant.
821
917
  */
822
918
  declare const ApprovalSchema: z.ZodObject<{
823
- schema_version: z.ZodLiteral<"0.1.0">;
919
+ schema_version: z.ZodString;
824
920
  id: z.ZodString & z.ZodType<`appr_${string}`, string, z.core.$ZodTypeInternals<`appr_${string}`, string>>;
825
921
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
826
922
  created_at: z.ZodString;
@@ -845,7 +941,7 @@ declare const ApprovalSchema: z.ZodObject<{
845
941
  resolved_at: z.ZodDefault<z.ZodNullable<z.ZodString>>;
846
942
  note: z.ZodDefault<z.ZodNullable<z.ZodString>>;
847
943
  rejection_reason: z.ZodDefault<z.ZodNullable<z.ZodString>>;
848
- }, z.core.$strip>;
944
+ }, z.core.$loose>;
849
945
  /** Inferred runtime type for {@link ApprovalSchema}. */
850
946
  type Approval = z.infer<typeof ApprovalSchema>;
851
947
 
@@ -952,7 +1048,7 @@ declare function enumerateApprovals(paths: BasouPaths): Promise<{
952
1048
  declare function isLazyExpired(approval: Approval, now: Date): boolean;
953
1049
 
954
1050
  declare const SessionStartedEventSchema: z.ZodObject<{
955
- schema_version: z.ZodLiteral<"0.1.0">;
1051
+ schema_version: z.ZodString;
956
1052
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
957
1053
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
958
1054
  occurred_at: z.ZodString;
@@ -961,7 +1057,7 @@ declare const SessionStartedEventSchema: z.ZodObject<{
961
1057
  type: z.ZodLiteral<"session_started">;
962
1058
  }, z.core.$strip>;
963
1059
  declare const SessionEndedEventSchema: z.ZodObject<{
964
- schema_version: z.ZodLiteral<"0.1.0">;
1060
+ schema_version: z.ZodString;
965
1061
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
966
1062
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
967
1063
  occurred_at: z.ZodString;
@@ -971,7 +1067,7 @@ declare const SessionEndedEventSchema: z.ZodObject<{
971
1067
  exit_code: z.ZodOptional<z.ZodNumber>;
972
1068
  }, z.core.$strip>;
973
1069
  declare const SessionStatusChangedEventSchema: z.ZodObject<{
974
- schema_version: z.ZodLiteral<"0.1.0">;
1070
+ schema_version: z.ZodString;
975
1071
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
976
1072
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
977
1073
  occurred_at: z.ZodString;
@@ -982,7 +1078,7 @@ declare const SessionStatusChangedEventSchema: z.ZodObject<{
982
1078
  to: z.ZodString;
983
1079
  }, z.core.$strip>;
984
1080
  declare const ApprovalRequestedEventSchema: z.ZodObject<{
985
- schema_version: z.ZodLiteral<"0.1.0">;
1081
+ schema_version: z.ZodString;
986
1082
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
987
1083
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
988
1084
  occurred_at: z.ZodString;
@@ -1004,7 +1100,7 @@ declare const ApprovalRequestedEventSchema: z.ZodObject<{
1004
1100
  status: z.ZodLiteral<"pending">;
1005
1101
  }, z.core.$strip>;
1006
1102
  declare const ApprovalApprovedEventSchema: z.ZodObject<{
1007
- schema_version: z.ZodLiteral<"0.1.0">;
1103
+ schema_version: z.ZodString;
1008
1104
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1009
1105
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1010
1106
  occurred_at: z.ZodString;
@@ -1016,7 +1112,7 @@ declare const ApprovalApprovedEventSchema: z.ZodObject<{
1016
1112
  note: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1017
1113
  }, z.core.$strip>;
1018
1114
  declare const ApprovalRejectedEventSchema: z.ZodObject<{
1019
- schema_version: z.ZodLiteral<"0.1.0">;
1115
+ schema_version: z.ZodString;
1020
1116
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1021
1117
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1022
1118
  occurred_at: z.ZodString;
@@ -1028,7 +1124,7 @@ declare const ApprovalRejectedEventSchema: z.ZodObject<{
1028
1124
  reason: z.ZodString;
1029
1125
  }, z.core.$strip>;
1030
1126
  declare const ApprovalExpiredEventSchema: z.ZodObject<{
1031
- schema_version: z.ZodLiteral<"0.1.0">;
1127
+ schema_version: z.ZodString;
1032
1128
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1033
1129
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1034
1130
  occurred_at: z.ZodString;
@@ -1038,7 +1134,7 @@ declare const ApprovalExpiredEventSchema: z.ZodObject<{
1038
1134
  approval_id: z.ZodString & z.ZodType<`appr_${string}`, string, z.core.$ZodTypeInternals<`appr_${string}`, string>>;
1039
1135
  }, z.core.$strip>;
1040
1136
  declare const CommandExecutedEventSchema: z.ZodObject<{
1041
- schema_version: z.ZodLiteral<"0.1.0">;
1137
+ schema_version: z.ZodString;
1042
1138
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1043
1139
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1044
1140
  occurred_at: z.ZodString;
@@ -1054,7 +1150,7 @@ declare const CommandExecutedEventSchema: z.ZodObject<{
1054
1150
  duration_ms: z.ZodNumber;
1055
1151
  }, z.core.$strip>;
1056
1152
  declare const GitSnapshotEventSchema: z.ZodObject<{
1057
- schema_version: z.ZodLiteral<"0.1.0">;
1153
+ schema_version: z.ZodString;
1058
1154
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1059
1155
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1060
1156
  occurred_at: z.ZodString;
@@ -1071,7 +1167,7 @@ declare const GitSnapshotEventSchema: z.ZodObject<{
1071
1167
  behind: z.ZodOptional<z.ZodNumber>;
1072
1168
  }, z.core.$strip>;
1073
1169
  declare const FileChangedEventSchema: z.ZodObject<{
1074
- schema_version: z.ZodLiteral<"0.1.0">;
1170
+ schema_version: z.ZodString;
1075
1171
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1076
1172
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1077
1173
  occurred_at: z.ZodString;
@@ -1088,7 +1184,7 @@ declare const FileChangedEventSchema: z.ZodObject<{
1088
1184
  old_path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1089
1185
  }, z.core.$strip>;
1090
1186
  declare const DecisionRecordedEventSchema: z.ZodObject<{
1091
- schema_version: z.ZodLiteral<"0.1.0">;
1187
+ schema_version: z.ZodString;
1092
1188
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1093
1189
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1094
1190
  occurred_at: z.ZodString;
@@ -1108,7 +1204,7 @@ declare const DecisionRecordedEventSchema: z.ZodObject<{
1108
1204
  }>>;
1109
1205
  }, z.core.$strip>;
1110
1206
  declare const TaskCreatedEventSchema: z.ZodObject<{
1111
- schema_version: z.ZodLiteral<"0.1.0">;
1207
+ schema_version: z.ZodString;
1112
1208
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1113
1209
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1114
1210
  occurred_at: z.ZodString;
@@ -1119,7 +1215,7 @@ declare const TaskCreatedEventSchema: z.ZodObject<{
1119
1215
  title: z.ZodString;
1120
1216
  }, z.core.$strip>;
1121
1217
  declare const TaskStatusChangedEventSchema: z.ZodObject<{
1122
- schema_version: z.ZodLiteral<"0.1.0">;
1218
+ schema_version: z.ZodString;
1123
1219
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1124
1220
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1125
1221
  occurred_at: z.ZodString;
@@ -1131,7 +1227,7 @@ declare const TaskStatusChangedEventSchema: z.ZodObject<{
1131
1227
  to: z.ZodString;
1132
1228
  }, z.core.$strip>;
1133
1229
  declare const TaskReconciledEventSchema: z.ZodObject<{
1134
- schema_version: z.ZodLiteral<"0.1.0">;
1230
+ schema_version: z.ZodString;
1135
1231
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1136
1232
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1137
1233
  occurred_at: z.ZodString;
@@ -1144,7 +1240,7 @@ declare const TaskReconciledEventSchema: z.ZodObject<{
1144
1240
  removed_linked_sessions: z.ZodDefault<z.ZodArray<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
1145
1241
  }, z.core.$strict>;
1146
1242
  declare const TaskLinkageRefreshedEventSchema: z.ZodObject<{
1147
- schema_version: z.ZodLiteral<"0.1.0">;
1243
+ schema_version: z.ZodString;
1148
1244
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1149
1245
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1150
1246
  occurred_at: z.ZodString;
@@ -1157,7 +1253,7 @@ declare const TaskLinkageRefreshedEventSchema: z.ZodObject<{
1157
1253
  final_count: z.ZodOptional<z.ZodNumber>;
1158
1254
  }, z.core.$strict>;
1159
1255
  declare const TaskDeletedEventSchema: z.ZodObject<{
1160
- schema_version: z.ZodLiteral<"0.1.0">;
1256
+ schema_version: z.ZodString;
1161
1257
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1162
1258
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1163
1259
  occurred_at: z.ZodString;
@@ -1168,7 +1264,7 @@ declare const TaskDeletedEventSchema: z.ZodObject<{
1168
1264
  title: z.ZodString;
1169
1265
  }, z.core.$strict>;
1170
1266
  declare const TaskArchivedEventSchema: z.ZodObject<{
1171
- schema_version: z.ZodLiteral<"0.1.0">;
1267
+ schema_version: z.ZodString;
1172
1268
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1173
1269
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1174
1270
  occurred_at: z.ZodString;
@@ -1179,7 +1275,7 @@ declare const TaskArchivedEventSchema: z.ZodObject<{
1179
1275
  title: z.ZodString;
1180
1276
  }, z.core.$strict>;
1181
1277
  declare const NoteAddedEventSchema: z.ZodObject<{
1182
- schema_version: z.ZodLiteral<"0.1.0">;
1278
+ schema_version: z.ZodString;
1183
1279
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1184
1280
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1185
1281
  occurred_at: z.ZodString;
@@ -1192,8 +1288,60 @@ declare const NoteAddedEventSchema: z.ZodObject<{
1192
1288
  next_step: "next_step";
1193
1289
  }>>;
1194
1290
  }, z.core.$strip>;
1291
+ declare const ReviewFindingSchema: z.ZodObject<{
1292
+ title: z.ZodString;
1293
+ severity: z.ZodOptional<z.ZodEnum<{
1294
+ low: "low";
1295
+ medium: "medium";
1296
+ high: "high";
1297
+ }>>;
1298
+ location: z.ZodOptional<z.ZodString>;
1299
+ summary: z.ZodOptional<z.ZodString>;
1300
+ }, z.core.$strip>;
1301
+ declare const ReviewBlockedSchema: z.ZodObject<{
1302
+ title: z.ZodString;
1303
+ reason: z.ZodEnum<{
1304
+ "spec-deviation": "spec-deviation";
1305
+ "design-reversal": "design-reversal";
1306
+ }>;
1307
+ why: z.ZodOptional<z.ZodString>;
1308
+ }, z.core.$strip>;
1309
+ declare const ReviewRecordedEventSchema: z.ZodObject<{
1310
+ schema_version: z.ZodString;
1311
+ id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1312
+ session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1313
+ occurred_at: z.ZodString;
1314
+ source: z.ZodString;
1315
+ prev_hash: z.ZodOptional<z.ZodString>;
1316
+ type: z.ZodLiteral<"review_recorded">;
1317
+ reviewer: z.ZodString;
1318
+ target: z.ZodString;
1319
+ verdict: z.ZodOptional<z.ZodEnum<{
1320
+ pass: "pass";
1321
+ "needs-attention": "needs-attention";
1322
+ fail: "fail";
1323
+ }>>;
1324
+ findings: z.ZodOptional<z.ZodArray<z.ZodObject<{
1325
+ title: z.ZodString;
1326
+ severity: z.ZodOptional<z.ZodEnum<{
1327
+ low: "low";
1328
+ medium: "medium";
1329
+ high: "high";
1330
+ }>>;
1331
+ location: z.ZodOptional<z.ZodString>;
1332
+ summary: z.ZodOptional<z.ZodString>;
1333
+ }, z.core.$strip>>>;
1334
+ blocked: z.ZodOptional<z.ZodArray<z.ZodObject<{
1335
+ title: z.ZodString;
1336
+ reason: z.ZodEnum<{
1337
+ "spec-deviation": "spec-deviation";
1338
+ "design-reversal": "design-reversal";
1339
+ }>;
1340
+ why: z.ZodOptional<z.ZodString>;
1341
+ }, z.core.$strip>>>;
1342
+ }, z.core.$strip>;
1195
1343
  declare const AdapterOutputEventSchema: z.ZodObject<{
1196
- schema_version: z.ZodLiteral<"0.1.0">;
1344
+ schema_version: z.ZodString;
1197
1345
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1198
1346
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1199
1347
  occurred_at: z.ZodString;
@@ -1214,7 +1362,7 @@ declare const AdapterOutputEventSchema: z.ZodObject<{
1214
1362
  * variant is uniquely strict to bar raw adapter bodies.
1215
1363
  */
1216
1364
  declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1217
- schema_version: z.ZodLiteral<"0.1.0">;
1365
+ schema_version: z.ZodString;
1218
1366
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1219
1367
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1220
1368
  occurred_at: z.ZodString;
@@ -1222,7 +1370,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1222
1370
  prev_hash: z.ZodOptional<z.ZodString>;
1223
1371
  type: z.ZodLiteral<"session_started">;
1224
1372
  }, z.core.$strip>, z.ZodObject<{
1225
- schema_version: z.ZodLiteral<"0.1.0">;
1373
+ schema_version: z.ZodString;
1226
1374
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1227
1375
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1228
1376
  occurred_at: z.ZodString;
@@ -1231,7 +1379,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1231
1379
  type: z.ZodLiteral<"session_ended">;
1232
1380
  exit_code: z.ZodOptional<z.ZodNumber>;
1233
1381
  }, z.core.$strip>, z.ZodObject<{
1234
- schema_version: z.ZodLiteral<"0.1.0">;
1382
+ schema_version: z.ZodString;
1235
1383
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1236
1384
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1237
1385
  occurred_at: z.ZodString;
@@ -1241,7 +1389,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1241
1389
  from: z.ZodString;
1242
1390
  to: z.ZodString;
1243
1391
  }, z.core.$strip>, z.ZodObject<{
1244
- schema_version: z.ZodLiteral<"0.1.0">;
1392
+ schema_version: z.ZodString;
1245
1393
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1246
1394
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1247
1395
  occurred_at: z.ZodString;
@@ -1262,7 +1410,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1262
1410
  reason: z.ZodString;
1263
1411
  status: z.ZodLiteral<"pending">;
1264
1412
  }, z.core.$strip>, z.ZodObject<{
1265
- schema_version: z.ZodLiteral<"0.1.0">;
1413
+ schema_version: z.ZodString;
1266
1414
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1267
1415
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1268
1416
  occurred_at: z.ZodString;
@@ -1273,7 +1421,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1273
1421
  resolver: z.ZodOptional<z.ZodString>;
1274
1422
  note: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1275
1423
  }, z.core.$strip>, z.ZodObject<{
1276
- schema_version: z.ZodLiteral<"0.1.0">;
1424
+ schema_version: z.ZodString;
1277
1425
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1278
1426
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1279
1427
  occurred_at: z.ZodString;
@@ -1284,7 +1432,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1284
1432
  resolver: z.ZodOptional<z.ZodString>;
1285
1433
  reason: z.ZodString;
1286
1434
  }, z.core.$strip>, z.ZodObject<{
1287
- schema_version: z.ZodLiteral<"0.1.0">;
1435
+ schema_version: z.ZodString;
1288
1436
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1289
1437
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1290
1438
  occurred_at: z.ZodString;
@@ -1293,7 +1441,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1293
1441
  type: z.ZodLiteral<"approval_expired">;
1294
1442
  approval_id: z.ZodString & z.ZodType<`appr_${string}`, string, z.core.$ZodTypeInternals<`appr_${string}`, string>>;
1295
1443
  }, z.core.$strip>, z.ZodObject<{
1296
- schema_version: z.ZodLiteral<"0.1.0">;
1444
+ schema_version: z.ZodString;
1297
1445
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1298
1446
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1299
1447
  occurred_at: z.ZodString;
@@ -1308,7 +1456,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1308
1456
  received_signal: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1309
1457
  duration_ms: z.ZodNumber;
1310
1458
  }, z.core.$strip>, z.ZodObject<{
1311
- schema_version: z.ZodLiteral<"0.1.0">;
1459
+ schema_version: z.ZodString;
1312
1460
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1313
1461
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1314
1462
  occurred_at: z.ZodString;
@@ -1324,7 +1472,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1324
1472
  ahead: z.ZodOptional<z.ZodNumber>;
1325
1473
  behind: z.ZodOptional<z.ZodNumber>;
1326
1474
  }, z.core.$strip>, z.ZodObject<{
1327
- schema_version: z.ZodLiteral<"0.1.0">;
1475
+ schema_version: z.ZodString;
1328
1476
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1329
1477
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1330
1478
  occurred_at: z.ZodString;
@@ -1340,7 +1488,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1340
1488
  }>;
1341
1489
  old_path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1342
1490
  }, z.core.$strip>, z.ZodObject<{
1343
- schema_version: z.ZodLiteral<"0.1.0">;
1491
+ schema_version: z.ZodString;
1344
1492
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1345
1493
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1346
1494
  occurred_at: z.ZodString;
@@ -1359,7 +1507,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1359
1507
  track: "track";
1360
1508
  }>>;
1361
1509
  }, z.core.$strip>, z.ZodObject<{
1362
- schema_version: z.ZodLiteral<"0.1.0">;
1510
+ schema_version: z.ZodString;
1363
1511
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1364
1512
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1365
1513
  occurred_at: z.ZodString;
@@ -1370,7 +1518,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1370
1518
  reason: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1371
1519
  superseded_by: z.ZodOptional<z.ZodString & z.ZodType<`decision_${string}`, string, z.core.$ZodTypeInternals<`decision_${string}`, string>>>;
1372
1520
  }, z.core.$strip>, z.ZodObject<{
1373
- schema_version: z.ZodLiteral<"0.1.0">;
1521
+ schema_version: z.ZodString;
1374
1522
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1375
1523
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1376
1524
  occurred_at: z.ZodString;
@@ -1380,7 +1528,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1380
1528
  task_id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
1381
1529
  title: z.ZodString;
1382
1530
  }, z.core.$strip>, z.ZodObject<{
1383
- schema_version: z.ZodLiteral<"0.1.0">;
1531
+ schema_version: z.ZodString;
1384
1532
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1385
1533
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1386
1534
  occurred_at: z.ZodString;
@@ -1391,7 +1539,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1391
1539
  from: z.ZodString;
1392
1540
  to: z.ZodString;
1393
1541
  }, z.core.$strip>, z.ZodObject<{
1394
- schema_version: z.ZodLiteral<"0.1.0">;
1542
+ schema_version: z.ZodString;
1395
1543
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1396
1544
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1397
1545
  occurred_at: z.ZodString;
@@ -1403,7 +1551,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1403
1551
  created_in_session_replacement: z.ZodDefault<z.ZodNullable<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
1404
1552
  removed_linked_sessions: z.ZodDefault<z.ZodArray<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
1405
1553
  }, z.core.$strict>, z.ZodObject<{
1406
- schema_version: z.ZodLiteral<"0.1.0">;
1554
+ schema_version: z.ZodString;
1407
1555
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1408
1556
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1409
1557
  occurred_at: z.ZodString;
@@ -1415,7 +1563,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1415
1563
  removed_linked_sessions: z.ZodDefault<z.ZodArray<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
1416
1564
  final_count: z.ZodOptional<z.ZodNumber>;
1417
1565
  }, z.core.$strict>, z.ZodObject<{
1418
- schema_version: z.ZodLiteral<"0.1.0">;
1566
+ schema_version: z.ZodString;
1419
1567
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1420
1568
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1421
1569
  occurred_at: z.ZodString;
@@ -1425,7 +1573,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1425
1573
  task_id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
1426
1574
  title: z.ZodString;
1427
1575
  }, z.core.$strict>, z.ZodObject<{
1428
- schema_version: z.ZodLiteral<"0.1.0">;
1576
+ schema_version: z.ZodString;
1429
1577
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1430
1578
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1431
1579
  occurred_at: z.ZodString;
@@ -1435,7 +1583,7 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1435
1583
  task_id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
1436
1584
  title: z.ZodString;
1437
1585
  }, z.core.$strict>, z.ZodObject<{
1438
- schema_version: z.ZodLiteral<"0.1.0">;
1586
+ schema_version: z.ZodString;
1439
1587
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1440
1588
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1441
1589
  occurred_at: z.ZodString;
@@ -1448,7 +1596,40 @@ declare const EventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1448
1596
  next_step: "next_step";
1449
1597
  }>>;
1450
1598
  }, z.core.$strip>, z.ZodObject<{
1451
- schema_version: z.ZodLiteral<"0.1.0">;
1599
+ schema_version: z.ZodString;
1600
+ id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1601
+ session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1602
+ occurred_at: z.ZodString;
1603
+ source: z.ZodString;
1604
+ prev_hash: z.ZodOptional<z.ZodString>;
1605
+ type: z.ZodLiteral<"review_recorded">;
1606
+ reviewer: z.ZodString;
1607
+ target: z.ZodString;
1608
+ verdict: z.ZodOptional<z.ZodEnum<{
1609
+ pass: "pass";
1610
+ "needs-attention": "needs-attention";
1611
+ fail: "fail";
1612
+ }>>;
1613
+ findings: z.ZodOptional<z.ZodArray<z.ZodObject<{
1614
+ title: z.ZodString;
1615
+ severity: z.ZodOptional<z.ZodEnum<{
1616
+ low: "low";
1617
+ medium: "medium";
1618
+ high: "high";
1619
+ }>>;
1620
+ location: z.ZodOptional<z.ZodString>;
1621
+ summary: z.ZodOptional<z.ZodString>;
1622
+ }, z.core.$strip>>>;
1623
+ blocked: z.ZodOptional<z.ZodArray<z.ZodObject<{
1624
+ title: z.ZodString;
1625
+ reason: z.ZodEnum<{
1626
+ "spec-deviation": "spec-deviation";
1627
+ "design-reversal": "design-reversal";
1628
+ }>;
1629
+ why: z.ZodOptional<z.ZodString>;
1630
+ }, z.core.$strip>>>;
1631
+ }, z.core.$strip>, z.ZodObject<{
1632
+ schema_version: z.ZodString;
1452
1633
  id: z.ZodString & z.ZodType<`evt_${string}`, string, z.core.$ZodTypeInternals<`evt_${string}`, string>>;
1453
1634
  session_id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1454
1635
  occurred_at: z.ZodString;
@@ -1501,6 +1682,12 @@ type TaskDeletedEvent = z.infer<typeof TaskDeletedEventSchema>;
1501
1682
  type TaskArchivedEvent = z.infer<typeof TaskArchivedEventSchema>;
1502
1683
  /** Narrowed runtime type for the `note_added` event variant. */
1503
1684
  type NoteAddedEvent = z.infer<typeof NoteAddedEventSchema>;
1685
+ /** Narrowed runtime type for the `review_recorded` event variant. */
1686
+ type ReviewRecordedEvent = z.infer<typeof ReviewRecordedEventSchema>;
1687
+ /** One finding surfaced by a `review_recorded` event. */
1688
+ type ReviewFinding = z.infer<typeof ReviewFindingSchema>;
1689
+ /** One blocked finding (spec-deviation / design-reversal) of a `review_recorded` event. */
1690
+ type ReviewBlocked = z.infer<typeof ReviewBlockedSchema>;
1504
1691
  /** Narrowed runtime type for the `adapter_output` event variant (.strict()). */
1505
1692
  type AdapterOutputEvent = z.infer<typeof AdapterOutputEventSchema>;
1506
1693
 
@@ -1579,6 +1766,7 @@ type SessionStatus = z.infer<typeof SessionStatusSchema>;
1579
1766
  * - `claude-code-adapter` — a live `basou run claude-code` process wrap.
1580
1767
  * - `claude-code-import` — derived after the fact from a Claude Code native
1581
1768
  * transcript (`~/.claude/projects/*.jsonl`) by `basou import claude-code`.
1769
+ * - `codex-adapter` — a live `basou run codex` process wrap.
1582
1770
  * - `codex-import` — derived after the fact from an OpenAI Codex native
1583
1771
  * rollout log (date-partitioned `~/.codex/sessions`) by `basou import codex`.
1584
1772
  * - `import` — a round-trip of a Basou-format export (`basou session import`).
@@ -1588,6 +1776,7 @@ declare const SessionSourceKindSchema: z.ZodEnum<{
1588
1776
  "claude-code-adapter": "claude-code-adapter";
1589
1777
  import: "import";
1590
1778
  "claude-code-import": "claude-code-import";
1779
+ "codex-adapter": "codex-adapter";
1591
1780
  "codex-import": "codex-import";
1592
1781
  human: "human";
1593
1782
  terminal: "terminal";
@@ -1632,11 +1821,11 @@ declare const SessionMetricsSchema: z.ZodObject<{
1632
1821
  active_intervals: z.ZodOptional<z.ZodArray<z.ZodObject<{
1633
1822
  start: z.ZodString;
1634
1823
  end: z.ZodString;
1635
- }, z.core.$strip>>>;
1824
+ }, z.core.$loose>>>;
1636
1825
  active_gap_cap_ms: z.ZodOptional<z.ZodNumber>;
1637
1826
  active_time_method: z.ZodOptional<z.ZodString>;
1638
1827
  machine_active_time_ms: z.ZodOptional<z.ZodNumber>;
1639
- }, z.core.$strip>;
1828
+ }, z.core.$loose>;
1640
1829
  /** Inferred runtime type for {@link SessionMetricsSchema}. */
1641
1830
  type SessionMetrics = z.infer<typeof SessionMetricsSchema>;
1642
1831
  /**
@@ -1661,7 +1850,7 @@ type SessionIntegrity = z.infer<typeof SessionIntegritySchema>;
1661
1850
  * `session:` key.
1662
1851
  */
1663
1852
  declare const SessionSchema: z.ZodObject<{
1664
- schema_version: z.ZodLiteral<"0.1.0">;
1853
+ schema_version: z.ZodString;
1665
1854
  session: z.ZodObject<{
1666
1855
  id: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
1667
1856
  label: z.ZodOptional<z.ZodString>;
@@ -1672,6 +1861,7 @@ declare const SessionSchema: z.ZodObject<{
1672
1861
  "claude-code-adapter": "claude-code-adapter";
1673
1862
  import: "import";
1674
1863
  "claude-code-import": "claude-code-import";
1864
+ "codex-adapter": "codex-adapter";
1675
1865
  "codex-import": "codex-import";
1676
1866
  human: "human";
1677
1867
  terminal: "terminal";
@@ -1679,7 +1869,7 @@ declare const SessionSchema: z.ZodObject<{
1679
1869
  version: z.ZodLiteral<"0.1.0">;
1680
1870
  external_id: z.ZodOptional<z.ZodString>;
1681
1871
  source_size_bytes: z.ZodOptional<z.ZodNumber>;
1682
- }, z.core.$strip>;
1872
+ }, z.core.$loose>;
1683
1873
  started_at: z.ZodString;
1684
1874
  ended_at: z.ZodOptional<z.ZodString>;
1685
1875
  status: z.ZodEnum<{
@@ -1697,7 +1887,7 @@ declare const SessionSchema: z.ZodObject<{
1697
1887
  command: z.ZodString;
1698
1888
  args: z.ZodDefault<z.ZodArray<z.ZodString>>;
1699
1889
  exit_code: z.ZodNullable<z.ZodNumber>;
1700
- }, z.core.$strip>;
1890
+ }, z.core.$loose>;
1701
1891
  related_files: z.ZodDefault<z.ZodArray<z.ZodString>>;
1702
1892
  events_log: z.ZodDefault<z.ZodString>;
1703
1893
  summary: z.ZodOptional<z.ZodNullable<z.ZodString>>;
@@ -1710,17 +1900,17 @@ declare const SessionSchema: z.ZodObject<{
1710
1900
  active_intervals: z.ZodOptional<z.ZodArray<z.ZodObject<{
1711
1901
  start: z.ZodString;
1712
1902
  end: z.ZodString;
1713
- }, z.core.$strip>>>;
1903
+ }, z.core.$loose>>>;
1714
1904
  active_gap_cap_ms: z.ZodOptional<z.ZodNumber>;
1715
1905
  active_time_method: z.ZodOptional<z.ZodString>;
1716
1906
  machine_active_time_ms: z.ZodOptional<z.ZodNumber>;
1717
- }, z.core.$strip>>;
1907
+ }, z.core.$loose>>;
1718
1908
  integrity: z.ZodOptional<z.ZodObject<{
1719
1909
  head_hash: z.ZodString;
1720
1910
  event_count: z.ZodNumber;
1721
1911
  }, z.core.$strict>>;
1722
- }, z.core.$strip>;
1723
- }, z.core.$strip>;
1912
+ }, z.core.$loose>;
1913
+ }, z.core.$loose>;
1724
1914
  /** Inferred runtime type for {@link SessionSchema}. */
1725
1915
  type Session = z.infer<typeof SessionSchema>;
1726
1916
 
@@ -2452,7 +2642,7 @@ type TaskStatus = z.infer<typeof TaskStatusSchema>;
2452
2642
  * the file into `task` (this schema) and `body` (the trailing string).
2453
2643
  */
2454
2644
  declare const TaskSchema: z.ZodObject<{
2455
- schema_version: z.ZodLiteral<"0.1.0">;
2645
+ schema_version: z.ZodString;
2456
2646
  task: z.ZodObject<{
2457
2647
  id: z.ZodString & z.ZodType<`task_${string}`, string, z.core.$ZodTypeInternals<`task_${string}`, string>>;
2458
2648
  title: z.ZodString;
@@ -2468,8 +2658,8 @@ declare const TaskSchema: z.ZodObject<{
2468
2658
  workspace_id: z.ZodString & z.ZodType<`ws_${string}`, string, z.core.$ZodTypeInternals<`ws_${string}`, string>>;
2469
2659
  created_in_session: z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>;
2470
2660
  linked_sessions: z.ZodDefault<z.ZodArray<z.ZodString & z.ZodType<`ses_${string}`, string, z.core.$ZodTypeInternals<`ses_${string}`, string>>>>;
2471
- }, z.core.$strip>;
2472
- }, z.core.$strip>;
2661
+ }, z.core.$loose>;
2662
+ }, z.core.$loose>;
2473
2663
  /** Inferred runtime type for {@link TaskSchema}. */
2474
2664
  type Task = z.infer<typeof TaskSchema>;
2475
2665
 
@@ -4774,10 +4964,22 @@ declare function buildJsonSchemas(): JsonSchemaArtifact[];
4774
4964
  declare function serializeJsonSchema(schema: Record<string, unknown>): string;
4775
4965
 
4776
4966
  /**
4777
- * Schema version literal pinned to "0.1.0" for Basou v0.1.
4778
- * Reused across every entity schema so inferred types narrow to the literal.
4967
+ * The `.basou` on-disk format version, of the form `MAJOR.MINOR.PATCH`.
4968
+ *
4969
+ * This basou reads format **major 0**: it accepts any `0.x.y` (a newer MINOR /
4970
+ * PATCH is additive and still parses, because the entity schemas are loose and
4971
+ * preserve unknown fields) and GATES a higher / unknown major with an explicit
4972
+ * "upgrade basou" error rather than a cryptic field-level parse failure. The
4973
+ * gate behavior is part of the frozen format contract, so it is defined before
4974
+ * the semver-1.0 freeze — it cannot be retrofitted onto a frozen `z.literal`.
4975
+ *
4976
+ * The format major is DECOUPLED from the npm / product version: shipping basou
4977
+ * product 1.0.0 does not bump this major — it stays `0` until the on-disk format
4978
+ * itself changes incompatibly. The regex (not a `.refine`) is the gate so it is
4979
+ * emitted faithfully into the published JSON Schema `pattern`, letting a
4980
+ * cross-language validator enforce the same major.
4779
4981
  */
4780
- declare const SchemaVersionSchema: z.ZodLiteral<"0.1.0">;
4982
+ declare const SchemaVersionSchema: z.ZodString;
4781
4983
  /**
4782
4984
  * ISO 8601 timestamp with explicit timezone offset (e.g. `+09:00`).
4783
4985
  *
@@ -4832,7 +5034,7 @@ declare const StatusSchema: z.ZodObject<{
4832
5034
  workspace: z.ZodObject<{
4833
5035
  id: z.ZodString & z.ZodType<`ws_${string}`, string, z.core.$ZodTypeInternals<`ws_${string}`, string>>;
4834
5036
  name: z.ZodString;
4835
- basou_version: z.ZodLiteral<"0.1.0">;
5037
+ basou_version: z.ZodString;
4836
5038
  }, z.core.$strict>;
4837
5039
  directories_present: z.ZodObject<{
4838
5040
  sessions: z.ZodBoolean;
@@ -5325,6 +5527,63 @@ type ReviewGapsInput = {
5325
5527
  */
5326
5528
  declare function findReviewGaps(input: ReviewGapsInput): Promise<ReviewGapsSummary>;
5327
5529
 
5530
+ /**
5531
+ * The deterministic writer for `basou review record` — the twin of
5532
+ * `basou decision capture`. The in-loop agent runs a review (with a
5533
+ * vendor-specific command), then pipes a JSON object describing what ran;
5534
+ * basou parses + validates it here and writes a `review_recorded` event,
5535
+ * with NO runtime LLM. Keeping parse + build in core (rather than the CLI,
5536
+ * where `decision capture` happens to live) makes the writer unit-testable
5537
+ * on its own and reusable by the read-only `review-gaps` surfacer.
5538
+ *
5539
+ * This is a self-report: basou records that a review happened; it does not
5540
+ * verify the review actually executed. Cryptographic enforcement is the
5541
+ * bridle's (mcp-bridle) concern — core stays read-only/advisory.
5542
+ */
5543
+ /** A finding in the review record input (the on-wire `findings[]` shape). */
5544
+ type ReviewRecordFindingInput = ReviewFinding;
5545
+ /** A blocked finding in the review record input (the on-wire `blocked[]` shape). */
5546
+ type ReviewRecordBlockedInput = ReviewBlocked;
5547
+ /** A parsed + validated review record: required minimum + optional rich fields. */
5548
+ type ReviewRecordInput = {
5549
+ /** What/who reviewed (e.g. "codex", a model name, "self"). Required. */
5550
+ reviewer: string;
5551
+ /** What was reviewed (e.g. "working-tree", a git ref, "PR #145"). Required. */
5552
+ target: string;
5553
+ /** Overall outcome. Optional. */
5554
+ verdict?: "pass" | "needs-attention" | "fail";
5555
+ /** Findings surfaced by the review. Optional. */
5556
+ findings?: ReviewRecordFindingInput[];
5557
+ /**
5558
+ * Findings blocked as spec-deviation / design-reversal. Optional, but an
5559
+ * explicit empty array is encouraged — it records "I blocked nothing" as the
5560
+ * adversarial-review protocol requires.
5561
+ */
5562
+ blocked?: ReviewRecordBlockedInput[];
5563
+ };
5564
+ /** Actionable hint shown when nothing is piped in. */
5565
+ declare const REVIEW_RECORD_NO_INPUT_HINT = "No input: pipe a JSON object describing the review to stdin or pass --file <path>.";
5566
+ /**
5567
+ * Parse + validate the review record input — a SINGLE JSON object (one
5568
+ * invocation = one review), unlike `decision capture`'s array. Errors name the
5569
+ * offending field (e.g. `findings[2].severity must be ...`) so the in-loop
5570
+ * agent can self-correct without guessing. Pure: no disk/environment access.
5571
+ */
5572
+ declare function parseReviewRecordInput(raw: string): ReviewRecordInput;
5573
+ /**
5574
+ * Build the `review_recorded` event from a validated input. Mirrors
5575
+ * `buildDecisionEvent`: optional fields are spread only when present so an
5576
+ * event with just the required minimum round-trips byte-identically.
5577
+ */
5578
+ declare function buildReviewRecordedEvent(input: {
5579
+ eventId: PrefixedId<"evt">;
5580
+ sessionId: PrefixedId<"ses">;
5581
+ occurredAt: string;
5582
+ review: ReviewRecordInput;
5583
+ }): Event;
5584
+ /** Ad-hoc session label for a recorded review: `Ad-hoc review: <reviewer> -> <target>`. */
5585
+ declare function buildReviewRecordLabel(review: ReviewRecordInput): string;
5586
+
5328
5587
  /**
5329
5588
  * Internal abstraction over child-process execution.
5330
5589
  *
@@ -5519,13 +5778,12 @@ declare function acquireLock(paths: BasouPaths, scope: LockScope, resourceId: st
5519
5778
  /**
5520
5779
  * Inputs for {@link createManifest}. Optional fields drop out of the
5521
5780
  * resulting Manifest entirely (they are not emitted as `null`/`undefined`
5522
- * in YAML); pass `null` for `repositoryUrl` to keep an explicit `null`.
5781
+ * in YAML).
5523
5782
  */
5524
5783
  type CreateManifestInput = {
5525
5784
  workspaceName: string;
5526
5785
  projectName?: string;
5527
5786
  projectDescription?: string;
5528
- repositoryUrl?: string | null;
5529
5787
  /** Override for tests; defaults to `new Date()`. */
5530
5788
  now?: Date;
5531
5789
  /** Override for tests; defaults to a freshly generated `ws_<ULID>`. */
@@ -5568,6 +5826,10 @@ declare const GENERATED_END = "<!-- BASOU:GENERATED:END -->";
5568
5826
  declare const PROTOCOL_START = "<!-- BASOU:PROTOCOLS:START -->";
5569
5827
  /** Marker line that ends a managed protocol block. */
5570
5828
  declare const PROTOCOL_END = "<!-- BASOU:PROTOCOLS:END -->";
5829
+ /** Marker line that begins a managed orientation block in a vendor context face (e.g. ~/.codex/AGENTS.md). */
5830
+ declare const ORIENTATION_START = "<!-- BASOU:ORIENTATION:START -->";
5831
+ /** Marker line that ends a managed orientation block. */
5832
+ declare const ORIENTATION_END = "<!-- BASOU:ORIENTATION:END -->";
5571
5833
  /** A start/end marker pair. Both lines are matched whole-line, exact. */
5572
5834
  type Markers = {
5573
5835
  start: string;
@@ -5886,4 +6148,4 @@ declare function overwriteYamlFile(filePath: string, value: unknown): Promise<vo
5886
6148
  */
5887
6149
  declare const BASOU_CORE_VERSION = "0.1.0";
5888
6150
 
5889
- export { ACTIVE_GAP_CAP_MS, AGENT_INFRA_DIRS, type ActiveTimeBasis, type AdapterOutputEvent, type AdoptCandidate, type AdoptCandidateKind, type AppendBasouGitignoreOptions, type AppendBasouGitignoreResult, type AppendEventToExistingInput, type AppendEventToExistingResult, type Approval, type ApprovalApprovedEvent, type ApprovalExpiredEvent, ApprovalIdSchema, type ApprovalLocation, type ApprovalRejectedEvent, type ApprovalRequestedEvent, ApprovalSchema, type ApprovalStatus, ApprovalStatusSchema, type ArchivePlan, type ArchiveTaskInput, type ArchiveTaskResult, type AttachTaskInput, type AttachUpdateTaskStatusInput, type AttachableStatus, BASOU_CORE_VERSION, type BasouPaths, type BuildStopHookCommandOptions, type BulkChainResult, CLAUDE_IMPORT_SOURCE, CODEX_IMPORT_SOURCE, type CaptureMode, type ChainBreakReason, type ChainTailState, type ChainVerdict, type ChainVerdictStatus, type ChainedEvents, ChildProcessRunner, type CitedReview, type ClaudeSettings, type ClaudeTranscriptRecord, type ClaudeTranscriptToPayloadOptions, type CodexRolloutRecord, type CodexRolloutToPayloadOptions, type CommandExecutedEvent, type CommandLookup, type CreateAdHocSessionInput, type CreateAdHocSessionResult, type CreateAdHocTaskInput, type CreateManifestInput, type CreateTaskInput, type CreateTaskResult, DEFAULT_STOP_HOOK_MIN_EDITS, type DayWorkStats, DecisionIdSchema, type DecisionRecordedEvent, type DecisionsRendererInput, type DecisionsRendererResult, type DeleteTaskInput, type DeleteTaskResult, type DiffResult, type EditTaskInput, type EditTaskResult, type Event, EventIdSchema, EventSchema, EventSourceSchema, type ExistingViewLink, FailedToFinalizeError, type FederatedRoot, type FileChange, type FileChangeStatus, type FileChangedEvent, GENERATED_END, GENERATED_START, type GitSnapshot, type GitSnapshotEvent, type GitignorePlanSummary, type HandoffRendererInput, type HandoffRendererResult, ID_PREFIXES, type IdPrefix, type ImportSessionOptions, type ImportSessionResult, type InstructionFileFact, type InstructionSymlinkFact, type InstructionSymlinkState, IsoTimestampSchema, JSON_SCHEMA_VERSION, type JsonSchemaArtifact, type LoadFederatedOptions, type LoadSessionEntriesOptions, type LoadTaskEntriesOptions, type LoadedApproval, type LockHandle, type LockScope, type Manifest, ManifestSchema, type MarkerSection, type Markers, type MeasureAvailability, type NoteAddedEvent, type OrientationRendererInput, type OrientationRendererResult, type OrientationSummary, PROTOCOL_END, PROTOCOL_START, type PrefixedId, type PresetAction, type PresetCollision, type PresetMarkerConflict, type PresetMarkerKind, type PresetPlanSummary, type PresetRepo, type ProcessRunner, type PublishKind, type PublishTarget, type RechainOptions, type RechainResult, type ReconcileAllResult, type ReconcileAllTasksInput, type ReconcileAllTasksOptions, type ReconcileFailure, type ReconcileResult, type ReconcileTaskInput, type RefreshLinkageInput, type RefreshLinkageResult, type ReimportOptions, type ReimportResult, type RenamePlan, type ReplayOptions, type ReplayWarning, type RepoEntry, type RepoGitignoreFacts, type RepoGitignorePlan, type RepoInstructions, type RepoLanguage, type RepoPresetFacts, type RepoPresetPlan, type RepoSymlinkFacts, type RepoSymlinkPlan, type RepoVisibility, type RepoWiringFacts, type ReportApprovalItem, type ReportData, type ReportDecisionItem, type ReportRendererInput, type ReportRendererResult, type ReportSessionItem, type ReportTaskItem, type RetrofitAction, type RetrofitAgentsState, type RetrofitFacts, type RetrofitPlan, type RetrofitReason, type ReviewGapRepoSummary, type ReviewGapUnit, type ReviewGapVerdict, type ReviewGapsInput, type ReviewGapsSummary, type RiskLevel, RiskLevelSchema, type RosterAdoptionPlan, type RosterDriftSummary, type RunOptions, type RunResult, STOP_HOOK_TIMEOUT_SECONDS, STUCK_THRESHOLD_MS, type SanitizePathOptions, type SanitizeRelatedFilesResult, SchemaVersionSchema, type Session, type SessionEndedEvent, type SessionEntry, SessionIdSchema, type SessionImportPayload, SessionImportPayloadSchema, type SessionInnerImportInput, SessionInnerImportSchema, type SessionIntegrity, SessionIntegritySchema, type SessionMetrics, SessionMetricsSchema, SessionSchema, type SessionSkipReason, type SessionSourceKind, SessionSourceKindSchema, type SessionStartedEvent, type SessionStatus, type SessionStatusChangedEvent, SessionStatusSchema, type SessionWorkStats, type SourceRootScope, type SourceRootsReconcile, type SourceWorkStats, type StatusCount, StatusSchema, type StatusSnapshot, type StopHookEvaluation, type StopHookEvaluationInput, type StopHookRemoval, type StopHookSilentReason, type StopHookUpsert, type SuspectReason, type SymlinkCollision, type SymlinkConflict, type SymlinkPlanSummary, type Task, type TaskArchivedEvent, type TaskCreatedEvent, type TaskDeletedEvent, type TaskDocument, TaskIdSchema, type TaskLinkageRefreshedEvent, type TaskReconciledEvent, TaskSchema, type TaskSkipReason, type TaskStatus, type TaskStatusChangedEvent, type TaskStatusCount, TaskStatusSchema, TaskWriteAfterEventError, type TaskWriteAfterEventPhase, type TokenTotals, type UpdateAdHocTaskStatusInput, type UpdateTaskStatusInput, type UpdateTaskStatusResult, type ViewCollision, type ViewConflict, type ViewLinkState, type ViewRepoFact, type ViewStrayUnknown, type WiringRisk, type WiringSummary, type WorkStatsInput, type WorkStatsResult, type WorkStatsTotals, WorkspaceIdSchema, type WorkspaceViewPlan, type WriteEventsBulkOptions, type WriteTaskFileMode, acquireLock, appendBasouGitignore, appendChainedEvent, appendChainedEventLocked, appendEvent, appendEventToExistingSession, archiveTask, assertBasouRootSafe, basouPaths, buildJsonSchemas, buildStatusSnapshot, buildStopHookCommand, chainEvents, chainRawJsonLines, classifyFilesBySourceRoot, classifyRetrofit, classifySuspect, claudeCodeAdapterMetadata, claudeTranscriptToImportPayload, codexRolloutToImportPayload, computeWorkStats, createAdHocSessionWithEvent, createManifest, createTaskWithEvent, deleteTask, editTask, ensureBasouDirectory, enumerateApprovals, enumerateArchivedTaskIds, enumerateSessionDirs, enumerateTaskIds, evaluateStopHook, finalizeSessionYaml, findBasouStopHookCommand, findErrorCode, findReviewGaps, formatDurationMs, genesisHash, getDiff, getSnapshot, importSessionFromJson, inspectChainTail, instructionMode, isBasouStopHookCommand, isGitNotFound, isImportDerivedSource, isLazyExpired, isRenderable, isValidPrefixedId, lineHash, linkYamlFile, loadApproval, loadFederatedSessionEntries, loadSessionEntries, loadTaskEntries, normalizeRepoKey, normalizeRepoPath, overwriteYamlFile, parseDuration, parseMarkers, pathBasename, planArchive, planGitignore, planRename, planRosterAdoption, planWorkspaceView, prefixedUlid, readAllEvents, readManifest, readMarkdownFile, readSessionYaml, readStatus, readTaskFile, readTaskFileWithArchiveFallback, readYamlFile, rechainSessionInPlace, reconcileAllTasks, reconcileSourceRoots, reconcileTask, refreshTaskLinkedSessions, reimportPreservingId, removeMarkerSection, removeStopHook, renderDecisions, renderHandoff, renderOrientation, renderPresetBlock, renderReport, renderWithMarkers, replayEvents, resolveBasouRepositoryRoot, resolveClaudeCodeCommand, resolveRepositoryRoot, resolveSessionId, resolveTaskId, safeSimpleGit, sanitizePath, sanitizeRelatedFiles, sanitizeWorkingDirectory, serializeEventLine, serializeJsonSchema, sessionWorkStatsFromEvents, summarizeAdapterOutput, summarizeOrientation, summarizePresetPlan, summarizeRosterDrift, summarizeSymlinkPlan, summarizeWiring, tryRemoteUrl, ulid, unknownManifestKeys, updateTaskStatusWithEvent, upsertStopHook, verifyEventsChain, writeEventsBulk, writeManifest, writeMarkdownFile, writeStatus, writeTaskFile, writeYamlFile };
6151
+ export { ACTIVE_GAP_CAP_MS, AGENT_INFRA_DIRS, type ActiveTimeBasis, type AdapterOutputEvent, type AdoptCandidate, type AdoptCandidateKind, type AppendBasouGitignoreOptions, type AppendBasouGitignoreResult, type AppendEventToExistingInput, type AppendEventToExistingResult, type Approval, type ApprovalApprovedEvent, type ApprovalExpiredEvent, ApprovalIdSchema, type ApprovalLocation, type ApprovalRejectedEvent, type ApprovalRequestedEvent, ApprovalSchema, type ApprovalStatus, ApprovalStatusSchema, type ArchivePlan, type ArchiveTaskInput, type ArchiveTaskResult, type AttachTaskInput, type AttachUpdateTaskStatusInput, type AttachableStatus, BASOU_CORE_VERSION, type BasouPaths, type BuildStopHookCommandOptions, type BulkChainResult, CLAUDE_IMPORT_SOURCE, CODEX_IMPORT_SOURCE, type CaptureMode, type ChainBreakReason, type ChainTailState, type ChainVerdict, type ChainVerdictStatus, type ChainedEvents, ChildProcessRunner, type CitedReview, type ClaudeSettings, type ClaudeTranscriptRecord, type ClaudeTranscriptToPayloadOptions, type CodexCommandLookup, type CodexRolloutRecord, type CodexRolloutToPayloadOptions, type CommandExecutedEvent, type CommandLookup, type CreateAdHocSessionInput, type CreateAdHocSessionResult, type CreateAdHocTaskInput, type CreateManifestInput, type CreateTaskInput, type CreateTaskResult, DEFAULT_STOP_HOOK_MIN_EDITS, type DayWorkStats, DecisionIdSchema, type DecisionRecordedEvent, type DecisionsRendererInput, type DecisionsRendererResult, type DeleteTaskInput, type DeleteTaskResult, type DiffResult, type EditTaskInput, type EditTaskResult, type Event, EventIdSchema, EventSchema, EventSourceSchema, type ExistingViewLink, FailedToFinalizeError, type FederatedRoot, type FileChange, type FileChangeStatus, type FileChangedEvent, GENERATED_END, GENERATED_START, type GitSnapshot, type GitSnapshotEvent, type GitignorePlanSummary, type HandoffRendererInput, type HandoffRendererResult, ID_PREFIXES, type IdPrefix, type ImportSessionOptions, type ImportSessionResult, type InstructionFileFact, type InstructionSymlinkFact, type InstructionSymlinkState, IsoTimestampSchema, JSON_SCHEMA_VERSION, type JsonSchemaArtifact, type LoadFederatedOptions, type LoadSessionEntriesOptions, type LoadTaskEntriesOptions, type LoadedApproval, type LockHandle, type LockScope, type Manifest, ManifestSchema, type MarkerSection, type Markers, type MeasureAvailability, type NoteAddedEvent, ORIENTATION_END, ORIENTATION_START, type OrientationRendererInput, type OrientationRendererResult, type OrientationSummary, PROTOCOL_END, PROTOCOL_START, type PrefixedId, type PresetAction, type PresetCollision, type PresetMarkerConflict, type PresetMarkerKind, type PresetPlanSummary, type PresetRepo, type ProcessRunner, type PublishKind, type PublishTarget, REVIEW_RECORD_NO_INPUT_HINT, type RechainOptions, type RechainResult, type ReconcileAllResult, type ReconcileAllTasksInput, type ReconcileAllTasksOptions, type ReconcileFailure, type ReconcileResult, type ReconcileTaskInput, type RefreshLinkageInput, type RefreshLinkageResult, type ReimportOptions, type ReimportResult, type RenamePlan, type ReplayOptions, type ReplayWarning, type RepoEntry, type RepoGitignoreFacts, type RepoGitignorePlan, type RepoInstructions, type RepoLanguage, type RepoPresetFacts, type RepoPresetPlan, type RepoSymlinkFacts, type RepoSymlinkPlan, type RepoVisibility, type RepoWiringFacts, type ReportApprovalItem, type ReportData, type ReportDecisionItem, type ReportRendererInput, type ReportRendererResult, type ReportSessionItem, type ReportTaskItem, type RetrofitAction, type RetrofitAgentsState, type RetrofitFacts, type RetrofitPlan, type RetrofitReason, type ReviewBlocked, type ReviewFinding, type ReviewGapRepoSummary, type ReviewGapUnit, type ReviewGapVerdict, type ReviewGapsInput, type ReviewGapsSummary, type ReviewGateResult, type ReviewGateSilentReason, type ReviewRecordBlockedInput, type ReviewRecordFindingInput, type ReviewRecordInput, type ReviewRecordedEvent, type RiskLevel, RiskLevelSchema, type RosterAdoptionPlan, type RosterDriftSummary, type RunOptions, type RunResult, STOP_HOOK_TIMEOUT_SECONDS, STUCK_THRESHOLD_MS, type SanitizePathOptions, type SanitizeRelatedFilesResult, SchemaVersionSchema, type Session, type SessionEndedEvent, type SessionEntry, SessionIdSchema, type SessionImportPayload, SessionImportPayloadSchema, type SessionInnerImportInput, SessionInnerImportSchema, type SessionIntegrity, SessionIntegritySchema, type SessionMetrics, SessionMetricsSchema, SessionSchema, type SessionSkipReason, type SessionSourceKind, SessionSourceKindSchema, type SessionStartedEvent, type SessionStatus, type SessionStatusChangedEvent, SessionStatusSchema, type SessionWorkStats, type SourceRootScope, type SourceRootsReconcile, type SourceWorkStats, type StatusCount, StatusSchema, type StatusSnapshot, type StopHookEvaluation, type StopHookEvaluationInput, type StopHookRemoval, type StopHookSilentReason, type StopHookUpsert, type SuspectReason, type SymlinkCollision, type SymlinkConflict, type SymlinkPlanSummary, type Task, type TaskArchivedEvent, type TaskCreatedEvent, type TaskDeletedEvent, type TaskDocument, TaskIdSchema, type TaskLinkageRefreshedEvent, type TaskReconciledEvent, TaskSchema, type TaskSkipReason, type TaskStatus, type TaskStatusChangedEvent, type TaskStatusCount, TaskStatusSchema, TaskWriteAfterEventError, type TaskWriteAfterEventPhase, type TokenTotals, type UpdateAdHocTaskStatusInput, type UpdateTaskStatusInput, type UpdateTaskStatusResult, type ViewCollision, type ViewConflict, type ViewLinkState, type ViewRepoFact, type ViewStrayUnknown, type WiringRisk, type WiringSummary, type WorkStatsInput, type WorkStatsResult, type WorkStatsTotals, WorkspaceIdSchema, type WorkspaceViewPlan, type WriteEventsBulkOptions, type WriteTaskFileMode, acquireLock, appendBasouGitignore, appendChainedEvent, appendChainedEventLocked, appendEvent, appendEventToExistingSession, archiveTask, assertBasouRootSafe, basouPaths, buildJsonSchemas, buildReviewRecordLabel, buildReviewRecordedEvent, buildStatusSnapshot, buildStopHookCommand, chainEvents, chainRawJsonLines, classifyFilesBySourceRoot, classifyRetrofit, classifySuspect, claudeCodeAdapterMetadata, claudeTranscriptToImportPayload, codexAdapterMetadata, codexRolloutToImportPayload, computeWorkStats, createAdHocSessionWithEvent, createManifest, createTaskWithEvent, deleteTask, editTask, ensureBasouDirectory, enumerateApprovals, enumerateArchivedTaskIds, enumerateSessionDirs, enumerateTaskIds, evaluateStopHook, finalizeSessionYaml, findBasouStopHookCommand, findErrorCode, findReviewGaps, formatDurationMs, genesisHash, getDiff, getSnapshot, importSessionFromJson, inspectChainTail, instructionMode, isBasouStopHookCommand, isGitNotFound, isImportDerivedSource, isLazyExpired, isRenderable, isValidPrefixedId, lineHash, linkYamlFile, loadApproval, loadFederatedSessionEntries, loadSessionEntries, loadTaskEntries, normalizeRepoKey, normalizeRepoPath, overwriteYamlFile, parseDuration, parseMarkers, parseReviewRecordInput, pathBasename, planArchive, planGitignore, planRename, planRosterAdoption, planWorkspaceView, prefixedUlid, readAllEvents, readManifest, readMarkdownFile, readSessionYaml, readStatus, readTaskFile, readTaskFileWithArchiveFallback, readYamlFile, rechainSessionInPlace, reconcileAllTasks, reconcileSourceRoots, reconcileTask, refreshTaskLinkedSessions, reimportPreservingId, removeMarkerSection, removeStopHook, renderDecisions, renderHandoff, renderOrientation, renderPresetBlock, renderReport, renderWithMarkers, replayEvents, resolveBasouRepositoryRoot, resolveClaudeCodeCommand, resolveCodexCommand, resolveRepositoryRoot, resolveSessionId, resolveTaskId, safeSimpleGit, sanitizePath, sanitizeRelatedFiles, sanitizeWorkingDirectory, serializeEventLine, serializeJsonSchema, sessionWorkStatsFromEvents, summarizeAdapterOutput, summarizeOrientation, summarizePresetPlan, summarizeRosterDrift, summarizeSymlinkPlan, summarizeWiring, tryRemoteUrl, ulid, unknownManifestKeys, updateTaskStatusWithEvent, upsertStopHook, verifyEventsChain, writeEventsBulk, writeManifest, writeMarkdownFile, writeStatus, writeTaskFile, writeYamlFile };