@open-agent-toolkit/cli 0.2.72 → 0.2.74

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 (165) hide show
  1. package/assets/agents/oat-reviewer.md +4 -3
  2. package/assets/agents/recon-worker.md +42 -8
  3. package/assets/bundle-metadata.json +1 -1
  4. package/assets/docs/cli-utilities/configuration.md +3 -56
  5. package/assets/docs/cli-utilities/tool-packs.md +4 -4
  6. package/assets/docs/contributing/code.md +2 -2
  7. package/assets/docs/contributing/index.md +0 -1
  8. package/assets/docs/reference/cli-reference.md +1 -1
  9. package/assets/docs/reference/troubleshooting.md +17 -40
  10. package/assets/docs/workflows/projects/artifacts.md +16 -34
  11. package/assets/docs/workflows/projects/lifecycle.md +20 -19
  12. package/assets/docs/workflows/skills/explainer-kit.md +180 -440
  13. package/assets/docs/workflows/skills/index.md +1 -2
  14. package/assets/docs/workflows/skills/recon.md +114 -23
  15. package/assets/public-package-versions.json +4 -4
  16. package/assets/skills/explainer-kit/SKILL.md +96 -171
  17. package/assets/skills/explainer-kit/recipes/engineer-tour.json +1 -22
  18. package/assets/skills/explainer-kit/recipes/program-recap.json +1 -29
  19. package/assets/skills/explainer-kit/recipes/project-explainer.json +1 -22
  20. package/assets/skills/explainer-kit/recipes/project-recap.v2.json +1 -43
  21. package/assets/skills/explainer-kit/references/fact-base-contract.md +76 -101
  22. package/assets/skills/explainer-kit/references/recap-authoring.md +99 -0
  23. package/assets/skills/explainer-kit/schemas/manifest.schema.json +13 -135
  24. package/assets/skills/explainer-kit/scripts/bundle.mjs +712 -0
  25. package/assets/skills/explainer-kit/scripts/lib/claim-subject.mjs +40 -0
  26. package/assets/skills/explainer-kit/scripts/lib/contracts.mjs +113 -1504
  27. package/assets/skills/explainer-kit/scripts/lib/failure.mjs +13 -0
  28. package/assets/skills/explainer-kit/scripts/lib/package-coverage.mjs +57 -403
  29. package/assets/skills/explainer-kit/scripts/lib/qa-result.mjs +168 -0
  30. package/assets/skills/explainer-kit/scripts/lib/qa.mjs +90 -488
  31. package/assets/skills/explainer-kit/scripts/lib/recipes.mjs +28 -545
  32. package/assets/skills/explainer-kit/scripts/lib/run-package.mjs +120 -0
  33. package/assets/skills/explainer-kit/scripts/lib/sanitize.mjs +42 -0
  34. package/assets/skills/explainer-kit/scripts/record.mjs +335 -0
  35. package/assets/skills/explainer-kit/scripts/verify.mjs +648 -0
  36. package/assets/skills/oat-explainer-kit/SKILL.md +57 -117
  37. package/assets/skills/oat-explainer-kit/references/config-contract.md +20 -64
  38. package/assets/skills/oat-explainer-kit/references/lifecycle-contract.md +85 -237
  39. package/assets/skills/oat-explainer-kit/scripts/bind-project-sources.mjs +18 -10
  40. package/assets/skills/oat-explainer-kit/scripts/check-core.mjs +1 -0
  41. package/assets/skills/oat-explainer-kit/scripts/check-terminal-outcome.mjs +256 -21
  42. package/assets/skills/oat-explainer-kit/scripts/persist-intent.mjs +82 -3
  43. package/assets/skills/oat-explainer-kit/scripts/resolve-config.mjs +0 -162
  44. package/assets/skills/oat-explainer-kit/scripts/resolve-intent.mjs +57 -123
  45. package/assets/skills/oat-project-autonomous/SKILL.md +14 -13
  46. package/assets/skills/oat-project-autonomous/references/gate-inventory.md +165 -165
  47. package/assets/skills/oat-project-complete/SKILL.md +168 -349
  48. package/assets/skills/oat-project-complete/scripts/consume-persisted-recap-intent.mjs +125 -0
  49. package/assets/skills/oat-project-complete/scripts/execute-synced-archive-entry.mjs +0 -30
  50. package/assets/skills/oat-project-complete/scripts/parse-completion-retry-fields.mjs +4 -37
  51. package/assets/skills/oat-project-complete/scripts/parse-synced-archive-resume-fields.mjs +17 -16
  52. package/assets/skills/oat-project-complete/scripts/recover-completion-receipts.mjs +9 -174
  53. package/assets/skills/oat-project-complete/scripts/resolve-completion-retry.mjs +1 -2
  54. package/assets/skills/oat-project-document/SKILL.md +1 -1
  55. package/assets/skills/oat-project-document/references/docs/autonomy-contract.md +165 -165
  56. package/assets/skills/oat-project-implement/SKILL.md +1 -1
  57. package/assets/skills/oat-project-implement/references/completion-and-closeout.md +44 -56
  58. package/assets/skills/oat-project-implement/references/docs/autonomy-contract.md +165 -165
  59. package/assets/skills/oat-project-lite/SKILL.md +1 -1
  60. package/assets/skills/oat-project-lite/references/docs/autonomy-contract.md +165 -165
  61. package/assets/skills/oat-project-plan/SKILL.md +5 -6
  62. package/assets/skills/oat-project-pr-final/SKILL.md +1 -1
  63. package/assets/skills/oat-project-pr-final/references/docs/autonomy-contract.md +165 -165
  64. package/assets/skills/oat-project-quick-start/SKILL.md +1 -1
  65. package/assets/skills/oat-project-quick-start/references/docs/autonomy-contract.md +165 -165
  66. package/assets/skills/oat-project-review-receive/SKILL.md +14 -1
  67. package/assets/skills/oat-project-summary/SKILL.md +35 -25
  68. package/assets/skills/oat-wave-execute/SKILL.md +11 -36
  69. package/assets/skills/oat-wave-program/SKILL.md +13 -37
  70. package/assets/skills/recon/SKILL.md +103 -40
  71. package/assets/skills/recon/references/packet-contract.md +150 -67
  72. package/assets/skills/recon/references/profiles.md +38 -16
  73. package/assets/skills/recon/references/worker-contract.md +39 -8
  74. package/assets/skills/recon/scripts/lib/contracts.mjs +703 -55
  75. package/assets/skills/recon/scripts/lib/routing.mjs +588 -0
  76. package/assets/skills/recon/scripts/lib/validated-run.mjs +2 -0
  77. package/assets/skills/recon/scripts/prepare-routing.mjs +88 -0
  78. package/assets/skills/recon/scripts/render-packet.mjs +69 -1
  79. package/assets/skills/recon/scripts/validate-packet.mjs +473 -56
  80. package/assets/skills/subagent-orchestration/SKILL.md +18 -9
  81. package/assets/skills/subagent-orchestration/references/model-selection-principles.md +17 -8
  82. package/dist/commands/config/index.d.ts.map +1 -1
  83. package/dist/commands/config/index.js +9 -113
  84. package/dist/commands/project/archive/archive-utils.d.ts.map +1 -1
  85. package/dist/commands/project/archive/archive-utils.js +32 -184
  86. package/dist/commands/project/archive/explainer-package-coverage.d.ts +3 -8
  87. package/dist/commands/project/archive/explainer-package-coverage.d.ts.map +1 -1
  88. package/dist/commands/project/archive/explainer-package-coverage.js +1 -1
  89. package/dist/config/oat-config.d.ts +0 -11
  90. package/dist/config/oat-config.d.ts.map +1 -1
  91. package/dist/config/oat-config.js +0 -34
  92. package/dist/config/resolve.d.ts.map +1 -1
  93. package/dist/config/resolve.js +0 -8
  94. package/dist/release/public-package-contract.d.ts.map +1 -1
  95. package/dist/release/public-package-contract.js +2 -10
  96. package/dist/validation/project-state.d.ts.map +1 -1
  97. package/dist/validation/project-state.js +42 -3
  98. package/package.json +2 -2
  99. package/assets/docs/contributing/explainer-kit-verification.md +0 -133
  100. package/assets/docs/workflows/skills/explainer-kit-providers.md +0 -155
  101. package/assets/skills/explainer-kit/briefs/deep-dive.md +0 -35
  102. package/assets/skills/explainer-kit/briefs/project-page.md +0 -38
  103. package/assets/skills/explainer-kit/briefs/supporting-diagram.md +0 -28
  104. package/assets/skills/explainer-kit/briefs/walkthrough-deck.md +0 -35
  105. package/assets/skills/explainer-kit/examples/project-explainer/content.md +0 -31
  106. package/assets/skills/explainer-kit/examples/project-explainer/fact-base.md +0 -22
  107. package/assets/skills/explainer-kit/examples/project-recap/content.md +0 -77
  108. package/assets/skills/explainer-kit/examples/project-recap/fact-base.json +0 -104
  109. package/assets/skills/explainer-kit/examples/project-recap/fact-base.md +0 -44
  110. package/assets/skills/explainer-kit/examples/theme-bundle.json +0 -87
  111. package/assets/skills/explainer-kit/recipes/project-recap.v1.json +0 -93
  112. package/assets/skills/explainer-kit/references/contracts.md +0 -324
  113. package/assets/skills/explainer-kit/references/destination-contract.md +0 -210
  114. package/assets/skills/explainer-kit/references/extension-contract.md +0 -80
  115. package/assets/skills/explainer-kit/references/golden-conformance.md +0 -80
  116. package/assets/skills/explainer-kit/references/visual-review.md +0 -71
  117. package/assets/skills/explainer-kit/schemas/author-request.v2.schema.json +0 -212
  118. package/assets/skills/explainer-kit/schemas/author-request.v3.schema.json +0 -241
  119. package/assets/skills/explainer-kit/schemas/author-result.v2.schema.json +0 -52
  120. package/assets/skills/explainer-kit/schemas/build-record.schema.json +0 -98
  121. package/assets/skills/explainer-kit/schemas/durability-evidence.schema.json +0 -53
  122. package/assets/skills/explainer-kit/schemas/publish-receipt.v1.schema.json +0 -97
  123. package/assets/skills/explainer-kit/schemas/publish-receipt.v2.schema.json +0 -215
  124. package/assets/skills/explainer-kit/schemas/publish-request.v1.schema.json +0 -32
  125. package/assets/skills/explainer-kit/schemas/publish-request.v2.schema.json +0 -34
  126. package/assets/skills/explainer-kit/schemas/run-request.schema.json +0 -147
  127. package/assets/skills/explainer-kit/schemas/set-plan.v1.schema.json +0 -149
  128. package/assets/skills/explainer-kit/schemas/terminal-evidence.v1.schema.json +0 -81
  129. package/assets/skills/explainer-kit/schemas/visual-review-evidence.v1.schema.json +0 -66
  130. package/assets/skills/explainer-kit/schemas/visual-review-request.v1.schema.json +0 -117
  131. package/assets/skills/explainer-kit/schemas/visual-review-result.v1.schema.json +0 -80
  132. package/assets/skills/explainer-kit/scripts/lib/catalog.mjs +0 -349
  133. package/assets/skills/explainer-kit/scripts/lib/content-approval.mjs +0 -418
  134. package/assets/skills/explainer-kit/scripts/lib/diagram.mjs +0 -514
  135. package/assets/skills/explainer-kit/scripts/lib/durability.mjs +0 -643
  136. package/assets/skills/explainer-kit/scripts/lib/fact-base.mjs +0 -664
  137. package/assets/skills/explainer-kit/scripts/lib/internal-references.mjs +0 -538
  138. package/assets/skills/explainer-kit/scripts/lib/markdown.mjs +0 -414
  139. package/assets/skills/explainer-kit/scripts/lib/publication-policy.mjs +0 -54
  140. package/assets/skills/explainer-kit/scripts/lib/records.mjs +0 -954
  141. package/assets/skills/explainer-kit/scripts/lib/render.mjs +0 -703
  142. package/assets/skills/explainer-kit/scripts/lib/s3-roots.mjs +0 -353
  143. package/assets/skills/explainer-kit/scripts/lib/s3-static.mjs +0 -759
  144. package/assets/skills/explainer-kit/scripts/lib/set-plan.mjs +0 -209
  145. package/assets/skills/explainer-kit/scripts/lib/source-backlinks.mjs +0 -218
  146. package/assets/skills/explainer-kit/scripts/lib/terminal-evidence.mjs +0 -157
  147. package/assets/skills/explainer-kit/scripts/lib/visual-review.mjs +0 -400
  148. package/assets/skills/explainer-kit/scripts/publish.mjs +0 -76
  149. package/assets/skills/explainer-kit/scripts/record-durability.mjs +0 -64
  150. package/assets/skills/explainer-kit/scripts/render-qa.mjs +0 -461
  151. package/assets/skills/explainer-kit/scripts/run.mjs +0 -3038
  152. package/assets/skills/explainer-kit/scripts/validate.mjs +0 -59
  153. package/assets/skills/oat-explainer-kit/references/author-callback.md +0 -53
  154. package/assets/skills/oat-explainer-kit/references/migration.md +0 -144
  155. package/assets/skills/oat-explainer-kit/references/visual-review-callback.md +0 -83
  156. package/assets/skills/oat-explainer-kit/scripts/derive-destination.mjs +0 -91
  157. package/assets/skills/oat-explainer-kit/scripts/finalize-tracked-run.mjs +0 -531
  158. package/assets/skills/oat-explainer-kit/scripts/probe-recap-seams.mjs +0 -371
  159. package/assets/skills/oat-explainer-kit/scripts/run.mjs +0 -905
  160. package/dist/commands/project/archive/explainer-source-backlinks.d.ts +0 -18
  161. package/dist/commands/project/archive/explainer-source-backlinks.d.ts.map +0 -1
  162. package/dist/commands/project/archive/explainer-source-backlinks.js +0 -27
  163. package/dist/commands/project/archive/explainer-terminal-evidence.d.ts +0 -29
  164. package/dist/commands/project/archive/explainer-terminal-evidence.d.ts.map +0 -1
  165. package/dist/commands/project/archive/explainer-terminal-evidence.js +0 -37
