@erclx/canon 5.34.0 → 5.36.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.
- package/README.md +15 -17
- package/claude/.claude-plugin/plugin.json +1 -1
- package/claude/skills/api-design/REQUIREMENT.md +1 -1
- package/claude/skills/auto-ship/references/draft-mark.md +1 -1
- package/claude/skills/canon-cli/REQUIREMENT.md +2 -2
- package/claude/skills/canon-cli/SKILL.md +12 -12
- package/claude/skills/canvas-board/REQUIREMENT.md +1 -1
- package/claude/skills/canvas-board/SKILL.md +2 -2
- package/claude/skills/canvas-board/references/design.md +53 -36
- package/claude/skills/codebase-layout/REQUIREMENT.md +1 -1
- package/claude/skills/codebase-layout/SKILL.md +2 -2
- package/claude/skills/create-rule/REQUIREMENT.md +6 -8
- package/claude/skills/create-rule/SKILL.md +8 -8
- package/claude/skills/create-rule/references/rule.md +11 -23
- package/claude/skills/create-skill/SKILL.md +2 -1
- package/claude/skills/create-skill/references/skill-paths.md +12 -15
- package/{standards/standard.md → claude/skills/create-skill/references/skill-reference.md} +50 -45
- package/claude/skills/create-skill/references/skill.md +9 -3
- package/claude/skills/design-taste/REQUIREMENT.md +6 -6
- package/claude/skills/design-taste/SKILL.md +2 -2
- package/claude/skills/design-taste/references/craft.md +1 -1
- package/claude/skills/design-taste/references/preflight.md +2 -2
- package/claude/skills/design-taste/references/tells.md +1 -1
- package/claude/skills/draft-and-pick/SKILL.md +1 -1
- package/claude/skills/draft-identity/SKILL.md +3 -2
- package/claude/skills/git-commit/references/versioning.md +13 -13
- package/claude/skills/git-pr/SKILL.md +1 -1
- package/claude/skills/git-pr/references/publish.md +1 -1
- package/claude/skills/markdown-craft/references/markdown.md +3 -2
- package/claude/skills/plan-feature/SKILL.md +1 -1
- package/claude/skills/review-address/REQUIREMENT.md +1 -1
- package/claude/skills/review-address/SKILL.md +2 -2
- package/claude/skills/review-craft/references/ui.md +1 -1
- package/claude/skills/review-pr/SKILL.md +3 -3
- package/claude/skills/review-pr/references/post.md +1 -1
- package/claude/skills/review-ui/REQUIREMENT.md +1 -1
- package/claude/skills/review-ui/SKILL.md +1 -1
- package/claude/skills/role-orchestrator/REQUIREMENT.md +2 -2
- package/claude/skills/role-orchestrator/SKILL.md +11 -12
- package/claude/skills/role-orchestrator/references/orchestrator-cloud-launch.md +3 -1
- package/claude/skills/role-orchestrator/references/orchestrator-dispatch.md +11 -8
- package/claude/skills/role-orchestrator/references/orchestrator-handback.md +10 -4
- package/claude/skills/role-orchestrator/references/orchestrator-launch.md +2 -2
- package/claude/skills/role-orchestrator/references/orchestrator-poll.md +11 -12
- package/claude/skills/role-orchestrator/references/orchestrator-review-dispatch.md +12 -15
- package/claude/skills/role-orchestrator/references/orchestrator-reviewer-launch.md +6 -4
- package/claude/skills/role-orchestrator/scripts/poll.ts +50 -1
- package/claude/skills/role-reviewer/REQUIREMENT.md +17 -7
- package/claude/skills/role-reviewer/SKILL.md +17 -10
- package/claude/skills/role-worker/REQUIREMENT.md +1 -1
- package/claude/skills/role-worker/SKILL.md +6 -6
- package/claude/skills/session-compact/references/handoff-note.md +1 -1
- package/claude/skills/target-setup/SKILL.md +2 -2
- package/claude/skills/target-setup/references/detect.md +3 -3
- package/claude/skills/test-craft/SKILL.md +2 -2
- package/claude/skills/ux-audit/REQUIREMENT.md +1 -1
- package/claude/skills/ux-audit/SKILL.md +2 -2
- package/claude/skills/ux-measure/REQUIREMENT.md +1 -1
- package/claude/skills/write-human/references/machine-tells.md +12 -0
- package/docs/agents/audits.md +1 -1
- package/docs/agents/commands.md +14 -13
- package/docs/agents/comments.md +1 -1
- package/docs/agents/counts.md +5 -6
- package/docs/agents/drift-surfaces.md +15 -19
- package/docs/agents/gov-detect.md +1 -1
- package/docs/agents/index.md +2 -3
- package/docs/agents/install-and-sync.md +10 -34
- package/docs/agents/markdown-audit.md +22 -12
- package/docs/agents/migrate.md +1 -1
- package/docs/agents/output-shape.md +1 -1
- package/docs/agents/overview.md +2 -2
- package/docs/agents/records-stale.md +1 -1
- package/docs/agents/records-validate.md +11 -23
- package/docs/agents/records.md +1 -1
- package/docs/agents/routing.md +1 -1
- package/docs/agents/rule-citations.md +9 -17
- package/docs/agents/scripting.md +2 -20
- package/docs/agents/state-scoped-risk.md +1 -1
- package/docs/agents/tasks-validate.md +1 -1
- package/docs/agents/teach.md +1 -1
- package/docs/target/index.md +1 -0
- package/docs/target/migrations.md +4 -0
- package/docs/target/projects.md +10 -10
- package/docs/target/scenarios.md +5 -6
- package/docs/target/standards-moved.md +32 -0
- package/docs/target/sync.md +5 -5
- package/docs/workflow/ai-workflow.md +1 -1
- package/docs/workflow/operating-model.md +16 -18
- package/docs/workflow/skill-map.md +1 -1
- package/docs/workflow/visual-design-workflow.md +3 -3
- package/governance/detect.toml +32 -36
- package/governance/renames.toml +44 -1
- package/governance/rules/lib/{305-e2e-reliability.md → e2e-reliability.md} +1 -1
- package/governance/rules/lib/{306-test-scope.md → test-scope.md} +2 -2
- package/governance/rules/ui/{410-a11y.md → a11y.md} +1 -1
- package/governance/rules/ui/{440-surface-capture.md → surface-capture.md} +3 -3
- package/governance/stacks/base.toml +15 -8
- package/governance/stacks/go.toml +2 -0
- package/governance/stacks/node.toml +1 -1
- package/governance/stacks/php.toml +2 -0
- package/governance/stacks/python.toml +1 -1
- package/package.json +1 -4
- package/scripts/core/install-check.sh +4 -10
- package/src/audits/catalog.ts +0 -9
- package/src/capture/frame-values.ts +3 -6
- package/src/claude/routing.ts +1 -1
- package/src/claude/skills-reach.ts +4 -6
- package/src/cli/help-all.ts +96 -0
- package/src/cli/help.ts +29 -29
- package/src/cli.ts +8 -3
- package/src/commands/claude.ts +29 -0
- package/src/commands/design.ts +22 -1
- package/src/commands/gov.ts +29 -11
- package/src/commands/init.ts +10 -1
- package/src/commands/labels.ts +4 -44
- package/src/commands/markdown.ts +96 -3
- package/src/commands/migrate.ts +1 -1
- package/src/commands/records.ts +5 -21
- package/src/commands/sync.ts +11 -0
- package/src/commands/tooling.ts +10 -4
- package/src/counts/catalogs.ts +0 -6
- package/src/design/budget.ts +14 -10
- package/src/design/document.ts +5 -5
- package/src/design/parse.ts +21 -4
- package/src/design/render.ts +3 -3
- package/src/gate/boundaries.ts +2 -2
- package/src/gate/measures.ts +7 -29
- package/src/gate/sequencer.ts +51 -2
- package/src/gate/stages.ts +0 -18
- package/src/gov/citations.ts +16 -71
- package/src/gov/stacks.ts +3 -3
- package/src/inventory/subjects.ts +1 -1
- package/src/markdown/bans.ts +1 -1
- package/src/markdown/ceiling.ts +6 -1
- package/src/markdown/colons.ts +86 -0
- package/src/markdown/gate.ts +15 -0
- package/src/markdown/heading-case.ts +74 -0
- package/src/migrate/scratch-evidence.ts +2 -2
- package/src/records/validate.ts +6 -194
- package/src/sandbox/provision.ts +0 -5
- package/src/secrets/shipped.ts +1 -2
- package/src/serve/static.ts +1 -2
- package/src/shipped/references.ts +42 -93
- package/src/sync/check.ts +18 -14
- package/src/sync/copy.ts +4 -5
- package/src/tooling/inject.ts +6 -37
- package/src/tooling/read.ts +2 -3
- package/src/tooling/scan.ts +4 -17
- package/src/tooling/subfolder.ts +2 -66
- package/tooling/astro/manifest.toml +0 -1
- package/tooling/astro/reference.md +0 -8
- package/tooling/base/configs/scripts/verify.json +1 -1
- package/tooling/base/configs/scripts/verify.ts +22 -17
- package/tooling/base/manifest.toml +7 -7
- package/tooling/base/reference.md +19 -32
- package/tooling/base/seeds/.github/workflows/verify.yml +0 -9
- package/tooling/base/seeds/.lintstagedrc +2 -4
- package/tooling/base/seeds/canon/context/ci.md +4 -6
- package/tooling/base/seeds/canon/context/development.md +2 -2
- package/tooling/claude/reference.md +1 -1
- package/tooling/claude/seeds/.claude/hooks/review-post-scan.sh +13 -1
- package/tooling/claude/seeds/.claude/hooks/scratch-guard.sh +1 -1
- package/tooling/claude/seeds/.claude/hooks/standards-audit.sh +27 -2
- package/tooling/claude/seeds/CLAUDE.md +1 -1
- package/tooling/claude/seeds/canon/DESIGN.md +24 -37
- package/tooling/go/reference.md +1 -1
- package/tooling/php/reference.md +1 -1
- package/tooling/python/reference.md +2 -2
- package/tooling/shell/configs/.github/workflows/shell.yml +30 -0
- package/tooling/shell/manifest.toml +12 -0
- package/tooling/shell/reference.md +46 -0
- package/tooling/vite-react/manifest.toml +0 -1
- package/tooling/vite-react/reference.md +0 -8
- package/tooling/web/configs/.github/workflows/readme-screenshot.yml +3 -5
- package/tooling/web/configs/.github/workflows/verify.yml +0 -9
- package/tooling/web/manifest.toml +1 -2
- package/tooling/web/reference.md +4 -6
- package/docs/agents/standards-audit.md +0 -40
- package/governance/rules/tooling/765-spelling.md +0 -19
- package/governance/stacks/astro.toml +0 -2
- package/governance/stacks/nextjs.toml +0 -2
- package/governance/stacks/node-server.toml +0 -2
- package/governance/stacks/python-fastapi.toml +0 -2
- package/governance/stacks/react.toml +0 -2
- package/src/commands/standards.ts +0 -278
- package/src/labels/spelling.ts +0 -120
- package/src/standards/audit.ts +0 -146
- package/src/standards/list.ts +0 -33
- package/src/standards/read.ts +0 -177
- package/src/standards/scope.ts +0 -56
- package/standards/index.md +0 -10
- package/tooling/base/configs/.vscode/extensions.json +0 -9
- package/tooling/base/configs/.vscode/settings.json +0 -3
- package/tooling/base/configs/scripts/verify.sh +0 -2
- package/tooling/base/seeds/.cspell/project-terms.txt +0 -0
- package/tooling/base/seeds/.cspell/tech-stack.txt +0 -25
- package/tooling/base/seeds/cspell.json +0 -20
- package/tooling/go/seeds/.cspell/tech-stack.txt +0 -16
- package/tooling/nextjs/seeds/.cspell/tech-stack.txt +0 -3
- package/tooling/php/seeds/.cspell/tech-stack.txt +0 -5
- package/tooling/python/seeds/.cspell/tech-stack.txt +0 -18
- package/tooling/vite-react/seeds/.cspell/project-terms.txt +0 -1
- package/tooling/vite-react/seeds/.cspell/tech-stack.txt +0 -2
- package/tooling/web/configs/.vscode/extensions.json +0 -13
- package/tooling/web/configs/.vscode/settings.json +0 -10
- package/tooling/web/seeds/.cspell/tech-stack.txt +0 -21
- /package/governance/rules/canon/{606-git.md → git.md} +0 -0
- /package/governance/rules/canon/{611-indexes.md → indexes.md} +0 -0
- /package/governance/rules/canon/{604-scratch.md → scratch.md} +0 -0
- /package/governance/rules/canon/{602-tasks.md → task-scope.md} +0 -0
- /package/governance/rules/canon/{605-worktrees.md → worktrees.md} +0 -0
- /package/governance/rules/claude/{566-output.md → output.md} +0 -0
- /package/governance/rules/code/{000-code.md → routing.md} +0 -0
- /package/governance/rules/code/{010-testing.md → testing.md} +0 -0
- /package/governance/rules/framework/{210-astro.md → astro.md} +0 -0
- /package/governance/rules/framework/{220-fastapi.md → fastapi.md} +0 -0
- /package/governance/rules/framework/{230-nextjs.md → nextjs.md} +0 -0
- /package/governance/rules/framework/{200-react.md → react.md} +0 -0
- /package/governance/rules/framework/{260-shadcn.md → shadcn.md} +0 -0
- /package/governance/rules/framework/{250-tailwind.md → tailwind.md} +0 -0
- /package/governance/rules/lang/{130-go.md → go.md} +0 -0
- /package/governance/rules/lang/{140-php.md → php.md} +0 -0
- /package/governance/rules/lang/{110-python.md → python.md} +0 -0
- /package/governance/rules/lang/{100-typescript.md → typescript.md} +0 -0
- /package/governance/rules/lib/{370-database.md → database.md} +0 -0
- /package/governance/rules/lib/{340-pydantic.md → pydantic.md} +0 -0
- /package/governance/rules/lib/{360-security-server.md → security-server.md} +0 -0
- /package/governance/rules/lib/{350-security-web.md → security-web.md} +0 -0
- /package/governance/rules/lib/{320-tanstack-query.md → tanstack-query.md} +0 -0
- /package/governance/rules/lib/{335-testing-go.md → testing-go.md} +0 -0
- /package/governance/rules/lib/{336-testing-php.md → testing-php.md} +0 -0
- /package/governance/rules/lib/{330-testing-py.md → testing-py.md} +0 -0
- /package/governance/rules/lib/{300-testing-ts.md → testing-ts.md} +0 -0
- /package/governance/rules/lib/{310-zod.md → zod.md} +0 -0
- /package/governance/rules/tooling/{700-ci-workflow.md → ci-workflow.md} +0 -0
- /package/governance/rules/tooling/{790-code-comments.md → code-comments.md} +0 -0
- /package/governance/rules/tooling/{780-config-comments.md → config-comments.md} +0 -0
- /package/governance/rules/tooling/{775-dependencies.md → dependencies.md} +0 -0
- /package/governance/rules/ui/{480-canvas.md → canvas.md} +0 -0
- /package/governance/rules/ui/{400-ui.md → copy.md} +0 -0
- /package/governance/rules/ui/{460-design-taste.md → design-taste.md} +0 -0
- /package/governance/rules/ui/{420-forms.md → forms.md} +0 -0
- /package/governance/rules/ui/{465-interface-casing.md → interface-casing.md} +0 -0
- /package/governance/rules/ui/{450-link-behavior.md → link-behavior.md} +0 -0
- /package/governance/rules/ui/{470-motion.md → motion.md} +0 -0
- /package/governance/rules/ui/{430-ux-completeness.md → ux-completeness.md} +0 -0
- /package/tooling/{base → shell}/configs/.editorconfig +0 -0
- /package/tooling/{base → shell}/configs/.shellcheckrc +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: role-reviewer
|
|
3
|
-
description: Asserts the reviewer role for a session dispatched to review one pull request another session built, holding what it may write, what it reads and never reads, the
|
|
3
|
+
description: Asserts the reviewer role for a session dispatched to review one pull request another session built, holding what it may write, what it reads and never reads, the messages it owes the worker and the controller, the lift it runs on a close, and the acts it refuses. Use when asked to "be the reviewer", "you are a reviewer session", at the start of a dispatched or hand-launched review of one pull request, or when a reviewing session needs to know what it may not write or who it answers to. Do NOT use to run the pass itself, which is `review-pr` for the code and `review-ui` for the running app, or to make the cross-branch call across a wave.
|
|
4
4
|
metadata:
|
|
5
5
|
family: parallel
|
|
6
6
|
---
|
|
@@ -25,7 +25,7 @@ from here.
|
|
|
25
25
|
|
|
26
26
|
## Where the session stands
|
|
27
27
|
|
|
28
|
-
- Write the review comment through `review-pr` and the body file it names under `.canon/tmp/pr/review/`, and nothing else. A UI reviewer writes the comment `review-ui` posts, its body file, and the browser's snapshots and frames, all under `.canon/tmp/pr/review-ui/`, and ticks the boxes it passed on the evidence comment through `canon pr tick`. A tracked file, a branch, a worktree, a board file, and a commit all sit outside what this session may touch.
|
|
28
|
+
- Write the review comment through `review-pr` and the body file it names under `.canon/tmp/pr/review/`, and nothing else. A UI reviewer writes the comment `review-ui` posts, its body file, and the browser's snapshots and frames, all under `.canon/tmp/pr/review-ui/`, and ticks the boxes it passed on the evidence comment through `canon pr tick`. Either reviewer writes the draft flag through `canon pr lift` and no other way. A tracked file, a branch, a worktree, a board file, and a commit all sit outside what this session may touch.
|
|
29
29
|
- Never enter a worktree and never check the branch out. The pass reads a change, and a checkout is the first step toward editing it.
|
|
30
30
|
- Read a file a finding rests on at the head `review-pr` resolved, through `git show <head>:<path>`. The main worktree holds the trunk, so a finding read off its copy is about a tree the pull request never changed, and it reads as confidently as one that is right.
|
|
31
31
|
- Resolve `.canon/plans/`, `.canon/tasks/`, and `.canon/tmp/` at the main worktree root, and send the body file as a heredoc, the main-root route `session-worktree` states. Report a plan or task that fails to resolve there as unreadable, naming the path, rather than reviewing as though the branch had none.
|
|
@@ -46,16 +46,23 @@ from here.
|
|
|
46
46
|
|
|
47
47
|
## The channel
|
|
48
48
|
|
|
49
|
-
|
|
50
|
-
|
|
49
|
+
Nobody watches this pass, so the messages below are owed and nothing else. The
|
|
50
|
+
worker and this session answer each other directly, and the controlling session
|
|
51
|
+
hears only what it acts on.
|
|
51
52
|
|
|
52
|
-
-
|
|
53
|
+
- Send the `review-address` dispatch to the worker holding the branch as `review-pr` Step 5 returns an open `## Review`, or as `review-ui` reports an open `## UI review`, carrying the pull request number, the heading, that step's count line verbatim, and this session's own sessionId for the worker's reply. Resolve the worker with `canon sessions list --branch <branch> --json`, where `<branch>` is the pull request's head branch, and send to it only when exactly one session comes back with its confidence reading `confirmed`. Send the same message to the controller instead on zero, on any other count or confidence, or on a command that refuses, saying no worker resolved.
|
|
54
|
+
- Run `canon pr lift <number> --json` after posting `## Review closed` or `## UI review closed`. Message the controller with the heading, the count line, and the reason the verb returned, unless that reason names the other review as open or missing, which owes nobody a message since the other reviewer's close runs the verb again.
|
|
53
55
|
- Send a block out as a message before it becomes an interactive prompt.
|
|
54
56
|
- Send nothing on progress, and send no recommendation to merge as an instruction. `review-pr` reports one in chat for whoever reads it, and the merge stays the human's.
|
|
55
57
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
58
|
+
Carry the sessionId in the message alone, never in the posted comment. The
|
|
59
|
+
comment is public, and an id there addresses nothing for a reader without the
|
|
60
|
+
roster.
|
|
61
|
+
|
|
62
|
+
Address the controlling session the launch named, which it names as a
|
|
63
|
+
`sessionId` rather than a name. `canon:session-relay` turns that id or the
|
|
64
|
+
worker's branch into an address and carries the send, so invoke it rather than
|
|
65
|
+
resolving a name here.
|
|
59
66
|
|
|
60
67
|
One rung stays here, because it is the rung that differs between roles. A
|
|
61
68
|
reviewer holds no feature branch, so inferring an addressee from the sessions
|
|
@@ -66,13 +73,13 @@ where exactly one does, and say the addressee was inferred.
|
|
|
66
73
|
## Refusing is part of the job
|
|
67
74
|
|
|
68
75
|
- Refuse to fix the defect this pass found, whoever asks. File it in the comment for the worker holding the branch instead. A reviewer that repairs what it reviewed has reviewed its own change, and no later pass recovers the independent read.
|
|
69
|
-
-
|
|
76
|
+
- Lift the draft mark through `canon pr lift` alone, and never ready the pull request directly, whoever asks. The verb reads the reviews, the evidence, the standing, and CI itself, so its lift needs no one to vouch for the request, and a direct ready skips every gate it holds.
|
|
70
77
|
- Refuse to merge, and refuse to approve through the review API in place of the comment `review-pr` posts, since the poll routes on that comment's heading and an approval carries none.
|
|
71
78
|
- Carry the evidence with a refusal. Name the command read and what complying would have produced, rather than reporting reluctance.
|
|
72
79
|
- Withdraw a finding the worker's reply shows wrong, the way `review-pr` states, rather than defending it. A withdrawal naming its cause is part of a pass, not a retreat from one.
|
|
73
80
|
|
|
74
81
|
## Lifetime
|
|
75
82
|
|
|
76
|
-
- The role runs from the launch to the merge of the pull request it reviewed, and covers every pass on that pull request. A re-review comes back to this session while it is live, which keeps the read the first pass paid for.
|
|
83
|
+
- The role runs from the launch to the merge of the pull request it reviewed, and covers every pass on that pull request. A re-review comes back to this session from the worker directly while it is live, which keeps the read the first pass paid for.
|
|
77
84
|
- A session handed a second pull request is a new reviewer under a new launch, since the first one's reading of the change is exactly what the second one must not carry.
|
|
78
85
|
- Treat this body as possibly older than the branch under review. A plugin skill loads from the marketplace cache rather than from the working tree.
|
|
@@ -19,7 +19,7 @@ Finishing is invisible from the other side. A worker that opens a pull request g
|
|
|
19
19
|
|
|
20
20
|
Nothing tells the session that refusing is allowed either. Four occasions across two days had a worker halt correctly with the cost falling on the dispatcher, and the correction that mattered most reached the right place because a worker argued back with evidence rather than complying. A role written only as report-upward suppresses exactly that.
|
|
21
21
|
|
|
22
|
-
The draft mark fails from both ends. On 2026-08-31 four sessions re-drafted a pull request someone had readied, acting on a belief no surface in the tree stated. On 2026-09-07 a controlling session told a worker to lift the mark rather than lifting it itself, and the worker complied and reported against the surface rather than the outcome.
|
|
22
|
+
The draft mark fails from both ends. On 2026-08-31 four sessions re-drafted a pull request someone had readied, acting on a belief no surface in the tree stated. On 2026-09-07 a controlling session told a worker to lift the mark rather than lifting it itself, and the worker complied and reported against the surface rather than the outcome. From 2026-10-12 `canon pr lift` reads the gates itself, so the reviewers run it on a close and the controlling session runs it as the fallback. A worker leaves the verb to them and readies a pull request directly for nobody, since a direct ready skips every gate the verb reads.
|
|
23
23
|
|
|
24
24
|
## Must
|
|
25
25
|
|
|
@@ -32,8 +32,8 @@ which `auto-ship` Step 2 loads.
|
|
|
32
32
|
- Report a plan that fails to resolve as unreadable from here, naming the main-root path. Reporting the task as having no plan is true where this session stands and wrong about the world, and a reader with no second tree to check cannot separate the two.
|
|
33
33
|
- Build the plan the launch named. Do not write a second one when the path fails to resolve, since a row that cites a plan already has one and drafting another produces two plans for one row.
|
|
34
34
|
- Copy a ready folder's files verbatim to the paths its plan's constraints name, when the plan's `**Constraints:**` block names one, and edit only what the gate or the overview's own list requires. A rewrite discards the text the handoff exists to carry.
|
|
35
|
-
- Report a draft flag reading ready once, and leave it cleared. The ship chain marks the pull request a draft and
|
|
36
|
-
-
|
|
35
|
+
- Report a draft flag reading ready once, and leave it cleared. The ship chain marks the pull request a draft, and only `canon pr lift` or the operator un-marks it, so a flag reading ready afterwards passed every gate the verb reads or was readied by a person, which GitHub requires before a merge. Re-drafting fights them, and no surface in the tree states a reason to.
|
|
36
|
+
- Leave the lift to the reviewers, who run `canon pr lift` on posting their close, and to the controlling session as the fallback. Refuse an instruction to ready the pull request directly, whoever sends it, since a direct ready skips every gate the verb reads.
|
|
37
37
|
- Rewrite a plan question's `- Suggested:` line as `overridden at execution to <pick>,` plus the measurement when this build decides against an unanswered one, leaving the `- Answer:` slot blank, and put the same deviation in one line under the open task's `## Findings`, per `${CLAUDE_SKILL_DIR}/../plan-feature/references/plan.md`.
|
|
38
38
|
|
|
39
39
|
## The board is read-only
|
|
@@ -51,13 +51,13 @@ owed and nothing else.
|
|
|
51
51
|
- Announce the pull request as the ship chain's pull request step returns, carrying the number, the branch, and the task it closes. That transition is the one moment only this session knows, and the controller's review poll no longer starts on a dispatch because of it.
|
|
52
52
|
- Carry the reach in that same message: the paths this branch wrote that another live plan or `## Run now` row holds, and who holds each, which `canon tasks plan-reach` reports as `claimed`. Report each as a rebase the controller should order, never as a breach, since sharing a path is not a hold. The gate cleared this branch against a prediction it has since outgrown, so the controller holds a reading of what this branch shares that stopped being true hours ago and nothing else tells it. Say the reach was unread rather than clear when the installed binary carries no such subcommand, and leave the undeclared list to the pull request.
|
|
53
53
|
- Carry a row this build turned up in that same message, with its title, its origin, and the surface it would take. Send it as its own message only when the session will end before a pull request opens, since the row has no other way to reach the controller.
|
|
54
|
-
-
|
|
54
|
+
- Ask for the re-review when an address-review pass finishes, as `review-address` Step 8 returns, carrying what was addressed and the PR's new CI state. Send it to the reviewer whose sessionId the review dispatch carried, resolved from that id at the moment of sending, since a reviewer holds the trunk branch and no branch lookup finds it. Send it to the controller instead when the dispatch named no reviewer or the id resolves to no live session. That transition is the other moment only this session knows, and the message is what starts the re-review rather than a poll for an answer nothing marks as landed.
|
|
55
55
|
- Send a block out as a message before it becomes an interactive prompt.
|
|
56
56
|
- Send nothing on progress. A worker reporting progress rebuilds, on this side of the channel, the poll the announcement retired on the other.
|
|
57
57
|
|
|
58
|
-
Address the session the launch named,
|
|
59
|
-
|
|
60
|
-
send, so invoke it rather than resolving a name here. It reads the roster at the
|
|
58
|
+
Address the session the launch named, and the reviewer by the sessionId its
|
|
59
|
+
dispatch carried, each as a `sessionId` rather than a name.
|
|
60
|
+
`canon:session-relay` turns that id into an address and carries the send, so invoke it rather than resolving a name here. It reads the roster at the
|
|
61
61
|
moment of sending, checks the result against the agent listing, and falls back
|
|
62
62
|
to a copyable block where this session holds no tool to send through. The
|
|
63
63
|
message owed stays in its own bullet above.
|
|
@@ -5,7 +5,7 @@ description: What each section of a compact handoff carries, what stays out, and
|
|
|
5
5
|
|
|
6
6
|
# Handoff note
|
|
7
7
|
|
|
8
|
-
The shape `session-compact` writes. It lives
|
|
8
|
+
The shape `session-compact` writes. It lives in this skill's `references/` because one skill reads it, and a shape nothing else cites has no second reader to correct it.
|
|
9
9
|
|
|
10
10
|
## The test every line passes
|
|
11
11
|
|
|
@@ -99,7 +99,7 @@ Step 2: `canon tooling sync <tooling-stack> --write` installs stack deps, script
|
|
|
99
99
|
CANON_NON_INTERACTIVE=1 canon tooling sync <tooling-stack> <target> --write
|
|
100
100
|
```
|
|
101
101
|
|
|
102
|
-
Monorepo with multiple language roots: run `canon init` once at the repo root so `base` (husky, prettier,
|
|
102
|
+
Monorepo with multiple language roots: run `canon init` once at the repo root so `base` (husky, prettier, commitlint, CI) lands single, then sync each subtree with `--skip base` so the shared layer is not re-dropped. Take the subtree commands from the per-root rows the preview printed rather than picking folders by hand. Detection found each root and its stack, and the two commands below show the shape.
|
|
103
103
|
|
|
104
104
|
```bash
|
|
105
105
|
CANON_NON_INTERACTIVE=1 canon tooling sync vite-react ./frontend --skip base --write
|
|
@@ -108,7 +108,7 @@ CANON_NON_INTERACTIVE=1 canon tooling sync python ./backend --skip base --write
|
|
|
108
108
|
|
|
109
109
|
Without `--skip base`, each subtree re-drops husky, and git honors only one `core.hooksPath`, so the extra hook dirs silently break. Each subtree keeps its own framework configs, and its own stack reference reads through `canon tooling reference <stack>`.
|
|
110
110
|
|
|
111
|
-
A subtree sync withholds `.github/`, since GitHub reads workflows only at the repository root, and names each withheld file with the `working-directory` a root CI job needs.
|
|
111
|
+
A subtree sync withholds `.github/`, since GitHub reads workflows only at the repository root, and names each withheld file with the `working-directory` a root CI job needs. A subtree needs its own `bun init` before its scripts and dependencies land. The sync warns and skips them until then.
|
|
112
112
|
|
|
113
113
|
Step 3: post-sync fixups. Golden configs arrive from sync, so no config generation is required. But a few items may need a one-time touch:
|
|
114
114
|
|
|
@@ -77,9 +77,9 @@ already reach every subfolder. Tooling installs per folder. So resolve one
|
|
|
77
77
|
governance stack for the whole repository and one tooling stack per language
|
|
78
78
|
root.
|
|
79
79
|
|
|
80
|
-
- **Stack:** pick the
|
|
80
|
+
- **Stack:** pick the governance stack by matching the repository root's detected language against stack names in the catalog. Governance stacks are per language, so a framework never names one, and its rules arrive as extras. If the root matched nothing, `base` is the stack, including when subfolders matched, since no subfolder owns the repository and picking one by order would state a preference nobody gave. Mark it `fallback` in the preview only when no root matched anywhere.
|
|
81
81
|
- **Tooling stack:** for each language root, pick the closest tooling stack from `canon tooling list --json` (e.g. `vite-react`, `astro`, `nextjs`). Distinct from the governance stack. Fall back to `base` for a root with no framework or language match, and carry that fallback into its preview row.
|
|
82
|
-
- **Next.js:** map `next` in a root's `package.json` dependencies, or a `next.config.ts`/`.js`/`.mjs` file in that root, to the `
|
|
82
|
+
- **Next.js:** map `next` in a root's `package.json` dependencies, or a `next.config.ts`/`.js`/`.mjs` file in that root, to the `node` governance stack and the `nextjs` tooling stack. The dependency name does not match the tooling stack name by itself, and the Next.js rule arrives as an extra.
|
|
83
83
|
- **Extras:** run `canon gov detect <target> --stack <stack> --json` from the target and take its `proposals` array as the candidate extras. Each proposal names a `rule` and the `evidence` that matched it across every language root to depth two. The verb already leaves out every rule the picked stack resolves, so do not dedupe again, and do not match a rule's `description` or `paths` by hand.
|
|
84
84
|
- **Subfolder language rules:** a language root below the repository root whose language the picked stack does not carry contributes its language rule by name, read from `canon gov list --json`. The verb proposes no language rule, since a stack reaches each one.
|
|
85
85
|
- **Subfolder tooling:** a language root below the repository root takes its own `canon tooling sync <stack> <path> --skip base`, since `canon init` already lands `base` once at the root. Leave a root whose stack resolves to `base` out of the commands, since that sync would land nothing. A repository-root `package.json` hosting only formatters and hooks is that case, and it adds no row.
|
|
@@ -111,7 +111,7 @@ toolkit repository, and option 2 hands the project-local file to `create-rule`.
|
|
|
111
111
|
Before executing, output:
|
|
112
112
|
|
|
113
113
|
- **Detected:** each technology with its evidence file, path included, so a subfolder marker reads as one
|
|
114
|
-
- **Stack:** picked governance stack and resolved rule count. Mark it `fallback` when no detected
|
|
114
|
+
- **Stack:** picked governance stack and resolved rule count. Mark it `fallback` when no detected language matched a catalog name.
|
|
115
115
|
- **Tooling stack:** one row per language root, each carrying its path, its picked tooling stack, a `fallback` mark on the same test, and its own command. On the repository root's row, name what `base` lands: configs, seeds, and gitignore entries in every case, plus the JavaScript development dependencies, scripts, and hook activation wherever a `package.json` exists to carry them. A project outside that ecosystem runs none of the second group and keeps the first. Omit these rows entirely on the `gov` phase, which syncs no tooling.
|
|
116
116
|
- **Extras:** each proposal with the evidence the verb returned, plus each subfolder language rule, listed in full as the list the operator confirms. A second matched stack reaches the install only through this list, since `canon init --stack` takes one stack, so a shortened list reads as that stack dropped.
|
|
117
117
|
- **Skip:** any `--skip` entries with reason
|
|
@@ -105,5 +105,5 @@ Run the final filter over every test written this session, checking each line. A
|
|
|
105
105
|
|
|
106
106
|
- The red, green, refactor procedure and its order: `test-first`, which loads this skill at its first step
|
|
107
107
|
- Reproducing a failure with no known cause: `systematic-debugging`
|
|
108
|
-
- Runner, file suffix, placement, and query conventions per language: `
|
|
109
|
-
- Settle, guard, and run-scope rules inside an end to end file: `
|
|
108
|
+
- Runner, file suffix, placement, and query conventions per language: `testing-ts`, `testing-py`, `testing-go`, and `testing-php`
|
|
109
|
+
- Settle, guard, and run-scope rules inside an end to end file: `e2e-reliability` and `test-scope`
|
|
@@ -37,4 +37,4 @@ The pass slides into fixing what it finds, and then the audit and the change lan
|
|
|
37
37
|
- Feature planning, which `plan-feature` owns
|
|
38
38
|
- Verifying one specific change, which `ui-checklist` owns
|
|
39
39
|
- Defining the intent it audits against, which the design document owns
|
|
40
|
-
- Measuring what a running interface costs to paint, block, or shift, which `ux-measure` owns. Contrast stays here rather than going with it, being computable from two color values this skill already reads off the
|
|
40
|
+
- Measuring what a running interface costs to paint, block, or shift, which `ux-measure` owns. Contrast stays here rather than going with it, being computable from two color values this skill already reads off the stylesheet's custom properties.
|
|
@@ -10,14 +10,14 @@ metadata:
|
|
|
10
10
|
## Guards
|
|
11
11
|
|
|
12
12
|
- If no UI files exist in the project (no JSX, TSX, Vue, Svelte, or HTML under `src/`), stop: `❌ No UI surfaces found to audit.`
|
|
13
|
-
- If the request asks what the interface costs to paint, block, or shift at runtime, run nothing and name `ux-measure`. This skill reads source and reaches no number a browser produces. Contrast is the exception and stays here, since it is computable from
|
|
13
|
+
- If the request asks what the interface costs to paint, block, or shift at runtime, run nothing and name `ux-measure`. This skill reads source and reaches no number a browser produces. Contrast is the exception and stays here, since it is computable from two color values in the stylesheet's custom properties, which the design document's lead names.
|
|
14
14
|
|
|
15
15
|
## Step 1: read context
|
|
16
16
|
|
|
17
17
|
Read these in parallel from the project root, skipping any that do not exist:
|
|
18
18
|
|
|
19
19
|
- `CLAUDE.md`: project type and conventions
|
|
20
|
-
- `canon/DESIGN.md`: visual intent,
|
|
20
|
+
- `canon/DESIGN.md`: visual intent, typography, and spacing rules, plus the stylesheet its lead names for the values
|
|
21
21
|
- `canon/REQUIREMENTS.md`: feature scope and non-goals
|
|
22
22
|
- A committed capture beside the surface's own source, when the project has one. A rendered surface reads differently composed than it reads written, and a capture is the only artifact here that shows the composed result rather than the markup. Absent one, note that this audit reads source only, and keep going. This is a stated fallback, not a stop: a project with no capture yet, or a capture mid-rebuild, still gets a source-only audit rather than losing the skill entirely.
|
|
23
23
|
|
|
@@ -43,7 +43,7 @@ A session that does start one picks a runner on the spot. The reading then comes
|
|
|
43
43
|
## Out of scope
|
|
44
44
|
|
|
45
45
|
- Judging the interface against stated intent, which `ux-audit` owns
|
|
46
|
-
- Contrast, which is computable from two color values in the
|
|
46
|
+
- Contrast, which is computable from two color values in the stylesheet `ux-audit` already reads. A contrast failure from a color computed at runtime stays invisible to that reader, and the cost is accepted rather than overlooked.
|
|
47
47
|
- Network waterfall, bundle size, and accessibility, which no version of this measures
|
|
48
48
|
- Writing behavioral tests against the interface, which `test-first` and `test-craft` own
|
|
49
49
|
- Fixing what the reading found
|
|
@@ -21,6 +21,7 @@ Work top down. The first three account for most of what a reader calls machine-w
|
|
|
21
21
|
- [Question as transition](#question-as-transition)
|
|
22
22
|
- [Escalating parallel clauses](#escalating-parallel-clauses)
|
|
23
23
|
- [Empty superlative frames](#empty-superlative-frames)
|
|
24
|
+
- [A colon or comma where the dash was](#a-colon-or-comma-where-the-dash-was)
|
|
24
25
|
|
|
25
26
|
## Rule of three
|
|
26
27
|
|
|
@@ -118,3 +119,14 @@ Fix by writing the two claims as two sentences, or by cutting the one that repea
|
|
|
118
119
|
`one of the most important`, `a critical piece of`, `at the heart of`. The frame ranks a thing against a set the sentence never names.
|
|
119
120
|
|
|
120
121
|
Fix by stating what the thing does. A ranking survives only where the set is named and the position is measured.
|
|
122
|
+
|
|
123
|
+
## A colon or comma where the dash was
|
|
124
|
+
|
|
125
|
+
An agent told to remove an em dash swaps in a colon or a comma and leaves the sentence as it was. The join is the same and so is the pause the dash made, which is the habit the ban was written against.
|
|
126
|
+
|
|
127
|
+
```markdown
|
|
128
|
+
Bad: The hook fires on every edit: it reads the record the verb wrote.
|
|
129
|
+
Good: The hook fires on every edit and reads the record the verb wrote.
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
Fix by splitting the sentence in two, or by cutting the clause that only restates the first. A colon after a label or before a list is not this tell.
|
package/docs/agents/audits.md
CHANGED
|
@@ -85,7 +85,7 @@ It sits under the project root rather than beside the aggregator in `src/`. The
|
|
|
85
85
|
|
|
86
86
|
### What is kept out of it
|
|
87
87
|
|
|
88
|
-
A gitignored record folder holds one machine's session scratch. Its counts describe somebody else's disk, so committing them writes a floor no other clone can reproduce and every contributor reads a regression against a number that was never about their tree. The board and
|
|
88
|
+
A gitignored record folder holds one machine's session scratch. Its counts describe somebody else's disk, so committing them writes a floor no other clone can reproduce and every contributor reads a regression against a number that was never about their tree. The board and every record kind are therefore reported on every run and recorded in none.
|
|
89
89
|
|
|
90
90
|
An audit that did not report is left out rather than written as zero. Zero there records a clean corpus nobody measured, and the next run reads its real numbers as a regression against a floor that was never taken.
|
|
91
91
|
|
package/docs/agents/commands.md
CHANGED
|
@@ -5,7 +5,9 @@ description: Every top-level command with its purpose, each domain's subcommands
|
|
|
5
5
|
|
|
6
6
|
# Command catalog
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
Bare `canon --help` lists every top-level command under five headings, Project, Domains, Author and render, Session and ship, and Repo reports, with descriptions cut at 80 columns. A pipe gets the same text without the frame glyphs. Behavior notes for the install and sync verbs live in `install-and-sync.md`.
|
|
9
|
+
|
|
10
|
+
`canon <command> --help` lists subcommands, and `canon <command> <subcommand> --help` a leaf's flags, exit codes, and examples. `canon <command> --help --all` prints both. An unknown subcommand exits 1 under a group taking no operand.
|
|
9
11
|
|
|
10
12
|
## Project-level
|
|
11
13
|
|
|
@@ -19,7 +21,6 @@ One row per top-level command, in the order `canon --help` prints them. A domain
|
|
|
19
21
|
| `canon migrate <verb>` | Move a project off a retired name or layout, reporting the plan until `--write` |
|
|
20
22
|
| `canon targets <verb>` | Report the projects this toolkit installed into |
|
|
21
23
|
| `canon gov <verb>` | Install and sync governance rules, and audit the tree against them |
|
|
22
|
-
| `canon standards <verb>` | List, audit, or print a standard by name |
|
|
23
24
|
| `canon tooling <verb>` | Sync, diff, and verify tooling stacks |
|
|
24
25
|
| `canon claude <verb>` | Install the Claude workflow and audit both skill corpora |
|
|
25
26
|
| `canon wiki <verb>` | Scaffold the wiki pages |
|
|
@@ -61,7 +62,7 @@ A port already in use is the ordinary case rather than a refusal, so it walks fo
|
|
|
61
62
|
|
|
62
63
|
A request naming a directory is redirected to its trailing-slash form rather than answered in place. A browser resolves a relative asset against the last slash of the URL it is on, so answering `/lesson` directly leaves the page asking for `/course.css` instead of `/lesson/course.css`, and it renders unstyled through the server that exists to prevent exactly that.
|
|
63
64
|
|
|
64
|
-
Containment is tested after symlinks are followed rather than on the path as written, and the test sits immediately before the read rather than beside the request that produced it. Resolving a request lexically clears a link pointing outside the served root, and
|
|
65
|
+
Containment is tested after symlinks are followed rather than on the path as written, and the test sits immediately before the read rather than beside the request that produced it. Resolving a request lexically clears a link pointing outside the served root, and a link out of the served root is the shape it guards against. Position is what makes the property hold: a directory request appends its index after the request path has been checked, so a check placed earlier leaves that index untested. `--index` answers a directory holding no `index.html` with a listing read per request, where the default stays a 404. Every entry the listing names takes the same containment test a request for it would, so a link out of the root is absent rather than greyed, and dotfiles are hidden. With no `--entry` and no root `index.html`, the printed link is `/` and `entryExists` reads true. An `--entry` that escapes the root refuses with `no-entry` before a port is taken, because `url` is the field a caller hands to a reader.
|
|
65
66
|
|
|
66
67
|
`canon demo` is the second browser command and the one that ships, since its purpose is running in a target rather than regenerating what this repository commits. It needs a browser binary the package does not carry, installed once with `bunx playwright install chromium`.
|
|
67
68
|
|
|
@@ -79,12 +80,11 @@ query = "button, a[href], input, select, textarea, [tabindex]"
|
|
|
79
80
|
|
|
80
81
|
## Domain commands
|
|
81
82
|
|
|
82
|
-
Each domain exposes a consistent shape where applicable: `list`, `install`, `sync`, `create`. The page named beside a domain carries its flags, records, and refusals, and `canon <domain> --help`
|
|
83
|
+
Each domain exposes a consistent shape where applicable: `list`, `install`, `sync`, `create`. The page named beside a domain carries its flags, records, and refusals, and `canon <domain> --help --all` prints every subcommand's flags.
|
|
83
84
|
|
|
84
85
|
- `migrate`, in `migrate.md`: `rename`, `skill-names`, `records`, `surface-roots`, `record-tree`, `rule-layout`, `scratch-evidence`, `record-layout`
|
|
85
86
|
- `targets`, in `targets.md`: `list`, `pulls`
|
|
86
|
-
- `gov`, in `install-and-sync.md`: `list`, `install`, `sync`, `build`, `regen`, `test-order`, `counts`, `superseded`, `citations`, `restated`
|
|
87
|
-
- `standards`, in `standards-audit.md`: `list`, `audit`, `<name>`
|
|
87
|
+
- `gov`, in `install-and-sync.md`: `list`, `install`, `sync`, `build`, `regen`, `detect` (in `gov-detect.md`), `test-order`, `counts`, `superseded`, `citations`, `restated`
|
|
88
88
|
- `tooling`, in `install-and-sync.md`: `list`, `sync`, `diff`, `reference`, `verify`, `inject`, `prune-gitignore`
|
|
89
89
|
- `claude`, in `skills-audit.md`: `init`, `sync`, `setup`, `routing`, `plugin-update`, `seeds list`, `skills list`, `skills audit`, `skills drift`, `skills reach`, `skills rank`
|
|
90
90
|
- `wiki`, in `scripting.md`: `init`
|
|
@@ -94,16 +94,17 @@ Each domain exposes a consistent shape where applicable: `list`, `install`, `syn
|
|
|
94
94
|
- `slides`, described below: `render`, `list`
|
|
95
95
|
- `demo`, in `demo.md`: `compile`, `run`, `frames`
|
|
96
96
|
- `inventory`, described above: `run`
|
|
97
|
-
- `teach`, in `teach.md`: `list`, `open`, `resource`, `glossary`, `lesson`, `stylesheet`, `nav`, `render`
|
|
98
|
-
- `canvas`, described below: `serve`, `list`, `page add`, `page rename`, `frame add`, `frame move`, `frame resize`, `selection`, `edit`, `editing`, `capture`
|
|
99
|
-
- `sandbox`, in `sandbox.md`: `reset`, `clean`, `check`, `coverage`
|
|
97
|
+
- `teach`, in `teach.md`: `list`, `up`, `open`, `resource`, `glossary`, `lesson`, `stylesheet`, `nav`, `render`
|
|
98
|
+
- `canvas`, described below: `serve`, `list`, `page add`, `page rename`, `frame add`, `frame move`, `frame resize`, `fit`, `arrange`, `selection`, `edit`, `editing`, `capture`
|
|
99
|
+
- `sandbox`, in `sandbox.md`: `run`, `equivalence`, `reset`, `clean`, `check`, `coverage`
|
|
100
100
|
- `tasks`, in `tasks.md`: `next-label`, `archive`, `decline`, `plan-citations`, `plan-answers`, `plan-branch`, `plan-reach`, `plan-link`, `pull-request`, `outcome`, `list`, `validate`
|
|
101
101
|
- `intake`, in `intake.md`: `list`, `answer`
|
|
102
|
-
- `records`, in `records.md`: `validate`, `
|
|
102
|
+
- `records`, in `records.md`: `validate`, `ordinal`, `size`, `stale`, `prune-tmp`, `push`, `pull`
|
|
103
103
|
- `sessions`, in `sessions.md`: `list`, `export`, `import`
|
|
104
|
-
- `worktrees`, in `worktrees.md`: `list`, `reclaim`
|
|
104
|
+
- `worktrees`, in `worktrees.md`: `list`, `reclaim`, `repair-bare-flag` (hidden)
|
|
105
105
|
- `hooks`, in `hooks.md`: `post-merge`
|
|
106
|
-
- `pr`, in `pr-reads.md`: `key-changes`, `head`, `checks`, `review-state`, `evidence`, `preview`, `local`, `frames`, `lift` (in `pr-lift.md`)
|
|
106
|
+
- `pr`, in `pr-reads.md`: `key-changes`, `head`, `checks`, `review-state`, `evidence`, `preview`, `local`, `frames`, `lift` (in `pr-lift.md`), `tick` (in `pr-tick.md`)
|
|
107
|
+
- `upstream`, in `upstream.md`: `fetch`, `catalog`, `due`, `advance`
|
|
107
108
|
- `audits`, in `audits.md`: `run`, `list`
|
|
108
109
|
- `gate`, in `gate.md`: `run`
|
|
109
110
|
- `secrets`, in `state-scoped-risk.md`: `scan`
|
|
@@ -130,7 +131,7 @@ Subcommands no other page describes:
|
|
|
130
131
|
- A deck folder's `deck.json` and the faces it embeds, its per-slide `<body>` attributes, transitions and entrances, speaker notes, and charts are described in `slides.md`.
|
|
131
132
|
- `canvas`, with its verbs, content format, and write routes, is described in `canvas.md`.
|
|
132
133
|
- `labels apply <number>` adds the labels this branch earns to its open pull request, refusing a pull request whose head is not the current branch or that is not open, and never creating a label the remote lacks or removing one a person added (`--check` writes nothing and exits 2 when labels are owed, `--base`, `--json`).
|
|
133
|
-
- `labels scan` fails a pull request or a posted review whose title, body, or review comment carries a phase label, a label a code span quotes, a gitignored record path, a session link, a banned character, a body heading outside the closed section list or a missing `## Summary` or `## Key changes`,
|
|
134
|
+
- `labels scan` fails a pull request or a posted review whose title, body, or review comment carries a phase label, a label a code span quotes, a gitignored record path, a session link, a banned character, a body heading outside the closed section list or a missing `## Summary` or `## Key changes`, or a title breaking `claude/skills/git-pr/references/pr.md`'s format, casing, or length rule (`--event`, `--body-file`, `--json`).
|
|
134
135
|
|
|
135
136
|
## Version skew
|
|
136
137
|
|
package/docs/agents/comments.md
CHANGED
|
@@ -29,6 +29,6 @@ This works only because density is a pure function of a tree. Which author or se
|
|
|
29
29
|
|
|
30
30
|
## Degradation sweep
|
|
31
31
|
|
|
32
|
-
The degradation sweep reads its vocabulary from whichever rule publishes a `## Degradation vocabulary` heading, preferring `.claude/rules/` over `governance/rules/`, so one definition serves the toolkit and every target. Discovery anchors on the heading rather than a filename, because a
|
|
32
|
+
The degradation sweep reads its vocabulary from whichever rule publishes a `## Degradation vocabulary` heading, preferring `.claude/rules/` over `governance/rules/`, so one definition serves the toolkit and every target. Discovery anchors on the heading rather than a filename, because a renamed rule would otherwise empty the vocabulary while the sweep still reported clean. With no such rule the sweep reports **skipped** rather than zero hits, since finding nothing and looking for nothing mean opposite things.
|
|
33
33
|
|
|
34
34
|
`090-code-comments` is the rule that publishes the list, and it ships on the `base` stack. A project that installs or syncs governance for the first time after that rule landed gets a sweep that previously reported skipped, so hits appear where the command used to stay quiet. Edit the backticked terms in the installed copy to change what that project sweeps for. The sweep matches comment text, so a comment naming a term as an example is a hit, and a hit is a prompt to read the line rather than a verdict on it.
|
package/docs/agents/counts.md
CHANGED
|
@@ -22,11 +22,10 @@ Under `--json` the record holds stdout alone and the frame still renders on stde
|
|
|
22
22
|
|
|
23
23
|
## The catalogs it reads
|
|
24
24
|
|
|
25
|
-
A closed set of
|
|
25
|
+
A closed set of four, each with a filesystem reader behind it rather than every list command this CLI ships:
|
|
26
26
|
|
|
27
27
|
- `skills`: shipped plugin skills, a folder per `claude/skills/*/SKILL.md`
|
|
28
28
|
- `rules`: authored governance rules, a file per `governance/rules/**/*.md`
|
|
29
|
-
- `standards`: the authoring corpus at `standards/`
|
|
30
29
|
- `commands`: top-level `canon` commands, read off `src/cli.ts`'s registration imports
|
|
31
30
|
- `audits`: the registered set in `src/audits/catalog.ts`, this entry included
|
|
32
31
|
|
|
@@ -36,7 +35,7 @@ The set is closed rather than derived, so widening it is a deliberate change to
|
|
|
36
35
|
|
|
37
36
|
A sentence has to carry an assertion verb (`loads`, `ships`, `carries`, `holds`, `counts`, `totals`, `documents`, `declares`, `installs`, `lists`, `contains`, `comprises`, `authors`), the quantifier `all`, or an article (`the`, `a`, `an`) immediately ahead of the number, which is immediately ahead of the catalog noun, with one optional qualifying word between the number and the noun (`sixty-one shipped skills`). The number reads either as digits or as a spelled-out cardinal through ninety-nine, since this corpus states a catalog size in words as often as in digits.
|
|
38
37
|
|
|
39
|
-
Nothing stands between the trigger and the number, which is the rule an author writing a new count has to know. It separates `the toolkit authors
|
|
38
|
+
Nothing stands between the trigger and the number, which is the rule an author writing a new count has to know. It separates `the toolkit authors 49 rules` and `took all 49 rules`, both read, from `a domain of 55 skills` and `denominator of sixty-one shipped skills`, neither of them read. A figure meant as a past state takes a date in the same sentence instead, which reads the sentence past whatever its shape.
|
|
40
39
|
|
|
41
40
|
## How the trigger set grew
|
|
42
41
|
|
|
@@ -44,7 +43,7 @@ The verb gate is not the first design tried. A bare number next to a catalog nou
|
|
|
44
43
|
|
|
45
44
|
The article half was added after a first review of the shipped design found a live miss: the development domain's gating-stages entry stated a stale audit total while the tree held 20, and the verb gate never reached it, since that sentence puts its verb after the noun rather than ahead of the number. Widening the trigger set to admit an article ahead of the number closed that gap.
|
|
46
45
|
|
|
47
|
-
The quantifier `all` and the verb `authors` joined on the same evidence, two more live misses failing only the trigger test. Allowing words to stand between the trigger and the number was the other candidate, measured and declined: at widths of one, two, and three it reached 77, 104, and 132 sentences against a baseline of 65, missed `took all
|
|
46
|
+
The quantifier `all` and the verb `authors` joined on the same evidence, two more live misses failing only the trigger test. Allowing words to stand between the trigger and the number was the other candidate, measured and declined: at widths of one, two, and three it reached 77, 104, and 132 sentences against a baseline of 65, missed `took all 49 rules` at every width, and reached `the toolkit authors 49 rules` only at a width admitting the indirect-noun shape below. The two words reach both at 75 sentences and no false positive.
|
|
48
47
|
|
|
49
48
|
## The plausibility filter
|
|
50
49
|
|
|
@@ -52,13 +51,13 @@ The verb gate alone still left four false positives standing: `carries two rules
|
|
|
52
51
|
|
|
53
52
|
A stated figure is read only when it sits within a factor of two of the true count, in either direction. That bound is tuned against the run this sweep was written against rather than reasoned to from first principles, the way `restated.ts` tunes its own document-frequency ceiling, and it is a property of the scale every catalog here sits at (the tens) rather than a universal rule.
|
|
54
53
|
|
|
55
|
-
The article gate is looser than the verb list and carries a real cost. Re-running against the tree once it widened caught the live miss above and also misread a passage in
|
|
54
|
+
The article gate is looser than the verb list and carries a real cost. Re-running against the tree once it widened caught the live miss above and also misread a passage in the standards destinations entry, since retired, naming a real subset, a standard outside the retired bundled fan-out, as a claim about the whole standards catalog. The qualifying adjective there fills the same optional-word slot `sixty-one shipped skills` needs to match at all, and no syntactic rule tells a qualifier that narrows a catalog from one that only restates it. The finding could not be closed by correcting a figure, since the sentence was true when the corpus held it, only unmarked as a past state, which is the class the date exclusion already reads past. Naming the moment, the same way a context entry dates its own figures, closed it with no change to the matcher.
|
|
56
55
|
|
|
57
56
|
## What it does not measure
|
|
58
57
|
|
|
59
58
|
A delta phrased as a transition (`from fourteen to fifteen`), a fraction (`thirteen of sixteen`), and a total reached through an indirect noun (`denominator of sixty-one shipped skills`) are all catalog-size claims this corpus carries, and none matches the trigger shape this reads. Each stays a known gap. The false-positive rate that gated closing them has a measurement behind it now, and what it showed is that the widening these three need is the one that costs a false positive rather than the one that does not.
|
|
60
59
|
|
|
61
|
-
A second figure in a sentence whose first figure already matched is a fourth gap and a structural one, since one match is taken per catalog per sentence. `authors
|
|
60
|
+
A second figure in a sentence whose first figure already matched is a fourth gap and a structural one, since one match is taken per catalog per sentence. `authors 49 rules under governance/rules/ and consumes 31 into .claude/rules/` is read for its 49 alone, which is correct here because the two figures name different populations, and a sentence stating one catalog twice would go unread the same way.
|
|
62
61
|
|
|
63
62
|
A calendar date (`2026-08-21`) or a backticked commit reference in the same sentence reads the whole sentence past, since that is how this corpus already marks a figure as a historical record rather than a live claim. The context entries carry a figure this way deliberately, and every one of them stays correct forever.
|
|
64
63
|
|
|
@@ -50,23 +50,19 @@ seed tree rather than from a fixed set of filenames, so a folder added later is
|
|
|
50
50
|
covered without a code change. Only an exact stem matches, which leaves a
|
|
51
51
|
suffixed variant such as `TASKS-ARCHIVE.md` unreported.
|
|
52
52
|
|
|
53
|
-
No skill splits the file. The
|
|
54
|
-
|
|
55
|
-
its destination shape, so the split is the project's own to make.
|
|
53
|
+
No skill splits the file. The destination's shape lives in the skill that owns
|
|
54
|
+
it, so the split is the project's own to make.
|
|
56
55
|
|
|
57
56
|
`unmigrated` names a domain sitting at the root layout an older toolkit installed
|
|
58
57
|
to, with nothing at the path the current one reads. It carries `rootPath`,
|
|
59
|
-
`installPath`, and a file count. Without it a project holding
|
|
58
|
+
`installPath`, and a file count. Without it a project holding an older layout at its
|
|
60
59
|
root reports zero entries for that domain and reads as clean, which is the most
|
|
61
60
|
misleading state the report can produce.
|
|
62
61
|
|
|
63
|
-
The field currently names no domain.
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
Nothing proposes moving it, and no command relocates the content. Move it
|
|
68
|
-
yourself. A leftover `snippets/` folder reports under the reverse walk instead,
|
|
69
|
-
where `docs/target/sync.md` says what to do with it.
|
|
62
|
+
The field currently names no domain. Snippets was the one the toolkit ever
|
|
63
|
+
installed at a project root, and it retired outright. A leftover `snippets/`
|
|
64
|
+
folder reports under the reverse walk instead, where `docs/target/sync.md` says
|
|
65
|
+
what to do with it.
|
|
70
66
|
|
|
71
67
|
`unmovedSurfaces` names a tracked surface the target still holds at its `.claude/`
|
|
72
68
|
spelling with nothing at the `canon/` one, such as `.claude/REQUIREMENTS.md` or
|
|
@@ -123,14 +119,14 @@ that is not a full clone as unmeasured rather than clean. This gap does not
|
|
|
123
119
|
reach the chain-based read above, since it consults no anchor at all.
|
|
124
120
|
|
|
125
121
|
In the fallback, entitlement is filtered, because a stack does not receive
|
|
126
|
-
every rule. The base stack
|
|
127
|
-
|
|
128
|
-
list would tell a base consumer about rules it can never receive and
|
|
129
|
-
reader to skip the section.
|
|
130
|
-
|
|
131
|
-
The filter accepts a band on either of two grounds. A folder
|
|
132
|
-
|
|
133
|
-
base later needs no code change. Every other band is read off the folders the
|
|
122
|
+
every rule. The base stack names ten rules, the language stacks add `code` and
|
|
123
|
+
their own language and testing rules, and every other rule is opt-in, so an
|
|
124
|
+
unfiltered list would tell a base consumer about rules it can never receive and
|
|
125
|
+
train the reader to skip the section.
|
|
126
|
+
|
|
127
|
+
The filter accepts a band on either of two grounds. A folder holding a rule the
|
|
128
|
+
base stack resolves to is entitled to every target, read through the stack file so
|
|
129
|
+
a rule added to base later needs no code change. Every other band is read off the folders the
|
|
134
130
|
target already carries, which is the fallback's only evidence of what a target
|
|
135
131
|
was entitled to before it recorded a chain. One band can be reached by more than
|
|
136
132
|
one stack, so the test over-reports inside a folder the target holds, which
|
package/docs/agents/index.md
CHANGED
|
@@ -45,11 +45,11 @@ CLI catalog and invocation rules for agents, split by command domain. Start with
|
|
|
45
45
|
- [The pull request checklist tick](pr-tick.md): How canon pr tick marks the checklist boxes a UI pass drove, the stamp that names the commit each passed at, why a render at a newer head clears a tick, the refusal reasons it names, and why a taste box is never ticked
|
|
46
46
|
- [Records push](records-push.md): Backing the record folders to a private remote and restoring them, which folders the payload carries, the one-time setup, the refusal reasons, and the hook that runs the push
|
|
47
47
|
- [Records stale](records-stale.md): Counting the releases since the requirements record was last reviewed, where the review date is read from, and the exit codes and refusals
|
|
48
|
-
- [Records validate](records-validate.md): Validating the session records
|
|
48
|
+
- [Records validate](records-validate.md): Validating the session records, the per-kind checks, which root they default to, the exit codes, and the refusal reasons
|
|
49
49
|
- [Records](records.md): The two roots a record folder resolves at, claiming the ordinal intake and groundwork share, reading each folder's size and growth, pruning stale scratch, and where validation, the canonical review count, and the private-remote backup are described
|
|
50
50
|
- [Restated instructions](restated.md): Counting the instructions the always-loaded file and every path-scoped rule share with the seed, the skill bodies, and each other, how a match is decided, the three classes, which surface a later edit starts from, and why the sweep reports rather than gates
|
|
51
51
|
- [Routing report](routing.md): Reading per CLAUDE.md section how many bullets name a path, what counts as naming one, when a rule counts as covering it, the two refusals, and why the verb reports rather than gates
|
|
52
|
-
- [Rule citations](rule-citations.md): Resolving every path a governance rule cites and every frontmatter glob the internal corpus declares, the
|
|
52
|
+
- [Rule citations](rule-citations.md): Resolving every path a governance rule cites and every frontmatter glob the internal corpus declares, the one form a citation is written in, the shapes that look like citations and are not, the two classes where an absent path is correct, why the glob half reads one corpus, and why this one gates
|
|
53
53
|
- [Sandbox](sandbox.md): Scenario routing, the expectation scoring surface, and the coverage census over scenarios and skills
|
|
54
54
|
- [Scripting](scripting.md): The runtime catalogs that replace hardcoded names, what each carries, and a headless invocation per domain
|
|
55
55
|
- [Sessions transfer](sessions-transfer.md): Moving a session to another machine, the export bundle and its manifest, placing it with import, the refusal reasons, and what a resume on the target depends on
|
|
@@ -57,7 +57,6 @@ CLI catalog and invocation rules for agents, split by command domain. Start with
|
|
|
57
57
|
- [Skill audit](skills-audit.md): Measuring both skill corpora against the skill standards, the checks it reads, the requirement gate that is the only failing one, and the drift verb that names bodies rewritten since a ref
|
|
58
58
|
- [Citation reach](skills-reach.md): Reporting the skill bodies that cite a path no target project receives, which corpus the verb reads, the ownership key that decides what counts, the one-word qualifier that marks a citation as decided, and why the verb reports instead of gating
|
|
59
59
|
- [Slides](slides.md): Where a deck folder lives and what it holds, what it declares for the whole deck in deck.json, the faces it embeds, what each slide declares on its own body, transitions and entrances, the master built from the project's tokens, speaker notes, charts, and what each refusal reports
|
|
60
|
-
- [Standard success criteria](standards-audit.md): Reading the corpus against the success-criterion gate, the two headings it accepts, why the check scopes to arrival rather than the whole corpus, and the exit codes it sets
|
|
61
60
|
- [State-scoped risk](state-scoped-risk.md): Reading committed state rather than an arriving change, the shipped-tree corpus the secret scan reads, what it keys on and how a deliberate value is exempted, the advisory check and its network failure mode, and why one gates while the other reports
|
|
62
61
|
- [Superseded values](superseded.md): Reading where the tree still asserts a value a changed convention no longer produces, why the sweep keys on the value rather than the file, the family stem behind a templated citation, the exemption marker, the blind spots it cannot reach, and why it reports rather than gates
|
|
63
62
|
- [Targets](targets.md): The projects this toolkit installed into, the record the install writes against the sweep that backs it, what bounds each answer, and the cross-target pull request read
|
|
@@ -19,7 +19,7 @@ removes a stale `.claude/GOV.md` from the retired build. Use
|
|
|
19
19
|
|
|
20
20
|
Everything under `.claude/rules/canon/` belongs to the toolkit, so a rule
|
|
21
21
|
there that the toolkit no longer ships is deleted on sync, edited or not. That
|
|
22
|
-
is how a retired rule stops loading in a target. A renamed
|
|
22
|
+
is how a retired rule stops loading in a target. A renamed rule
|
|
23
23
|
the toolkit declares in `governance/renames.toml` moves instead: the sync
|
|
24
24
|
installs the rule under its new name and deletes the old file, whether or not
|
|
25
25
|
the target's stamp records a stack. Local edits to the old file are not
|
|
@@ -27,16 +27,16 @@ carried, and the sync says so. The sync lists each change by path before it
|
|
|
27
27
|
applies, and the target's git diff is the record afterwards. `canon sync
|
|
28
28
|
--check` lists the same file as `retired` or `renamed` before any sync runs.
|
|
29
29
|
|
|
30
|
-
A rule that only routed a path to a standard
|
|
31
|
-
|
|
32
|
-
`claude/skill.md`. A held copy of each syncs in place, and the
|
|
33
|
-
intake, session, design, readme, and rule copies are deleted as
|
|
34
|
-
markdown rule is hand-written at `writing/markdown.md
|
|
35
|
-
`
|
|
30
|
+
A rule that only routed a path to a standard now names the skill that owns
|
|
31
|
+
the guidance. The tasks, plan, context, and skill rules are hand-written at
|
|
32
|
+
`canon/` and `claude/skill.md`. A held copy of each syncs in place, and the
|
|
33
|
+
groundwork, intake, session, design, readme, and rule copies are deleted as
|
|
34
|
+
retired. The markdown rule is hand-written at `writing/markdown.md` and names
|
|
35
|
+
the `markdown-craft` skill, and `800-prose` retires.
|
|
36
36
|
|
|
37
|
-
A project's own rules belong under `.claude/rules/project/`, where
|
|
38
|
-
|
|
39
|
-
|
|
37
|
+
A project's own rules belong under `.claude/rules/project/`, where a slug
|
|
38
|
+
the toolkit also ships collides with nothing, and a rule placed under `canon/`
|
|
39
|
+
instead is lost on the next sync.
|
|
40
40
|
|
|
41
41
|
A sync never deletes a rule that a newer canon release installed. The stamp
|
|
42
42
|
records the newest release that synced governance, and an older binary holds
|
|
@@ -86,12 +86,6 @@ from an anchor a later sync could advance past the rule's own commit. A
|
|
|
86
86
|
target whose install predates the recorded chain falls back to the same
|
|
87
87
|
band-inference `newRules` uses in `canon sync --check`.
|
|
88
88
|
|
|
89
|
-
There is no `canon standards sync` and no `canon standards install`. The corpus
|
|
90
|
-
installs into no project, so the domain has nothing in a target to reconcile.
|
|
91
|
-
`canon standards <name>` prints one, resolving `standards/` at the working root
|
|
92
|
-
and then the corpus inside the package, and `canon standards list --json` carries
|
|
93
|
-
the catalog, each entry labeled by the root it was read from.
|
|
94
|
-
|
|
95
89
|
## Tooling diff and sync
|
|
96
90
|
|
|
97
91
|
`canon tooling diff <stack> [target]` is the read-only comparison, and a session asking what differs reaches for it by default. It writes nothing and exits 1 when anything differs and 0 when nothing does, so it gates CI. `--json` adds the scan record on stdout with `ok: true`, and the frame goes to stderr. A refusal such as an unknown stack, an excluded stack, or a toolkit-root target still exits 1 and answers `{ ok: false, reason, message }`, so a caller branches on the record and reads a typo'd stack name as a refusal rather than as drift.
|
|
@@ -129,23 +123,6 @@ Claude Code loads both copies of an edited rule at session start. Run `canon
|
|
|
129
123
|
migrate rule-layout` first to move a target off the flat layout, which reports
|
|
130
124
|
what it would move and applies it under `--write`.
|
|
131
125
|
|
|
132
|
-
## Standards resolution
|
|
133
|
-
|
|
134
|
-
`canon standards <name>` writes the document to stdout and the root it answered
|
|
135
|
-
from to stderr, so a caller capturing with `$(...)` receives the document alone.
|
|
136
|
-
A name resolves with or without its `.md` extension, and one that matches no
|
|
137
|
-
standard exits 1 after listing the catalog on stderr.
|
|
138
|
-
|
|
139
|
-
Two roots answer, in order: `standards/` at the working directory, then the
|
|
140
|
-
corpus inside the package. A project that authors standards of its own uses the
|
|
141
|
-
first, and this repository's own authoring root is the same path. `.claude/standards/`
|
|
142
|
-
is not among them, and no repository writes one any more. A copy an older
|
|
143
|
-
toolkit installed into a target resolves nothing.
|
|
144
|
-
|
|
145
|
-
There is no citation closure to compute, since nothing is copied. A standard
|
|
146
|
-
that hands a concern to a sibling names it in `Does not govern:` and a reader
|
|
147
|
-
runs the verb again for that name.
|
|
148
|
-
|
|
149
126
|
## Governance regen
|
|
150
127
|
|
|
151
128
|
`canon gov regen` is the one governance verb that runs against the toolkit root,
|
|
@@ -258,7 +235,6 @@ still prompts. `--skip` takes `wiki`, `governance`, and `records`, and warns
|
|
|
258
235
|
without aborting on any other value. Records has nothing to run non-interactively,
|
|
259
236
|
since the private backup repository does not exist yet at scaffold time, so its
|
|
260
237
|
step only prints the one-time setup reminder and `--skip records` silences it.
|
|
261
|
-
There is no `--standards`, since no run writes that corpus into the target.
|
|
262
238
|
|
|
263
239
|
## Unguarded tooling primitives
|
|
264
240
|
|