@erclx/canon 5.31.0 → 5.32.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 (303) hide show
  1. package/README.md +1 -1
  2. package/claude/.claude-plugin/plugin.json +1 -1
  3. package/claude/skills/api-design/references/adopted.md +1 -1
  4. package/claude/skills/auto-ship/REQUIREMENT.md +4 -16
  5. package/claude/skills/auto-ship/SKILL.md +13 -58
  6. package/claude/skills/auto-ship/references/draft-mark.md +2 -2
  7. package/claude/skills/auto-ship/references/failure-recovery.md +1 -5
  8. package/claude/skills/auto-ship/references/tier-failures.md +1 -1
  9. package/claude/skills/auto-ship/references/ui-checklist.md +2 -2
  10. package/claude/skills/auto-ship/references/verb-absent.md +3 -27
  11. package/claude/skills/backlog-triage/SKILL.md +1 -1
  12. package/claude/skills/canon-cli/REQUIREMENT.md +4 -6
  13. package/claude/skills/canon-cli/SKILL.md +2 -2
  14. package/claude/skills/canon-feedback/REQUIREMENT.md +1 -1
  15. package/claude/skills/canon-feedback/SKILL.md +10 -13
  16. package/claude/skills/canon-feedback-triage/REQUIREMENT.md +13 -14
  17. package/claude/skills/canon-feedback-triage/SKILL.md +49 -30
  18. package/claude/skills/canvas/REQUIREMENT.md +3 -4
  19. package/claude/skills/canvas/SKILL.md +5 -5
  20. package/{standards → claude/skills/canvas/references}/canvas.md +12 -1
  21. package/claude/skills/ci-workflow/REQUIREMENT.md +0 -1
  22. package/claude/skills/context-fold/REQUIREMENT.md +8 -20
  23. package/claude/skills/context-fold/SKILL.md +20 -44
  24. package/claude/skills/context-fold/references/classify.md +7 -8
  25. package/claude/skills/context-fold/references/completion-report.md +2 -6
  26. package/claude/skills/context-fold/references/context-refresh.md +5 -15
  27. package/claude/skills/context-fold/references/promoted-pages.md +3 -3
  28. package/claude/skills/context-fold/references/receipt-sweep.md +6 -17
  29. package/claude/skills/context-fold/references/unusable-baseline.md +4 -6
  30. package/claude/skills/create-rule/REQUIREMENT.md +0 -1
  31. package/claude/skills/create-skill/REQUIREMENT.md +6 -4
  32. package/claude/skills/create-skill/SKILL.md +8 -7
  33. package/{standards → claude/skills/create-skill/references}/skill-paths.md +1 -0
  34. package/claude/skills/decision-escalate/REQUIREMENT.md +1 -1
  35. package/claude/skills/decision-escalate/SKILL.md +1 -1
  36. package/claude/skills/design-taste/REQUIREMENT.md +0 -2
  37. package/claude/skills/design-taste/SKILL.md +1 -3
  38. package/claude/skills/design-taste/references/vocabulary.md +1 -1
  39. package/claude/skills/docs-sync/REQUIREMENT.md +3 -3
  40. package/claude/skills/document-health/REQUIREMENT.md +2 -2
  41. package/claude/skills/document-health/SKILL.md +4 -5
  42. package/claude/skills/document-health/references/axes.md +4 -6
  43. package/claude/skills/draft-and-pick/REQUIREMENT.md +16 -14
  44. package/claude/skills/draft-and-pick/SKILL.md +40 -32
  45. package/claude/skills/draft-and-pick/references/live-arms.md +9 -9
  46. package/claude/skills/draft-doc/REQUIREMENT.md +5 -5
  47. package/claude/skills/draft-doc/SKILL.md +9 -10
  48. package/claude/skills/draft-doc/references/requirements.md +61 -0
  49. package/claude/skills/draft-doc/references/wiki-kind.md +53 -0
  50. package/claude/skills/draft-doc/references/wiki.md +50 -30
  51. package/claude/skills/draft-figure/REQUIREMENT.md +2 -2
  52. package/claude/skills/draft-figure/SKILL.md +4 -4
  53. package/claude/skills/draft-figure/references/architecture-set.md +4 -4
  54. package/claude/skills/draft-figure/references/hand-drawn.md +1 -1
  55. package/claude/skills/draft-figure/references/mermaid-path.md +55 -0
  56. package/claude/skills/draft-figure/references/mermaid.md +43 -34
  57. package/claude/skills/draft-identity/REQUIREMENT.md +1 -1
  58. package/claude/skills/draft-identity/SKILL.md +9 -7
  59. package/claude/skills/draft-ready/REQUIREMENT.md +1 -1
  60. package/claude/skills/draft-ready/SKILL.md +6 -6
  61. package/claude/skills/draft-ready/references/assembly.md +1 -1
  62. package/{standards → claude/skills/draft-ready/references}/ready.md +13 -5
  63. package/claude/skills/git-issue/references/issue.md +3 -3
  64. package/claude/skills/git-ship/REQUIREMENT.md +0 -2
  65. package/claude/skills/git-ship/SKILL.md +16 -24
  66. package/claude/skills/plan-feature/SKILL.md +2 -6
  67. package/{standards → claude/skills/plan-feature/references}/plan.md +9 -10
  68. package/claude/skills/plan-groundwork/SKILL.md +5 -6
  69. package/{standards → claude/skills/plan-groundwork/references}/groundwork.md +17 -4
  70. package/claude/skills/plan-intake/SKILL.md +2 -3
  71. package/{standards → claude/skills/plan-intake/references}/intake.md +17 -2
  72. package/claude/skills/plan-intake-answer/REQUIREMENT.md +1 -1
  73. package/claude/skills/plan-intake-answer/SKILL.md +1 -1
  74. package/claude/skills/review-address/SKILL.md +1 -1
  75. package/claude/skills/review-craft/REQUIREMENT.md +3 -3
  76. package/claude/skills/review-craft/SKILL.md +2 -2
  77. package/claude/skills/review-craft/references/ui.md +4 -4
  78. package/claude/skills/review-pr/REQUIREMENT.md +1 -1
  79. package/claude/skills/review-pr/SKILL.md +5 -7
  80. package/claude/skills/review-ui/REQUIREMENT.md +0 -1
  81. package/claude/skills/review-ui/SKILL.md +1 -1
  82. package/claude/skills/role-orchestrator/REQUIREMENT.md +0 -3
  83. package/claude/skills/role-orchestrator/SKILL.md +8 -8
  84. package/claude/skills/role-orchestrator/references/orchestrator-dispatch.md +3 -3
  85. package/claude/skills/role-orchestrator/references/orchestrator-handoff.md +7 -10
  86. package/claude/skills/role-orchestrator/references/orchestrator-parked.md +2 -2
  87. package/claude/skills/role-orchestrator/references/orchestrator-refill.md +0 -3
  88. package/claude/skills/role-orchestrator/references/orchestrator-resume.md +1 -1
  89. package/claude/skills/role-planner/SKILL.md +2 -2
  90. package/claude/skills/role-reviewer/SKILL.md +1 -1
  91. package/claude/skills/role-worker/SKILL.md +2 -2
  92. package/claude/skills/session-compact/REQUIREMENT.md +1 -4
  93. package/claude/skills/session-compact/SKILL.md +3 -13
  94. package/claude/skills/session-compact/references/handoff-note.md +2 -2
  95. package/claude/skills/session-map/REQUIREMENT.md +1 -9
  96. package/claude/skills/session-map/SKILL.md +8 -16
  97. package/{standards → claude/skills/session-map/references}/session.md +17 -11
  98. package/claude/skills/session-relay/REQUIREMENT.md +1 -1
  99. package/claude/skills/session-resume/REQUIREMENT.md +4 -6
  100. package/claude/skills/session-resume/SKILL.md +3 -9
  101. package/claude/skills/session-worktree/SKILL.md +1 -1
  102. package/claude/skills/session-worktree/references/main-root-writes.md +2 -2
  103. package/claude/skills/systematic-debugging/REQUIREMENT.md +0 -1
  104. package/claude/skills/target-check/REQUIREMENT.md +3 -3
  105. package/claude/skills/target-check/SKILL.md +1 -1
  106. package/claude/skills/target-check/references/domains.md +1 -1
  107. package/claude/skills/target-setup/REQUIREMENT.md +4 -4
  108. package/claude/skills/target-setup/SKILL.md +3 -3
  109. package/claude/skills/target-setup/references/detect.md +1 -1
  110. package/claude/skills/task-board/SKILL.md +4 -4
  111. package/claude/skills/task-board/references/archive.md +1 -1
  112. package/{standards → claude/skills/task-board/references}/board.md +9 -0
  113. package/claude/skills/task-board/references/decline.md +1 -1
  114. package/{standards → claude/skills/task-board/references}/tasks.md +13 -8
  115. package/claude/skills/teach-workspace/SKILL.md +1 -1
  116. package/claude/skills/teach-workspace/references/revisit.md +1 -1
  117. package/{standards → claude/skills/teach-workspace/references}/teach.md +17 -5
  118. package/claude/skills/ux-audit/REQUIREMENT.md +2 -2
  119. package/claude/skills/ux-audit/SKILL.md +2 -3
  120. package/claude/skills/write-human/REQUIREMENT.md +0 -1
  121. package/claude/skills/write-human/SKILL.md +1 -1
  122. package/docs/agents/audits.md +1 -1
  123. package/docs/agents/canvas.md +1 -1
  124. package/docs/agents/commands.md +1 -6
  125. package/docs/agents/context-audit-checks.md +9 -23
  126. package/docs/agents/context-audit.md +7 -15
  127. package/docs/agents/context-classify.md +5 -5
  128. package/docs/agents/counts.md +5 -5
  129. package/docs/agents/drift-surfaces.md +2 -2
  130. package/docs/agents/index.md +3 -5
  131. package/docs/agents/install-and-sync.md +6 -6
  132. package/docs/agents/intake.md +1 -1
  133. package/docs/agents/records-stale.md +5 -5
  134. package/docs/agents/records-validate.md +1 -1
  135. package/docs/agents/records.md +2 -2
  136. package/docs/agents/restated.md +1 -1
  137. package/docs/agents/rule-citations.md +1 -1
  138. package/docs/agents/skills-audit.md +2 -2
  139. package/docs/agents/state-scoped-risk.md +2 -2
  140. package/docs/agents/superseded.md +2 -2
  141. package/docs/agents/tasks-plans.md +1 -1
  142. package/docs/agents/tasks-validate.md +1 -1
  143. package/docs/agents/tasks.md +1 -1
  144. package/docs/agents/teach.md +1 -1
  145. package/docs/agents/upstream.md +26 -2
  146. package/docs/target/migrations.md +24 -0
  147. package/docs/target/projects.md +5 -7
  148. package/docs/target/scenarios.md +2 -2
  149. package/docs/target/sync.md +3 -3
  150. package/docs/workflow/ai-workflow.md +7 -38
  151. package/docs/workflow/index.md +1 -1
  152. package/docs/workflow/operating-model.md +8 -8
  153. package/docs/workflow/parallel-features.md +7 -7
  154. package/docs/workflow/skill-map-on-request.md +12 -15
  155. package/docs/workflow/skill-map.md +20 -32
  156. package/docs/workflow/visual-design-workflow.md +11 -14
  157. package/governance/renames.toml +0 -19
  158. package/governance/rules/canon/605-worktrees.md +1 -1
  159. package/governance/rules/{standards → canon}/plan.md +4 -5
  160. package/governance/rules/canon/tasks.md +18 -0
  161. package/governance/stacks/base.toml +1 -1
  162. package/package.json +1 -1
  163. package/scripts/core/install-check.sh +1 -1
  164. package/scripts/core/regen-web-previews.ts +1 -1
  165. package/src/audits/catalog.ts +5 -97
  166. package/src/claude/cases/authoring.ts +0 -18
  167. package/src/claude/cases/misc.ts +0 -13
  168. package/src/claude/cases/setup.ts +3 -20
  169. package/src/claude/cases/workflow.ts +0 -33
  170. package/src/claude/seeds.ts +1 -7
  171. package/src/claude/skills-audit.ts +1 -1
  172. package/src/cli/help.ts +1 -4
  173. package/src/cli.ts +0 -4
  174. package/src/commands/claude.ts +8 -14
  175. package/src/commands/context.ts +18 -280
  176. package/src/commands/feedback.ts +22 -91
  177. package/src/commands/records.ts +5 -5
  178. package/src/commands/sync.ts +5 -3
  179. package/src/commands/upstream.ts +135 -0
  180. package/src/context/audit.ts +5 -14
  181. package/src/context/classify/extract.ts +6 -13
  182. package/src/context/classify/patterns.ts +2 -41
  183. package/src/context/classify/prompts.ts +2 -6
  184. package/src/context/classify/run.ts +3 -3
  185. package/src/context/folders.ts +7 -12
  186. package/src/context/gate.ts +11 -91
  187. package/src/context/requirements.ts +13 -4
  188. package/src/counts/scan.ts +3 -3
  189. package/src/design/components.ts +2 -2
  190. package/src/feedback/body.ts +0 -12
  191. package/src/gate/measures.ts +6 -57
  192. package/src/gov/citations.ts +9 -3
  193. package/src/gov/restated.ts +3 -3
  194. package/src/markdown/structure.ts +2 -2
  195. package/src/migrate/record-layout.ts +3 -3
  196. package/src/records/ordinal.ts +1 -1
  197. package/src/records/prune.ts +2 -1
  198. package/src/records/stale-canonical.ts +2 -2
  199. package/src/roots/record.ts +1 -1
  200. package/src/sandbox/scenario.ts +115 -11
  201. package/src/shipped/references.ts +3 -3
  202. package/src/standards/read.ts +31 -0
  203. package/src/sync/seeds-report.ts +1 -1
  204. package/src/tasks/reach.ts +2 -2
  205. package/src/tasks/validate.ts +1 -1
  206. package/src/teach/workspace.ts +1 -1
  207. package/src/upstream/cursor.ts +1 -1
  208. package/src/upstream/due.ts +128 -0
  209. package/src/upstream/releases.ts +2 -1
  210. package/standards/context.md +3 -5
  211. package/standards/design.md +2 -3
  212. package/standards/index.md +0 -22
  213. package/standards/publish.md +1 -1
  214. package/standards/skill.md +1 -1
  215. package/tooling/base/reference.md +1 -1
  216. package/tooling/claude/reference.md +6 -20
  217. package/tooling/claude/seeds/.claude/hooks/records-index.sh +8 -20
  218. package/tooling/claude/seeds/.claude/hooks/standards-audit.sh +3 -3
  219. package/tooling/claude/seeds/CLAUDE.md +1 -3
  220. package/tooling/claude/seeds/canon/REQUIREMENTS.md +2 -9
  221. package/tooling/web/configs/e2e/screenshot.ts +0 -1
  222. package/claude/skills/auto-ship/references/review-findings.md +0 -20
  223. package/claude/skills/bash-cli-script/REQUIREMENT.md +0 -43
  224. package/claude/skills/bash-cli-script/SKILL.md +0 -53
  225. package/claude/skills/bash-cli-script/references/template.md +0 -19
  226. package/claude/skills/canon-operator/REQUIREMENT.md +0 -62
  227. package/claude/skills/canon-operator/SKILL.md +0 -113
  228. package/claude/skills/canon-rollout/REQUIREMENT.md +0 -59
  229. package/claude/skills/canon-rollout/SKILL.md +0 -140
  230. package/claude/skills/canon-rollout/references/failure-recovery.md +0 -20
  231. package/claude/skills/context-fold/references/anchor-sweep.md +0 -58
  232. package/claude/skills/context-fold/references/wireframe-sweep.md +0 -45
  233. package/claude/skills/create-standard/REQUIREMENT.md +0 -33
  234. package/claude/skills/create-standard/SKILL.md +0 -31
  235. package/claude/skills/design-extract/REQUIREMENT.md +0 -42
  236. package/claude/skills/design-extract/SKILL.md +0 -108
  237. package/claude/skills/draft-and-pick/references/frame.html +0 -118
  238. package/claude/skills/draft-doc/references/wireframes.md +0 -48
  239. package/claude/skills/markdown-propose/REQUIREMENT.md +0 -47
  240. package/claude/skills/markdown-propose/SKILL.md +0 -122
  241. package/claude/skills/markdown-propose/references/format.md +0 -118
  242. package/claude/skills/memory-capture/REQUIREMENT.md +0 -50
  243. package/claude/skills/memory-capture/SKILL.md +0 -117
  244. package/claude/skills/memory-review/REQUIREMENT.md +0 -52
  245. package/claude/skills/memory-review/SKILL.md +0 -129
  246. package/claude/skills/memory-review/references/later-phases.md +0 -118
  247. package/claude/skills/memory-review/references/receipt-format.md +0 -64
  248. package/claude/skills/project-commands/REQUIREMENT.md +0 -42
  249. package/claude/skills/project-commands/SKILL.md +0 -87
  250. package/claude/skills/repo-metadata/REQUIREMENT.md +0 -37
  251. package/claude/skills/repo-metadata/SKILL.md +0 -54
  252. package/claude/skills/restate-plainly/REQUIREMENT.md +0 -41
  253. package/claude/skills/restate-plainly/SKILL.md +0 -41
  254. package/claude/skills/review-branch/REQUIREMENT.md +0 -40
  255. package/claude/skills/review-branch/SKILL.md +0 -137
  256. package/claude/skills/seed-sync/REQUIREMENT.md +0 -45
  257. package/claude/skills/seed-sync/SKILL.md +0 -158
  258. package/claude/skills/sketch-design/REQUIREMENT.md +0 -38
  259. package/claude/skills/sketch-design/SKILL.md +0 -94
  260. package/claude/skills/ux-walkthrough/REQUIREMENT.md +0 -56
  261. package/claude/skills/ux-walkthrough/SKILL.md +0 -53
  262. package/claude/skills/ux-walkthrough/references/builds.md +0 -15
  263. package/claude/skills/ux-walkthrough/references/candidate-pages.md +0 -11
  264. package/claude/skills/ux-walkthrough/references/measuring.md +0 -22
  265. package/claude/skills/ux-walkthrough/references/record.md +0 -36
  266. package/claude/skills/ux-walkthrough/references/relay.md +0 -25
  267. package/docs/agents/architecture-record.md +0 -36
  268. package/docs/agents/review-classification.md +0 -76
  269. package/governance/rules/canon/603-memory.md +0 -11
  270. package/governance/rules/lang/120-bash.md +0 -18
  271. package/governance/rules/standards/architecture.md +0 -13
  272. package/governance/rules/standards/groundwork.md +0 -13
  273. package/governance/rules/standards/intake.md +0 -12
  274. package/governance/rules/standards/memory.md +0 -12
  275. package/governance/rules/standards/ready.md +0 -13
  276. package/governance/rules/standards/requirements.md +0 -12
  277. package/governance/rules/standards/session.md +0 -13
  278. package/governance/rules/standards/tasks.md +0 -15
  279. package/governance/rules/standards/teach.md +0 -14
  280. package/governance/rules/standards/wiki.md +0 -13
  281. package/governance/rules/standards/wireframes.md +0 -13
  282. package/src/autoship/classify.ts +0 -75
  283. package/src/autoship/paths.ts +0 -50
  284. package/src/commands/autoship.ts +0 -129
  285. package/src/commands/repo.ts +0 -393
  286. package/src/context/architecture.ts +0 -654
  287. package/src/context/wireframe-states.ts +0 -238
  288. package/src/repo/metadata.ts +0 -206
  289. package/standards/architecture.md +0 -127
  290. package/standards/memory.md +0 -158
  291. package/standards/mermaid.md +0 -64
  292. package/standards/requirements.md +0 -79
  293. package/standards/wiki.md +0 -77
  294. package/standards/wireframes.md +0 -143
  295. package/tooling/claude/seeds/.claude/memory/index.md +0 -8
  296. package/tooling/claude/seeds/canon/ARCHITECTURE.md +0 -23
  297. package/tooling/claude/seeds/canon/wireframes/index.md +0 -8
  298. /package/{standards → claude/skills/create-skill/references}/skill-practice.md +0 -0
  299. /package/{standards → claude/skills/create-skill/references}/skill-requirement.md +0 -0
  300. /package/{standards → claude/skills/plan-feature/references}/plan-lifecycle.md +0 -0
  301. /package/{standards → claude/skills/plan-groundwork/references}/groundwork-spikes.md +0 -0
  302. /package/{standards → claude/skills/task-board/references}/tasks-decline.md +0 -0
  303. /package/{standards → claude/skills/teach-workspace/references}/glossary.md +0 -0