@@ -11,8 +11,7 @@ Use this section when you want to choose the right OAT skill for a task. If you
11
11
 
12
12
  - [Writing Skills](../../contributing/skills.md) - Contributor guide to skill authoring, contracts, and governance.
13
13
  - [Docs Workflows](../../docs-tooling/workflows.md) - How docs CLI helpers and docs skills work together.
14
- - [Explainer Kit](explainer-kit.md) - Core and OAT adapter usage, recipes and expansion profiles, the two authoring paths, warnings and QA severity, themes, lifecycle policy, durability, and publishing.
15
- - [Explainer Provider Integration](explainer-kit-providers.md) - Provider-neutral planner, author, trusted browser-session, and visual-critic contracts.
14
+ - [Explainer Kit](explainer-kit.md) - Agent-authored generation flow, direct and lifecycle callers, verification ladder, run package, and outcomes.
16
15
  - [Repo Improve](repo-improve.md) - Source modes, external-plan boundaries, optional tracking, and OAT import handoff.
17
16
  - [Recon Evidence Packets](recon.md) - Approved worker profiles, validated claim states, packet layout, partial outcomes, and directory-only handoff.
18
17
 
@@ -10,6 +10,12 @@ It gathers source-grounded findings through approved worker waves, validates
10
10
  their locators and assurance state, and gives the next consumer one compact
