@open-agent-toolkit/cli 0.2.29 → 0.2.31

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 (87) hide show
  1. package/assets/bundle-metadata.json +1 -1
  2. package/assets/docs/cli-utilities/configuration.md +52 -1
  3. package/assets/docs/contributing/code.md +19 -7
  4. package/assets/docs/contributing/explainer-kit-verification.md +9 -1
  5. package/assets/docs/contributing/skills.md +9 -0
  6. package/assets/docs/workflows/projects/artifacts.md +5 -0
  7. package/assets/docs/workflows/projects/index.md +1 -0
  8. package/assets/docs/workflows/projects/lifecycle.md +23 -0
  9. package/assets/docs/workflows/projects/retro.md +261 -0
  10. package/assets/docs/workflows/skills/explainer-kit-providers.md +16 -5
  11. package/assets/docs/workflows/skills/explainer-kit.md +98 -38
  12. package/assets/docs/workflows/skills/index.md +6 -0
  13. package/assets/public-package-versions.json +4 -4
  14. package/assets/skills/explainer-kit/SKILL.md +33 -8
  15. package/assets/skills/explainer-kit/briefs/project-recap.md +25 -7
  16. package/assets/skills/explainer-kit/recipes/project-recap.v2.json +72 -0
  17. package/assets/skills/explainer-kit/references/contracts.md +49 -17
  18. package/assets/skills/explainer-kit/references/destination-contract.md +141 -25
  19. package/assets/skills/explainer-kit/references/extension-contract.md +19 -10
  20. package/assets/skills/explainer-kit/references/visual-authoring.md +24 -0
  21. package/assets/skills/explainer-kit/references/visual-review.md +19 -5
  22. package/assets/skills/explainer-kit/schemas/author-request.v3.schema.json +241 -0
  23. package/assets/skills/explainer-kit/schemas/publish-receipt.v2.schema.json +215 -0
  24. package/assets/skills/explainer-kit/schemas/publish-request.v2.schema.json +34 -0
  25. package/assets/skills/explainer-kit/schemas/run-request.schema.json +4 -1
  26. package/assets/skills/explainer-kit/schemas/terminal-evidence.v1.schema.json +81 -0
  27. package/assets/skills/explainer-kit/schemas/visual-review-evidence.v1.schema.json +66 -0
  28. package/assets/skills/explainer-kit/scripts/lib/catalog.mjs +109 -3
  29. package/assets/skills/explainer-kit/scripts/lib/contracts.mjs +550 -17
  30. package/assets/skills/explainer-kit/scripts/lib/durability.mjs +90 -8
  31. package/assets/skills/explainer-kit/scripts/lib/fs-safe.mjs +5 -0
  32. package/assets/skills/explainer-kit/scripts/lib/internal-references.mjs +538 -0
  33. package/assets/skills/explainer-kit/scripts/lib/package-coverage.mjs +129 -11
  34. package/assets/skills/explainer-kit/scripts/lib/publication-policy.mjs +54 -0
  35. package/assets/skills/explainer-kit/scripts/lib/recipes.mjs +2 -1
  36. package/assets/skills/explainer-kit/scripts/lib/records.mjs +139 -22
  37. package/assets/skills/explainer-kit/scripts/lib/s3-roots.mjs +353 -0
  38. package/assets/skills/explainer-kit/scripts/lib/s3-static.mjs +237 -107
  39. package/assets/skills/explainer-kit/scripts/lib/set-plan.mjs +1 -0
  40. package/assets/skills/explainer-kit/scripts/lib/terminal-evidence.mjs +157 -0
  41. package/assets/skills/explainer-kit/scripts/lib/visual-review.mjs +26 -6
  42. package/assets/skills/explainer-kit/scripts/run.mjs +1006 -144
  43. package/assets/skills/oat-explainer-kit/SKILL.md +16 -3
  44. package/assets/skills/oat-explainer-kit/references/config-contract.md +13 -8
  45. package/assets/skills/oat-explainer-kit/references/lifecycle-contract.md +50 -6
  46. package/assets/skills/oat-explainer-kit/references/migration.md +2 -1
  47. package/assets/skills/oat-explainer-kit/references/visual-review-callback.md +11 -0
  48. package/assets/skills/oat-explainer-kit/scripts/bind-project-sources.mjs +37 -15
  49. package/assets/skills/oat-explainer-kit/scripts/check-terminal-outcome.mjs +83 -0
  50. package/assets/skills/oat-explainer-kit/scripts/derive-destination.mjs +91 -0
  51. package/assets/skills/oat-explainer-kit/scripts/finalize-tracked-run.mjs +66 -10
  52. package/assets/skills/oat-explainer-kit/scripts/resolve-config.mjs +60 -21
  53. package/assets/skills/oat-explainer-kit/scripts/resolve-paths.mjs +52 -8
  54. package/assets/skills/oat-explainer-kit/scripts/run.mjs +271 -36
  55. package/assets/skills/oat-project-autonomous/references/gate-inventory.md +38 -38
  56. package/assets/skills/oat-project-complete/SKILL.md +60 -8
  57. package/assets/skills/oat-project-document/references/docs/autonomy-contract.md +38 -38
  58. package/assets/skills/oat-project-implement/SKILL.md +1 -1
  59. package/assets/skills/oat-project-implement/references/completion-and-closeout.md +28 -6
  60. package/assets/skills/oat-project-implement/references/docs/autonomy-contract.md +38 -38
  61. package/assets/skills/oat-project-pr-final/references/docs/autonomy-contract.md +38 -38
  62. package/assets/skills/oat-project-quick-start/references/docs/autonomy-contract.md +38 -38
  63. package/assets/skills/oat-project-retro/SKILL.md +310 -0
  64. package/assets/skills/oat-project-retro/references/apply-procedure.md +212 -0
  65. package/assets/skills/oat-project-retro/references/evidence-and-lanes.md +91 -0
  66. package/assets/skills/oat-project-retro/references/retro-quality-bar.md +100 -0
  67. package/assets/skills/oat-project-retro-file/SKILL.md +387 -0
  68. package/assets/templates/project-retro.md +236 -0
  69. package/dist/commands/config/index.d.ts.map +1 -1
  70. package/dist/commands/config/index.js +99 -0
  71. package/dist/commands/init/tools/shared/skill-manifest.d.ts +2 -2
  72. package/dist/commands/init/tools/shared/skill-manifest.d.ts.map +1 -1
  73. package/dist/commands/init/tools/shared/skill-manifest.js +3 -0
  74. package/dist/commands/project/archive/archive-utils.d.ts.map +1 -1
  75. package/dist/commands/project/archive/archive-utils.js +57 -7
  76. package/dist/commands/project/archive/explainer-terminal-evidence.d.ts +29 -0
  77. package/dist/commands/project/archive/explainer-terminal-evidence.d.ts.map +1 -0
  78. package/dist/commands/project/archive/explainer-terminal-evidence.js +37 -0
  79. package/dist/config/oat-config.d.ts +14 -1
  80. package/dist/config/oat-config.d.ts.map +1 -1
  81. package/dist/config/oat-config.js +42 -2
  82. package/dist/config/resolve.d.ts.map +1 -1
  83. package/dist/config/resolve.js +9 -0
  84. package/package.json +2 -2
  85. /package/assets/skills/explainer-kit/recipes/{project-recap.json → project-recap.v1.json} +0 -0
  86. /package/assets/skills/explainer-kit/schemas/{publish-receipt.schema.json → publish-receipt.v1.schema.json} +0 -0
  87. /package/assets/skills/explainer-kit/schemas/{publish-request.schema.json → publish-request.v1.schema.json} +0 -0
