@oscaner-skills/cdd-engine 2.0.0 → 3.0.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.
Files changed (84) hide show
  1. package/README.md +2 -2
  2. package/README.zh-CN.md +2 -2
  3. package/package.json +4 -3
  4. package/src-next/__tests__/dead-decl.guard.test.ts +39 -0
  5. package/src-next/__tests__/floor.guard.test.ts +69 -0
  6. package/src-next/__tests__/issue-body.guard.test.ts +66 -0
  7. package/src-next/__tests__/phase-suffix.guard.test.ts +72 -0
  8. package/src-next/__tests__/smoke.integration.test.ts +60 -77
  9. package/src-next/__tests__/support/strip-comments.ts +99 -0
  10. package/src-next/__tests__/zero-dep.test.ts +6 -46
  11. package/src-next/contract/__tests__/__snapshots__/project.schema.overall-spec.snap +39 -21
  12. package/src-next/contract/__tests__/__snapshots__/project.schema.phase-spec.snap +40 -28
  13. package/src-next/contract/__tests__/__snapshots__/project.schema.plan.snap +40 -23
  14. package/src-next/contract/__tests__/__snapshots__/project.schema.single-spec.snap +38 -21
  15. package/src-next/contract/__tests__/__snapshots__/project.shape.overall-spec.snap +21 -6
  16. package/src-next/contract/__tests__/__snapshots__/project.shape.phase-spec.snap +22 -12
  17. package/src-next/contract/__tests__/__snapshots__/project.shape.plan.snap +23 -8
  18. package/src-next/contract/__tests__/__snapshots__/project.shape.single-spec.snap +21 -6
  19. package/src-next/contract/__tests__/declare.test.ts +251 -12
  20. package/src-next/contract/__tests__/doc.test.ts +214 -45
  21. package/src-next/contract/__tests__/dockey.guard.test.ts +58 -0
  22. package/src-next/contract/__tests__/edge-conditions.guard.test.ts +81 -0
  23. package/src-next/contract/__tests__/frontmatter.test.ts +164 -0
  24. package/src-next/contract/__tests__/judge.test.ts +410 -172
  25. package/src-next/contract/__tests__/lint.test.ts +49 -39
  26. package/src-next/contract/__tests__/project.test.ts +60 -19
  27. package/src-next/contract/__tests__/structure-pin.test.ts +186 -0
  28. package/src-next/contract/declare.ts +179 -91
  29. package/src-next/contract/doc.ts +227 -164
  30. package/src-next/contract/frontmatter.ts +233 -0
  31. package/src-next/contract/home-extractors.ts +397 -0
  32. package/src-next/contract/invariants.ts +214 -69
  33. package/src-next/contract/judge.ts +28 -19
  34. package/src-next/contract/lint.ts +5 -41
  35. package/src-next/contract/project.ts +103 -43
  36. package/src-next/contract/skill-anatomy.ts +39 -11
  37. package/src-next/face/__tests__/board-view.test.ts +318 -115
  38. package/src-next/face/__tests__/capsule.test.ts +49 -25
  39. package/src-next/face/__tests__/channel-closure.guard.test.ts +28 -1
  40. package/src-next/face/__tests__/cli.test.ts +1091 -837
  41. package/src-next/face/__tests__/face.test.ts +5 -5
  42. package/src-next/face/__tests__/install-rows.guard.test.ts +58 -0
  43. package/src-next/face/__tests__/preview.test.ts +374 -0
  44. package/src-next/face/__tests__/projection.test.ts +5 -3
  45. package/src-next/face/__tests__/repo-root.guard.test.ts +120 -0
  46. package/src-next/face/__tests__/termination.test.ts +650 -0
  47. package/src-next/face/artifacts.ts +90 -37
  48. package/src-next/face/board-view.ts +128 -138
  49. package/src-next/face/capsule.ts +30 -16
  50. package/src-next/face/cli.ts +306 -97
  51. package/src-next/face/declare.ts +15 -18
  52. package/src-next/face/gate.ts +19 -18
  53. package/src-next/face/host.ts +6 -30
  54. package/src-next/face/lifecycle.ts +213 -188
  55. package/src-next/face/preview.ts +151 -0
  56. package/src-next/face/projection.ts +4 -1
  57. package/src-next/face/route-render.ts +39 -14
  58. package/src-next/face/termination.ts +573 -0
  59. package/src-next/face/words.ts +20 -2
  60. package/src-next/infra/__tests__/infra.test.ts +49 -3
  61. package/src-next/infra/__tests__/root.test.ts +56 -0
  62. package/src-next/infra/doc-roots.ts +29 -0
  63. package/src-next/infra/root.ts +73 -0
  64. package/src-next/infra/runtime.ts +12 -65
  65. package/src-next/infra/workspace.ts +95 -5
  66. package/src-next/render/__tests__/render.test.ts +92 -41
  67. package/src-next/render/__tests__/skeleton.test.ts +282 -64
  68. package/src-next/render/issue-body.ts +5 -2
  69. package/src-next/render/skeleton.ts +155 -90
  70. package/src-next/render/templates.ts +51 -56
  71. package/src-next/session/__tests__/graph.test.ts +11 -4
  72. package/src-next/session/__tests__/ledger.test.ts +3 -2
  73. package/src-next/session/__tests__/next.test.ts +100 -8
  74. package/src-next/session/__tests__/preflight.test.ts +79 -25
  75. package/src-next/session/__tests__/round-naming.test.ts +142 -0
  76. package/src-next/session/__tests__/run.test.ts +140 -128
  77. package/src-next/session/__tests__/wave.test.ts +11 -4
  78. package/src-next/session/ledger.ts +96 -24
  79. package/src-next/session/next.ts +116 -15
  80. package/src-next/session/preflight.ts +41 -10
  81. package/src-next/session/round-naming.ts +84 -0
  82. package/src-next/session/run.ts +24 -20
  83. package/templates/report/issue-body.json +0 -46
  84. package/src-next/face/__tests__/sync-runner.test.ts +0 -70