11
11
  entry point instead of every worker transcript.
12
12
 
13
+ Recon controls the profile, routing proposal, and evidence flow. Shared
14
+ orchestration guidance classifies the concrete assignments, the dispatch skill
15
+ resolves and launches exact targets supported by the active harness, and the
16
+ calling agent owns scope, approval dialogue, sufficiency judgment, and final
17
+ conclusions.
18
+
13
19
  The first release is standalone. It does not automatically run from project
14
20
  discovery, quick start, `analyze`, or `deep-research`. Those workflows can
15
21
  consume an explicitly supplied packet path without changing their own
@@ -45,10 +51,11 @@ oat tools update --pack research --scope project
45
51
 
46
52
  The research pack acquires its two dispatch dependencies from the utility pack
47
53
  at the same scope. You do not need to select a named model during installation.
48
- At run time, OAT resolves a currently available target that meets the planned
49
- work's task-class floor and asks you to approve the exact provider, model,
50
- effort, role, topology, authority, and execution limits before any worker
51
- launches.
54
+ At run time, OAT resolves each wave independently against its task class and
55
+ floor, then asks you to approve every wave's exact supported provider-native
56
+ axes, role, topology, rationale, conditions, authority, and finite execution
57
+ limits before any worker launches. Active provider guidance and the live
58
+ catalog own current qualification; recon does not maintain a second model list.
52
59
 
53
60
  ## Run a Recon
54
61
 