@@ -20,19 +20,19 @@ OAT lifecycle callers use the adapter.
20
20
 
21
21
  ## Recipes
22
22
 
23
- The core ships four versioned recipes on the `explainer-kit.recipe/v2` file
24
- schema. Each recipe's own `version` selector remains `"1"`, so `{id, version}`
25
- callers and manifest cross-checks are unaffected by the schema move.
23
+ The core ships four recipe families on the `explainer-kit.recipe/v2` file
24
+ schema. Most recipe selectors remain at version `"1"`. New project recaps use
25
+ immutable `project-recap@2`, while `project-recap@1` remains readable for replay.
26
26
 
27
27
  A v2 recipe declares a **floor** — the artifacts every run must produce — plus
28
28
  a licensed **expansion** set. Most recipes retain one floor artifact.
29
- Unattended `project-recap` is the exception: it plans and composes an adaptive
30
- minimum set before any artifact author runs.
29
+ `project-recap@2` requires one complete navigational hub and plans any additional
30
+ artifact before an author runs.
31
31
 
32
32
  | Recipe | Use | Required floor |
33
33
  | ------------------- | ------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------- |
34
34
  | `project-explainer` | Working explanation after project planning | one Markdown `hub` covering architecture, decisions, risks, phases, and validation |
35
- | `project-recap` | Final record after implementation and final review | HTML visual hub, architecture/system diagram, and deck governed by one set plan |
35
+ | `project-recap` | Final record after implementation and final review | one HTML navigational hub; diagrams, decks, and deep dives are adaptive expansions |
36
36
  | `program-recap` | Bird's-eye record of a multi-wave delivery program | one Markdown `hub` covering the wave map, outcomes, convention evolution, aggregate numbers, and follow-up ledger |
37
37
  | `engineer-tour` | Engineer-facing orientation to a codebase and its flow | one HTML-composed `explainer` covering orientation, architecture, execution flow, key code, and validation |
38
38
 
@@ -46,8 +46,8 @@ adding an OAT dependency.
46
46
  ### Project recap modes
47
47
 
48
48
  Project recaps default to `recapMode: artistic`. This mode uses the shared set
49
- plan and provider-neutral author seam to compose the required HTML hub,
50
- architecture view, and deck.
49
+ plan and provider-neutral author seam to compose the required HTML hub plus any
50
+ source-backed expansion that answers a distinct reader question.
51
51
 
