@fenglimg/fabric-shared 2.0.0-rc.13 → 2.0.0-rc.21

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.js CHANGED
@@ -1,3 +1,4 @@
1
+ import "./chunk-LXNCAKJZ.js";
1
2
  import {
2
3
  PROTECTED_TOKENS,
3
4
  createTranslator,
@@ -6,7 +7,7 @@ import {
6
7
  enMessages,
7
8
  normalizeLocale,
8
9
  zhCNMessages
9
- } from "./chunk-WIH5HBKU.js";
10
+ } from "./chunk-VKCXD6CI.js";
10
11
  import {
11
12
  FabExtractKnowledgeInputSchema,
12
13
  FabExtractKnowledgeInputShape,
@@ -46,7 +47,15 @@ import {
46
47
  planContextOutputSchema,
47
48
  structuredWarningSchema
48
49
  } from "./chunk-NNDFOOBO.js";
49
- import "./chunk-LXNCAKJZ.js";
50
+ import {
51
+ BOOTSTRAP_CANONICAL,
52
+ BOOTSTRAP_MARKER_BEGIN,
53
+ BOOTSTRAP_MARKER_END,
54
+ BOOTSTRAP_REGEX,
55
+ LEGACY_KB_MARKER_BEGIN,
56
+ LEGACY_KB_MARKER_END,
57
+ LEGACY_KB_REGEX
58
+ } from "./chunk-QZNUUIL3.js";
50
59
 
51
60
  // src/schemas/agents-meta.ts
52
61
  import { z } from "zod";
@@ -166,7 +175,7 @@ function defaultAgentsMetaCounters() {
166
175
  }
167
176
  function deriveAgentsMetaStableId(file) {
168
177
  const normalized = normalizePath(file);
169
- if (normalized === "AGENTS.md" || normalized === ".fabric/bootstrap/README.md") {
178
+ if (normalized === "AGENTS.md") {
170
179
  return "bootstrap";
171
180
  }
172
181
  return getDepthSource(normalized).replace(/\.md$/u, "");
@@ -183,7 +192,7 @@ function deriveAgentsMetaIdentitySource(node) {
183
192
  }
184
193
  function deriveAgentsMetaLayer(file) {
185
194
  const normalized = normalizePath(file);
186
- if (normalized === "AGENTS.md" || normalized === ".fabric/bootstrap/README.md") {
195
+ if (normalized === "AGENTS.md") {
187
196
  return "L0";
188
197
  }
189
198
  if (hasCrossCuttingSegment(normalized)) {
@@ -315,9 +324,14 @@ var fabricLanguageSchema = z5.enum([
315
324
  var defaultLayerFilterSchema = z5.enum(["team", "personal", "both"]);
316
325
  var fabricConfigSchema = z5.object({
317
326
  clientPaths: clientPathsSchema.optional(),
318
- externalFixturePath: z5.string().optional(),
327
+ // rc.17 (R-cut): the dev/test fixture-path config field was removed
328
+ // end-to-end. The `EXTERNAL_FIXTURE_PATH` env var is now the sole source
329
+ // consumed by `resolveDevMode()`. No z.preprocess alias — pre-rc.17
330
+ // fabric-config.json files carrying the field will be silently dropped by
331
+ // the lenient root parser (no .strict() at root). Pre-user clean-slate per
332
+ // memory/feedback_clean_slate.md; mirrors the rc.12 hard-rename precedent
333
+ // documented above.
319
334
  scanIgnores: z5.array(z5.string()).optional(),
320
- auditMode: auditModeSchema.optional(),
321
335
  audit_mode: auditModeSchema.optional(),
322
336
  mcpPayloadLimits: mcpPayloadLimitsSchema,
323
337
  // Backward-compat: both fields are optional with defaults so existing
@@ -439,156 +453,294 @@ var fabricConfigSchema = z5.object({
439
453
  review_stale_pending_days: z5.number().int().positive().optional().default(14)
440
454
  });
441
455
 
442
- // src/schemas/forensic-report.ts
456
+ // src/schemas/fabric-config-introspect.ts
443
457
  import { z as z6 } from "zod";
444
- var forensicCodeSampleSchema = z6.object({
445
- path: z6.string(),
446
- lines: z6.string(),
447
- snippet: z6.string(),
448
- pattern_hint: z6.string()
449
- });
450
- var forensicEvidenceAnchorSchema = z6.object({
451
- file: z6.string(),
452
- line: z6.string(),
453
- snippet: z6.string()
454
- });
455
- var forensicAssertionCoverageSchema = z6.object({
456
- ratio: z6.number().min(0).max(1),
457
- total: z6.number().int().nonnegative(),
458
- matched: z6.number().int().nonnegative(),
459
- co_occurring_patterns: z6.array(z6.string())
460
- });
461
- var forensicAssertionSchema = z6.object({
462
- type: z6.enum(["framework", "pattern", "invariant", "domain"]),
463
- statement: z6.string(),
464
- confidence: z6.enum(["HIGH", "MEDIUM", "LOW"]),
465
- evidence: z6.array(forensicEvidenceAnchorSchema),
458
+ var positiveIntSchema = z6.coerce.number().int().positive();
459
+ function makePositiveIntField(key, defaultValue) {
460
+ return {
461
+ key,
462
+ group: "B_hint_threshold",
463
+ widget: "text",
464
+ label_i18n_key: `cli.config.fields.${key}.label`,
465
+ description_i18n_key: `cli.config.fields.${key}.description`,
466
+ default: defaultValue,
467
+ validate(raw) {
468
+ const trimmed = raw.trim();
469
+ if (trimmed === "") {
470
+ return { ok: false, error: "Value is required (positive integer)." };
471
+ }
472
+ const parsed = positiveIntSchema.safeParse(trimmed);
473
+ if (!parsed.success) {
474
+ return {
475
+ ok: false,
476
+ error: "Must be a positive integer (e.g. 1, 12, 24)."
477
+ };
478
+ }
479
+ return { ok: true, value: parsed.data };
480
+ },
481
+ format_for_display(value) {
482
+ if (typeof value === "number") return String(value);
483
+ if (value === void 0 || value === null) return String(defaultValue);
484
+ return String(value);
485
+ }
486
+ };
487
+ }
488
+ function makeEnumField(key, group, enumValues, defaultValue) {
489
+ return {
490
+ key,
491
+ group,
492
+ widget: "select",
493
+ label_i18n_key: `cli.config.fields.${key}.label`,
494
+ description_i18n_key: `cli.config.fields.${key}.description`,
495
+ default: defaultValue,
496
+ enum_values: enumValues,
497
+ validate(raw) {
498
+ const trimmed = raw.trim();
499
+ if (!enumValues.includes(trimmed)) {
500
+ return {
501
+ ok: false,
502
+ error: `Must be one of: ${enumValues.join(", ")}.`
503
+ };
504
+ }
505
+ return { ok: true, value: trimmed };
506
+ },
507
+ format_for_display(value) {
508
+ if (typeof value === "string" && enumValues.includes(value)) return value;
509
+ if (value === void 0 || value === null) return defaultValue;
510
+ return String(value);
511
+ }
512
+ };
513
+ }
514
+ var SCHEMA_DEFAULTS = fabricConfigSchema.parse({});
515
+ function pickNumberDefault(key) {
516
+ const v = SCHEMA_DEFAULTS[key];
517
+ if (typeof v !== "number") {
518
+ throw new Error(
519
+ `fabric-config-introspect: expected numeric default for ${String(key)}, got ${typeof v}`
520
+ );
521
+ }
522
+ return v;
523
+ }
524
+ function pickStringDefault(key) {
525
+ const v = SCHEMA_DEFAULTS[key];
526
+ if (typeof v !== "string") {
527
+ throw new Error(
528
+ `fabric-config-introspect: expected string default for ${String(key)}, got ${typeof v}`
529
+ );
530
+ }
531
+ return v;
532
+ }
533
+ var AUDIT_MODE_PANEL_DEFAULT = "warn";
534
+ function getPanelFields() {
535
+ return PANEL_FIELDS;
536
+ }
537
+ function getPanelFieldByKey(key) {
538
+ return PANEL_FIELDS.find((f) => f.key === key);
539
+ }
540
+ var PANEL_FIELDS = [
541
+ // --- Group A: Locale (2) ---
542
+ makeEnumField(
543
+ "fabric_language",
544
+ "A_locale",
545
+ fabricLanguageSchema.options,
546
+ pickStringDefault("fabric_language")
547
+ ),
548
+ makeEnumField(
549
+ "default_layer_filter",
550
+ "A_locale",
551
+ defaultLayerFilterSchema.options,
552
+ pickStringDefault("default_layer_filter")
553
+ ),
554
+ // --- Group B: Hint thresholds (8 — see leading docstring for the
555
+ // 7-vs-8 reconciliation; archive_edit_threshold is the 8th key) ---
556
+ makePositiveIntField("archive_hint_hours", pickNumberDefault("archive_hint_hours")),
557
+ makePositiveIntField(
558
+ "archive_hint_cooldown_hours",
559
+ pickNumberDefault("archive_hint_cooldown_hours")
560
+ ),
561
+ makePositiveIntField(
562
+ "archive_edit_threshold",
563
+ pickNumberDefault("archive_edit_threshold")
564
+ ),
565
+ makePositiveIntField(
566
+ "underseed_node_threshold",
567
+ pickNumberDefault("underseed_node_threshold")
568
+ ),
569
+ makePositiveIntField(
570
+ "review_hint_pending_count",
571
+ pickNumberDefault("review_hint_pending_count")
572
+ ),
573
+ makePositiveIntField(
574
+ "review_hint_pending_age_days",
575
+ pickNumberDefault("review_hint_pending_age_days")
576
+ ),
577
+ makePositiveIntField(
578
+ "maintenance_hint_days",
579
+ pickNumberDefault("maintenance_hint_days")
580
+ ),
581
+ makePositiveIntField(
582
+ "maintenance_hint_cooldown_days",
583
+ pickNumberDefault("maintenance_hint_cooldown_days")
584
+ ),
585
+ // --- Group C: Audit (1) ---
586
+ makeEnumField(
587
+ "audit_mode",
588
+ "C_audit",
589
+ auditModeSchema.options,
590
+ AUDIT_MODE_PANEL_DEFAULT
591
+ )
592
+ ];
593
+
594
+ // src/schemas/forensic-report.ts
595
+ import { z as z7 } from "zod";
596
+ var forensicCodeSampleSchema = z7.object({
597
+ path: z7.string(),
598
+ lines: z7.string(),
599
+ snippet: z7.string(),
600
+ pattern_hint: z7.string()
601
+ });
602
+ var forensicEvidenceAnchorSchema = z7.object({
603
+ file: z7.string(),
604
+ line: z7.string(),
605
+ snippet: z7.string()
606
+ });
607
+ var forensicAssertionCoverageSchema = z7.object({
608
+ ratio: z7.number().min(0).max(1),
609
+ total: z7.number().int().nonnegative(),
610
+ matched: z7.number().int().nonnegative(),
611
+ co_occurring_patterns: z7.array(z7.string())
612
+ });
613
+ var forensicAssertionSchema = z7.object({
614
+ type: z7.enum(["framework", "pattern", "invariant", "domain"]),
615
+ statement: z7.string(),
616
+ confidence: z7.enum(["HIGH", "MEDIUM", "LOW"]),
617
+ evidence: z7.array(forensicEvidenceAnchorSchema),
466
618
  coverage: forensicAssertionCoverageSchema,
467
- proposed_rule: z6.string().optional(),
468
- alternatives: z6.array(z6.string()).optional()
469
- });
470
- var forensicTopologySchema = z6.object({
471
- total_files: z6.number().int().nonnegative(),
472
- by_ext: z6.record(z6.number().int().nonnegative()),
473
- key_dirs: z6.array(z6.string()),
474
- max_depth: z6.number().int().nonnegative()
475
- });
476
- var forensicEntryPointSchema = z6.object({
477
- path: z6.string(),
478
- reason: z6.string(),
479
- size_bytes: z6.number().int().nonnegative().optional()
480
- });
481
- var forensicFrameworkSchema = z6.object({
482
- kind: z6.string(),
483
- version: z6.string(),
484
- subkind: z6.string(),
485
- evidence: z6.array(z6.string())
486
- });
487
- var forensicReadmeSchema = z6.object({
488
- quality: z6.enum(["missing", "stub", "ok"]),
489
- line_count: z6.number().int().nonnegative(),
490
- has_contributing: z6.boolean()
491
- });
492
- var candidateFileEntrySchema = z6.object({
493
- path: z6.string(),
494
- family: z6.enum(["entry", "component", "config", "test", "domain"]),
495
- rationale: z6.string()
496
- });
497
- var forensicSamplingBudgetSchema = z6.object({
498
- max_files: z6.literal(15),
499
- max_lines_per_file: z6.literal(100)
500
- });
501
- var forensicReportSchema = z6.object({
502
- version: z6.string(),
503
- generated_at: z6.string(),
504
- generated_by: z6.string(),
505
- target: z6.string(),
506
- project_name: z6.string(),
619
+ proposed_rule: z7.string().optional(),
620
+ alternatives: z7.array(z7.string()).optional()
621
+ });
622
+ var forensicTopologySchema = z7.object({
623
+ total_files: z7.number().int().nonnegative(),
624
+ by_ext: z7.record(z7.number().int().nonnegative()),
625
+ key_dirs: z7.array(z7.string()),
626
+ max_depth: z7.number().int().nonnegative()
627
+ });
628
+ var forensicEntryPointSchema = z7.object({
629
+ path: z7.string(),
630
+ reason: z7.string(),
631
+ size_bytes: z7.number().int().nonnegative().optional()
632
+ });
633
+ var forensicFrameworkSchema = z7.object({
634
+ kind: z7.string(),
635
+ version: z7.string(),
636
+ subkind: z7.string(),
637
+ evidence: z7.array(z7.string())
638
+ });
639
+ var forensicReadmeSchema = z7.object({
640
+ quality: z7.enum(["missing", "stub", "ok"]),
641
+ line_count: z7.number().int().nonnegative(),
642
+ has_contributing: z7.boolean()
643
+ });
644
+ var candidateFileEntrySchema = z7.object({
645
+ path: z7.string(),
646
+ family: z7.enum(["entry", "component", "config", "test", "domain"]),
647
+ rationale: z7.string()
648
+ });
649
+ var forensicSamplingBudgetSchema = z7.object({
650
+ max_files: z7.literal(15),
651
+ max_lines_per_file: z7.literal(100)
652
+ });
653
+ var forensicReportSchema = z7.object({
654
+ version: z7.string(),
655
+ generated_at: z7.string(),
656
+ generated_by: z7.string(),
657
+ target: z7.string(),
658
+ project_name: z7.string(),
507
659
  framework: forensicFrameworkSchema,
508
660
  topology: forensicTopologySchema,
509
- entry_points: z6.array(forensicEntryPointSchema),
510
- code_samples: z6.array(forensicCodeSampleSchema),
511
- assertions: z6.array(forensicAssertionSchema),
512
- candidate_files: z6.array(candidateFileEntrySchema),
661
+ entry_points: z7.array(forensicEntryPointSchema),
662
+ code_samples: z7.array(forensicCodeSampleSchema),
663
+ assertions: z7.array(forensicAssertionSchema),
664
+ candidate_files: z7.array(candidateFileEntrySchema),
513
665
  sampling_budget: forensicSamplingBudgetSchema,
514
666
  readme: forensicReadmeSchema,
515
- recommendations_for_skill: z6.array(z6.string()).optional()
667
+ recommendations_for_skill: z7.array(z7.string()).optional()
516
668
  });
517
669
 
518
670
  // src/schemas/init-context.ts
519
- import { z as z7 } from "zod";
520
- var initContextFrameworkSchema = z7.object({
521
- kind: z7.string(),
522
- version: z7.string(),
523
- subkind: z7.string()
671
+ import { z as z8 } from "zod";
672
+ var initContextFrameworkSchema = z8.object({
673
+ kind: z8.string(),
674
+ version: z8.string(),
675
+ subkind: z8.string()
524
676
  });
525
- var initContextInvariantConfidenceSnapshotSchema = z7.object({
526
- confidence: z7.enum(["HIGH", "MEDIUM", "LOW"]),
527
- evidence_refs: z7.array(z7.string())
677
+ var initContextInvariantConfidenceSnapshotSchema = z8.object({
678
+ confidence: z8.enum(["HIGH", "MEDIUM", "LOW"]),
679
+ evidence_refs: z8.array(z8.string())
528
680
  });
529
- var initContextSourceEvidenceSchema = z7.object({
530
- file: z7.string(),
531
- lines: z7.string()
681
+ var initContextSourceEvidenceSchema = z8.object({
682
+ file: z8.string(),
683
+ lines: z8.string()
532
684
  });
533
- var initContextInvariantSchema = z7.object({
534
- type: z7.enum(["ban", "require", "protect"]),
535
- rule: z7.string(),
536
- rationale: z7.string().optional(),
685
+ var initContextInvariantSchema = z8.object({
686
+ type: z8.enum(["ban", "require", "protect"]),
687
+ rule: z8.string(),
688
+ rationale: z8.string().optional(),
537
689
  confidence_snapshot: initContextInvariantConfidenceSnapshotSchema.optional(),
538
- source_evidence: z7.array(initContextSourceEvidenceSchema).optional()
539
- });
540
- var initContextDomainGroupSchema = z7.object({
541
- name: z7.string(),
542
- paths: z7.array(z7.string()),
543
- summary: z7.string().optional(),
544
- topology_type: z7.enum(["mirror", "cross-cutting"]).optional(),
545
- target_path: z7.string().optional()
546
- });
547
- var initContextInterviewTrailEntrySchema = z7.object({
548
- phase: z7.string(),
549
- question: z7.string(),
550
- answer: z7.string(),
551
- presentation: z7.string().optional(),
552
- user_corrections: z7.array(z7.string()).optional()
553
- });
554
- var initContextSchema = z7.object({
690
+ source_evidence: z8.array(initContextSourceEvidenceSchema).optional()
691
+ });
692
+ var initContextDomainGroupSchema = z8.object({
693
+ name: z8.string(),
694
+ paths: z8.array(z8.string()),
695
+ summary: z8.string().optional(),
696
+ topology_type: z8.enum(["mirror", "cross-cutting"]).optional(),
697
+ target_path: z8.string().optional()
698
+ });
699
+ var initContextInterviewTrailEntrySchema = z8.object({
700
+ phase: z8.string(),
701
+ question: z8.string(),
702
+ answer: z8.string(),
703
+ presentation: z8.string().optional(),
704
+ user_corrections: z8.array(z8.string()).optional()
705
+ });
706
+ var initContextSchema = z8.object({
555
707
  framework: initContextFrameworkSchema,
556
- architecture_patterns: z7.array(z7.string()),
557
- invariants: z7.array(initContextInvariantSchema),
558
- domain_groups: z7.array(initContextDomainGroupSchema),
559
- interview_trail: z7.array(initContextInterviewTrailEntrySchema),
560
- forensic_ref: z7.string()
708
+ architecture_patterns: z8.array(z8.string()),
709
+ invariants: z8.array(initContextInvariantSchema),
710
+ domain_groups: z8.array(initContextDomainGroupSchema),
711
+ interview_trail: z8.array(initContextInterviewTrailEntrySchema),
712
+ forensic_ref: z8.string()
561
713
  });
562
714
 
563
715
  // src/schemas/events.ts
564
- import { z as z8 } from "zod";
565
- var metaUpdatedEventSchema = z8.object({
566
- type: z8.literal("meta:updated"),
716
+ import { z as z9 } from "zod";
717
+ var metaUpdatedEventSchema = z9.object({
718
+ type: z9.literal("meta:updated"),
567
719
  payload: agentsMetaSchema
568
720
  });
569
- var lockDriftEventSchema = z8.object({
570
- type: z8.literal("lock:drift"),
571
- payload: z8.object({
572
- locked: z8.array(humanLockEntrySchema),
573
- drifted: z8.array(humanLockEntrySchema)
721
+ var lockDriftEventSchema = z9.object({
722
+ type: z9.literal("lock:drift"),
723
+ payload: z9.object({
724
+ locked: z9.array(humanLockEntrySchema),
725
+ drifted: z9.array(humanLockEntrySchema)
574
726
  })
575
727
  });
576
- var lockApprovedEventSchema = z8.object({
577
- type: z8.literal("lock:approved"),
578
- payload: z8.object({
579
- locked: z8.array(humanLockEntrySchema),
580
- approved: z8.array(humanLockEntrySchema)
728
+ var lockApprovedEventSchema = z9.object({
729
+ type: z9.literal("lock:approved"),
730
+ payload: z9.object({
731
+ locked: z9.array(humanLockEntrySchema),
732
+ approved: z9.array(humanLockEntrySchema)
581
733
  })
582
734
  });
583
- var ledgerAppendedEventSchema = z8.object({
584
- type: z8.literal("ledger:appended"),
735
+ var ledgerAppendedEventSchema = z9.object({
736
+ type: z9.literal("ledger:appended"),
585
737
  payload: ledgerEntrySchema
586
738
  });
587
- var driftDetectedEventSchema = z8.object({
588
- type: z8.literal("drift:detected"),
739
+ var driftDetectedEventSchema = z9.object({
740
+ type: z9.literal("drift:detected"),
589
741
  payload: forensicReportSchema
590
742
  });
591
- var fabricEventSchema = z8.discriminatedUnion("type", [
743
+ var fabricEventSchema = z9.discriminatedUnion("type", [
592
744
  metaUpdatedEventSchema,
593
745
  lockDriftEventSchema,
594
746
  lockApprovedEventSchema,
@@ -597,278 +749,304 @@ var fabricEventSchema = z8.discriminatedUnion("type", [
597
749
  ]);
598
750
 
599
751
  // src/schemas/event-ledger.ts
600
- import { z as z9 } from "zod";
752
+ import { z as z10 } from "zod";
601
753
  var eventLedgerEnvelopeSchema = {
602
- kind: z9.literal("fabric-event"),
603
- id: z9.string(),
604
- ts: z9.number().int().nonnegative(),
605
- schema_version: z9.literal(1),
606
- correlation_id: z9.string().optional(),
607
- session_id: z9.string().optional()
754
+ kind: z10.literal("fabric-event"),
755
+ id: z10.string(),
756
+ ts: z10.number().int().nonnegative(),
757
+ schema_version: z10.literal(1),
758
+ correlation_id: z10.string().optional(),
759
+ session_id: z10.string().optional()
608
760
  };
609
- var stringRecordSchema = z9.record(z9.string());
610
- var knowledgeContextPlannedEventSchema = z9.object({
761
+ var stringRecordSchema = z10.record(z10.string());
762
+ var knowledgeContextPlannedEventSchema = z10.object({
611
763
  ...eventLedgerEnvelopeSchema,
612
- event_type: z9.literal("knowledge_context_planned"),
613
- target_paths: z9.array(z9.string()),
614
- required_stable_ids: z9.array(z9.string()),
615
- ai_selectable_stable_ids: z9.array(z9.string()),
616
- final_stable_ids: z9.array(z9.string()),
617
- selection_token: z9.string().optional(),
618
- client_hash: z9.string().optional(),
619
- intent: z9.string().optional(),
620
- known_tech: z9.array(z9.string()).optional(),
621
- diagnostics: z9.array(z9.unknown()).optional()
622
- });
623
- var knowledgeSelectionEventSchema = z9.object({
764
+ event_type: z10.literal("knowledge_context_planned"),
765
+ target_paths: z10.array(z10.string()),
766
+ required_stable_ids: z10.array(z10.string()),
767
+ ai_selectable_stable_ids: z10.array(z10.string()),
768
+ final_stable_ids: z10.array(z10.string()),
769
+ selection_token: z10.string().optional(),
770
+ client_hash: z10.string().optional(),
771
+ intent: z10.string().optional(),
772
+ known_tech: z10.array(z10.string()).optional(),
773
+ diagnostics: z10.array(z10.unknown()).optional()
774
+ });
775
+ var knowledgeSelectionEventSchema = z10.object({
624
776
  ...eventLedgerEnvelopeSchema,
625
- event_type: z9.literal("knowledge_selection"),
626
- selection_token: z9.string(),
627
- target_paths: z9.array(z9.string()),
628
- required_stable_ids: z9.array(z9.string()),
629
- ai_selectable_stable_ids: z9.array(z9.string()),
630
- ai_selected_stable_ids: z9.array(z9.string()),
631
- final_stable_ids: z9.array(z9.string()),
777
+ event_type: z10.literal("knowledge_selection"),
778
+ selection_token: z10.string(),
779
+ target_paths: z10.array(z10.string()),
780
+ required_stable_ids: z10.array(z10.string()),
781
+ ai_selectable_stable_ids: z10.array(z10.string()),
782
+ ai_selected_stable_ids: z10.array(z10.string()),
783
+ final_stable_ids: z10.array(z10.string()),
632
784
  ai_selection_reasons: stringRecordSchema,
633
- rejected_stable_ids: z9.array(z9.string()),
634
- ignored_stable_ids: z9.array(z9.string())
785
+ rejected_stable_ids: z10.array(z10.string()),
786
+ ignored_stable_ids: z10.array(z10.string())
635
787
  });
636
- var knowledgeSectionsFetchedEventSchema = z9.object({
788
+ var knowledgeSectionsFetchedEventSchema = z10.object({
637
789
  ...eventLedgerEnvelopeSchema,
638
- event_type: z9.literal("knowledge_sections_fetched"),
639
- selection_token: z9.string(),
640
- target_paths: z9.array(z9.string()).optional(),
641
- requested_sections: z9.array(z9.string()),
642
- final_stable_ids: z9.array(z9.string()),
643
- ai_selected_stable_ids: z9.array(z9.string()),
644
- diagnostics: z9.array(z9.unknown()).optional()
645
- });
646
- var editIntentCheckedEventSchema = z9.object({
790
+ event_type: z10.literal("knowledge_sections_fetched"),
791
+ selection_token: z10.string(),
792
+ target_paths: z10.array(z10.string()).optional(),
793
+ requested_sections: z10.array(z10.string()),
794
+ final_stable_ids: z10.array(z10.string()),
795
+ ai_selected_stable_ids: z10.array(z10.string()),
796
+ diagnostics: z10.array(z10.unknown()).optional()
797
+ });
798
+ var editIntentCheckedEventSchema = z10.object({
647
799
  ...eventLedgerEnvelopeSchema,
648
- event_type: z9.literal("edit_intent_checked"),
649
- path: z9.string(),
650
- compliant: z9.boolean(),
651
- intent: z9.string(),
652
- ledger_entry_id: z9.string(),
653
- ledger_source: z9.enum(["ai", "human"]).optional(),
654
- commit_sha: z9.string().optional(),
655
- parent_sha: z9.string().optional(),
656
- parent_ledger_entry_id: z9.string().optional(),
657
- diff_stat: z9.string().optional(),
658
- annotation: z9.string().optional(),
659
- matched_rule_context_ts: z9.number().int().nonnegative().nullable(),
660
- window_ms: z9.number().int().nonnegative()
661
- });
662
- var knowledgeDriftDetectedEventSchema = z9.object({
800
+ event_type: z10.literal("edit_intent_checked"),
801
+ path: z10.string(),
802
+ compliant: z10.boolean(),
803
+ intent: z10.string(),
804
+ ledger_entry_id: z10.string(),
805
+ ledger_source: z10.enum(["ai", "human"]).optional(),
806
+ commit_sha: z10.string().optional(),
807
+ parent_sha: z10.string().optional(),
808
+ parent_ledger_entry_id: z10.string().optional(),
809
+ diff_stat: z10.string().optional(),
810
+ annotation: z10.string().optional(),
811
+ matched_rule_context_ts: z10.number().int().nonnegative().nullable(),
812
+ window_ms: z10.number().int().nonnegative()
813
+ });
814
+ var knowledgeDriftDetectedEventSchema = z10.object({
663
815
  ...eventLedgerEnvelopeSchema,
664
- event_type: z9.literal("knowledge_drift_detected"),
665
- revision: z9.string().optional(),
666
- drifted_stable_ids: z9.array(z9.string()),
667
- missing_files: z9.array(z9.string()),
668
- stale_files: z9.array(z9.string()),
669
- details: z9.array(
670
- z9.object({
671
- file: z9.string(),
672
- stable_id: z9.string(),
673
- expected_hash: z9.string(),
674
- actual_hash: z9.string().nullable()
816
+ event_type: z10.literal("knowledge_drift_detected"),
817
+ revision: z10.string().optional(),
818
+ drifted_stable_ids: z10.array(z10.string()),
819
+ missing_files: z10.array(z10.string()),
820
+ stale_files: z10.array(z10.string()),
821
+ details: z10.array(
822
+ z10.object({
823
+ file: z10.string(),
824
+ stable_id: z10.string(),
825
+ expected_hash: z10.string(),
826
+ actual_hash: z10.string().nullable()
675
827
  })
676
828
  ).optional()
677
829
  });
678
- var mcpEventLedgerEventSchema = z9.object({
830
+ var mcpEventLedgerEventSchema = z10.object({
679
831
  ...eventLedgerEnvelopeSchema,
680
- event_type: z9.literal("mcp_event"),
681
- mcp_event_id: z9.string(),
682
- stream_id: z9.string(),
683
- message: z9.unknown()
832
+ event_type: z10.literal("mcp_event"),
833
+ mcp_event_id: z10.string(),
834
+ stream_id: z10.string(),
835
+ message: z10.unknown()
684
836
  });
685
- var reapplyCompletedEventSchema = z9.object({
837
+ var reapplyCompletedEventSchema = z10.object({
686
838
  ...eventLedgerEnvelopeSchema,
687
- event_type: z9.literal("reapply_completed"),
688
- preserved_ledger: z9.boolean(),
689
- preserved_meta: z9.boolean(),
690
- rules_count: z9.number().int().nonnegative()
839
+ event_type: z10.literal("reapply_completed"),
840
+ preserved_ledger: z10.boolean(),
841
+ preserved_meta: z10.boolean(),
842
+ rules_count: z10.number().int().nonnegative()
691
843
  });
692
- var eventLedgerTruncatedEventSchema = z9.object({
844
+ var eventLedgerTruncatedEventSchema = z10.object({
693
845
  ...eventLedgerEnvelopeSchema,
694
- event_type: z9.literal("event_ledger_truncated"),
695
- byte_offset: z9.number().int().nonnegative(),
696
- byte_length: z9.number().int().nonnegative(),
697
- corrupted_path: z9.string()
846
+ event_type: z10.literal("event_ledger_truncated"),
847
+ byte_offset: z10.number().int().nonnegative(),
848
+ byte_length: z10.number().int().nonnegative(),
849
+ corrupted_path: z10.string()
698
850
  });
699
- var mcpConfigMigratedEventSchema = z9.object({
851
+ var mcpConfigMigratedEventSchema = z10.object({
700
852
  ...eventLedgerEnvelopeSchema,
701
- event_type: z9.literal("mcp_config_migrated"),
702
- source: z9.literal("doctor_fix"),
703
- removed_from: z9.string()
853
+ event_type: z10.literal("mcp_config_migrated"),
854
+ source: z10.literal("doctor_fix"),
855
+ removed_from: z10.string()
704
856
  });
705
- var metaReconciledOnStartupEventSchema = z9.object({
857
+ var bootstrapMarkerMigratedEventSchema = z10.object({
706
858
  ...eventLedgerEnvelopeSchema,
707
- event_type: z9.literal("meta_reconciled_on_startup"),
708
- reconciled_files: z9.array(z9.string()),
709
- duration_ms: z9.number().int().nonnegative(),
710
- source: z9.literal("reconcileKnowledge")
859
+ event_type: z10.literal("bootstrap_marker_migrated"),
860
+ path: z10.string(),
861
+ migrated_count: z10.number().int().nonnegative(),
862
+ legacy_marker: z10.literal("fabric:knowledge-base"),
863
+ new_marker: z10.literal("fabric:bootstrap"),
864
+ timestamp: z10.string()
711
865
  });
712
- var metaReconciledEventSchema = z9.object({
866
+ var metaReconciledOnStartupEventSchema = z10.object({
713
867
  ...eventLedgerEnvelopeSchema,
714
- event_type: z9.literal("meta_reconciled"),
715
- reconciled_files: z9.array(z9.string()),
716
- duration_ms: z9.number().int().nonnegative(),
717
- trigger: z9.enum(["doctor", "manual"]),
718
- source: z9.literal("reconcileKnowledge")
868
+ event_type: z10.literal("meta_reconciled_on_startup"),
869
+ reconciled_files: z10.array(z10.string()),
870
+ duration_ms: z10.number().int().nonnegative(),
871
+ source: z10.literal("reconcileKnowledge")
719
872
  });
720
- var claudeSkillPathMigratedEventSchema = z9.object({
873
+ var metaReconciledEventSchema = z10.object({
721
874
  ...eventLedgerEnvelopeSchema,
722
- event_type: z9.literal("claude_skill_path_migrated"),
723
- from: z9.string(),
724
- to: z9.string()
875
+ event_type: z10.literal("meta_reconciled"),
876
+ reconciled_files: z10.array(z10.string()),
877
+ duration_ms: z10.number().int().nonnegative(),
878
+ trigger: z10.enum(["doctor", "manual"]),
879
+ source: z10.literal("reconcileKnowledge")
725
880
  });
726
- var claudeHookPathMigratedEventSchema = z9.object({
881
+ var claudeSkillPathMigratedEventSchema = z10.object({
727
882
  ...eventLedgerEnvelopeSchema,
728
- event_type: z9.literal("claude_hook_path_migrated"),
729
- from: z9.string(),
730
- to: z9.string()
883
+ event_type: z10.literal("claude_skill_path_migrated"),
884
+ from: z10.string(),
885
+ to: z10.string()
731
886
  });
732
- var codexSkillPathMigratedEventSchema = z9.object({
887
+ var claudeHookPathMigratedEventSchema = z10.object({
733
888
  ...eventLedgerEnvelopeSchema,
734
- event_type: z9.literal("codex_skill_path_migrated"),
735
- from: z9.string(),
736
- to: z9.string()
889
+ event_type: z10.literal("claude_hook_path_migrated"),
890
+ from: z10.string(),
891
+ to: z10.string()
737
892
  });
738
- var initScanCompletedEventSchema = z9.object({
893
+ var codexSkillPathMigratedEventSchema = z10.object({
739
894
  ...eventLedgerEnvelopeSchema,
740
- event_type: z9.literal("init_scan_completed"),
741
- written_stable_ids: z9.array(z9.string()),
742
- duration_ms: z9.number().int().nonnegative(),
743
- source: z9.enum(["init", "scan", "doctor_fix"]).optional()
895
+ event_type: z10.literal("codex_skill_path_migrated"),
896
+ from: z10.string(),
897
+ to: z10.string()
744
898
  });
745
- var knowledgeProposedEventSchema = z9.object({
899
+ var initScanCompletedEventSchema = z10.object({
746
900
  ...eventLedgerEnvelopeSchema,
747
- event_type: z9.literal("knowledge_proposed"),
748
- stable_id: z9.string().optional(),
749
- timestamp: z9.string().datetime(),
750
- reason: z9.string().optional()
901
+ event_type: z10.literal("init_scan_completed"),
902
+ written_stable_ids: z10.array(z10.string()),
903
+ duration_ms: z10.number().int().nonnegative(),
904
+ source: z10.enum(["init", "scan", "doctor_fix", "doctor-rescan"]).optional()
751
905
  });
752
- var knowledgePromoteStartedEventSchema = z9.object({
906
+ var knowledgeProposedEventSchema = z10.object({
753
907
  ...eventLedgerEnvelopeSchema,
754
- event_type: z9.literal("knowledge_promote_started"),
755
- stable_id: z9.string().optional(),
756
- timestamp: z9.string().datetime(),
757
- reason: z9.string().optional()
908
+ event_type: z10.literal("knowledge_proposed"),
909
+ stable_id: z10.string().optional(),
910
+ timestamp: z10.string().datetime(),
911
+ reason: z10.string().optional()
758
912
  });
759
- var knowledgePromotedEventSchema = z9.object({
913
+ var knowledgePromoteStartedEventSchema = z10.object({
760
914
  ...eventLedgerEnvelopeSchema,
761
- event_type: z9.literal("knowledge_promoted"),
762
- stable_id: z9.string().optional(),
763
- timestamp: z9.string().datetime(),
764
- reason: z9.string().optional()
915
+ event_type: z10.literal("knowledge_promote_started"),
916
+ stable_id: z10.string().optional(),
917
+ timestamp: z10.string().datetime(),
918
+ reason: z10.string().optional()
765
919
  });
766
- var knowledgePromoteFailedEventSchema = z9.object({
920
+ var knowledgePromotedEventSchema = z10.object({
767
921
  ...eventLedgerEnvelopeSchema,
768
- event_type: z9.literal("knowledge_promote_failed"),
769
- stable_id: z9.string().optional(),
770
- timestamp: z9.string().datetime(),
771
- reason: z9.string()
922
+ event_type: z10.literal("knowledge_promoted"),
923
+ stable_id: z10.string().optional(),
924
+ timestamp: z10.string().datetime(),
925
+ reason: z10.string().optional()
772
926
  });
773
- var knowledgeLayerChangedEventSchema = z9.object({
927
+ var knowledgePromoteFailedEventSchema = z10.object({
774
928
  ...eventLedgerEnvelopeSchema,
775
- event_type: z9.literal("knowledge_layer_changed"),
776
- stable_id: z9.string().optional(),
777
- timestamp: z9.string().datetime(),
778
- reason: z9.string().optional(),
779
- from_layer: z9.enum(["team", "personal"]),
780
- to_layer: z9.enum(["team", "personal"])
781
- });
782
- var knowledgeSlugRenamedEventSchema = z9.object({
929
+ event_type: z10.literal("knowledge_promote_failed"),
930
+ stable_id: z10.string().optional(),
931
+ timestamp: z10.string().datetime(),
932
+ reason: z10.string()
933
+ });
934
+ var knowledgeLayerChangedEventSchema = z10.object({
783
935
  ...eventLedgerEnvelopeSchema,
784
- event_type: z9.literal("knowledge_slug_renamed"),
785
- stable_id: z9.string().optional(),
786
- timestamp: z9.string().datetime(),
787
- reason: z9.string().optional(),
788
- from_slug: z9.string(),
789
- to_slug: z9.string()
790
- });
791
- var knowledgeDemotedEventSchema = z9.object({
936
+ event_type: z10.literal("knowledge_layer_changed"),
937
+ stable_id: z10.string().optional(),
938
+ timestamp: z10.string().datetime(),
939
+ reason: z10.string().optional(),
940
+ from_layer: z10.enum(["team", "personal"]),
941
+ to_layer: z10.enum(["team", "personal"])
942
+ });
943
+ var knowledgeSlugRenamedEventSchema = z10.object({
792
944
  ...eventLedgerEnvelopeSchema,
793
- event_type: z9.literal("knowledge_demoted"),
794
- stable_id: z9.string().optional(),
795
- timestamp: z9.string().datetime(),
796
- reason: z9.string().optional()
945
+ event_type: z10.literal("knowledge_slug_renamed"),
946
+ stable_id: z10.string().optional(),
947
+ timestamp: z10.string().datetime(),
948
+ reason: z10.string().optional(),
949
+ from_slug: z10.string(),
950
+ to_slug: z10.string()
797
951
  });
798
- var knowledgeArchivedEventSchema = z9.object({
952
+ var knowledgeDemotedEventSchema = z10.object({
799
953
  ...eventLedgerEnvelopeSchema,
800
- event_type: z9.literal("knowledge_archived"),
801
- stable_id: z9.string().optional(),
802
- timestamp: z9.string().datetime(),
803
- reason: z9.string().optional()
954
+ event_type: z10.literal("knowledge_demoted"),
955
+ stable_id: z10.string().optional(),
956
+ timestamp: z10.string().datetime(),
957
+ reason: z10.string().optional()
804
958
  });
805
- var knowledgeArchiveAttemptedEventSchema = z9.object({
959
+ var knowledgeArchivedEventSchema = z10.object({
806
960
  ...eventLedgerEnvelopeSchema,
807
- event_type: z9.literal("knowledge_archive_attempted"),
808
- stable_id: z9.string().optional(),
809
- timestamp: z9.string().datetime(),
810
- reason: z9.string().optional()
961
+ event_type: z10.literal("knowledge_archived"),
962
+ stable_id: z10.string().optional(),
963
+ timestamp: z10.string().datetime(),
964
+ reason: z10.string().optional()
811
965
  });
812
- var knowledgeDeferredEventSchema = z9.object({
966
+ var knowledgeArchiveAttemptedEventSchema = z10.object({
813
967
  ...eventLedgerEnvelopeSchema,
814
- event_type: z9.literal("knowledge_deferred"),
815
- stable_id: z9.string().optional(),
816
- timestamp: z9.string().datetime(),
817
- reason: z9.string().optional(),
818
- until: z9.string().datetime().optional()
968
+ event_type: z10.literal("knowledge_archive_attempted"),
969
+ stable_id: z10.string().optional(),
970
+ timestamp: z10.string().datetime(),
971
+ reason: z10.string().optional()
819
972
  });
820
- var knowledgeRejectedEventSchema = z9.object({
973
+ var knowledgeDeferredEventSchema = z10.object({
821
974
  ...eventLedgerEnvelopeSchema,
822
- event_type: z9.literal("knowledge_rejected"),
823
- stable_id: z9.string().optional(),
824
- timestamp: z9.string().datetime(),
825
- reason: z9.string()
975
+ event_type: z10.literal("knowledge_deferred"),
976
+ stable_id: z10.string().optional(),
977
+ timestamp: z10.string().datetime(),
978
+ reason: z10.string().optional(),
979
+ until: z10.string().datetime().optional()
826
980
  });
827
- var knowledgeConsumedEventSchema = z9.object({
981
+ var knowledgeRejectedEventSchema = z10.object({
828
982
  ...eventLedgerEnvelopeSchema,
829
- event_type: z9.literal("knowledge_consumed"),
830
- stable_id: z9.string(),
831
- consumed_at: z9.string().datetime(),
832
- client_hash: z9.string()
983
+ event_type: z10.literal("knowledge_rejected"),
984
+ stable_id: z10.string().optional(),
985
+ timestamp: z10.string().datetime(),
986
+ reason: z10.string()
833
987
  });
834
- var knowledgeScopeDegradedEventSchema = z9.object({
988
+ var knowledgeConsumedEventSchema = z10.object({
835
989
  ...eventLedgerEnvelopeSchema,
836
- event_type: z9.literal("knowledge_scope_degraded"),
837
- stable_id: z9.string(),
838
- timestamp: z9.string().datetime(),
839
- from_scope: z9.enum(["narrow", "broad"]),
840
- to_scope: z9.enum(["narrow", "broad"]),
841
- reason: z9.string()
842
- });
843
- var doctorRunEventSchema = z9.object({
990
+ event_type: z10.literal("knowledge_consumed"),
991
+ stable_id: z10.string(),
992
+ consumed_at: z10.string().datetime(),
993
+ client_hash: z10.string()
994
+ });
995
+ var knowledgeScopeDegradedEventSchema = z10.object({
844
996
  ...eventLedgerEnvelopeSchema,
845
- event_type: z9.literal("doctor_run"),
846
- mode: z9.enum(["lint", "apply-lint"]),
847
- issues: z9.number().int().nonnegative(),
848
- mutations: z9.number().int().nonnegative().optional(),
849
- timestamp: z9.string().datetime()
997
+ event_type: z10.literal("knowledge_scope_degraded"),
998
+ stable_id: z10.string(),
999
+ timestamp: z10.string().datetime(),
1000
+ from_scope: z10.enum(["narrow", "broad"]),
1001
+ to_scope: z10.enum(["narrow", "broad"]),
1002
+ reason: z10.string()
850
1003
  });
851
- var knowledgePathDangledEventSchema = z9.object({
1004
+ var doctorRunEventSchema = z10.object({
852
1005
  ...eventLedgerEnvelopeSchema,
853
- event_type: z9.literal("knowledge_path_dangled"),
854
- stable_id: z9.string(),
855
- removed_glob: z9.string()
1006
+ event_type: z10.literal("doctor_run"),
1007
+ mode: z10.enum(["lint", "fix-knowledge"]),
1008
+ issues: z10.number().int().nonnegative(),
1009
+ mutations: z10.number().int().nonnegative().optional(),
1010
+ timestamp: z10.string().datetime()
856
1011
  });
857
- var relevanceMigrationRunEventSchema = z9.object({
1012
+ var knowledgePathDangledEventSchema = z10.object({
858
1013
  ...eventLedgerEnvelopeSchema,
859
- event_type: z9.literal("relevance_migration_run"),
860
- timestamp: z9.string().datetime(),
861
- scanned_count: z9.number().int().nonnegative(),
862
- touched_count: z9.number().int().nonnegative()
1014
+ event_type: z10.literal("knowledge_path_dangled"),
1015
+ stable_id: z10.string(),
1016
+ removed_glob: z10.string()
863
1017
  });
864
- var pendingAutoArchivedEventSchema = z9.object({
1018
+ var relevanceMigrationRunEventSchema = z10.object({
865
1019
  ...eventLedgerEnvelopeSchema,
866
- event_type: z9.literal("pending_auto_archived"),
867
- pending_path: z9.string(),
868
- archived_to: z9.string(),
869
- reason: z9.string()
1020
+ event_type: z10.literal("relevance_migration_run"),
1021
+ timestamp: z10.string().datetime(),
1022
+ scanned_count: z10.number().int().nonnegative(),
1023
+ touched_count: z10.number().int().nonnegative()
870
1024
  });
871
- var eventLedgerEventSchema = z9.discriminatedUnion("event_type", [
1025
+ var pendingAutoArchivedEventSchema = z10.object({
1026
+ ...eventLedgerEnvelopeSchema,
1027
+ event_type: z10.literal("pending_auto_archived"),
1028
+ pending_path: z10.string(),
1029
+ archived_to: z10.string(),
1030
+ reason: z10.string()
1031
+ });
1032
+ var assistantTurnObservedEventSchema = z10.object({
1033
+ ...eventLedgerEnvelopeSchema,
1034
+ event_type: z10.literal("assistant_turn_observed"),
1035
+ kb_line_raw: z10.string().nullable(),
1036
+ cite_ids: z10.array(z10.string()).default([]),
1037
+ cite_tags: z10.array(z10.enum(["planned", "recalled", "chained-from", "dismissed", "none"])).default([]),
1038
+ client: z10.enum(["cc", "codex", "cursor"]).optional(),
1039
+ turn_id: z10.string(),
1040
+ envelope_index: z10.number().int().nonnegative().optional(),
1041
+ timestamp: z10.string().datetime()
1042
+ });
1043
+ var citePolicyActivatedEventSchema = z10.object({
1044
+ ...eventLedgerEnvelopeSchema,
1045
+ event_type: z10.literal("cite_policy_activated"),
1046
+ policy_version: z10.string(),
1047
+ timestamp: z10.string().datetime()
1048
+ });
1049
+ var eventLedgerEventSchema = z10.discriminatedUnion("event_type", [
872
1050
  knowledgeContextPlannedEventSchema,
873
1051
  knowledgeSelectionEventSchema,
874
1052
  knowledgeSectionsFetchedEventSchema,
@@ -878,6 +1056,9 @@ var eventLedgerEventSchema = z9.discriminatedUnion("event_type", [
878
1056
  reapplyCompletedEventSchema,
879
1057
  eventLedgerTruncatedEventSchema,
880
1058
  mcpConfigMigratedEventSchema,
1059
+ // v2.0.0-rc.19 TASK-004: bootstrap_marker_migrated — one-time fabric:knowledge-base
1060
+ // → fabric:bootstrap marker rewrite emitted per file by `fab doctor --fix`.
1061
+ bootstrapMarkerMigratedEventSchema,
881
1062
  metaReconciledOnStartupEventSchema,
882
1063
  metaReconciledEventSchema,
883
1064
  claudeSkillPathMigratedEventSchema,
@@ -910,13 +1091,23 @@ var eventLedgerEventSchema = z9.discriminatedUnion("event_type", [
910
1091
  doctorRunEventSchema,
911
1092
  // v2.0.0-rc.9 TASK-003 (A3): relevance_migration_run — emitted by
912
1093
  // `doctor --apply-lint` after the lint #26 frontmatter back-fill pass.
913
- relevanceMigrationRunEventSchema
1094
+ relevanceMigrationRunEventSchema,
1095
+ // v2.0.0-rc.20 TASK-02: assistant_turn_observed — per-turn cite-policy
1096
+ // observation (raw KB: line text + parsed cite_ids/cite_tags + client).
1097
+ assistantTurnObservedEventSchema,
1098
+ // v2.0.0-rc.20 TASK-02: cite_policy_activated — session/policy-bump
1099
+ // marker recording when a given policy_version became active.
1100
+ citePolicyActivatedEventSchema
914
1101
  ]);
915
1102
  export {
916
1103
  AGENTS_META_IDENTITY_SOURCES,
917
1104
  AGENTS_META_LAYERS,
918
1105
  AGENTS_META_TOPOLOGY_TYPES,
919
1106
  AgentsMetaCountersSchema,
1107
+ BOOTSTRAP_CANONICAL,
1108
+ BOOTSTRAP_MARKER_BEGIN,
1109
+ BOOTSTRAP_MARKER_END,
1110
+ BOOTSTRAP_REGEX,
920
1111
  FabExtractKnowledgeInputSchema,
921
1112
  FabExtractKnowledgeInputShape,
922
1113
  FabExtractKnowledgeOutputSchema,
@@ -928,6 +1119,9 @@ export {
928
1119
  KNOWLEDGE_TYPE_CODES,
929
1120
  KnowledgeEntryFrontmatterSchema,
930
1121
  KnowledgeTypeSchema,
1122
+ LEGACY_KB_MARKER_BEGIN,
1123
+ LEGACY_KB_MARKER_END,
1124
+ LEGACY_KB_REGEX,
931
1125
  LayerSchema,
932
1126
  MaturitySchema,
933
1127
  PROPOSED_REASON_DESCRIPTIONS,
@@ -942,8 +1136,11 @@ export {
942
1136
  aiLedgerEntrySchema,
943
1137
  allocateKnowledgeId,
944
1138
  annotateIntentRequestSchema,
1139
+ assistantTurnObservedEventSchema,
945
1140
  auditModeSchema,
1141
+ bootstrapMarkerMigratedEventSchema,
946
1142
  candidateFileEntrySchema,
1143
+ citePolicyActivatedEventSchema,
947
1144
  claudeHookPathMigratedEventSchema,
948
1145
  claudeSkillPathMigratedEventSchema,
949
1146
  clientPathsSchema,
@@ -982,6 +1179,8 @@ export {
982
1179
  getKnowledgeAnnotations,
983
1180
  getKnowledgeInputSchema,
984
1181
  getKnowledgeOutputSchema,
1182
+ getPanelFieldByKey,
1183
+ getPanelFields,
985
1184
  historyStateQuerySchema,
986
1185
  humanLedgerEntrySchema,
987
1186
  humanLockApproveRequestSchema,