@@ -59,21 +66,31 @@ context source, output directory, or strict authority:
59
66
  /recon "How is provider sync materialized?" --profile standard --scope packages/cli/src/providers
60
67
  ```
61
68
 
62
- The default profile is `standard`. Every run uses one approved model and effort
63
- for every pass. Profiles change pass topology, redundancy, lane caps, and
64
- maximum concurrency; they do not silently choose a different model tier.
65
-
66
- | Profile | Use it for | Required assurance work | Claim ceiling |
67
- | ---------- | ------------------------------------------- | ---------------------------------------------------------------------------------------- | ------------- |
68
- | `quick` | Bounded orientation | Mapping, gathering, compilation, schema validation, and locator validation | `supported` |
69
- | `standard` | Load-bearing evidence | Quick work plus blind semantic verification, adversarial review, coverage, and reconcile | `verified` |
70
- | `thorough` | Expensive failure or correlated blind spots | Standard work plus redundant gathering and verification and contradiction resolution | `verified` |
71
-
72
- The approval manifest shows the exact adaptive lane count, concurrency, pass
73
- topology, deadlines, retries, and source/write authority. Declining approval
74
- launches nothing. A change to a provider, model, effort, route, role, service
75
- tier, or execution cap requires renewed approval; there is no silent
76
- substitution after approval.
69
+ The default profile is `standard`. Each homogeneous wave has an independently
70
+ selected and approved exact target. Bounded mapping, extraction, citation
71
+ reopening, counterexample search, and mechanical dossier compilation start with
72
+ economical qualified routes. A wave that genuinely requires interpretation or
73
+ reconciliation judgment can use a stronger approved target without raising the
74
+ cost of unrelated evidence waves.
75
+
76
+ | Profile | Use it for | Required assurance work | Claim ceiling |
77
+ | ---------- | ------------------------------------------- | ------------------------------------------------------------------------------------------------------------------ | ------------- |
78
+ | `quick` | Bounded orientation | Mapping, gathering, compilation, schema validation, and locator validation; no independent semantic pass by design | `supported` |
79
+ | `standard` | Load-bearing evidence | Quick work plus blind semantic verification, adversarial review, coverage, and reconcile | `verified` |
80
+ | `thorough` | Expensive failure or correlated blind spots | Standard work plus required redundant gathering and redundant verification | `verified` |
81
+
82
+ A thorough run may additionally predeclare an optional, condition-bound
83
+ `contradiction-resolution` evidence wave. It runs only when its approved
84
+ predicate triggers and is not required when that branch is not triggered.
85
+
86
+ The approval manifest shows each wave's exact target, task class, class floor,
87
+ selection rationale, adaptive lane count, conditional rule, concurrency,
88
+ deadlines, retries, and source/write authority. An unsupported provider-native
89
+ control is shown explicitly as unavailable or null; recon never translates an
90
+ effort label across harnesses or infers capability from an opaque selector.
91
+ Declining approval launches nothing. Any target, topology, condition, or limit
92
+ change requires renewed approval; there is no silent substitution after
93
+ approval.
77
94
 
78
95
  Before any worker launches, recon confirms that the live launch surface can run
79
96
  the approved role, model, effort, and authority level. If it cannot, the run
@@ -82,6 +99,48 @@ launched. Deadlines are approved execution limits chosen for the task class,
82
99
  not short watchdogs; an accepted lane is never interrupted by hand because a
83
100
  displayed deadline elapsed.
84
101
 
102
+ ### Preview and Check Routing
103
+
104
+ The installed proposal helper renders the complete envelope in Markdown or
105
+ JSON without recording approval or launching work. From a project-scoped
106
+ installation:
107
+
108
+ ```bash
109
+ node .agents/skills/recon/scripts/prepare-routing.mjs --manifest draft-manifest.json --format markdown
110
+ node .agents/skills/recon/scripts/prepare-routing.mjs --manifest draft-manifest.json --format json
111
+ ```
112
+
113
+ Immediately before a launch, the controller uses the same production logic to
114
+ compare the constructed target with that wave's approved exact target:
115
+
116
+ ```bash
117
+ node .agents/skills/recon/scripts/prepare-routing.mjs --manifest manifest.json --wave gather-1 --check-target candidate-target.json
118
+ ```
119
+
120
+ These commands validate structure, approval integrity, and exact identity. They
121
+ do not launch a worker, rank model names, attest actual runtime identity, or
122
+ measure cost.
123
+
124
+ ### Bounded Conditional Evidence
125
+
126
+ Standard and thorough may predeclare finite conditional
127
+ `contradiction-resolution` evidence waves. A completed predecessor can trigger
128
+ one such wave to seek discriminating evidence; accepted failure, cancellation,
129
+ timeout, or missing output cannot trigger a replacement. Triggered,
130
+ not-triggered, and unresolved dispositions remain visible. Both branches feed
131
+ the same single mandatory terminal reconciliation.
132
+
133
+ A triggered condition must cite complete, digest-bound evidence from an approved
134
+ predecessor in the same run. Evidence copied from another run cannot activate
135
+ the destination wave and fails packet validation with
136
+ `CONDITION_EVIDENCE_RUN_MISMATCH`.
137
+
138
+ If a need for stronger reconciliation judgment is foreseeable, select that one
139
+ terminal target before approval. If it appears only after approval, recon
140
+ preserves completed evidence and returns an unresolved, out-of-envelope gap for
141
+ renewed approval or a new run. It never mutates the target, silently retries,
142
+ or launches a second reconciliation.
143
+
85
144
  ## Destination Precedence
86
145
 
87
146
  `recon` always creates a new topic-and-run directory. It never overwrites an
@@ -119,6 +178,26 @@ non-publishable candidate generation withdraws any existing `packet.md`:
119
178
  - `raw/` contains worker dossiers, candidate artifacts, and safe failure
120
179
  diagnostics. It is not normal consumer input.
121
180
 
181
+ The `recon.packet-manifest` contract accepts version 2 only. Evidence artifact
182
+ kinds remain independently versioned at version 1. Approval is session-local
183
+ and records only `{ type, approvedAt }`: resuming, reloading, or changing the
184
+ proposal requires a fresh preview and explicit approval before launch.
185
+
186
+ Every valid packet renders a compact Intended Routing section from the already
187
+ validated normalized view. It labels exact targets and condition dispositions
188
+ as approved intent, not proof of the native process that ran, launcher receipts,
189
+ token or billing totals, or universal correctness. A valid packet continues to
190
+ reference version 1 evidence artifacts. Evidence, claims, contradictions, and
191
+ gaps remain the packet's main consumer context.
192
+
193
+ Every dossier and review result identifies the approved wave and lane that wrote
194
+ it. Primary and redundant gather artifacts therefore satisfy only their owning
195
+ waves; lanes from one gather wave cannot impersonate the other pass. In a
196
+ thorough run, redundant gathering finishes before compilation, and the compiled
197
+ ledger must reference every completed primary and redundant gather dossier by
198
+ exact path and digest before review briefs are created. Missing provenance fails
199
+ with `MISSING_THOROUGH_GATHER_LEDGER_INPUT`.
200
+
122
201
  The ledger compiler and packet validator enforce categorical referential
123
202
  integrity on `synthesis.keyClaimIds` and `synthesis.unresolvedQuestionIds`. Any
124
203
  reference to an unknown claim or question ID fails validation with
@@ -143,9 +222,11 @@ percentages:
143
222
  - `unresolved`: available evidence cannot settle the claim; and
144
223
  - `unsupported`: valid supporting evidence is absent or verification failed.
145
224
 
146
- A quick packet never promotes a claim to `verified`. Stronger profiles can do
147
- so only when their required review artifacts validate and were written by
148
- approved lanes.
225
+ A quick packet is an evidence packet for an intelligent consumer and has no
226
+ independent semantic pass by design. It never promotes a claim to `verified`;
227
+ the caller assesses sufficiency and conclusions. Stronger profiles can promote
228
+ claims only when their required independent review artifacts validate and were
229
+ written by approved lanes.
149
230
 
150
231
  When an independent semantic review rejects a proposed claim, the reconciler
151
232
  transitions it to `unsupported` rather than deleting it. This preserves the
@@ -189,7 +270,17 @@ omitted passes, material gaps, affected claims, and required assurance
189
270
  downgrades. A run may be partial even when it achieved the requested profile if
190
271
  a material evidence gap remains. The achieved profile is derived from the
191
272
  complete typed artifacts in the packet; each required pass without a complete
192
- result needs a material `PASS_FAILED` or `PASS_OMITTED` gap naming it.
273
+ result needs a material `PASS_FAILED` or `PASS_OMITTED` gap. Each approved lane
274
+ must likewise have a complete artifact or a material outcome gap carrying its
275
+ exact `waveId` and `laneId`; legacy mode-only gaps remain valid only when the mode
276
+ unambiguously identifies one single-lane wave.
277
+
278
+ A complete artifact and material failure or omission for the same exact wave and
279
+ lane are contradictory, so validation fails closed with
280
+ `CONTRADICTORY_PASS_OUTCOME`. Complete evidence from one lane and exact failure
281
+ evidence from a different lane are not contradictory: the completed lane can
282
+ preserve the achieved pass while the failed lane makes the published run an
283
+ honest `partial` packet at that achieved profile.
193
284
 
194
285
  Status updates and the final handoff label each failure as `worker`,
195
286
  `provider/dispatch`, `contract validation`, or `source availability`, and
@@ -1,6 +1,6 @@
1
1
  {
2
- "cli": "0.2.72",
3
- "docs-config": "0.2.72",
4
- "docs-theme": "0.2.72",
5
- "docs-transforms": "0.2.72"
2
+ "cli": "0.2.74",
3
+ "docs-config": "0.2.74",
4
+ "docs-theme": "0.2.74",
5
+ "docs-transforms": "0.2.74"
6
6
  }
@@ -4,194 +4,119 @@ description: Use when building destination-neutral visual explainer artifacts fr
4
4
  user-invocable: true
5
5
  allowed-tools: Read, Write, Edit, Bash, Grep, Glob, Agent, mcp__*
6
6
  metadata:
7
- version: 2.1.1
7
+ version: 3.0.2
8
8
  ---
9
9
 
10
10
  # Explainer Kit
11
11
 
12
- Build visual explainer artifact sets from explicit inputs without reading OAT,
13
- user, vault, or destination configuration.
12
+ Build one destination-neutral visual explainer from explicit inputs without
13
+ reading OAT, user, vault, or destination configuration.
14
14
 
15
15
  ## Responsibilities
16
16
 
17
- - Validate versioned run, source, theme, artifact, durability, and publishing
18
- contracts.
19
- - Reconcile one cited fact base before producing narrative content.
20
- - Author every artifact against a bundled brief on one of two paths, and scale
21
- the artifact set with the content through recipe-declared expansion profiles.
22
- - Render neutral, self-contained artifacts from bundled recipes and templates.
23
- - Report editorial and layout findings as manifest warnings while keeping
24
- safety and provenance violations hard failures.
25
- - Record build outcomes and verify caller-supplied durability evidence.
26
- - Publish only through an explicitly requested, human-gated connector.
27
-
28
- ## Dependency Direction
29
-
30
- This skill is the canonical core. It must not depend on `oat-explainer-kit` or
31
- OAT project state. Adapters and private wrappers may construct a core run
32
- request and consume its manifest, build record, and optional publish receipt.
33
-
34
- ## Wrapper Extension Seam
35
-
36
- Wrappers own private pre-resolution and post-run work. They resolve presets,
37
- vaults, external documents, and personal destinations before translating the
38
- result into one `ExplainerRunRequestV1`; after the core run, they consume the
39
- versioned manifest and optional receipt to create links or companion records.
40
- They must not inject private work between core stages or expose private lanes as
41
- public config. See `references/extension-contract.md` for the frozen sequence,
42
- version policy, and compatibility fixture.
17
+ - Collect only allowlisted inputs and create a cited fact base plus bounded
18
+ anchor ledger.
19
+ - Give the host agent the selected recipe brief, authoring mechanics, theme,
20
+ and one recipe shell.
21
+ - Verify required sections, source discipline, script safety, and both
22
+ directions of machine-checkable claim traceability.
23
+ - Use the highest available browser rung without blocking browser-less hosts.
24
+ - Record one exact-inventory `explainer-kit.manifest/v2` run package.
43
25
 
44
26
  ## Asset Resolution
45
27
 
46
- Resolve schemas, recipes, templates, scripts, examples, and references relative
47
- to this installed skill directory. Never resolve runtime assets from a source
48
- checkout or from absolute operator-specific paths.
28
+ Resolve schemas, recipes, templates, scripts, and references relative to this
29
+ installed skill directory. Never resolve runtime assets from a source checkout
30
+ or from absolute operator-specific paths.
49
31
 
50
- ## Core Run
32
+ ## Run
51
33
 
52
- Construct a complete `ExplainerRunRequestV1`, then invoke the packaged core:
34
+ Choose one recipe and one input mode, then prepare the run:
53
35
 
54
36
  ```bash