@@ -13,19 +13,22 @@
13
13
  // · schema — a JSON Schema per doc type (properties keyed by anchor, the
14
14
  // required set from the required-presence elements, property
15
15
  // descriptions carrying presence · home · ref-kind);
16
- // · slices — the parse face: every element's anchor-literal slice (escaped
17
- // anchor, closed under parsing — each slice parses its anchor)
18
- // plus the declared value pattern compiled for line/cell
19
- // matching;
16
+ // · slices — the parse face: every element's anchor-literal slice plus the
17
+ // declared value pattern compiled for line/cell matching.
18
+ // Frontmatter-home elements are exempt from both compilations —
19
+ // their anchor is a YAML key, looked up directly against the
20
+ // parsed front-matter, never scanned line-by-line (§3.3);
20
21
  // · tokens — the flat anchor lexicon, one token per registered element;
21
22
  // · reference — the per-element reference vocabulary (ref-kind + value
22
23
  // pattern), one entry per registered element;
23
- // · skeleton — the required-only doc-skeleton face (spec §4.1): every
24
- // required element classified into its placeholder-anchoring
25
- // slot kind (content / link / numeric-heading / generator-truth
26
- // / table-header / table-row / scaffold) in shape-group order —
27
- // the skeleton the `cdd schema get <type> --output skeleton`
28
- // render face (D19) assembles.
24
+ // · skeleton — the doc-skeleton face (spec §4.1/§4.2): every required
25
+ // element classified into its placeholder-anchoring slot kind
26
+ // (content / link / numeric-heading / generator-truth /
27
+ // table-header / table-row / scaffold) in shape-group order,
28
+ // plus the independent front-matter emission list (the head's
29
+ // required + optional keys) — the skeleton the
30
+ // `cdd schema get <type> --output skeleton` render face (D19)
31
+ // assembles.
29
32
  //