52
52
  `recapMode: deterministic-markdown` is an explicit fallback for callers that
53
53
  need deterministic output. It preserves the same planned artifact portfolio and
@@ -63,16 +63,16 @@ artifact `type`, authoring path, brief, optional shell, and a mandatory
63
63
  `maxCount`. Every recipe also carries a mandatory `expansion.limits.maxArtifacts`
64
64
  that caps the whole expansion set; floor artifacts do not count against it.
65
65
 
66
- | Recipe | Profiles (max per profile) | `maxArtifacts` |
67
- | ------------------- | ------------------------------------------------ | -------------- |
68
- | `project-recap` | `status-view` 1, `rollout-view` 1, `deep-dive` 3 | 5 |
69
- | `program-recap` | `supporting-diagram` 3, `project-page` 12 | 12 |
70
- | `project-explainer` | `supporting-diagram` 4 | 4 |
71
- | `engineer-tour` | `supporting-diagram` 4 | 4 |
66
+ | Recipe | Profiles (max per profile) | `maxArtifacts` |
67
+ | ------------------- | ----------------------------------------------------------- | -------------- |
68
+ | `project-recap@2` | `supporting-diagram` 1, `walkthrough-deck` 1, `deep-dive` 3 | 5 |
69
+ | `program-recap` | `supporting-diagram` 3, `project-page` 12 | 12 |
70
+ | `project-explainer` | `supporting-diagram` 4 | 4 |
71
+ | `engineer-tour` | `supporting-diagram` 4 | 4 |
72
72
 
73
- For project recaps, optional status and rollout views require matching
74
- source-backed justifications, while `deep-dive` remains a Markdown
75
- `explainer`. Other recipes retain their recipe-owned diagram and project-page
73
+ For project recaps, every optional diagram, deck, or deep dive needs a distinct
74
+ reader question, supporting source evidence, and rationale for choosing that
75
+ medium. Other recipes retain their recipe-owned diagram and project-page
76
76
  profiles. Every declared type stays inside the frozen `manifest/v1` enum.
77
77
 
78
78
  ## Content authoring and review
@@ -116,6 +116,11 @@ author request, so an unattended author receives everything it needs in one
116
116
  payload. Changing a brief changes output expectations with no contract
117
117
  migration.
118
118
 
119
+ The bundled authoring prose covers typographic roles, hierarchy, composition,
120
+ density, medium leverage, template repetition, diagram semantics, and
121
+ cross-artifact cohesion. These remain editorial judgments rather than numeric
122
+ scores or deterministic layout checks.
123
+
119
124
  ### The planning and author seams
120
125
 
121
126
  Before authoring, one provider-neutral `planSet` callback produces the complete
@@ -125,15 +130,17 @@ portfolio. Every run also requires one provider-neutral author callback, in
125
130
  without one fails with `E_AUTHOR_REQUIRED`.
126
131
 
127
132
  The core invokes the author once per planned artifact with an
128
- `explainer-kit.author-request/v2` payload carrying the artifact identity and
133
+ `explainer-kit.author-request/v3` payload carrying the artifact identity and
129
134
  type, its authoring path, the inlined brief, the reconciled fact base, the
130
135
  resolved theme, the shell source for artistic artifacts, the immutable set
131
- context, the matching planned artifact, and bundled medium-specific authoring
132
- guidance. The installed skill is the complete unattended baseline; optional
136
+ context, the matching planned artifact, canonical artifact links, and bundled
137
+ medium-specific authoring guidance. Version 2 requests remain readable for
138
+ replay. The installed skill is the complete unattended baseline; optional
133
139
  provider capabilities can enhance composition but are not required. The core
134
- accepts only a schema-valid `explainer-kit.author-result/v2` containing exactly one of
135
- `content.markdown` or `content.html` plus non-secret provenance. Authored
136
- content is still checked for excessive verbatim overlap with the fact base.
140
+ accepts only a schema-valid `explainer-kit.author-result/v2` containing exactly
141
+ one of `content.markdown` or `content.html` plus non-secret provenance.
142
+ Authored content is still checked for excessive verbatim overlap with the fact
143
+ base.
137
144
 
138
145
  Direct callbacks and module entry points are first-class but transient: they
139
146
  never enter retained request contracts. See
@@ -143,9 +150,10 @@ planner, author, browser-session, and visual-critic boundaries.
143
150
  ### Planner-owned adaptive sets
144
151
 
145
152
  The set planner finalizes required and optional artifacts before authoring.
146
- Project recaps always contain a hub, architecture/system diagram, and deck;
147
- the planner may add only recipe-licensed optional views with a source-backed
148
- justification. Recipe and per-profile limits still bound the portfolio.
153
+ New project recaps always contain a navigational hub. The planner may add only
154
+ recipe-licensed optional diagrams, decks, or deep dives with a distinct reader
155
+ question, source evidence, and medium rationale. Recipe and per-profile limits
156
+ still bound the portfolio.
149
157
  Undeclared sources, conflicting ledger values, duplicate IDs, and unjustified
150
158
  optionals fail validation. Author results cannot add, remove, or replace