55
- node scripts/run.mjs --request /path/to/request.json
37
+ node scripts/bundle.mjs \
38
+ --recipe project-recap \
39
+ --project /path/to/project \
40
+ --theme /path/to/theme.resolved.json \
41
+ --out /path/to/run-root
56
42
  ```
57
43
 
58
- The core composes validation, fact-base processing, bounded recipe/content
59
- discovery, authoring, theme resolution, rendering, QA, approval, and
60
- manifest/build-record persistence. It runs without OAT files or ambient
61
- configuration. Supplied fact bases receive only lightweight
62
- consistency/freshness checks. Federated inputs require a provider-neutral
63
- critic callback and invoke it exactly once. Optional claim `sections` tags
64
- route facts to matching recipe narrative sections; untagged claims remain
65
- shared context for every required section.
66
-
67
- ## Authoring
68
-
69
- Every run requires a provider-neutral author callback in **both** modes; there
70
- is no synthetic content model. A run without one fails `E_AUTHOR_REQUIRED`.
71
- In-process callers supply `options.author`; JSON-only CLI callers supply
72
- `--author-module`. Keep executable callback references out of the persisted run
73
- request.
74
-
75
- The recipe — never the author — selects each artifact's authoring path. Floor
76
- entries and expansion profiles declare `authoring: markdown` for the narrative
77
- path or `authoring: html` for the artistic path. The core invokes the author
78
- once per artifact with an `explainer-kit.author-request/v3` payload carrying the
79
- artifact identity and type, its authoring path, the inlined brief from
80
- `briefs/`, the reconciled fact base, the resolved theme, the shell source for
81
- artistic artifacts, the required narrative sections for narrative floor
82
- artifacts, and canonical `artifactLinks` with explicit `index.html` site paths
83
- and receiver-relative hrefs. Version 2 requests remain readable for replay. It
84
- accepts only a schema-valid
85
- `explainer-kit.author-result/v2` with exactly one of `content.markdown` or
86
- `content.html` plus non-secret provenance, rejects excessive verbatim source
87
- overlap, retains each validated result under `source/author/` and its content
88
- under `source/content/<artifact>.md` or `.html`, and never prompts.
89
-
90
- Authors follow the bundled medium-specific rules in
91
- `references/visual-authoring.md`. They do not require a home-directory plugin:
92
- an optional installed visual-explainer capability may enhance composition, but
93
- the bundled briefs, shells, and guidance are the complete unattended baseline.
94
-
95
- Markdown content is parsed to a validated AST and rendered through the themed
96
- block library, including GFM tables and task lists, GFM alert callouts, fenced
97
- `timeline` blocks, and fenced `diagram` blocks rendered to inline SVG at build
98
- time. HTML content is validated at the DOM level: the authored document's
99
- scripts must match the declared core shell's ordered multiset of script hashes
100
- exactly, and inline event handlers and external active content are rejected.
101
- Non-script markup stays free within the allowlist.
102
-
103
- A floor artifact may return `proposedArtifacts` of `{id, profileId, rationale}`
104
- to grow the set when the content earns it. The referenced profile supplies the
105
- type, authoring path, brief, and shell, so the author never chooses policy.
106
- Unknown profiles and unsafe, duplicate, or floor-colliding IDs are hard errors;
107
- proposals over a profile's `maxCount` or the recipe's
108
- `expansion.limits.maxArtifacts` are rejected with a warning and the run
109
- continues. Accepted expansion artifacts render to
110
- `site/{directory}/{slug}/{artifactId}/index.html` and are linked from the floor
111
- hub; floor artifacts keep their existing paths.
112
-
113
- `project-recap@2` requires one complete navigational hub and makes diagrams,
114
- decks, and deep dives adaptive expansions. The planner proposes one only when
115
- it can name a distinct reader question, the supporting source evidence, and why
116
- that medium improves on adding more hub prose. The prose brief governs
117
- typographic roles, hierarchy, slide archetypes, diagram semantics,
118
- fit-to-content composition, density, repetition, and medium choice. These are
119
- editorial judgments, not new request fields or renderer rules.
120
- `project-recap@1` remains readable for replay with its historical three-artifact
121
- floor.
122
-
123
- ## Review, Approval, and Warnings
124
-
125
- Approval runs after theme, render, hard internal-reference validation, safety
126
- validation, the guideline checker, and render QA, immediately before publish and
127
- durability — so a reviewer approves rendered artifacts and the complete warning
128
- set, not raw prose. The reference gate resolves `href`, `src`, `srcset`,
129
- fragments, and safe embedded references against explicit manifest/site-tree
130
- files. It may invoke the existing correction author once, then rerenders and
131
- revalidates before any browser or visual review. A later visual correction also
132
- rerenders and passes through the validation-only reference gate without
133
- receiving another correction attempt. An exhausted `E_INTERNAL_REFERENCE`
134
- finding fails closed and cannot reach durability.
135
-
136
- Interactive runs stop with an `incomplete` outcome once artifacts are built and
137
- checked. Review the rendered `site/` tree, the sources under `source/content/`,
138
- and the accumulated warnings, then provide an explicit JSON decision and rerun
139
- the same request:
44
+ Use exactly one of the supported input modes:
45
+
46
+ - `--project <dir>` for a project recap or project explainer;
47
+ - `--program <artifact> --summaries <dir> --archive <dir>` for a program
48
+ recap;
49
+ - `--inputs <file|dir>...` for documents; or
50
+ - `--fact-base <path>` for a supplied fact base.
51
+
52
+ ### Front door
53
+
54
+ When a person invokes this skill directly, ask them to name the recipe, choose
55
+ `--out <dir>`, and provide exactly one direct input mode:
56
+
57
+ - `--project <dir>` for an OAT project;
58
+ - `--inputs <file|dir>...` for documents; or
59
+ - `--fact-base <path>` for a prepared fact base.
60
+
61
+ Run from the installed skill directory. If the person does not supply a
62
+ resolved theme, materialize the deterministic `clean-neutral` default before
63
+ bundling:
140
64
 
141
65
  ```bash