@@ -1,42 +0,0 @@
1
- ---
2
- name: design-extract
3
- description: Why a design system is drafted from what the tree already holds, and how a proposed value is kept distinguishable from a sourced one
4
- ---
5
-
6
- # Design extract requirement
7
-
8
- ## Gap
9
-
10
- Without this skill, a session asked for a design system either invents token values with nothing behind them or refuses because the project ships no stylesheet. It writes over a `canon/DESIGN.md` someone already filled. It fills every cell so the file looks complete, which leaves a reader unable to tell a hex sampled from the CLI apart from one the session made up, and a proposal nobody flagged gets built on. A trailing tag column added to mark that uncertainty breaks the render parser instead.
11
-
12
- The greenfield case is the one that fails quietly. A project with no UI code still has a personality paragraph and a stated platform, so values can be proposed against a signal rather than pulled from a default palette. A session that does not know this reports there is nothing to extract.
13
-
14
- ## Must
15
-
16
- - Pick the source or greenfield path from what the project tree holds, never from a flag or an argument
17
- - Announce which path ran, since the two produce different-looking output from one skill
18
- - Fetch the seed template and keep every heading and table header intact, because the render parser reads them
19
- - Mark any cell not traced to a source value inline inside the cell value, and take the uncertainty into the sentence when the section is prose
20
- - Anchor every greenfield proposal to a personality or requirements signal rather than to a default
21
- - Render the preview and report its path, so the proposals get looked at before they are committed
22
-
23
- ## Must not
24
-
25
- - Overwrite a `canon/DESIGN.md` that already carries content beyond the seed
26
- - Guess a value on the source path when no signal exists. Leave the cell blank instead.
27
- - Invent a non-goal. A proposed motion line is correct when nothing rules motion out.
28
- - Put the verify tag in a trailing column, which breaks the row
29
- - Rewrite the transcribed personality paragraph, which is the one section that is not a proposal
30
-
31
- ## Guards
32
-
33
- - `canon/DESIGN.md` already populated: stop rather than mutating it
34
- - `canon` not on PATH: stop, since the seed template and the render both need it
35
- - Greenfield path with no `canon/REQUIREMENTS.md` or no `## Personality` section: stop, because there is nothing to propose against. Evaluate this only after Step 1 picks the path.
36
-
37
- ## Out of scope
38
-
39
- - Mutating an existing design system, which is a direct edit of the file rather than a skill
40
- - Producing the HTML and CSS preview, which `canon design render` owns
41
- - Auditing the implemented UI against the tokens, which `ux-audit` owns
42
- - Architecture and flow diagrams, which `draft-figure` owns
@@ -1,108 +0,0 @@
1
- ---
2
- name: design-extract
3
- description: Drafts `canon/DESIGN.md` from a project's existing prose and shell UI surfaces, or proposes token values from `REQUIREMENTS.md` and a `## Personality` section when no UI code exists yet. Use when asked to "extract the design system", "draft DESIGN.md", "bootstrap design tokens", "capture the visual system", "propose a design system", "bootstrap DESIGN.md from scratch", "draft tokens for a greenfield project", or "replace Claude Design onboarding". Do NOT use to mutate an existing `canon/DESIGN.md`.
4
- metadata:
5
- family: setup
6
- ---
7
-
8
- # Design extract
9
-
10
- ## Guards
11
-
12
- - If `canon/DESIGN.md` already exists and has content beyond the seed template, stop: `❌ canon/DESIGN.md already populated. Edit directly or archive the existing file first.`
13
- - If `canon` is not on PATH, stop: `❌ canon CLI not found.`
14
-
15
- Step 1 carries two more stops that apply to one path only. Do not evaluate them before the path is picked.
16
-
17
- ## Step 1: pick the path from what the project already has
18
-
19
- Check the project root for UI surfaces: `src/ui.ts`, `src/ui.tsx`, `src/components/**`, `scripts/lib/ui.sh`, and any `*.css`, `tailwind.config.*`, or `theme.*`.
20
-
21
- - Any match takes the source path. Existing code defines the system, so every filled cell traces to a value already in the tree.
22
- - No match takes the greenfield path. Nothing anchors a value there unless a picked reference does, so name `sketch-design` as the first move: a picked reference anchors a cell where a paragraph alone cannot. A direct run of this skill still falls through to the proposal-from-personality rules in Step 4, tag included, so this skill stays runnable on its own with nothing rendered yet.
23
-
24
- The project decides this, never a user flag or an argument. Announce which path ran in one line before Step 2, since the two produce different-looking output from the same skill.
25
-
26
- The greenfield path needs a personality paragraph to propose against, and stops without one. The source path needs neither file and skips both stops.
27
-
28
- - If `canon/REQUIREMENTS.md` is missing, stop: `❌ canon/REQUIREMENTS.md not found. Write requirements before proposing a design system.`
29
- - If `canon/REQUIREMENTS.md` has no `## Personality` section, stop: `❌ canon/REQUIREMENTS.md missing ## Personality section. Add a paragraph describing voice and tone before running this skill.`
30
-
31
- ## Step 2: read source signals in parallel
32
-
33
- Read these on both paths, skipping any that do not exist:
34
-
35
- - `CLAUDE.md`: voice and personality
36
- - `canon/REQUIREMENTS.md`: the `## Personality` paragraph, worldview, non-goals
37
- - `${CLAUDE_SKILL_DIR}/../markdown-craft/references/markdown.md`: word, punctuation, and formatting constraints
38
- - The `write-human` skill: tone and sentence construction constraints
39
-
40
- On the source path, also read the UI surfaces matched in Step 1 plus `canon docs output-shape` and `canon docs index`, for output shape or framing rules already documented in the toolkit's own reference. Skip either that fails to resolve, since a project keeping its framing rules elsewhere is read there instead.
41
-
42
- On the greenfield path, also read `canon/ARCHITECTURE.md` for platform, tech stack, and surface type. Do not scan `src/`, stylesheets, or UI modules. Step 1 already established they hold nothing.
43
-
44
- On the greenfield path, also check `.canon/picks/*/design-handoff.md` for a file the `sketch-design` skill wrote, taking the most recently modified match when more than one exists. Read it when found. Its presence is what Step 4 traces cells from instead of proposing them.
45
-
46
- Run these reads in parallel. Do not speculatively recurse into every directory.
47
-
48
- ## Step 3: fetch the seed template
49
-
50
- Run this from the project root:
51
-
52
- ```bash
53
- canon claude seeds list --json | jq -r '.[] | select(.path == "canon/DESIGN.md") | .content'
54
- ```
55
-
56
- Use the returned content as the target shape. Keep every section heading and every table header intact. The `canon design render` parser depends on them.
57
-
58
- ## Step 4: fill the template
59
-
60
- Walk each section once. Follow `${CLAUDE_SKILL_DIR}/../markdown-craft/references/markdown.md` for punctuation throughout: no em dashes, no semicolons. Use commas or separate sentences instead. Load the `write-human` skill for word choice, which keeps marketing words out.
61
-
62
- Mark any cell not traced to a source value by appending ` ? verify` inside the cell value, never as a trailing column. The cell stays inside the table shape: `| #ffffff ? verify |`. A trailing `| ? verify` after the row breaks the parser. A prose section takes its uncertainty inline instead, for example `Proposed 150ms ease-out, not yet confirmed.`, because a trailing tag on a sentence renders raw in the preview.
63
-
64
- On the source path, the tag marks the exception. On the greenfield path it marks nearly every cell, since the values are speculative until code or a designer anchors them.
65
-
66
- ### Source path
67
-
68
- - **Personality**: one paragraph. Transcribe what `CLAUDE.md` and `canon/REQUIREMENTS.md` say about voice, tone, and visual feeling. Do not invent rules the source does not state. If nothing matches, write a one-sentence placeholder ending in `? verify`.
69
- - **Color**: one row per role. Source hex values from the CLI UI files or stylesheets. If a role has no source signal, leave `Value` blank rather than guessing.
70
- - **Typography**: one row per role. Source families and sizes from stylesheet or theme config. Leave cells blank when no signal exists.
71
- - **Spacing**: fill the base unit and multipliers from stylesheet tokens or obvious repeated values in the UI code.
72
- - **Borders**: one row per role. Source from stylesheet or CSS variables.
73
- - **Motion** and **Iconography**: one line each. Default to `No animation.` and `No custom icons.` when no evidence exists.
74
-
75
- ### Greenfield path
76
-
77
- Anchor every proposal to a signal, never to a default. "Calm and dense" pins muted grays and tight spacing. A requirements non-goal of "no motion" makes Motion read `No animation.` with no tag. A CLI-only surface leans Typography monospaced and keeps Borders minimal.
78
-
79
- - **Traced cells**: when Step 2 matched a `design-handoff.md` file, fill only the fields it actually states, no tag, the same traced-versus-proposed distinction the source path draws for a stylesheet value.
80
- - The handoff carries hex and family and size, never Weight, Line height, or a color's Intent. Those cells, every field of a role the handoff never names, and Motion and Iconography regardless, still follow the proposal rules below, tag included.
81
- - **Personality**: transcribe the `## Personality` paragraph from `canon/REQUIREMENTS.md` verbatim. This is the one section that is not a proposal. No tag.
82
- - **Color**: one row per role. Rewrite the Intent cell in personality language, for example `near-white page canvas` instead of the seed default `page canvas`. Propose hex values matching the personality. Dense and calm gives low saturation and high text contrast. Playful gives saturated accents. Every Intent and Value cell gets `? verify`.
83
- - **Typography**: one row per role. Propose families fitting the platform, system UI for web, monospaced for CLI tools, serif for editorial, and a harmonious scale. Every cell gets `? verify`.
84
- - **Spacing**: propose a base unit matching density intent. Dense gives a 4px base, roomy gives 8px. Keep the Multiplier column as the seed ships it, no tag. Only the Value column gets `? verify`.
85
- - **Borders**: propose radius and width per role. Sharp and technical gives a small radius, soft gives a larger one. Every Radius and Width cell gets `? verify`.
86
- - **Motion**: one line. Write `No animation.` when the requirements forbid motion. Otherwise phrase the uncertainty inline.
87
- - **Iconography**: one line. Propose style and source library matching personality, phrasing the uncertainty inline.
88
-
89
- Do not invent non-goals. A proposed motion line is fine when neither the personality paragraph nor the requirements rule motion out.
90
-
91
- ## Step 5: write and render
92
-
93
- Write the filled template to `canon/DESIGN.md` from the project root. Then run:
94
-
95
- ```bash
96
- canon design render
97
- ```
98
-
99
- The command writes an HTML plus CSS preview to `.canon/tmp/render/design/`. Output the path in chat so the user can open it.
100
-
101
- ## Response format
102
-
103
- ```plaintext
104
- 📝 Wrote canon/DESIGN.md
105
- 📝 Wrote .canon/tmp/render/design/index.html
106
-
107
- Ran the <source|greenfield> path. N cells marked `? verify`. Open the preview and confirm before committing.
108
- ```
@@ -1,118 +0,0 @@
1
- <!doctype html>
2
- <html lang="en" data-theme="light">
3
- <head>
4
- <meta charset="utf-8" />
5
- <title>Draft and pick frame</title>
6
- <style>
7
- :root {
8
- --bg: #f4f4f5;
9
- --fg: #18181b;
10
- --bar: #ffffff;
11
- --line: #d4d4d8;
12
- }
13
- :root[data-theme='dark'] {
14
- --bg: #18181b;
15
- --fg: #f4f4f5;
16
- --bar: #27272a;
17
- --line: #3f3f46;
18
- }
19
- * {
20
- box-sizing: border-box;
21
- }
22
- body {
23
- margin: 0;
24
- height: 100vh;
25
- display: flex;
26
- flex-direction: column;
27
- background: var(--bg);
28
- color: var(--fg);
29
- font-family: system-ui, sans-serif;
30
- font-size: 14px;
31
- }
32
- header {
33
- display: flex;
34
- gap: 12px;
35
- align-items: center;
36
- padding: 8px 12px;
37
- background: var(--bar);
38
- border-bottom: 1px solid var(--line);
39
- }
40
- select,
41
- button {
42
- font: inherit;
43
- color: inherit;
44
- background: var(--bg);
45
- border: 1px solid var(--line);
46
- border-radius: 4px;
47
- padding: 4px 8px;
48
- }
49
- main {
50
- flex: 1;
51
- overflow: auto;
52
- display: flex;
53
- justify-content: center;
54
- padding: 12px;
55
- }
56
- iframe {
57
- width: 100%;
58
- height: 100%;
59
- border: 1px solid var(--line);
60
- background: #fff;
61
- }
62
- </style>
63
- </head>
64
- <body>
65
- <header>
66
- <label
67
- >Page
68
- <select id="picker"></select
69
- ></label>
70
- <button id="theme" type="button">Theme: light</button>
71
- <span>F12 device toolbar to resize</span>
72
- </header>
73
- <main><iframe id="page" title="Candidate page"></iframe></main>
74
- <!-- The skill replaces the token below with one JSON object: {"themeKey": "<key the arms read>", "rounds": [{"label": "...", "pages": [{"label": "...", "src": "<path relative to this file>"}]}]} -->
75
- <script type="application/json" id="frame-data">
76
- __FRAME_DATA__
77
- </script>
78
- <script>
79
- const data = JSON.parse(document.getElementById('frame-data').textContent)
80
- const picker = document.getElementById('picker')
81
- const themeButton = document.getElementById('theme')
82
- const frame = document.getElementById('page')
83
- let theme = 'light'
84
-
85
- for (const round of data.rounds) {
86
- for (const page of round.pages) {
87
- const option = document.createElement('option')
88
- option.value = page.src
89
- option.textContent = round.label + ' · ' + page.label
90
- picker.append(option)
91
- }
92
- }
93
-
94
- // A page that stores its own theme and reads it back on load overwrites the
95
- // attribute alone, so write the stored key as well as the attribute.
96
- function applyTheme() {
97
- document.documentElement.dataset.theme = theme
98
- themeButton.textContent = 'Theme: ' + theme
99
- try {
100
- const win = frame.contentWindow
101
- win.document.documentElement.setAttribute('data-theme', theme)
102
- win.localStorage.setItem(data.themeKey, theme)
103
- } catch {}
104
- }
105
-
106
- picker.addEventListener('change', () => {
107
- frame.src = picker.value
108
- })
109
- themeButton.addEventListener('click', () => {
110
- theme = theme === 'light' ? 'dark' : 'light'
111
- applyTheme()
112
- })
113
- frame.addEventListener('load', applyTheme)
114
-
115
- if (picker.options.length > 0) frame.src = picker.value
116
- </script>
117
- </body>
118
- </html>
@@ -1,48 +0,0 @@
1
- ---
2
- title: Wireframes kind
3
- description: The root check, tree-walk guard, tier detection, transcription and role-intent modes, and regen folder for a brand-new wireframe surface, read by draft-doc once the request resolves to the wireframes kind
4
- ---
5
-
6
- # Wireframes kind
7
-
8
- `draft-doc` reads this file when the request resolves to a surface under `canon/wireframes/`. An existing surface is edited directly, since no skill owns a full rewrite of one.
9
-
10
- This kind stays independent of `context-fold`'s wireframe coverage sweep, which writes only a bare `TODO` stub for a surface a diff touched and reports drift against one a wireframe already covers. Neither the stub nor the drift check is a draft, and this kind never reads or writes through that mechanism.
11
-
12
- ## Root
13
-
14
- A project the surface move has not reached keeps its wireframes folder under `.claude/` rather than `canon/`. Walk and write at whichever root already carries the folder, and create it under `canon/` only when neither does, since a new `canon/` folder would hide every surface the old one holds. `<wireframes-root>` below names the root this check settled.
15
-
16
- ## Guards
17
-
18
- - Derive a kebab-case slug from the surface. Walk the whole `<wireframes-root>` tree, including a surface nested inside a grouped subfolder, rather than checking the top level alone. A match at any depth means the surface already has a file. Stop: `❌ <path> already covers this surface. Edit it directly; this skill only drafts a surface with no file yet.`
19
-
20
- ## Placement
21
-
22
- - Check every title and description in `<wireframes-root>/index.md` against the surface, and stop the same way on a match.
23
- - Place the file at `<wireframes-root>/<slug>.md`, or inside a grouped subfolder only when the surface belongs beside siblings that already share one.
24
-
25
- ## Tier detection
26
-
27
- - Read `canon/DESIGN.md` and every existing wireframe file for a tier signal: an Excalidraw or Figma reference, or a marker naming one of them.
28
- - Always draft the regions-and-states shape regardless of what is detected, since that is the only shape any shipped mechanism produces. Report a higher tier rather than attempting a companion render for it.
29
- - Default silently to tier 0 when nothing is detected.
30
-
31
- ## Draft
32
-
33
- - Decide the mode before drafting. When the surface names an already-built component or file, open that source and draft in transcription mode, citing the render function, the stylesheet rule, or the built file each region and label traces to, per the standard's Transcription-wireframes section.
34
- - Draft in role-intent mode otherwise: label each region by its role, never by a class name or a token value.
35
- - Draft `title` and `description` frontmatter, then a lead paragraph naming what the surface is for and what it covers, then `## Regions` as a bullet list naming every region and where it sits relative to the others.
36
- - Draw an ASCII `plaintext` fence with `←` role annotations only when the layout is not built yet. Skip the fence in transcription mode, which already cites the built source instead.
37
- - Draft `## States` as a table listing every state a visitor can reach, what reaches it, what it shows in words, and its evidence folder, reading `not captured` in the evidence cell until a capture lands.
38
- - Follow with `## Copy`, `## Behavior`, and `## Not on this surface`, against the standard's template.
39
- - Give a layout that changes across a breakpoint or state its own entry in the regions list, named by what triggers it, never for a spacing difference alone.
40
- - Leave out algorithms, event-handler code, framework prop or class names outside transcription mode, and anything else the standard sends to a context entry instead.
41
-
42
- ## Preview
43
-
44
- Add `**Detected tier:** <tier-0 | tier-1 | tier-2 | none detected>` and the mode, and confirm both with the path, since each is a judgment call.
45
-
46
- ## Write
47
-
48
- Run `canon markdown audit` against the prose outside the fenced block. Regenerate `<wireframes-root>`, so the surface appears in its `index.md` at once.
@@ -1,47 +0,0 @@
1
- ---
2
- name: markdown-propose
3
- description: Why a markdown rewrite is proposed per file and answered before anything applies, rather than edited live or argued in chat
4
- ---
5
-
6
- # Markdown propose requirement
7
-
8
- ## Gap
9
-
10
- Rewriting a passage in a governing document today means editing it live or arguing in chat, and two surfaces sit near this moment without covering it. `canon markdown audit` measures bans and structural checkpoints from package data.
11
-
12
- `review-branch` reports findings on a diff someone already wrote. Neither drafts a replacement, carries an answer slot, or waits.
13
-
14
- A review delivered in chat gets applied from memory across files nobody reopened, and nothing records which changes the operator approved. A change nobody agreed to either lands unreviewed, because the session acting on a chat review cannot tell an approved line from an inferred one, or never gets written down at all, because a finding with no draft behind it hands the rewrite back to whoever reads it next.
15
-
16
- A second failure compounds the first. A claim copied across several files is corrected in the one a session happened to open, and the copies elsewhere now read as freshly reviewed while still disagreeing, since nothing reconciles a restatement against the source it was drawn from.
17
-
18
- ## Must
19
-
20
- - Take the concern and the surface as inputs and run one procedure against them, so a second concern reuses this skill rather than forking it
21
- - Grep the named surface for the concern before proposing, so a defect's site count is measured rather than assumed
22
- - Draft the replacement text, not only the finding
23
- - Carry three labelled variants on a change whose replacement was invented, and one on a change that corrects text to a recorded fact
24
- - Write one proposal file per source file under `.canon/proposals/<nn>-<slug>/` and stop, leaving `You:` empty on every change
25
- - Apply only a change carrying an answer, one file at a time, and re-grep its anchor before applying it
26
- - Report what each file leaves alone, so a proposal cannot be read as finding everything wanting
27
-
28
- ## Must not
29
-
30
- - Edit a source file during the Propose phase
31
- - Apply an unanswered change, or a subset of a file's answered changes while leaving the rest for later
32
- - Fill a `You:` slot, or infer a disposition from an empty one
33
- - Name a specific concern in this skill's own procedure. A concern belongs in the invocation, and hardcoding one narrows the skill to the day it was written.
34
- - Assume the skill earns its place because the gap is real. Whether anything invokes it beyond the operator typing its name has no answer at creation time, and is a review criterion to read against a later usage census rather than a gate this file can pass on its own.
35
-
36
- ## Guards
37
-
38
- - No concern named and none derivable: stop rather than inferring one
39
- - No surface named and none derivable: stop rather than screening the whole tree
40
- - The concern resolves to one file: stop and say a single-file change needs no proposal folder
41
-
42
- ## Out of scope
43
-
44
- - Reporting a violation with no drafted replacement, which `canon markdown audit` already owns
45
- - Reviewing a diff someone already wrote, which `review-branch` owns
46
- - Filing a raw brain dump as findings, which `plan-intake` owns
47
- - Reviewing `.canon/memory/` and proposing promote-or-retire actions per entry, which `memory-review` owns on a different subject with a different answer contract
@@ -1,122 +0,0 @@
1
- ---
2
- name: markdown-propose
3
- description: Reviews a named markdown surface against a named concern, drafts a per-file proposal under `.canon/proposals/<nn>-<slug>/` carrying a diff and a reason for each change, and stops without editing a source file. Takes the concern and the surface as inputs, such as a claim stated stronger than the record, a fact gone stale, two files disagreeing, or a passage duplicated without derivation. A later invocation applies what the operator answered. Use when asked to "propose a change to CLAUDE.md", "draft a rewrite of this standard", "propose fixes to this doc", "draft alternatives for this passage", or "apply the answered proposals". Do NOT use to report without drafting a replacement (`canon markdown audit`), to review a diff already made (`review-branch`), or to file a raw brain dump as findings (`plan-intake`).
4
- metadata:
5
- family: check
6
- ---
7
-
8
- # Markdown propose
9
-
10
- Reviews what a markdown surface says against a named concern and proposes what it should say instead. Writes proposals and stops. The operator answers per change, and a later invocation applies the answered set.
11
-
12
- The value is the gate. A rewrite delivered in chat gets applied from memory across files nobody reopened, and nothing records what was approved.
13
-
14
- ## Guards
15
-
16
- - No concern named and none derivable from the conversation. Stop: `❌ No concern to screen for. Name what looks wrong, or the surface to review.`
17
- - No surface named and none derivable. Stop: `❌ No surface to review. Name the files, or the folder, to screen.`
18
- - The concern resolves to one file only. Stop and say so: a single-file change needs no proposal folder.
19
- - A named file cannot be read. Stop and name it. Do not screen what resolved and report a partial result.
20
-
21
- ## Phase detection
22
-
23
- Two phases share this body, picked by whether a proposal folder already exists for the request's slug.
24
-
25
- Derive `<slug>` from the concern and the surface, kebab-case, naming the subject rather than the activity. List `.canon/proposals/` at the main worktree root and match the topic against the slug half of each `<nn>-<slug>` folder already there before deriving a fresh one, the same way `plan-intake` matches its own folder. Never match against `.claude/` itself.
26
-
27
- With no match, a fresh folder takes the next ordinal in `.canon/proposals/`'s own sequence: list the folders present, take the highest `<nn>`, and increment it, starting at `01` when none exist. That sequence is independent of the one `intake` and `groundwork` share, so a proposals folder never reads or claims from theirs.
28
-
29
- - No matching folder, or the operator names a concern and a surface: **Propose**.
30
- - A matching folder exists and the operator says apply, ship, or commit the answers: **Apply**.
31
-
32
- All `.canon/proposals/` reads and writes resolve at the main worktree root, not the current worktree. Resolve that root the way `session-worktree` does.
33
-
34
- ## Write scope
35
-
36
- Write only inside `.canon/proposals/<nn>-<slug>/`. A source file, a standard, a rule, and a plan all live outside that folder, so this one rule forbids every one of them during the Propose phase. The Apply phase is the one exception, and only for a change carrying a `You:` answer.
37
-
38
- ## Concerns
39
-
40
- The concern is an input, not a flow toggle. The passes below are one procedure and the concern decides what pass 1 looks for.
41
-
42
- | Concern | What it looks like |
43
- | ------------- | -------------------------------------------------------------------- |
44
- | Inflation | a claim stated stronger than the record supports |
45
- | Staleness | a fact correct when written and wrong now, usually a date or a count |
46
- | Contradiction | two files, or two sections, asserting incompatible things |
47
- | Duplication | one passage copied across files with no derivation, drifting apart |
48
-
49
- The operator may name a concern outside this table. Run the same procedure against it.
50
-
51
- ## Propose phase
52
-
53
- Read `${CLAUDE_SKILL_DIR}/references/format.md` before writing anything. Do not work the proposal format from memory.
54
-
55
- ### 1. Find the sites
56
-
57
- Grep the named surface for the concern and its near-variants. A defect rarely repeats verbatim, so search the habit rather than the string.
58
-
59
- Count hits per file before reading them. A file with one hit and a file with eight are different problems.
60
-
61
- ### 2. Find what it should say
62
-
63
- Read whatever the operator names as the authoritative source for the concern. Absent one, grep the rest of the tree for a passage already stating the corrected form, since a correct version often already exists somewhere the defect has not reached.
64
-
65
- Report a file that contradicts itself. A file holding both the defect and its corrected form is the strongest finding available, because the replacement is already drafted somewhere in the tree and needs no invention.
66
-
67
- ### 3. Judge per line, not per match
68
-
69
- A matched string means different things in different registers. A word describing a mechanism is a fact about how something works. The same word describing reach is a claim about who relies on it. Sweeping both because they share a string is what makes the next pass harder to trust.
70
-
71
- ### 4. Write the proposals
72
-
73
- One file per source file under `.canon/proposals/<nn>-<slug>/`, per `${CLAUDE_SKILL_DIR}/references/format.md`.
74
-
75
- Draft the replacement text. A proposal reporting a problem without a replacement hands the work back rather than doing it.
76
-
77
- Carry an `Open:` on any change whose replacement was written rather than corrected, and give it three variants per the format reference. Correcting an overstatement to the recorded fact has one answer. Inventing a paragraph has no right answer, and one draft asks the operator to veto instead of to choose, which costs a round every time the intent lands wrong.
78
-
79
- Separate the two kinds before drafting. A change that deletes a claim the record does not support is cheap and rarely argued. A change that writes new prose is where the effort belongs.
80
-
81
- Close each file with what it leaves alone, and say why those lines survived.
82
-
83
- ### 5. Report
84
-
85
- Name the count, the files, and the single highest-value change. Point at the folder and stop.
86
-
87
- Do not edit a source file. Do not fill a `You:` slot.
88
-
89
- Propose in dependency order and state it in `00-overview.md` when the surface spans more than two files. A file other files quote is settled first, otherwise the same wording gets decided twice.
90
-
91
- ## Apply phase
92
-
93
- Read `${CLAUDE_SKILL_DIR}/references/format.md` before applying anything, if this session has not already read it this pass.
94
-
95
- Follow the Applying section there: one file at a time in settle order, every answered change in that file and nothing unanswered, re-grepping each anchor before applying it, sweeping the other named surfaces for the same claim before committing, and moving an applied change into `applied.md`.
96
-
97
- Report the counts once the pass stops: files committed, changes applied, changes still carrying an empty `You:`. Leave the folder in place. Neither phase deletes it.
98
-
99
- ## Output
100
-
101
- Chat output is the report. This skill persists only the proposal folder itself.
102
-
103
- ```plaintext
104
- 📂 Opened .canon/proposals/<nn>-<slug>/
105
-
106
- **Screened:** <N> files, <N> changes proposed, <N> carrying three variants
107
-
108
- **Highest value:** <the single strongest change, one line>
109
-
110
- Next: answer the `You:` slots in the files under .canon/proposals/<nn>-<slug>/,
111
- then re-invoke this skill to apply what you answered.
112
- ```
113
-
114
- Use `📂 Resumed` in place of `📂 Opened` on a resume pass. The Apply phase reports instead:
115
-
116
- ```plaintext
117
- ✅ Applied .canon/proposals/<nn>-<slug>/
118
-
119
- **Committed:** <N> files, <N> changes
120
-
121
- **Still open:** <N> changes with an empty `You:`
122
- ```
@@ -1,118 +0,0 @@
1
- # Proposal format reference
2
-
3
- Governs the proposal `markdown-propose` writes before it edits anything. The concern being screened is an input and does not change the format.
4
-
5
- ## Contents
6
-
7
- - [Folder](#folder)
8
- - [Change format](#change-format)
9
- - [The answer contract](#the-answer-contract)
10
- - [Applying](#applying)
11
- - [After](#after)
12
- - [Retrieval](#retrieval)
13
-
14
- ## Folder
15
-
16
- - One folder per screening pass at `.canon/proposals/<nn>-<slug>/`, where the slug names the subject rather than the activity
17
- - One proposal file per source file, named `<nn>-<source filename, its own extension dropped>.md`, so a source already named `CLAUDE.md` becomes `01-CLAUDE.md` rather than `01-CLAUDE.md.md`
18
- - `00-overview.md` when the pass spans more than two source files, holding the cross-file pattern, the change counts, and the settle order
19
- - `applied.md` once the first change lands, holding every applied change with its reason and the answer it carried
20
-
21
- The folder's own `<nn>` and a proposal file's own `<nn>` are two independent counters. The folder's ordinal records when the pass was opened, counted within `.canon/proposals/` alone rather than shared with `plan-groundwork` or `plan-intake`'s sequence, and a proposal file's ordinal inside it records settle order, the dependency order changes apply in. Reading one as the other gets a pass dated wrong or an apply ordered wrong.
22
-
23
- The name carries both structures the folder has. The basename pairs a proposal to its source so a reader opens the two side by side, and the number is the settle order, which is a dependency rather than a preference: a file other files quote is settled first. Do not group proposals by theme.
24
-
25
- A proposal opened after the initial pass takes the next free number, and the folder is never renumbered. Its number records when the site was found rather than where it belongs in the dependency order. Renumbering to restore the order would rewrite the names of files already carrying answers, which costs more than the ordering is worth once applying has started.
26
-
27
- Settle a late proposal ahead of any unapplied proposal quoting the surface it covers, whatever the two numbers say. A proposal already applied is past the question, since the file it governs is committed.
28
-
29
- ## Change format
30
-
31
- Each proposal file opens with `# Proposal: <source path>`, one line naming the concern, the settle order, and the full surface the pass screened, then one `###` heading per change, ending with a `## Left alone` section. A change never sits at `##`, which the closing section reserves, and a variant never sits at `###`, which the change heading reserves. Skipping from `#` straight to `###` is deliberate: the file has exactly one layer of change between its title and its variants.
32
-
33
- Naming the surface on every file, not only the first, is what lets Applying's cross-surface grep run cold. The Propose and Apply invocations are typically separate sessions days apart, so the surface the operator named has to survive on the file rather than in a conversation neither session shares.
34
-
35
- A change carries an `###` heading, a fenced `diff` block holding the current text against the proposed, the reason beneath it, and its own answer slot.
36
-
37
- - Heading: `### N. The sentence or section it sits in`
38
- - Body: a `diff` fence, `-` for current and `+` for proposed
39
- - `- **Why:** the reason, naming what the change fixes`
40
- - `- **Open:** only where the replacement was drafted rather than corrected`
41
- - `- **Recommended:** only where a pick is proposed ahead of the answer, directly above the slot`
42
- - `- **You:**` last on every change, shipped empty
43
-
44
- ### Variants
45
-
46
- A corrected change carries one replacement. A drafted one carries three, because the intent behind invented prose is not recoverable from the source text and a single draft turns the answer slot into a veto.
47
-
48
- - Ship three variants on any change carrying `Open:`, labelled `#### A`, `#### B`, `#### C`
49
- - Make them differ in approach rather than in wording. Three phrasings of one bet are one variant.
50
- - State the bet each one makes in a line above its block, so the choice is between strategies and not between paragraphs
51
- - Ship one replacement everywhere else. A word swapped for the recorded fact has no second option worth reading.
52
-
53
- Three is the cap as well as the count. A fourth splits attention without widening the space.
54
-
55
- ### Placement
56
-
57
- - Title a change by the section or sentence it sits in, never by its position in the file
58
- - Quote text from another file in a `markdown` block rather than citing a line number, which goes stale on the first applied change
59
- - Split a `Why:` into labelled halves when one change fixes two things (`**Why, the date:**`)
60
- - Carry an `Open:` on any change whose replacement text was written rather than corrected, so a blanket answer cannot swallow it
61
-
62
- Close each file with what it leaves alone. A pass reporting only what it would change reads as one that found everything wanting.
63
-
64
- ## The answer contract
65
-
66
- `You:` belongs to the operator and ships empty on every change. Empty means unread and never agreement, matching the intake contract in `${CLAUDE_SKILL_DIR}/../../standards/intake.md` rather than the plan file's, which reads a blank slot as accepting the suggestion above it. State the inversion at the top of `00-overview.md` when the folder spans more than one file, since a contract read from the wrong surface gets applied to the wrong document.
67
-
68
- - One `You:` per change, last in its bullet list, so an answer lands where the change is read
69
- - Never fill a `You:` slot and never infer a disposition from an empty one
70
- - The slot takes free text, not only `ok`. A rejection, a caveat, or a rewrite of the proposed line are all valid answers and a later pass reads them correctly.
71
- - A pick made on the operator's behalf goes on a `- **Recommended:**` line directly above the slot, never inside it, and states which variant it takes and why. The slot below it still ships empty, so a count of unread changes still reads the change as unread.
72
-
73
- An answer rejecting the draft reopens the change rather than closing it. Move that answer to a `- **Answered:**` line above the variants it produced, and ship a fresh empty `- **You:**` beneath them. The change reads as unread again, which is what it is.
74
-
75
- Per-change slots do not license a partial sweep. Answering a change records one decision, and the applying rule below is what holds the set together.
76
-
77
- The overview file carries no slot, since it proposes no changes.
78
-
79
- ## Applying
80
-
81
- - Apply one file at a time, in the folder's settle order
82
- - Apply every change in that file that carries an answer, and nothing that does not
83
- - Re-grep each change's anchor against its source before applying it, and again after a rebase
84
- - Grep the other named surfaces for the same claim before committing the file
85
- - Write every hit that grep returns onto the proposal owning the file it sits in, as a change with its own answer slot, and open a proposal for a surface the pass has none for
86
- - Commit the file once its own answered changes are applied. A hit in a sibling never holds it.
87
- - Move an applied change into `applied.md` beside the proposals, carrying its reason and its answer
88
-
89
- A partial pass is worse than none, and a file is the unit that can be finished. Settling one claim across every file at once touches all of them and closes none, so each file ends the pass looking reviewed while other changes in it sit answered and unapplied. The surface grep is what covers the cross-file half a per-file pass would otherwise miss.
90
-
91
- Recording a hit rather than acting on it is what keeps the grep from rebuilding the whole-set gate. A sibling holding the same claim is a change nobody has answered yet, and holding this file until it is answered makes every file wait on the slowest one, which is the shape the per-file unit replaced.
92
-
93
- A proposal outlives its own diff. The source moves under it, so an approved change stops matching while the defect it names survives in fresh wording. The anchor re-grep is the only thing that catches that.
94
-
95
- ## After
96
-
97
- - Strip the `diff` blocks
98
- - Keep the files, their headings, their reasons, and the answers
99
-
100
- What remains is the record of what changed and why, which is the half no commit message holds. The folder stays where it is, beside every earlier pass, so a later one reads what an earlier one settled instead of asking it again.
101
-
102
- The folder is gitignored, and backed wherever a records remote is configured. It carries decision state rather than generated data, which is why `src/records/backup.ts` names it in `BACKED_FOLDERS` so `canon records push` and `canon records pull` carry it there, refusing with `no-remote` otherwise, but nothing else about its contents is enforced.
103
-
104
- ## Retrieval
105
-
106
- Count the unread changes per file:
107
-
108
- ```bash
109
- grep -c '^- \*\*You:\*\*$' .canon/proposals/<nn>-<slug>/*.md
110
- ```
111
-
112
- Report every answer given, against the change it sits under:
113
-
114
- ```bash
115
- awk '/^### /{h=FILENAME": "$0} /^- \*\*You:\*\*./{print h; print " "$0}' .canon/proposals/<nn>-<slug>/*.md
116
- ```
117
-
118
- Both walk `###` headings, which is the mechanical reason an answer typed anywhere else is lost.