151
159
  artifacts.
@@ -188,11 +196,21 @@ evidence to an independent critic. Fixture sessions are test-only and are
188
196
  rejected in unattended production.
189
197
 
190
198
  A `correct` disposition permits one bounded correction and exactly one final
191
- review; there is no second correction or third review. Missing, forged,
199
+ review; there is no second correction or third review. The correction budget is
200
+ shared with the internal-link gate described below, so a `correct` disposition
201
+ is refused outright with `E_VISUAL_CORRECTION` when link validation already
202
+ spent the single bounded correction on this run. Missing, forged,
192
203
  cross-record-mismatched, or invalid evidence, a failed critic, or an unresolved
193
204
  correction ends as `built-needs-review`. Such output is retained for diagnosis
194
205
  but cannot become durable, finalized, archived, or published.
195
206
 
207
+ The critic reviews the whole set for typography, hierarchy, composition,
208
+ density, medium leverage, template repetition, diagram semantics, and
209
+ cross-artifact cohesion. It returns the existing provider-neutral result:
210
+ `pass` when no required correction remains or `correct` with concrete,
211
+ artifact-scoped actions for the bounded correction round. No numeric design
212
+ threshold is part of the contract.
213
+
196
214
  The approval record is also the durable source of truth for the resolved
197
215
  artifact set. It records every floor and accepted expansion artifact for all
198
216
  approval states, including pending and rejected, so a paused expanded run
@@ -221,6 +239,26 @@ Every legacy `ekrt1` token is rejected. A paused run created with the legacy
221
239
  format must restart to receive an authenticated token; editing retained package
222
240
  state cannot opt it into compatibility.
223
241
 
242
+ ### Internal-link validation
243
+
244
+ Every internal reference in the rendered set must resolve to a
245
+ manifest-declared target before the run can reach browser review. The gate runs
246
+ after render and uses a bounded tokenizer rather than a general HTML parser.
247
+ Relative references resolve from the current explicit file and must bind
248
+ exactly to the manifest/site tree, and a referenced fragment must resolve to
249
+ exactly one ID in its target document. Directory references, path traversal,
250
+ missing targets, missing fragments, ambiguous fragments, and unsafe schemes all
251
+ fail with `E_INTERNAL_REFERENCE`.
252
+
253
+ A failure gets one bounded correction round, re-rendered and revalidated. That
254
+ round is the same single budget the visual-review `correct` disposition uses —
255
+ whichever gate reaches it first consumes it. Once it is exhausted the run fails
256
+ hard: the QA stage is recorded `failed` with code-only evidence and the scrubbed
257
+ message `The qa stage failed.`, and the run is neither durability- nor
258
+ publication-eligible. No finding is retained, so nothing in the durable record
259
+ names the broken reference; the failure is attributed to the `link-validation`
260
+ evidence stage.
261
+
224
262
  ## Warnings and QA severity
225
263
 
226
264
  QA findings are split by severity, and the split is what lets thin content ship
@@ -296,9 +334,17 @@ Reviewed source and citation backlinks are absolute canonical GitHub blob URLs
296
334
  pinned to the exact 40-character commit revision and line range, so they
297
335
  survive project archival without resolving through a mutable branch or local
298
336
  checkout. Each recap also emits
299
- `site/initiatives/<slug>/catalog.json` from the finalized manifest. Its
300
- artifact IDs, types, paths, URLs, and source backlinks must remain in exact
301
- manifest parity; authors do not hand-maintain the catalog.
337
+ `site/initiatives/<slug>/catalog.json` from the finalized manifest, versioned
338
+ as `explainer-kit.initiative-catalog/v2`. Its artifact IDs, types, paths,
339
+ URLs, and source backlinks must remain in exact manifest parity; authors do
340
+ not hand-maintain the catalog. The catalog's `publicVerification` field is a
341
+ **policy marker, never an outcome**: `required` when the run's public access
342
+ policy calls for anonymous URL verification, `skipped-by-policy` for
343
+ protected destinations. It records what the publication policy was — the
344
+ per-artifact verification outcomes live in `publish-receipt.json`.
345
+ Compatibility is regenerate-only: consumers parse the declared version, and
346
+ no v1 read path exists because no released consumer could verify v1 catalog
347
+ evidence.
302
348
 
303
349
  `manifest.immutableHashes` covers the exact retained bytes for
304
350
  `run-request.json`, content approval, fact-base JSON and Markdown, declared
@@ -322,12 +368,25 @@ Build success and durability are separate:
322
368
 
323
369
  The core verifies caller-supplied commit or publish evidence; it never creates
324
370
  Git commits. Publishing is always explicitly requested and human-gated. The