142
- node scripts/run.mjs \
143
- --request /path/to/request.json \
144
- --reviewed-source /path/to/content-review.json
66
+ node --input-type=module --eval '
67
+ import { writeFile } from "node:fs/promises";
68
+ import { resolveTheme } from "./scripts/lib/theme.mjs";
69
+ const { theme } = await resolveTheme({ style: "clean-neutral" });
70
+ await writeFile(process.argv[1], `${JSON.stringify(theme, null, 2)}\n`);
71
+ ' /path/to/theme.resolved.json
145
72
  ```
146
73
 
147
- An approval decision resumes the existing run; a rejection persists its
148
- correction list, and a later approval re-renders and re-runs QA against the
149
- edited sources before proceeding. Approval does not authorize publishing: a
150
- publish request still requires the separate human-gated publisher callback.
151
-
152
- Review provenance persists in `source/content-approval.json` as an
153
- `explainer-kit.content-approval/v2` record. It carries
154
- `marking: human-approved` for interactive approval and `auto-drafted` for
155
- unattended runs, surfaced in the run result and never written to the manifest,
156
- plus the complete resolved artifact set so a paused expanded run rehydrates
157
- without re-invoking the author.
158
-
159
- Safety and provenance violations fail the run with `E_QA`. Editorial and layout
160
- findings — narrative-coverage, architecture-diagram, and structured-depth
161
- guideline misses, rejected over-limit proposals, and render-QA layout findings —
162
- append stable warning IDs to the manifest's `warnings[]` and let the run
163
- succeed.
164
-
165
- Visual critics use the independent whole-set rubric in
166
- `references/visual-review.md`, which separates review judgment from
167
- medium-specific authoring rules. They assess typography, hierarchy,
168
- composition, density, medium leverage, template repetition, diagram semantics,
169
- and cross-artifact cohesion from rendered browser evidence. The rubric keeps
170
- the existing provider-neutral result contract: `pass` means no required
171
- correction remains, while `correct` carries concrete artifact-scoped actions
172
- into the one bounded correction round. It does not assign design scores or
173
- encode geometry thresholds.
174
-
175
- Render QA is opt-in. It runs only against an injected `browserProbe`, and the
176
- core never launches a browser of its own — reviewing the rendered output in a
177
- browser is the generating agent's job. Unattended project recaps require both
178
- complete browser evidence and an independent visual-critic `pass`. A missing
179
- probe or critic, a terminal critic failure, or an unresolved correction records
180
- `built-needs-review`: built artifacts and review evidence remain available, but
181
- durability and publishing callbacks are not invoked. Other runs without a probe
182
- record `render-qa-skipped-no-probe` and continue.
183
-
184
- See `references/contracts.md` for source formats, callback modules, retained
185
- intermediates, and result semantics.
186
-
187
- Durability and publishing run only when the request selects them and the caller
188
- supplies the matching callback. The core does not create commits, discover
189
- destinations, or publish automatically. A successful build remains
190
- `built-not-durable` until caller-supplied evidence is verified.
191
- `built-needs-review` is terminal but cannot receive durability evidence or be
192
- published.
193
-
194
- ## Progress Indicators
74
+ Pass that file as `--theme /path/to/theme.resolved.json`. After bundling,
75
+ propose the bounded input scope and show a concise summary of the prepared fact
76
+ base so the person can correct the scope or source facts before authoring. This
77
+ is a lightweight interactive confirmation, not a project gate or approval
78
+ workflow.
79
+
80
+ Always pass `--recipe`, `--theme`, and `--out`. `bundle.mjs` writes
81
+ `source/fact-base.json`, `source/fact-base.md`, `source/ledger.json`, and
82
+ `theme.resolved.json`. If it reports `reuse: true`, return the existing
83
+ satisfied run without changing it.
84
+
85
+ The host agent then reads the selected recipe's `floor[0].briefRef`,
86
+ `references/recap-authoring.md`, the fact base, anchor ledger, and resolved
87
+ theme. Copy the recipe's shell from `templates/` and author exactly one
88
+ standalone `site/index.html`. Preserve every required narrative section ID,
89
+ keep all CSS and approved scripts inline, make no external requests, and spell
90
+ every machine-checkable fact as the fact base spells it. Unattended runs never
91
+ prompt.
92
+
93
+ Run browser-free verification and the highest available browser rung. Record a
94
+ direct front-door run as interactive:
95
+
96
+ ```bash
97
+ node scripts/verify.mjs --run-root /path/to/run-root --recipe project-recap
98
+ node scripts/record.mjs \
99
+ --run-root /path/to/run-root \
100
+ --recipe project-recap \
101
+ --slug project-recap \
102
+ --mode interactive \
103
+ --theme /path/to/run-root/theme.resolved.json
104
+ ```
105
+
106
+ Lifecycle callers use `--mode unattended` instead and never prompt.
107
+
108
+ The ladder is host browser capture and inspection, then the bundled Playwright
109
+ probe, then the browser-free `none` rung. Host evidence uses 320, 768, and 1440
110
+ pixel screenshots bound to the exact artifact hash and an explicit visual
111
+ verdict. Browser-free structure, source-dumping, shell-script, ledger-to-page,
112
+ and page-to-ledger checks run at every rung.
113
+
114
+ `record.mjs` writes `explainer-kit.manifest/v2`. `built` means browser and
115
+ visual checks passed. `built-needs-review` is a usable artifact whose browser
116
+ rung was unavailable or found issues. `failed` and `incomplete` do not satisfy
117
+ generation. Do not write into the run root after recording.
118
+
119
+ ## Progress Indicators (User-Facing)
195
120
 
196
121
  For interactive runs, show a concise banner and stage updates:
197
122
 
@@ -201,6 +126,6 @@ EXPLAINER KIT
201
126
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
202
127
  ```