30
33
  // The module's whole behavior surface is the Projector class (the zero-bare-
31
34
  // function discipline: module-level exports are types / the class — the projection
@@ -43,9 +46,20 @@ import type {
43
46
  RefKind,
44
47
  RegistryElement,
45
48
  } from "./declare.ts";
49
+ import { DOC_TYPE_VALUES } from "./declare.ts";
46
50
 
47
- /** The projection record keys — mirrors the declared-registries record shape ({ "overall-spec", plan, "phase-spec", "single-spec" }). */
48
- export type DocKey = "overall-spec" | "plan" | "phase-spec" | "single-spec";
51
+ /** The projection record keys — the declared-registries record shape ({ "overall-spec",
52
+ * plan, "phase-spec", "single-spec" }). Derived from the ONE declaration root
53
+ * (declare.ts): the `DocKey` type aliases `DocType` and the runtime `DOC_KEYS`
54
+ * tuple aliases `DOC_TYPE_VALUES`, so the value domain has a single source (spec
55
+ * §3.2 ③) — judge/declare/board-view all consume these, never a second copy. */
56
+ export type DocKey = DocType;
57
+
58
+ /** The four doc-type record keys in canonical order — the runtime companion of
59
+ * `DocKey`, re-exported from the declaration root (declare.ts `DOC_TYPE_VALUES`).
60
+ * The judge's policy composition and the board's declaration domain read THIS
61
+ * tuple; a value drift is impossible (one array). */
62
+ export const DOC_KEYS = DOC_TYPE_VALUES;
49
63
 
50
64
  // ---------------------------------------------------------------------------
51
65
  // shared derivation chain
@@ -140,12 +154,17 @@ export interface ElementSlice {
140
154
  /** The document surface the anchor lives in. */
141
155
  home: Home;
142
156
  /**
143
- * The anchor-literal slice — the escaped anchor compiled. It parses the
144
- * anchor itself (each slice parses its own anchor) and locates the literal
145
- * token inside a document line.
157
+ * The anchor-literal slice — the escaped anchor compiled for body surfaces
158
+ * (home !== "frontmatter"). It parses the anchor itself (each slice parses its
159
+ * own anchor) and locates the literal token inside a document line.
160
+ * Frontmatter-home elements carry no compiled pattern — their anchor is a YAML
161
+ * key, looked up directly against the parsed front-matter, never a line scan
162
+ * (§3.3).
146
163
  */
147
- anchorPattern: RegExp;
148
- /** The value slice — the declared value pattern compiled; matches the element's line/cell in a document. */
164
+ anchorPattern?: RegExp;
165
+ /** The value slice — the declared value pattern compiled for body surfaces;
166
+ * undefined on frontmatter-home elements (their values are judged against the
167
+ * declared scalar pattern in the registry, not a compiled line slice). */
149
168
  valuePattern?: RegExp;
150
169
  }
151
170
 
@@ -220,7 +239,7 @@ export type SlotKind =
220
239
  /** A digit-family heading — `N.` / `N.M` / `Task N:` render with true numbers
221
240
  * (a literal `N` would puncture the declared digit-shaped value pattern). */
222
241
  | "numeric-heading"
223
- /** A pattern-typed truth row — an enum domain's first legal literal (`**Status**:
242
+ /** A pattern-typed truth row — an enum domain's first legal literal (`status:
224
243
  * Draft`) or a graph row (hard edge / legend) — a conforming row, not a fill. */
225
244
  | "generator-truth"
226
245
  /** A table column-header row. */
@@ -231,11 +250,12 @@ export type SlotKind =
231
250
  * the fixed structure headings — structural, never fill positions. */
232
251
  | "scaffold";
233
252
 