325
- public `s3-static` connector validates corresponding S3 and HTTPS roots with a
326
- run-unique sentinel, uploads only manifest-declared `site/` files, verifies the
327
- content type and SHA-256 response bytes at public URLs, and writes
328
- `publish-receipt.json`. Public roots cannot contain credentials, queries, or
329
- fragments. Publishing is additive and does not run a root-wide destructive
330
- sync.
371
+ public `s3-static` connector validates each S3 and HTTPS root independently and
372
+ proves the destination with a run-unique sentinel, uploads only
373
+ manifest-declared `site/` files, and writes `publish-receipt.json`.
374
+ Verification depends on the declared `publicAccess` policy: in `public` mode
375
+ the connector anonymously fetches each published URL and compares content
376
+ type and SHA-256 response bytes; in `protected` mode it verifies object
377
+ integrity through authenticated S3 hashing instead, and every receipt entry
378
+ records `publicVerification: skipped-protected` so the skipped anonymous
379
+ check is visible rather than implied.
380
+
381
+ Root screening is strict on both roots: no credentials, queries, or
382
+ fragments; no whitespace, C0/C1 control characters, or backslashes; and the
383
+ gate applies to every publish-request and publish-receipt contract version
384
+ rather than being pinned to one version string. Public roots must be HTTPS
385
+ and must not address loopback, link-local, or private networks, and
386
+ verification fetches refuse redirects (`redirect: 'error'`) — see the
387
+ [publication environment variables](/docs/cli-utilities/configuration#explainer-publication-environment-variables)
388
+ for the explicit private-root opt-in and its durable receipt trace.
389
+ Publishing is additive and does not run a root-wide destructive sync.
331
390
 
332
391
  Release validation drives the bounded curated-style/template matrix in a real
333
392
  installed Chromium browser and retains machine-readable viewport, clipping,
@@ -375,8 +434,9 @@ typed adapter settings.
375
434
  Private integrations use the core boundary directly: resolve private inputs
376
435
  before the run, construct one versioned request, invoke the core once, then
377
436
  publish or link the versioned manifest after the run. Wrapper acceptance reads
378
- the complete post-run `PublishReceiptV1`, verifies every manifest artifact and
379
- the core run ID, and rejects foreign or stale receipts. Presets, private source
437
+ the complete post-run `publish-receipt/v2`, verifies every manifest artifact
438
+ and the core run ID, and rejects foreign or stale receipts; `publish-receipt/v1`
439
+ remains readable for replay of older runs only. Presets, private source
380
440
  systems, external-document synchronization, and personal destinations remain
381
441
  wrapper-owned.
382
442
 
@@ -24,6 +24,10 @@ Use this section when you want to choose the right OAT skill for a task. If you
24
24
  - Split a broad discovery or brainstorm into child projects: `oat-project-split`
25
25
  - Retroactively capture existing work: `oat-project-capture`
26
26
  - Run or receive reviews: `oat-project-review-provide`, `oat-project-review-receive`, or the non-project review variants
27
+ - Generate an evidence-grounded project retrospective, apply approved repo
28
+ improvements, or file tracker feedback: `oat-project-retro` and
29
+ `oat-project-retro-file`. See
30
+ [Project Retrospectives](../projects/retro.md).
27
31
  - Capture a scoped, shippable backlog item: `oat-pjm-add-backlog-item` directly when the work is already scoped, or `oat-brainstorm` when the thought hasn't converged yet — the brainstorm dispatcher's "scoped backlog item" destination pre-fills the title / description / acceptance criteria / scope estimate / priority from the conversation and then runs `oat-pjm-add-backlog-item` with confirmed inputs
28
32
  - Manage the repo backlog and reference docs: `oat-pjm-update-repo-reference`, `oat-pjm-review-backlog`
29
33
  - Turn a repo audit, maintainability review, backlog review, backlog directory, or backlog item into standalone external implementation plans: `oat-repo-improve`. Plans land under `.oat/repo/reference/external-plans/`; execute them directly or optionally pass one to `oat-project-import-plan` for tracked OAT execution.
@@ -74,6 +78,8 @@ Use this section when you want to choose the right OAT skill for a task. If you
74
78
  - `oat-project-pr-progress`
75
79
  - `oat-project-pr-final`
76
80
  - `oat-project-document`
81
+ - `oat-project-retro`
82
+ - `oat-project-retro-file`
77
83
  - `oat-explainer-kit`
78
84
  - `oat-wrap-up`
79
85
  - `oat-project-complete`
@@ -1,6 +1,6 @@
1
1
  {
2
- "cli": "0.2.29",
3
- "docs-config": "0.2.29",
4
- "docs-theme": "0.2.29",
5
- "docs-transforms": "0.2.29"
2
+ "cli": "0.2.31",
3
+ "docs-config": "0.2.31",
4
+ "docs-theme": "0.2.31",
5
+ "docs-transforms": "0.2.31"
6
6
  }
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: explainer-kit
3
- version: 2.0.3
3
+ version: 2.1.0
4
4
  description: Use when building destination-neutral visual explainer artifacts from explicit, versioned inputs.
5
5
  user-invocable: true
6
6
  allowed-tools: Read, Write, Edit, Bash, Grep, Glob, Agent, mcp__*
@@ -74,11 +74,13 @@ request.
74
74
  The recipe — never the author — selects each artifact's authoring path. Floor
75
75
  entries and expansion profiles declare `authoring: markdown` for the narrative
76
76
  path or `authoring: html` for the artistic path. The core invokes the author
77
- once per artifact with an `explainer-kit.author-request/v2` payload carrying the
77
+ once per artifact with an `explainer-kit.author-request/v3` payload carrying the
78
78
  artifact identity and type, its authoring path, the inlined brief from
79
79
  `briefs/`, the reconciled fact base, the resolved theme, the shell source for
80
- artistic artifacts, and the required narrative sections for narrative floor
81
- artifacts. It accepts only a schema-valid
80
+ artistic artifacts, the required narrative sections for narrative floor
81
+ artifacts, and canonical `artifactLinks` with explicit `index.html` site paths
82
+ and receiver-relative hrefs. Version 2 requests remain readable for replay. It
83
+ accepts only a schema-valid
82
84
  `explainer-kit.author-result/v2` with exactly one of `content.markdown` or
83
85
  `content.html` plus non-secret provenance, rejects excessive verbatim source
84
86
  overlap, retains each validated result under `source/author/` and its content
@@ -107,11 +109,28 @@ continues. Accepted expansion artifacts render to
107
109
  `site/{directory}/{slug}/{artifactId}/index.html` and are linked from the floor
108
110
  hub; floor artifacts keep their existing paths.
109
111
 
112
+ `project-recap@2` requires one complete navigational hub and makes diagrams,
113
+ decks, and deep dives adaptive expansions. The planner proposes one only when
114
+ it can name a distinct reader question, the supporting source evidence, and why
115
+ that medium improves on adding more hub prose. The prose brief governs
116
+ typographic roles, hierarchy, slide archetypes, diagram semantics,
117
+ fit-to-content composition, density, repetition, and medium choice. These are
118
+ editorial judgments, not new request fields or renderer rules.
119
+ `project-recap@1` remains readable for replay with its historical three-artifact
120
+ floor.
121
+
110
122
  ## Review, Approval, and Warnings
111
123
 
112
- Approval runs after theme, render, safety validation, the guideline checker, and
113
- render QA, immediately before publish and durability — so a reviewer approves
114
- rendered artifacts and the complete warning set, not raw prose.
124
+ Approval runs after theme, render, hard internal-reference validation, safety
125
+ validation, the guideline checker, and render QA, immediately before publish and
126
+ durability — so a reviewer approves rendered artifacts and the complete warning
127
+ set, not raw prose. The reference gate resolves `href`, `src`, `srcset`,
128
+ fragments, and safe embedded references against explicit manifest/site-tree
129
+ files. It may invoke the existing correction author once, then rerenders and
130
+ revalidates before any browser or visual review. A later visual correction also
131
+ rerenders and passes through the validation-only reference gate without
132
+ receiving another correction attempt. An exhausted `E_INTERNAL_REFERENCE`
133
+ finding fails closed and cannot reach durability.
115
134
 
116
135
  Interactive runs stop with an `incomplete` outcome once artifacts are built and
117
136
  checked. Review the rendered `site/` tree, the sources under `source/content/`,
@@ -144,7 +163,13 @@ succeed.
144
163
 
145
164
  Visual critics use the independent whole-set rubric in
146
165
  `references/visual-review.md`, which separates review judgment from
147
- medium-specific authoring rules.
166
+ medium-specific authoring rules. They assess typography, hierarchy,
167
+ composition, density, medium leverage, template repetition, diagram semantics,
168
+ and cross-artifact cohesion from rendered browser evidence. The rubric keeps
169
+ the existing provider-neutral result contract: `pass` means no required
170
+ correction remains, while `correct` carries concrete artifact-scoped actions
171
+ into the one bounded correction round. It does not assign design scores or
172
+ encode geometry thresholds.
148
173
 
149
174
  Render QA is opt-in. It runs only against an injected `browserProbe`, and the
150
175
  core never launches a browser of its own — reviewing the rendered output in a
@@ -34,14 +34,32 @@ Use the same terms, statuses, and numbers throughout.
34
34
 
35
35
  ## Floor
36
36
 
37
- Produce one rich narrative hub covering all six sections above. It must contain
38
- at least one high-level architecture diagram, structured lists where useful,
39
- and evidence tables for implementation and validation. The page should remain
40
- useful without any expansion artifact.
37
+ Produce one rich navigational hub covering all six sections above. It must
38
+ orient the reader, expose the project state and outcome in the first viewport,
39
+ and link every selected artifact with descriptive labels. The hub should remain
40
+ complete and useful without an expansion artifact.
41
+
42
+ Establish deliberate typographic roles for the title, framing statement,
43
+ section headings, labels, body text, and evidence annotations. Build hierarchy
44
+ through scale, spacing, contrast, and grouping instead of applying one repeated
45
+ card or section treatment everywhere. Keep density fit to the material: shorten
46
+ or restructure crowded passages, but do not pad sparse evidence with decorative
47
+ filler. Choose tables, lists, diagrams, and prose only when each medium makes
48
+ the evidence easier to understand.
41
49
 
42
50
  ## Expansion license
43
51
 
44
- Propose additional diagrams, a deep-dive, or a walkthrough deck when complexity
45
- earns it. Expansion should clarify a real boundary, flow, trade-off, or
46
- operational handoff that would overload the hub. Do not expand to repeat the
52
+ Propose a supporting diagram, walkthrough deck, or deep-dive only when it
53
+ answers a distinct reader question that the hub cannot answer cleanly. For
54
+ every proposal, identify the reader question, the source evidence that supports
55
+ it, and the rationale for choosing that medium. Do not expand to repeat the
47
56
  same story in another format.
57
+
58
+ Use a diagram when topology, direction, ownership, or flow carries meaning.
59
+ Preserve branches, fan-in, cycles, labels, and explicit relationships, and fit
60
+ the frame to the content rather than leaving a tiny graph in a large canvas.
61
+ Use a deck only when pacing adds value; choose slide archetypes to match the
62
+ story, such as an outcome opener, comparison, system view, decision, evidence,
63
+ or next-action frame. Vary composition to fit each claim instead of repeating
64
+ one template. Use a deep-dive when source-backed mechanics or trade-offs need
65
+ more room than the hub can give them.
@@ -0,0 +1,72 @@
1
+ {
2
+ "schemaVersion": "explainer-kit.recipe/v2",
3
+ "id": "project-recap",
4
+ "version": "2",
5
+ "sourceRoles": [
6
+ {
7
+ "role": "project",
8
+ "required": true,
9
+ "accepts": ["file", "directory", "git", "github"],
10
+ "minBindings": 1,
11
+ "maxBindings": 1
12
+ }
13
+ ],
14
+ "floor": [
15
+ {
16
+ "id": "project-recap",
17
+ "type": "hub",
18
+ "authoring": "html",
19
+ "template": "house-style",
20
+ "required": true,
21
+ "briefRef": "briefs/project-recap.md",
22
+ "requiredNarrative": [
23
+ "original-request",
24
+ "key-agent-decisions",
25
+ "as-built-architecture",
26
+ "implementation-record",
27
+ "validation-evidence",
28
+ "outcome"
29
+ ]
30
+ }
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": 1
41
+ },
42
+ {
43
+ "profileId": "walkthrough-deck",
44
+ "type": "deck",
45
+ "authoring": "html",
46
+ "briefRef": "briefs/walkthrough-deck.md",
47
+ "shell": "deck-shell",
48
+ "maxCount": 1
49
+ },
50
+ {
51
+ "profileId": "deep-dive",
52
+ "type": "explainer",
53
+ "authoring": "markdown",
54
+ "briefRef": "briefs/deep-dive.md",
55
+ "maxCount": 3
56
+ }
57
+ ],
58
+ "limits": {
59
+ "maxArtifacts": 5
60
+ }
61
+ },
62
+ "fallback": {
63
+ "mode": "deterministic-markdown",
64
+ "selection": "explicit",
65
+ "authoring": "markdown",
66
+ "scope": "portfolio"
67
+ },
68
+ "discoveryLimits": {
69
+ "consecutiveNoNewFindingsRounds": 2,
70
+ "maxRounds": 8
71
+ }
72
+ }
@@ -34,25 +34,34 @@ Every run, interactive or unattended, also requires a provider-neutral author
34
34
  callback; a run without one fails `E_AUTHOR_REQUIRED`. An in-process caller