203
128
 
204
- Report validation, fact-base, content, theme, render, QA, durability, and
205
- publish stages as they begin and complete. Keep unattended output structured
206
- and non-interactive.
129
+ Report bundle, authoring, verification, browser rung, recording, and outcome
130
+ stages as they begin and complete. Keep unattended output structured and
131
+ non-interactive.
@@ -15,9 +15,7 @@
15
15
  {
16
16
  "id": "engineer-tour",
17
17
  "type": "explainer",
18
- "authoring": "html",
19
18
  "template": "engineer-tour",
20
- "required": true,
21
19
  "briefRef": "briefs/engineer-tour.md",
22
20
  "requiredNarrative": [
23
21
  "orientation",
@@ -27,24 +25,5 @@
27
25
  "validation"
28
26
  ]
29
27
  }
30
- ],
31
- "expansion": {
32
- "profiles": [
33
- {
34
- "profileId": "supporting-diagram",
35
- "type": "diagram",
36
- "authoring": "html",
37
- "briefRef": "briefs/supporting-diagram.md",
38
- "shell": "diagram-shell",
39
- "maxCount": 4
40
- }
41
- ],
42
- "limits": {
43
- "maxArtifacts": 4
44
- }
45
- },
46
- "discoveryLimits": {
47
- "consecutiveNoNewFindingsRounds": 2,
48
- "maxRounds": 8
49
- }
28
+ ]
50
29
  }