234
- /** One skeleton slot — a required element's contribution to the assembled skeleton. */
253
+ /** One skeleton slot — an element's contribution to the assembled skeleton. */
235
254
  export interface SkeletonSlot {
236
255
  /** The machine anchor token. */
237
256
  anchor: string;
238
- /** Required elements only — every projected slot is required. */
257
+ /** The element's declared presence — always required in the body slot list;
258
+ * the front-matter emission list also carries the type's optional keys. */
239
259
  presence: Presence;
240
260
  /** The document surface the anchor lives in. */
241
261
  home: Home;
@@ -247,14 +267,22 @@ export interface SkeletonSlot {
247
267
  refKind: RefKind;
248
268
  }
249
269
 
250
- /** One doc type's skeleton projection — the required-only slot list in shape
251
- * home-group order (optional/conditional elements generate no slot — the zero
252
- * conditional-residue contract mirrored at the skeleton surface). */
270
+ /** One doc type's skeleton projection — the body slot list in shape home-group
271
+ * order (optional/conditional elements generate no slot — the zero
272
+ * conditional-residue contract mirrored at the skeleton surface) plus the
273
+ * independent front-matter emission list (spec §4.2: the required keys plus
274
+ * the type's optional frontmatter-home keys — `base` / `depends-on` — which
275
+ * never ride the slot channel). */
253
276
  export interface DocSkeleton {
254
277
  /** The doc-type identity the projection derives from. */
255
278
  docType: DocType;
256
- /** The required elements' slots in shape home-group order. */
279
+ /** The required elements' slots in shape home-group order (body + the required
280
+ * front-matter keys). */
257
281
  slots: readonly SkeletonSlot[];
282
+ /** The front-matter emission list in registry order — the required head keys
283
+ * plus the type's optional frontmatter-home keys, minus the deliberately
284
+ * omitted `parent-version` (§4.2's shape-typed exclusion). */
285
+ frontmatter: readonly SkeletonSlot[];
258
286
  }
259
287
 
260
288
  // ---------------------------------------------------------------------------
@@ -326,7 +354,8 @@ export class Projector {
326
354
  return this.#projectAll((registry) => this.#projectDocReference(registry));
327
355
  }
328
356
 
329
- /** Derive all four doc types' required-only doc-skeleton faces. */
357
+ /** Derive all four doc types' doc-skeleton faces (body slots + the front-matter
358
+ * emission list). */
330
359
  skeleton(): SkeletonProjection {
331
360
  return this.#projectAll((registry) => this.#projectDocSkeleton(registry));
332
361
  }
@@ -437,13 +466,19 @@ export class Projector {
437
466
  #projectDocSlices(registry: ElementRegistry): DocSlices {
438
467
  const slices: ElementSlice[] = [];
439
468
  for (const element of this.#deriveRegistry(registry)) {
469
+ // Frontmatter-home elements anchor on YAML keys — a key is looked up
470
+ // directly against the parsed front-matter, so both RegExp compilations
471
+ // (anchor + value) stop on the header leg (§3.3).
472
+ const header = element.home === "frontmatter";
440
473
  slices.push({
441
474
  anchor: element.anchor,
442
475
  presence: element.presence,
443
476
  home: element.home,
444
- anchorPattern: new RegExp(Projector.#escapeRegExp(element.anchor)),
477
+ anchorPattern: header ? undefined : new RegExp(Projector.#escapeRegExp(element.anchor)),
445
478
  valuePattern:
446
- element.valuePattern === undefined ? undefined : new RegExp(element.valuePattern),
479
+ element.valuePattern === undefined || header
480
+ ? undefined
481
+ : new RegExp(element.valuePattern),
447
482
  });
448
483
  }
449
484
  return { docType: registry.docType, slices };
@@ -475,14 +510,18 @@ export class Projector {
475
510
  }
476
511
 
477
512
  // -------------------------------------------------------------------------
478
- // the skeleton face — the required-only doc-skeleton projection (spec §4.1)
513
+ // the skeleton face — the doc-skeleton projection (spec §4.1/§4.2)
479
514
  // -------------------------------------------------------------------------
480
515
 
481
516
  /** Project one registry onto its doc-skeleton face — the required elements'
482
517
  * slots in the shape's home-group order (the shape walk is the ordering
483
518
  * source: group sequence + within-group registry order, never a second order
484
519
  * declaration). Optional/conditional elements generate no slot — the zero
485
- * conditional-residue contract mirrored at the skeleton surface. */
520
+ * conditional-residue contract mirrored at the skeleton surface. The
521
+ * front-matter emission list is projected independently of the slot channel
522
+ * (§4.2: required head keys + the type's optional head keys; `parent-version`
523
+ * is the one explicit exclusion — its `v<n>.<m>` domain admits no placeholder
524
+ * form). */
486
525
  #projectDocSkeleton(registry: ElementRegistry): DocSkeleton {
487
526
  const byAnchor = new Map(
488
527
  this.#deriveRegistry(registry).map((element) => [element.anchor, element]),
@@ -495,7 +534,23 @@ export class Projector {
495
534
  slots.push(this.#skeletonSlot(derived));
496
535
  }
497
536
  }
498
- return { docType: registry.docType, slots };
537
+ return { docType: registry.docType, slots, frontmatter: this.#frontmatterSlots(registry) };
538
+ }
539
+
540
+ /** The front-matter emission list — the independent line set §4.2 prescribes:
541
+ * every frontmatter-home required key plus the type's optional head keys
542
+ * (`base` / `depends-on`), in registry order. `parent-version` is the single
543
+ * explicit exclusion: an optional shape-typed key whose domain admits neither
544
+ * placeholder form, so absence is the only legal skeleton state (the consumer
545
+ * fills it when the parent version is known). */
546
+ #frontmatterSlots(registry: ElementRegistry): SkeletonSlot[] {
547
+ const out: SkeletonSlot[] = [];
548
+ for (const element of this.#deriveRegistry(registry)) {
549
+ if (element.home !== "frontmatter") continue;
550
+ if (element.anchor === "parent-version") continue;
551
+ out.push(this.#skeletonSlot(element));
552
+ }
553
+ return out;
499
554
  }
500
555
 
501
556
  /** Project one derived element onto its skeleton slot row. */
@@ -520,7 +575,7 @@ export class Projector {
520
575
  * literal `N` (a literal `N` punctures the declared
521
576
  * digit-shaped value pattern);
522
577
  * · generator-truth — a pattern-typed value row: a fully-anchored enum domain
523
- * (the first legal literal — `**Status**` → Draft) or a
578
+ * (the first legal literal — `status: Draft`) or a
524
579
  * graph row (hard edge / legend conforming lines);
525
580
  * · table-header / table-row / scaffold — the table column headers, the data
526
581
  * rows and the fixed scaffold rows (the version line, the
@@ -530,15 +585,16 @@ export class Projector {
530
585
  * fully-anchored enum / graph elements).
531
586
  */
532
587
  #skeletonSlotOf(element: DerivedElement): SlotKind {
533
- // The link-typed anchor slots are the HEADER parent-program / spec-ref links
534
- // (`**Parent program**` · the plan's `**Spec:**`) — the enum-typed table cells
535
- // (a Design-spec cell, a markdown-link implementation-plan cell) ride the
536
- // generator-truth class, never a link slot.
588
+ // The link-typed anchor slots are the front-matter link keys (`spec` · the
589
+ // `parent-program` of plan / phase-spec) — their values render as placeholder
590
+ // links (`<…>` targets on the exemption chain), never `:::fill`. The
591
+ // enum-typed table cells (a Design-spec cell, a markdown-link
592
+ // implementation-plan cell) ride the generator-truth class, never a link
593
+ // slot — the home + ref-kind pair keys the class (the frontmatter-home
594
+ // anchors are now YAML keys, so the old `\[`-shape probe no longer applies).
537
595
  if (
538
- element.home === "header" &&
539
- (element.refKind === "parent-program" || element.refKind === "spec-ref") &&
540
- element.valuePattern !== undefined &&
541
- /\\\[/.test(element.valuePattern)
596
+ element.home === "frontmatter" &&
597
+ (element.refKind === "parent-program" || element.refKind === "spec-ref")
542
598
  )
543
599
  return "link";
544
600
  if (
@@ -547,7 +603,9 @@ export class Projector {
547
603
  /\\d/.test(element.valuePattern)
548
604
  )
549
605
  return "numeric-heading";
550
- if (element.anchor === "**Version**") return "scaffold";
606
+ // The front-matter version and date rows are fixed scaffold — the same class
607
+ // as the table version/date tokens.
608
+ if (element.anchor === "version" || element.anchor === "date") return "scaffold";
551
609
  if (element.home === "graph" || Projector.#isEnumPattern(element.valuePattern))
552
610
  return "generator-truth";
553
611
  if (element.home === "table") {
@@ -559,9 +617,11 @@ export class Projector {
559
617
  if (element.anchor === "Dependency cell") return "content";
560
618
  return "scaffold";
561
619
  }
562
- // The doc title is the header's one free-text position (a fill slot) — every
563
- // other remaining heading anchor is fixed structure.
564
- if (element.anchor === "# Title") return "content";
620
+ // The front-matter content keys (the title plus the other free-text head
621
+ // scalars — author · depends-on · base) are the head's fill positions (`:::fill
622
+ // <key>` in the emitted front matter); the remaining heading anchors are fixed
623
+ // structure.
624
+ if (element.anchor === "title") return "content";
565
625
  if (element.anchor.startsWith("#")) return "scaffold";
566
626
  return "content";
567
627
  }
@@ -44,11 +44,15 @@ export interface AnatomyDigraph {
44
44
  loopHubNode: {
45
45
  name: string;
46
46
  };
47
- /** The engine-lexicon pinned loop-condition phrases (the v1.20 word-table pin) — the ONLY
48
- * condition labels the loop-family NEXT-LOOP hub's out-edges may carry (the
49
- * `until next is terminal` self-loop · the `no next` failure face — the static
50
- * digraph truth shares ONE word table with the runtime `next:` instance,
51
- * mechanically anti-drift). */
47
+ /** The loop-condition phrases the loop-family NEXT-LOOP hub's out-edges may
48
+ * carry (the `until next is terminal` self-loop · the `no next` failure face).
49
+ * This slot IS the authoritative home for the family (P9 branch-review-1 F9):
50
+ * the phrases are the SKILL-digraph EDGE-LABEL vocabulary — a consumer-surface
51
+ * prose face the runtime `next:` never emits — so there is no engine runtime
52
+ * constant to derive them from (unlike the status family ← the word table and
53
+ * the route family ← `ROUTE_DECISION_WORDS`, both engine-grounded). The
54
+ * edge-conditions guard pins the two runtime-derived families against their
55
+ * engine sources and consumes THIS slot verbatim for the loop family. */
52
56
  nextLoopConditions: readonly string[];
53
57
  }
54
58
 
@@ -77,6 +81,17 @@ export interface AnatomyConsumerPurity {
77
81
  zeroTraceRule: string;
78
82
  }
79
83
 
84
+ /** The frontmatter-validity rule (spec §4 · D42) — every shipped SKILL.md's YAML
85
+ * frontmatter block must parse under a REAL YAML parser. A bare ASCII `: ` inside
86
+ * an unquoted scalar (e.g. `the engine's next: line`) makes the block unparseable,
87
+ * and the harness then silently drops the skill — an ungated declaration. */
88
+ export interface AnatomyFrontmatter {
89
+ /** The frontmatter fence delimiter (the block between two `---` lines). */
90
+ fence: string;
91
+ /** The rule wording the check quotes when a frontmatter block fails to parse. */
92
+ rule: string;
93
+ }
94
+
80
95
  /** The author-entry bootstrap surface (§10 · the D29-regression pin) — the flow's
81
96
  * content-authoring entry nodes and the skeleton bootstrap literal each one's Do
82
97
  * must carry. D29's stripping rule keys on the ENTRY ROLE, not the surface shape:
@@ -118,6 +133,8 @@ export interface SkillAnatomyContract {
118
133
  growthBoundary: AnatomyGrowthBoundary;
119
134
  consumerPurity: AnatomyConsumerPurity;
120
135
  authorBootstrap: AnatomyAuthorBootstrap;
136
+ /** The frontmatter-validity rule (spec §4 · D42) — the real-YAML-parse gate. */
137
+ frontmatter: AnatomyFrontmatter;
121
138
  skills: { registry: Readonly<Record<string, SkillRosterRow>> };
122
139
  wording: Readonly<Record<string, string>>;
123
140
  /** The engine-lexicon pinned condition words (the v1.20 word-table pin) — the phrase set the
@@ -223,6 +240,13 @@ export const SKILL_ANATOMY = {
223
240
  ],
224
241
  skeletonCommandPattern: "schema get \\S+ --output skeleton",
225
242
  },
243
+ // The frontmatter-validity rule (spec §4 · D42) — every shipped SKILL.md's YAML
244
+ // frontmatter block must parse under a REAL parser; a bare `: ` in an unquoted
245
+ // scalar breaks the block and the harness silently drops the skill.
246
+ frontmatter: {
247
+ fence: "---",
248
+ rule: "every SKILL.md frontmatter block must parse under a real YAML parser — an unquoted `: ` in a scalar makes the block unparseable and the harness silently drops the skill (D42)",
249
+ },
226
250
  skills: { registry: SKILL_ROSTER },
227
251
  // The check-facing diagnostic wording — the prose the anatomy assertions quote
228
252
  // when a structure rule fires (the contract's self-describing face).
@@ -252,12 +276,16 @@ export const SKILL_ANATOMY = {
252
276
  routeFactRule:
253
277
  "next: is consumed as a dispatch-ready literal (the literal IS the dispatch, no kind→command mapping layer); a full cdd command string never follows the next: token on a line; BLOCKED/TIMEOUT carry no next line and are not consumed as next steps",
254
278
  },
255
- // The engine-lexicon pinned condition words (the v1.20 word-table pin) — the phrase set the
256
- // digraph's loop/closure decision edges may carry: the NEXT-LOOP phrases + the
257
- // decision status words (the review-closure status vocabulary) + the Route-kind
258
- // words (the `next:` lexical domain). Sorted lexicographically, documented by
259
- // edition; the wording test (face/words + session/next) pins the derivation — a
260
- // drifted engine word fails the pin, never a silent second list.
279
+ // The engine-lexicon pinned condition words (the v1.20 word-table pin) — the phrase
280
+ // set the digraph's loop/closure decision edges may carry: the NEXT-LOOP phrases +
281
+ // the decision status words (the word table's status vocabulary minus the failure
282
+ // statuses) + the Route decision words (the `next:` lexical domain). This declared
283
+ // value is PINNED by the engine-suite derivation gate
284
+ // (contract/__tests__/edge-conditions.guard.test.ts) — it must equal the derivation
285
+ // from the engine word table / Route lexicon (`CAPSULE_WORDS.status` minus
286
+ // `FAILED_STATUS`, `ROUTE_DECISION_WORDS`, `nextLoopConditions`); a drifted engine
287
+ // word fails that gate, never a silent second list. The kairos-suite edge assertion
288
+ // consumes this set as its label allowlist.
261
289
  edgeConditionWords: [
262
290
  "until next is terminal",
263
291
  "no next",