35
35
  supplies `options.author(request)`; a JSON-only CLI caller uses
36
36
  `--author-module author.mjs`. The core invokes it once per resolved artifact
37
- with an `explainer-kit.author-request/v2` payload containing the artifact
37
+ with an `explainer-kit.author-request/v3` payload containing the artifact
38
38
  identity and type, the artifact's authoring path, the inlined brief, the bundled
39
39
  `visualAuthoringGuidance`, the reconciled fact base, the resolved theme, the
40
40
  shell source for artistic artifacts, the required narrative sections for
41
- narrative floor artifacts, and bounded-discovery context. The guidance is
41
+ narrative floor artifacts, bounded-discovery context, and `artifactLinks`.
42
+ Each canonical link entry names the planned artifact, its explicit site-relative
43
+ path ending in `index.html`, and the relative `href` from the receiving
44
+ artifact's own location. The guidance is
42
45
  loaded only from the installed skill's `references/visual-authoring.md`; no
43
46
  ambient or home-directory file is consulted. The callback must return an
44
47
  `explainer-kit.author-result/v2` carrying exactly one of `content.markdown` or
45
48
  `content.html`, matching the artifact's declared authoring path, plus non-secret
46
49
  provenance. The executable callback is never persisted in `run-request.json`.
47
50
 