@@ -15,9 +15,7 @@
15
15
  {
16
16
  "id": "program-recap",
17
17
  "type": "hub",
18
- "authoring": "markdown",
19
18
  "template": "house-style",
20
- "required": true,
21
19
  "briefRef": "briefs/program-recap.md",
22
20
  "requiredNarrative": [
23
21
  "program-overview",
@@ -28,31 +26,5 @@
28
26
  "follow-up-ledger"
29
27
  ]
30
28
  }
31
- ],
32
- "expansion": {
33
- "profiles": [
34
- {
35
- "profileId": "supporting-diagram",
36
- "type": "diagram",
37
- "authoring": "html",
38
- "briefRef": "briefs/supporting-diagram.md",
39
- "shell": "diagram-shell",
40
- "maxCount": 3
41
- },
42
- {
43
- "profileId": "project-page",
44
- "type": "explainer",
45
- "authoring": "markdown",
46
- "briefRef": "briefs/project-page.md",
47
- "maxCount": 12
48
- }
49
- ],
50
- "limits": {
51
- "maxArtifacts": 12
52
- }
53
- },
54
- "discoveryLimits": {
55
- "consecutiveNoNewFindingsRounds": 2,
56
- "maxRounds": 8
57
- }
29
+ ]
58
30
  }
@@ -15,9 +15,7 @@
15
15
  {
16
16
  "id": "project-explainer",
17
17
  "type": "hub",
18
- "authoring": "markdown",
19
18
  "template": "house-style",
20
- "required": true,
21
19
  "briefRef": "briefs/project-explainer.md",
22
20
  "requiredNarrative": [
23
21
  "planned-architecture",
@@ -27,24 +25,5 @@
27
25
  "validation-approach"
28
26
  ]
29
27
  }
30
- ],
31
- "expansion": {
32
- "profiles": [
33
- {
34
- "profileId": "supporting-diagram",
35
- "type": "diagram",
36
- "authoring": "html",
37
- "briefRef": "briefs/supporting-diagram.md",
38
- "shell": "diagram-shell",
39
- "maxCount": 4
40
- }
41
- ],
42
- "limits": {
43
- "maxArtifacts": 4
44
- }
45
- },
46
- "discoveryLimits": {
47
- "consecutiveNoNewFindingsRounds": 2,
48
- "maxRounds": 8
49
- }
28
+ ]
50
29
  }