48
- Project recap requests have an explicit `recapMode`. Omitting it selects and
49
- persists `artistic`, which keeps the recipe's rich HTML floor. Selecting
50
- `deterministic-markdown` before the run applies the recipe-owned fallback to
51
- the complete planned portfolio, including optional expansions, while retaining
52
- the same adaptive hub, architecture, and deck identities. The resulting
53
- Markdown author records and `source/content/*.md` paths remain distinct in the
54
- manifest and immutable rebuild package. An artistic author failure fails the
55
- run; the core never silently retries or downgrades it as Markdown.
51
+ New project recap producers select immutable `project-recap@2`. Its
52
+ navigational hub is the only mandatory artifact. A diagram, deck, or deep dive
53
+ is an optional expansion only when its justification states a distinct reader
54
+ question, supporting source evidence, and the rationale for using that medium.
55
+ Project recap requests also have an explicit `recapMode`. Omitting it selects
56
+ and persists `artistic`, which keeps the recipe's rich HTML floor. Selecting
57
+ `deterministic-markdown` before the run applies the recipe-owned fallback to the
58
+ complete planned portfolio the hub plus any accepted expansions — without
59
+ changing its artifact identities. The resulting Markdown author records and
60
+ `source/content/*.md` paths remain distinct in the manifest and immutable
61
+ rebuild package. An artistic author failure fails the run; the core never
62
+ silently retries or downgrades it as Markdown. `project-recap@1` is immutable
63
+ replay guidance only: retained v1 requests remain readable, but current
64
+ producers do not select it.
56
65
 
57
66
  Before artifact authoring, a caller supplies one provider-neutral `planSet`
58
67
  callback. It receives the reconciled fact base and recipe policy and returns
@@ -62,7 +71,7 @@ callback. It receives the reconciled fact base and recipe policy and returns
62
71
  {
63
72
  "schemaVersion": "explainer-kit.set-plan/v1",
64
73
  "planId": "project-recap-set",
65
- "recipe": { "id": "project-recap", "version": "1" },
74
+ "recipe": { "id": "project-recap", "version": "2" },
66
75
  "sourceIds": ["plan"],
67
76
  "ledger": {
68
77
  "terminology": [],
@@ -87,9 +96,11 @@ The set plan owns the shared terminology/status/number ledger, source coverage,
87
96
  adaptive portfolio, per-artifact draft, and visual intent. Optional entries add
88
97
  a source-backed `justification`; undeclared sources, conflicting ledger values,
89
98
  duplicate artifact IDs, and unjustified optional entries are invalid. Each
90
- `author-request/v2` carries the complete immutable `setContext` plus the exact
99
+ `author-request/v3` carries the complete immutable `setContext` plus the exact
91
100
  matching `plannedArtifact`. The planner finalizes floor and expansion entries
92
101
  before authoring; author results cannot add, remove, or replace artifacts.
102
+ Version 2 requests remain valid for deterministic replay; new runs emit only
103
+ the complete v3 request.
93
104
  When a planner draft contains a supported non-linear graph, the request also
94
105
  carries its closed `graphSemantics` (direction, nodes, edges, and topology).
95
106
  Artistic HTML must expose one exact `data-direction`. Each planned node requires
@@ -183,12 +194,33 @@ The core executes:
183
194
  5. author every planned artifact against the same set context
184
195
  6. render typed artifacts through the narrative renderer or validate
185
196
  agent-composed HTML, per each artifact's declared authoring path
186
- 7. run structural and guideline QA, plus required browser and independent
197
+ 7. validate every post-render `href`, `src`, `srcset`, and embedded reference
198
+ against the manifest paths and generated site tree; reject directory links,
199
+ escapes, missing files or fragments, malformed references, and unsafe
200
+ embedded resources
201
+ 8. optionally apply one bounded author correction, then rerender and revalidate
202
+ the complete site before any browser callback
203
+ 9. run structural and guideline QA, plus required browser and independent
187
204
  visual review for unattended project recaps
188
- 8. close any unresolved recap review gate before external persistence
189
- 9. resolve content approval — the interactive gate pauses here, after render and
190
- QA and before anything is published or persisted externally
191
- 10. write the manifest and build record
205
+ 10. close any unresolved recap review gate before external persistence
206
+ 11. resolve content approval — the interactive gate pauses here, after render and
207
+ QA and before anything is published or persisted externally
208
+ 12. write the manifest and build record
209
+
210
+ The internal-reference gate uses a bounded tokenizer/classifier rather than a
211
+ general HTML parser. Relative references resolve from the current explicit file
212
+ with an isolated HTTPS base, then must bind exactly to the manifest/site tree.
213
+ Referenced fragments must resolve to exactly one ID in the target document;
214
+ unused duplicate renderer-generated IDs do not fail indexing. Safe base64 image
215
+ data references and same-document fragments are classified separately. A
216
+ malformed, unresolved, or ambiguous reference fails `E_INTERNAL_REFERENCE`.
217
+ Once the one correction is exhausted, including after visual correction, the run
218
+ fails hard: the QA stage is recorded `failed` with code-only evidence and the
219
+ scrubbed message `The qa stage failed.`, and the run is not durability- or
220
+ publication-eligible. No finding is retained and nothing names the broken
221
+ reference — terminal evidence is code-only by design, and the failure is
222
+ attributed to the `link-validation` evidence stage rather than to
223
+ `browser-review`.
192
224
 
193
225
  An incomplete interactive result includes
194
226
  `approval.resumeToken: "ekrt2:<64 lowercase hex characters>"`. The token is an