@erclx/aitk 0.51.0 → 0.53.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/claude/.claude-plugin/plugin.json +1 -1
- package/claude/skills/claude-design-extract/SKILL.md +2 -1
- package/claude/skills/claude-docs/SKILL.md +1 -1
- package/claude/skills/claude-memory-capture/SKILL.md +2 -1
- package/claude/skills/claude-standards-audit/SKILL.md +5 -3
- package/claude/skills/create-skill/SKILL.md +2 -1
- package/claude/skills/create-snippet/SKILL.md +3 -2
- package/claude/skills/create-snippet/references/snippets.md +2 -1
- package/claude/skills/create-standard/SKILL.md +2 -1
- package/claude/skills/docs-sync/SKILL.md +2 -1
- package/claude/skills/git-issue/SKILL.md +2 -1
- package/claude/skills/git-issue/references/issue.md +2 -1
- package/claude/skills/git-pr/SKILL.md +2 -1
- package/claude/skills/git-pr/references/pr.md +2 -1
- package/claude/skills/git-split/references/pr.md +2 -1
- package/claude/skills/git-stage/SKILL.md +2 -1
- package/docs/agents/context-audit-checks.md +3 -1
- package/docs/agents/context-audit.md +35 -2
- package/docs/agents/index.md +1 -1
- package/docs/agents/install-and-sync.md +6 -0
- package/docs/ai-workflow.md +1 -1
- package/docs/operating-model.md +4 -4
- package/docs/visual-design-workflow.md +16 -16
- package/docs/zshrc-aliases.md +1 -1
- package/governance/rules/claude/500-prose.md +4 -3
- package/governance/rules/claude/501-markdown.md +13 -0
- package/governance/stacks/base.toml +1 -1
- package/package.json +1 -1
- package/scripts/core/install-check.sh +1 -1
- package/scripts/core/verify.sh +83 -0
- package/src/claude/seeds.ts +17 -3
- package/src/commands/context.ts +34 -7
- package/src/comments/vocabulary.ts +1 -1
- package/src/context/audit.ts +14 -0
- package/src/context/gate.ts +43 -0
- package/src/seed-marker.ts +74 -0
- package/src/sync/seeds-report.ts +16 -1
- package/src/tooling/inject.ts +17 -1
- package/standards/bundled/issue.md +2 -1
- package/standards/bundled/pr.md +2 -1
- package/standards/bundled/snippets.md +2 -1
- package/standards/diagrams.md +4 -3
- package/standards/index.md +2 -1
- package/standards/markdown.md +72 -0
- package/standards/prose.md +6 -57
- package/standards/publish.md +3 -2
- package/standards/readme.md +3 -2
- package/standards/skill.md +2 -1
- package/standards/standard.md +2 -1
- package/standards/versioning.md +2 -1
- package/standards/wireframes.md +3 -2
- package/tooling/claude/seeds/.claude/hooks/standards-audit.sh +5 -1
|
@@ -33,6 +33,7 @@ Read these from the project root on both paths, skipping any that do not exist:
|
|
|
33
33
|
- `CLAUDE.md`: voice, personality, spelling rules
|
|
34
34
|
- `.claude/REQUIREMENTS.md`: the `## Personality` paragraph, worldview, non-goals
|
|
35
35
|
- `.claude/standards/prose.md`: tone constraints
|
|
36
|
+
- `.claude/standards/markdown.md`: punctuation and formatting constraints
|
|
36
37
|
|
|
37
38
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
38
39
|
|
|
@@ -54,7 +55,7 @@ Use the returned content as the target shape. Keep every section heading and eve
|
|
|
54
55
|
|
|
55
56
|
## Step 4: fill the template
|
|
56
57
|
|
|
57
|
-
Walk each section once. Follow `.claude/standards/prose.md` throughout: no em dashes, no semicolons, no marketing buzzwords. Use commas or separate sentences instead.
|
|
58
|
+
Walk each section once. Follow `.claude/standards/markdown.md` for punctuation and `.claude/standards/prose.md` for word choice throughout: no em dashes, no semicolons, no marketing buzzwords. Use commas or separate sentences instead.
|
|
58
59
|
|
|
59
60
|
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.
|
|
60
61
|
|
|
@@ -97,7 +97,7 @@ For each doc with relevant changes, apply updates following these rules. Read a
|
|
|
97
97
|
|
|
98
98
|
- Update only the sections affected by session decisions.
|
|
99
99
|
- Do not rewrite sections unrelated to what changed.
|
|
100
|
-
- Follow `.claude/standards/prose.md` for all edits.
|
|
100
|
+
- Follow `.claude/standards/prose.md` and `.claude/standards/markdown.md` for all edits.
|
|
101
101
|
|
|
102
102
|
Write each updated file immediately. Claude Code's tool permission dialog is the confirmation gate. Do not wait for user input.
|
|
103
103
|
|
|
@@ -23,7 +23,8 @@ Read in parallel from the project root, skipping any that do not exist:
|
|
|
23
23
|
- `CLAUDE.md`: Memory section rules, including save thresholds and file format overrides
|
|
24
24
|
- `.claude/memory/index.md`: existing index, to avoid duplicates
|
|
25
25
|
- `.claude/context/index.md`: the domain catalog Step 3 routes against
|
|
26
|
-
- `.claude/standards/prose.md`:
|
|
26
|
+
- `.claude/standards/prose.md`: voice and banned words applied to memory file bodies
|
|
27
|
+
- `.claude/standards/markdown.md`: punctuation and formatting applied to memory file bodies
|
|
27
28
|
|
|
28
29
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
29
30
|
|
|
@@ -9,6 +9,7 @@ description: Audits changed markdown files against every authoring standard that
|
|
|
9
9
|
|
|
10
10
|
- Resolve the base ref first, per Diff baseline below, then scope the file list exactly as Step 1 does, fallback included. If no markdown files changed, stop: `✅ No markdown changes to audit.` A guard that reads bare local `main`, or that skips the unusable-baseline fallback, passes the skill clean on a branch it never read.
|
|
11
11
|
- If neither `.claude/standards/prose.md` nor `${CLAUDE_SKILL_DIR}/../../standards/prose.md` is present, stop: `❌ prose.md standard not found. Install toolkit standards first.` Test the file rather than the directory, since a project that installed standards before a given file existed keeps the directory without ever receiving that file.
|
|
12
|
+
- Apply the same test to `markdown.md`, stopping with its own name. It carries the character bans and the formatting rules, so a run reaching only `prose.md` reports word choice against a clean file and calls the pass complete.
|
|
12
13
|
|
|
13
14
|
## Diff baseline
|
|
14
15
|
|
|
@@ -72,7 +73,7 @@ Read each applicable standard once. For each changed file, audit against every r
|
|
|
72
73
|
- **Pattern rules**: grep the file for every token the standard bans. Grep is authoritative. Reading alone misses occurrences.
|
|
73
74
|
- **Judgment rules**: check each rule in context against the standard that states it.
|
|
74
75
|
|
|
75
|
-
Every changed markdown file gets the prose pattern pass, since `.claude/standards/prose.md`
|
|
76
|
+
Every changed markdown file gets the prose pattern pass, since `.claude/standards/prose.md` and `.claude/standards/markdown.md` both apply to all of them. Take the banned tokens from those standards at read time rather than from a list held here. The banned words sit in the first and the banned characters in the second, so a pass reading one file finds half the tokens.
|
|
76
77
|
|
|
77
78
|
## Step 4: report
|
|
78
79
|
|
|
@@ -81,8 +82,9 @@ Group findings by file with line references, naming the standard each one comes
|
|
|
81
82
|
```markdown
|
|
82
83
|
path/to/file.md
|
|
83
84
|
|
|
84
|
-
- L12: `
|
|
85
|
-
- L34: `
|
|
85
|
+
- L12: `markdown.md`, em dash in prose
|
|
86
|
+
- L34: `markdown.md`, semicolon used to join clauses
|
|
87
|
+
- L51: `prose.md`, vague qualifier `simply`
|
|
86
88
|
- L67: `context.md`, decision entry names no rejected alternative
|
|
87
89
|
```
|
|
88
90
|
|
|
@@ -9,7 +9,8 @@ disable-model-invocation: true
|
|
|
9
9
|
Read these files from the project root in parallel:
|
|
10
10
|
|
|
11
11
|
- `.claude/standards/skill.md`: skill structure, skill types, frontmatter fields, invocation rules
|
|
12
|
-
- `.claude/standards/prose.md`:
|
|
12
|
+
- `.claude/standards/prose.md`: voice and banned words for skill body text
|
|
13
|
+
- `.claude/standards/markdown.md`: punctuation and formatting for skill body text
|
|
13
14
|
|
|
14
15
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
15
16
|
|
|
@@ -7,10 +7,11 @@ description: Creates a new snippet file in `snippets/` or `.claude/snippets/`. U
|
|
|
7
7
|
|
|
8
8
|
Creates one snippet file. Read these files in parallel:
|
|
9
9
|
|
|
10
|
-
- `.claude/standards/prose.md` from the project root:
|
|
10
|
+
- `.claude/standards/prose.md` from the project root: voice and banned words for all generated text
|
|
11
|
+
- `.claude/standards/markdown.md` from the project root: punctuation and formatting for all generated text
|
|
11
12
|
- `${CLAUDE_SKILL_DIR}/references/snippets.md`: authoring conventions, invocation channels, use patterns
|
|
12
13
|
|
|
13
|
-
Read `${CLAUDE_SKILL_DIR}/../../standards
|
|
14
|
+
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
14
15
|
|
|
15
16
|
## Guards
|
|
16
17
|
|
|
@@ -13,7 +13,8 @@ Governs a snippet file: what one is for, whether a prompt qualifies as one, how
|
|
|
13
13
|
Does not govern:
|
|
14
14
|
|
|
15
15
|
- Skill folders, which carry frontmatter, references, and scripts a snippet has none of: `skill.md`
|
|
16
|
-
- Voice
|
|
16
|
+
- Voice and word choice in snippet prose: `prose.md`
|
|
17
|
+
- Punctuation and formatting in snippet prose: `markdown.md`
|
|
17
18
|
|
|
18
19
|
## What a snippet is
|
|
19
20
|
|
|
@@ -7,7 +7,8 @@ description: Creates a new standard file in `standards/` or `.claude/standards/`
|
|
|
7
7
|
|
|
8
8
|
Creates one standard file. Read these files in parallel:
|
|
9
9
|
|
|
10
|
-
- `.claude/standards/prose.md` from the project root:
|
|
10
|
+
- `.claude/standards/prose.md` from the project root: voice and banned words for all generated text
|
|
11
|
+
- `.claude/standards/markdown.md` from the project root: punctuation and formatting for all generated text
|
|
11
12
|
- `.claude/standards/standard.md` from the project root: the meta-standard for shape, frontmatter, and structure
|
|
12
13
|
|
|
13
14
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
@@ -7,7 +7,8 @@ description: Rewrites stale `README.md` and `docs/*.md` sections based on change
|
|
|
7
7
|
|
|
8
8
|
Read these files from the project root in parallel:
|
|
9
9
|
|
|
10
|
-
- `.claude/standards/prose.md`:
|
|
10
|
+
- `.claude/standards/prose.md`: voice and banned words for all generated text
|
|
11
|
+
- `.claude/standards/markdown.md`: punctuation and formatting for all generated text
|
|
11
12
|
- `.claude/standards/readme.md`: README structure, required sections, and content rules
|
|
12
13
|
|
|
13
14
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
@@ -12,7 +12,8 @@ Format an issue from session context following the issue standard, then file it
|
|
|
12
12
|
Read these in parallel:
|
|
13
13
|
|
|
14
14
|
- `${CLAUDE_SKILL_DIR}/references/issue.md`: issue title, labels, body sections, and banned phrases
|
|
15
|
-
- `.claude/standards/prose.md` from the project root:
|
|
15
|
+
- `.claude/standards/prose.md` from the project root: voice and banned words for all generated text
|
|
16
|
+
- `.claude/standards/markdown.md` from the project root: punctuation and formatting for all generated text
|
|
16
17
|
|
|
17
18
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
18
19
|
|
|
@@ -14,7 +14,8 @@ Does not govern:
|
|
|
14
14
|
|
|
15
15
|
- Pull request title and body: `pr.md`
|
|
16
16
|
- Whether a phase label may appear in issue text: `versioning.md`
|
|
17
|
-
- Voice
|
|
17
|
+
- Voice and banned words in issue prose: `prose.md`
|
|
18
|
+
- Punctuation and formatting in issue prose: `markdown.md`
|
|
18
19
|
|
|
19
20
|
## Title
|
|
20
21
|
|
|
@@ -11,7 +11,8 @@ Read these files in parallel:
|
|
|
11
11
|
|
|
12
12
|
- `${CLAUDE_SKILL_DIR}/references/branch.md`: branch format, valid types, and constraints
|
|
13
13
|
- `${CLAUDE_SKILL_DIR}/references/pr.md`: structure, rules, and banned phrases
|
|
14
|
-
- `.claude/standards/prose.md` from the project root:
|
|
14
|
+
- `.claude/standards/prose.md` from the project root: voice and banned words for all generated text
|
|
15
|
+
- `.claude/standards/markdown.md` from the project root: punctuation and formatting for all generated text
|
|
15
16
|
- `.claude/standards/versioning.md` from the project root: phase label vs semver discipline
|
|
16
17
|
|
|
17
18
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
@@ -15,7 +15,8 @@ Does not govern:
|
|
|
15
15
|
- Commit subject format, which shares the title form: `commit.md`
|
|
16
16
|
- Branch naming: `branch.md`
|
|
17
17
|
- Whether a phase label or a semver tag may appear in a title or body: `versioning.md`
|
|
18
|
-
- Voice
|
|
18
|
+
- Voice and banned words in pull request prose: `prose.md`
|
|
19
|
+
- Punctuation and formatting in pull request prose: `markdown.md`
|
|
19
20
|
|
|
20
21
|
## Title
|
|
21
22
|
|
|
@@ -15,7 +15,8 @@ Does not govern:
|
|
|
15
15
|
- Commit subject format, which shares the title form: `commit.md`
|
|
16
16
|
- Branch naming: `branch.md`
|
|
17
17
|
- Whether a phase label or a semver tag may appear in a title or body: `versioning.md`
|
|
18
|
-
- Voice
|
|
18
|
+
- Voice and banned words in pull request prose: `prose.md`
|
|
19
|
+
- Punctuation and formatting in pull request prose: `markdown.md`
|
|
19
20
|
|
|
20
21
|
## Title
|
|
21
22
|
|
|
@@ -8,7 +8,8 @@ description: Groups staged files by concern and generates one conventional commi
|
|
|
8
8
|
Read these files in parallel:
|
|
9
9
|
|
|
10
10
|
- `${CLAUDE_SKILL_DIR}/references/commit.md`: format, types, scopes, and constraints
|
|
11
|
-
- `.claude/standards/prose.md` from the project root:
|
|
11
|
+
- `.claude/standards/prose.md` from the project root: voice and banned words for all generated text
|
|
12
|
+
- `.claude/standards/markdown.md` from the project root: punctuation and formatting for all generated text
|
|
12
13
|
|
|
13
14
|
Read a standard from `${CLAUDE_SKILL_DIR}/../../standards/` instead when the project does not have it.
|
|
14
15
|
|
|
@@ -13,7 +13,9 @@ The required-section check reports what does not declare `## Overview` and `## L
|
|
|
13
13
|
|
|
14
14
|
Which unit answers depends on the folder. Entries of the folder named under `.claude/` are one domain each, so each answers for itself and a finding names the entry. Entries of a folder a domain split into describe that one domain between them, so any sibling answers and a finding names the folder. Holding a split folder to the rule per file would report every child beside its `overview.md`, and rolling the named folder up would let one conforming entry stand in for every other domain sitting next to it.
|
|
15
15
|
|
|
16
|
-
It reports rather than gates, the closer call because a missing section reads more like a fact than the other judgments. What settles it is that the standard sanctions omitting `## Layout` from a domain owning no paths in the repo, and no measure separates that from an entry that forgot it. A domain covering only external tools is that case, and it reports on every run. The JSON record carries the findings as `missingSections` and the list as `checkpoints.requiredSections`.
|
|
16
|
+
It reports rather than gates by default, the closer call because a missing section reads more like a fact than the other judgments. What settles it is that the standard sanctions omitting `## Layout` from a domain owning no paths in the repo, and no measure separates that from an entry that forgot it. A domain covering only external tools is that case, and it reports on every run. The JSON record carries the findings as `missingSections` and the list as `checkpoints.requiredSections`.
|
|
17
|
+
|
|
18
|
+
`--gate` promotes the finding to a failing exit code, which the seed stage runs and no other caller does. That mode needs an answer to the sanctioned omission above, so a file declaring `stub: true` in its frontmatter is dropped before the check and reported nowhere. Both are described in `context-audit.md`.
|
|
17
19
|
|
|
18
20
|
## Length and depth
|
|
19
21
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Context audit
|
|
3
|
-
description: Running the audit, its flags and folder scope, the exit codes,
|
|
3
|
+
description: Running the audit, its flags and folder scope, the exit codes, the citation gate, and the widened gate the seed stage runs
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Context audit
|
|
@@ -13,6 +13,7 @@ aitk context audit --json
|
|
|
13
13
|
aitk context audit --citations-only
|
|
14
14
|
aitk context audit --folder context,diagrams
|
|
15
15
|
aitk context audit --folder docs
|
|
16
|
+
aitk context audit tooling/base/seeds --gate
|
|
16
17
|
```
|
|
17
18
|
|
|
18
19
|
| Option | Behavior |
|
|
@@ -20,6 +21,9 @@ aitk context audit --folder docs
|
|
|
20
21
|
| `--json` | Add a machine-readable record on stdout, keeping the frame |
|
|
21
22
|
| `--folder <list>` | Comma-separated folder names (default: the three below) |
|
|
22
23
|
| `--citations-only` | Run the gating citation check alone, printing nothing when it passes |
|
|
24
|
+
| `--gate` | Fail on a missing required section or index drift as well |
|
|
25
|
+
|
|
26
|
+
`--citations-only` and `--gate` refuse together. The first runs the citation check alone, so the two findings the second adds are never measured, and a run honoring both would exit clean on a file short a required section.
|
|
23
27
|
|
|
24
28
|
## Folder scope
|
|
25
29
|
|
|
@@ -31,7 +35,36 @@ A run where no requested name resolves refuses, whichever list it read. Naming t
|
|
|
31
35
|
|
|
32
36
|
## Exit codes
|
|
33
37
|
|
|
34
|
-
Exit codes are `0` for a clean run, `1` for a refusal, and `2` for
|
|
38
|
+
Exit codes are `0` for a clean run, `1` for a refusal, and `2` for a gating finding. An unresolved citation gates under every mode. Length, depth, bullet weight, table, and provenance findings print and return `0` under every mode, because each is a judgment and failing a push on one would make the check something to route around.
|
|
39
|
+
|
|
40
|
+
Required-section and index findings sit between the two. Both are answerable from the file rather than weighed, so `--gate` promotes them to failing codes while a bare run leaves them advisory. The toolkit runs the bare form against itself and the widened form against the seed tree, described below.
|
|
41
|
+
|
|
42
|
+
## The seed gate
|
|
43
|
+
|
|
44
|
+
`bun run check` runs `--gate` against every `tooling/<stack>/seeds/` directory carrying a `.claude/` folder, discovered per run so a new stack is covered without a script edit. The seed tree installs into every scaffolded project, so a seed breaking the standard it seeds teaches the wrong shape to each one, and no rule path reaches the tree to report it.
|
|
45
|
+
|
|
46
|
+
The widened gate is correct here and wrong at the project root. A seed is authored once and read by every target, while a context entry in a live project is edited under time pressure by the people who own it. A missing section in the first is a defect shipping outward, and in the second it is a threshold worth reporting and not worth blocking a push over.
|
|
47
|
+
|
|
48
|
+
Coverage follows the index-plus-entry contract, so it reaches seeded entries and the indexes beside them. Seed files sitting directly under `.claude/`, currently `ARCHITECTURE.md`, `DESIGN.md`, and `REQUIREMENTS.md`, belong to no audited folder and stay outside it.
|
|
49
|
+
|
|
50
|
+
The stage prints the entries it measured per root and warns on a root that measured none. A root can resolve an audited folder and hold no entry in it, which `tooling/claude/seeds` does today, so a single pass line over the set would report coverage of a tree nothing opened.
|
|
51
|
+
|
|
52
|
+
It reads the exit code rather than pass against fail, since the two failing codes mean opposite things. A root carrying a `.claude/` that resolves no audited folder refuses at 1 and warns, while a seed short a required section gates at 2 and fails the push. A new stack seeding `.claude/` alone therefore reports what it is rather than a violation it does not have.
|
|
53
|
+
|
|
54
|
+
### Exempting a skeleton
|
|
55
|
+
|
|
56
|
+
A seed that deliberately omits a required section sets `stub: true` in its frontmatter, and the section check then skips it. Every other measure still reads the file, since a stub is exempt from owing sections rather than from being well formed.
|
|
57
|
+
|
|
58
|
+
```markdown
|
|
59
|
+
---
|
|
60
|
+
title: Architecture
|
|
61
|
+
stub: true
|
|
62
|
+
---
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Only `true` counts. A field holding anything else reads as a seed that meant to turn the exemption off, so a typo cannot silence the gate. Both install paths strip the field on the way into a target, which keeps toolkit bookkeeping out of a project whose own tooling would never read it. A block holding nothing else is dropped whole.
|
|
66
|
+
|
|
67
|
+
The exemption exists because the section check has a false-positive class. A standard may sanction omitting a section, and no measure separates that from a file that forgot it, which is why the finding stays advisory everywhere the widened gate is not running. No seed sets the field today.
|
|
35
68
|
|
|
36
69
|
## The citation gate
|
|
37
70
|
|
package/docs/agents/index.md
CHANGED
|
@@ -12,7 +12,7 @@ CLI catalog and invocation rules for agents, split by command domain. Start with
|
|
|
12
12
|
- [Command catalog](commands.md): Every project-level command and every domain subcommand, plus the shape each domain exposes
|
|
13
13
|
- [Comments](comments.md): Comment density by language and kind, the two structural exclusions, and how the degradation sweep finds its vocabulary
|
|
14
14
|
- [Context audit checks](context-audit-checks.md): What each non-gating check reports, the unit each checkpoint is measured in, and which folders each check reaches
|
|
15
|
-
- [Context audit](context-audit.md): Running the audit, its flags and folder scope, the exit codes,
|
|
15
|
+
- [Context audit](context-audit.md): Running the audit, its flags and folder scope, the exit codes, the citation gate, and the widened gate the seed stage runs
|
|
16
16
|
- [Docs](docs.md): How aitk docs resolves the toolkit's own reference surface from an install root, and how a split domain is named
|
|
17
17
|
- [Indexes](indexes.md): Flags, exit codes, and JSON shape for aitk indexes regen, plus when it auto-stages what it rewrote
|
|
18
18
|
- [Install and sync](install-and-sync.md): What each install and sync verb writes, refuses, or leaves alone, and how drift is attributed in a target project
|
|
@@ -144,6 +144,12 @@ needs a stamp and seeds carry none, so a file history cannot attribute stays
|
|
|
144
144
|
`drifted`. Reconcile the section with `claude-seed-sync`, which merges one
|
|
145
145
|
section at a time rather than replacing a file the project edits.
|
|
146
146
|
|
|
147
|
+
A markdown seed installs rewritten rather than copied, since the `stub: true`
|
|
148
|
+
marker the toolkit's own seed gate reads is stripped on the way in. The
|
|
149
|
+
comparison above runs against what the install would write, so a marked seed a
|
|
150
|
+
target never touched still reports `matching`. Every other seed copies byte for
|
|
151
|
+
byte.
|
|
152
|
+
|
|
147
153
|
`superseded` names a file a newer seed folder replaced, such as `.claude/TASKS.md`
|
|
148
154
|
against the `.claude/tasks/` that now ships. The entry carries `replacedBy` and
|
|
149
155
|
nothing else, and the file is never deleted, since the content belongs to the
|
package/docs/ai-workflow.md
CHANGED
|
@@ -76,7 +76,7 @@ Run one orchestrator at a time. The board is gitignored, so a second session rea
|
|
|
76
76
|
|
|
77
77
|
Before a handoff, the orchestrator checks the plan against the tree rather than reading it: grep each construct it names and count the sites, confirm every phase label it cites is still open, and open each file it describes. A plan goes stale from whatever merged after it was written, and reading cannot catch that.
|
|
78
78
|
|
|
79
|
-
`.claude/plans/`, `.claude/review/`, and `.claude/memory/` all resolve at the main worktree root, so artifacts created in any session are visible from any sibling worktree. See [Claude Code and git worktrees](../wiki/claude-worktrees.md) for the full rule and the domain-level fan-out guidance.
|
|
79
|
+
`.claude/plans/`, `.claude/review/`, and `.claude/memory/` all resolve at the main worktree root, so artifacts created in any session are visible from any sibling worktree. See [Claude Code and git worktrees](../wiki/claude/claude-worktrees.md) for the full rule and the domain-level fan-out guidance.
|
|
80
80
|
|
|
81
81
|
A plan that ships is archived, never deleted. `aitk:claude-docs` moves it to `.claude/plans-archive/` and retargets the task file's `Plan:` line at the new location, so a completed task still leads to the reasoning behind it. Both folders are gitignored, which is why a deleted plan had no recovery path. A plan cited by more than one task stays put until the last of them closes, since moving it early would strand every other pointer.
|
|
82
82
|
|
package/docs/operating-model.md
CHANGED
|
@@ -10,7 +10,7 @@ A way to build fast and reliably across parallel Claude Code sessions without a
|
|
|
10
10
|
loop and without losing the human review gate. One warm session plans and
|
|
11
11
|
reviews. Cold worker sessions build. The human launches workers and merges. This
|
|
12
12
|
page covers the roles and the loop. For the worktree mechanism (isolation, merge
|
|
13
|
-
order, port collisions), see [Claude Code and git worktrees](../wiki/claude-worktrees.md).
|
|
13
|
+
order, port collisions), see [Claude Code and git worktrees](../wiki/claude/claude-worktrees.md).
|
|
14
14
|
|
|
15
15
|
## Two roles
|
|
16
16
|
|
|
@@ -105,11 +105,11 @@ at two or three worker tracks and split them across the stack so they do not
|
|
|
105
105
|
collide on the same files. Unit checks run freely in many worktrees at once.
|
|
106
106
|
Only fixed-port work (a dev server, an end-to-end run, a screenshot) and
|
|
107
107
|
singleton resources (one local model server, one GPU) serialize. See
|
|
108
|
-
[Claude Code and git worktrees](../wiki/claude-worktrees.md) for merge order and the
|
|
108
|
+
[Claude Code and git worktrees](../wiki/claude/claude-worktrees.md) for merge order and the
|
|
109
109
|
port-collision detail.
|
|
110
110
|
|
|
111
111
|
## Related
|
|
112
112
|
|
|
113
|
-
- [Claude Code and git worktrees](../wiki/claude-worktrees.md) for the isolation and fan-out mechanics
|
|
114
|
-
- [Claude Code subagents](../wiki/claude-subagents.md) for in-session parallelism without worktrees
|
|
113
|
+
- [Claude Code and git worktrees](../wiki/claude/claude-worktrees.md) for the isolation and fan-out mechanics
|
|
114
|
+
- [Claude Code subagents](../wiki/claude/claude-subagents.md) for in-session parallelism without worktrees
|
|
115
115
|
- `.claude/context/claude-plugin/skill-strategy.md` for how the skills in the loop are categorized
|
|
@@ -8,9 +8,9 @@ category: Workflow
|
|
|
8
8
|
|
|
9
9
|
Three tiers cover the range from prose-only design docs to a fully graphical design source of truth. Pick one per project based on how UI-heavy the work is, whether stakeholders review visuals, and whether a designer is involved. Tiers stack, so moving up does not invalidate work done at a lower tier.
|
|
10
10
|
|
|
11
|
-
The tier framework sits alongside [Claude Design](../wiki/claude-design.md), [visual wireframes](../wiki/visual-wireframes.md), [community skills and plugins](../wiki/community-skills.md), and [community MCP servers](../wiki/community-mcp-servers.md). Those pages catalog the tooling. This page decides when to reach for what.
|
|
11
|
+
The tier framework sits alongside [Claude Design](../wiki/claude/claude-design.md), [visual wireframes](../wiki/tools/visual-wireframes.md), [community skills and plugins](../wiki/tools/community-skills.md), and [community MCP servers](../wiki/tools/community-mcp-servers.md). Those pages catalog the tooling. This page decides when to reach for what.
|
|
12
12
|
|
|
13
|
-
Two tools anchor tier 1 and tier 2. [Stitch](../wiki/stitch.md) is the agent-addressable default through its MCP server at `stitch.googleapis.com/mcp`, with a free tier of 400 daily credits that covers daily iteration. [Claude Design](../wiki/claude-design.md), released 2026-04-17 and priced inside Claude subscriptions, is the ceiling tool reserved for codebase extraction and the richly annotated handoff bundle. Each covers a different job, they are not swappable.
|
|
13
|
+
Two tools anchor tier 1 and tier 2. [Stitch](../wiki/tools/stitch.md) is the agent-addressable default through its MCP server at `stitch.googleapis.com/mcp`, with a free tier of 400 daily credits that covers daily iteration. [Claude Design](../wiki/claude/claude-design.md), released 2026-04-17 and priced inside Claude subscriptions, is the ceiling tool reserved for codebase extraction and the richly annotated handoff bundle. Each covers a different job, they are not swappable.
|
|
14
14
|
|
|
15
15
|
## Tier 0: prose only
|
|
16
16
|
|
|
@@ -51,16 +51,16 @@ Impeccable, if installed, keeps its own root `DESIGN.md` and `PRODUCT.md` in the
|
|
|
51
51
|
|
|
52
52
|
### Tools
|
|
53
53
|
|
|
54
|
-
- Stitch via MCP at `stitch.googleapis.com/mcp`. Default pick for agent-driven visual generation. Free tier of 400 daily credits. See [Stitch](../wiki/stitch.md).
|
|
55
|
-
- Excalidraw canvas server on localhost plus the `yctimlin/mcp_excalidraw` MCP shim, for projects that need an agent to draw, read back, and revise a canvas. See [visual wireframes](../wiki/visual-wireframes.md) for setup and footguns.
|
|
56
|
-
- Playwright MCP for browser-side verification. See [Playwright](../wiki/community-mcp-servers.md#playwright-microsoft).
|
|
57
|
-
- Chrome DevTools MCP for live frontend debugging. See [Chrome DevTools](../wiki/community-mcp-servers.md#chrome-devtools-google).
|
|
58
|
-
- Claude Design as the ceiling option for codebase extraction or polished handoff bundles. See [Claude Design](../wiki/claude-design.md).
|
|
54
|
+
- Stitch via MCP at `stitch.googleapis.com/mcp`. Default pick for agent-driven visual generation. Free tier of 400 daily credits. See [Stitch](../wiki/tools/stitch.md).
|
|
55
|
+
- Excalidraw canvas server on localhost plus the `yctimlin/mcp_excalidraw` MCP shim, for projects that need an agent to draw, read back, and revise a canvas. See [visual wireframes](../wiki/tools/visual-wireframes.md) for setup and footguns.
|
|
56
|
+
- Playwright MCP for browser-side verification. See [Playwright](../wiki/tools/community-mcp-servers.md#playwright-microsoft).
|
|
57
|
+
- Chrome DevTools MCP for live frontend debugging. See [Chrome DevTools](../wiki/tools/community-mcp-servers.md#chrome-devtools-google).
|
|
58
|
+
- Claude Design as the ceiling option for codebase extraction or polished handoff bundles. See [Claude Design](../wiki/claude/claude-design.md).
|
|
59
59
|
|
|
60
60
|
### Skills
|
|
61
61
|
|
|
62
62
|
- Everything from tier 0
|
|
63
|
-
- A frontend design skill to steer visual quality. Pick one of [Impeccable](../wiki/community-skills.md#pbakausimpeccable), [UI/UX Pro Max](../wiki/community-skills.md#nextlevelbuilderui-ux-pro-max-skill), or Anthropic's `frontend-design` plugin. Impeccable is the strongest default because of its curated anti-patterns.
|
|
63
|
+
- A frontend design skill to steer visual quality. Pick one of [Impeccable](../wiki/tools/community-skills.md#pbakausimpeccable), [UI/UX Pro Max](../wiki/tools/community-skills.md#nextlevelbuilderui-ux-pro-max-skill), or Anthropic's `frontend-design` plugin. Impeccable is the strongest default because of its curated anti-patterns.
|
|
64
64
|
|
|
65
65
|
### When to pick
|
|
66
66
|
|
|
@@ -91,9 +91,9 @@ Design happens in a graphical tool. `.claude/DESIGN.md` either regenerates from
|
|
|
91
91
|
|
|
92
92
|
### Tools
|
|
93
93
|
|
|
94
|
-
- Figma desktop app with the [Figma Dev Mode MCP](../wiki/community-skills.md#figma-mcp-and-code-to-canvas) for teams with a dedicated designer already on Figma. Bidirectional sync and Code to Canvas capture.
|
|
95
|
-
- Claude Design with its Claude Code handoff bundle for teams without an existing Figma investment and for solo founders or PMs driving design themselves. One-way handoff, no bidirectional sync. See [Claude Design](../wiki/claude-design.md).
|
|
96
|
-
- Stitch via MCP as a low-cost complement to either, used for bulk screen generation driven by Claude Code. See [Stitch](../wiki/stitch.md).
|
|
94
|
+
- Figma desktop app with the [Figma Dev Mode MCP](../wiki/tools/community-skills.md#figma-mcp-and-code-to-canvas) for teams with a dedicated designer already on Figma. Bidirectional sync and Code to Canvas capture.
|
|
95
|
+
- Claude Design with its Claude Code handoff bundle for teams without an existing Figma investment and for solo founders or PMs driving design themselves. One-way handoff, no bidirectional sync. See [Claude Design](../wiki/claude/claude-design.md).
|
|
96
|
+
- Stitch via MCP as a low-cost complement to either, used for bulk screen generation driven by Claude Code. See [Stitch](../wiki/tools/stitch.md).
|
|
97
97
|
- Playwright and Chrome DevTools MCPs as in tier 1
|
|
98
98
|
|
|
99
99
|
### Skills
|
|
@@ -128,9 +128,9 @@ Zero or one yes: tier 0. Two or three: tier 1. Four: tier 2. Resist over-tiering
|
|
|
128
128
|
|
|
129
129
|
## References
|
|
130
130
|
|
|
131
|
-
- [Stitch](../wiki/stitch.md): Gemini-powered design product with the MCP server that anchors tier 1
|
|
132
|
-
- [Claude Design](../wiki/claude-design.md): first-party hosted design product and handoff bundle
|
|
131
|
+
- [Stitch](../wiki/tools/stitch.md): Gemini-powered design product with the MCP server that anchors tier 1
|
|
132
|
+
- [Claude Design](../wiki/claude/claude-design.md): first-party hosted design product and handoff bundle
|
|
133
133
|
- `.claude/context/claude-plugin/skill-strategy.md`: how to decide between workflow and domain-knowledge skills
|
|
134
|
-
- [Visual wireframes](../wiki/visual-wireframes.md): Excalidraw research and setup for the tier 1 wireframe companion
|
|
135
|
-
- [Community skills and plugins](../wiki/community-skills.md): catalog of frontend design skills and integrations
|
|
136
|
-
- [Community MCP servers](../wiki/community-mcp-servers.md): catalog of MCPs referenced across all tiers
|
|
134
|
+
- [Visual wireframes](../wiki/tools/visual-wireframes.md): Excalidraw research and setup for the tier 1 wireframe companion
|
|
135
|
+
- [Community skills and plugins](../wiki/tools/community-skills.md): catalog of frontend design skills and integrations
|
|
136
|
+
- [Community MCP servers](../wiki/tools/community-mcp-servers.md): catalog of MCPs referenced across all tiers
|
package/docs/zshrc-aliases.md
CHANGED
|
@@ -56,7 +56,7 @@ Use `clp` in any other repository where you want the toolkit skills available. W
|
|
|
56
56
|
|
|
57
57
|
Use `cls` or `clps` to save Opus usage on routine sessions. Switch mid-session with `/model` to avoid restarting.
|
|
58
58
|
|
|
59
|
-
Use `clw <name>` for features that will take more than one session. A worktree isolates the branch, the transcripts, and the `/resume` history. See [Claude Code and git worktrees](../wiki/claude-worktrees.md) for fan-out rules.
|
|
59
|
+
Use `clw <name>` for features that will take more than one session. A worktree isolates the branch, the transcripts, and the `/resume` history. See [Claude Code and git worktrees](../wiki/claude/claude-worktrees.md) for fan-out rules.
|
|
60
60
|
|
|
61
61
|
Use `clc` to resume the last session without a picker. Use `clr` when you have several sessions and need to pick by name or recency. Outside the toolkit repo, `clpc` is the same shortcut as `clc` with the plugin loaded.
|
|
62
62
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Route markdown edits to the prose standard for voice,
|
|
2
|
+
description: Route markdown edits to the prose standard for voice, language, and frontmatter wording
|
|
3
3
|
paths:
|
|
4
4
|
- '**/*.md'
|
|
5
5
|
---
|
|
@@ -8,5 +8,6 @@ paths:
|
|
|
8
8
|
|
|
9
9
|
## Authority
|
|
10
10
|
|
|
11
|
-
- Follow `.claude/standards/prose.md` for
|
|
12
|
-
- Read it before a substantial prose edit. Do not work the
|
|
11
|
+
- Follow `.claude/standards/prose.md` for voice, language, and the wording of a `title` or `description`. It is the single source.
|
|
12
|
+
- Read it before a substantial prose edit. Do not work the banned words from memory.
|
|
13
|
+
- Punctuation, formatting, and file references are a separate topic. `501-markdown` routes them.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Route markdown edits to the markdown standard for headings, lists, punctuation, and file references
|
|
3
|
+
paths:
|
|
4
|
+
- '**/*.md'
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Markdown mechanics standards
|
|
8
|
+
|
|
9
|
+
## Authority
|
|
10
|
+
|
|
11
|
+
- Follow `.claude/standards/markdown.md` for headings, paragraph and list structure, code spans, punctuation, emphasis, and file references. It is the single source.
|
|
12
|
+
- Read it before a substantial markdown edit. Do not work the banned characters from memory.
|
|
13
|
+
- Voice, language, and frontmatter wording are a separate topic. `500-prose` routes them.
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
extends = ""
|
|
2
|
-
rules = ["000-constitution", "010-testing", "020-concurrency", "030-error-handling", "040-performance", "050-logging", "060-naming", "070-planning", "080-config-comments", "090-code-comments", "500-prose", "510-context", "520-wireframes", "530-requirements", "540-architecture", "550-design", "555-tasks", "560-diagrams", "570-skill", "580-readme", "590-rule-authoring", "591-standard-authoring"]
|
|
2
|
+
rules = ["000-constitution", "010-testing", "020-concurrency", "030-error-handling", "040-performance", "050-logging", "060-naming", "070-planning", "080-config-comments", "090-code-comments", "500-prose", "501-markdown", "510-context", "520-wireframes", "530-requirements", "540-architecture", "550-design", "555-tasks", "560-diagrams", "570-skill", "580-readme", "590-rule-authoring", "591-standard-authoring"]
|
package/package.json
CHANGED
|
@@ -79,7 +79,7 @@ log_step "Assert scaffold"
|
|
|
79
79
|
# The snippets path has to name a slug the default preset still carries, since
|
|
80
80
|
# init resolves snippets through `essentials`. Editing that preset without
|
|
81
81
|
# editing this line fails the gate on a correct install.
|
|
82
|
-
for path in "CLAUDE.md" ".claude/snippets/decision-help.md" ".claude/standards/prose.md" ".claude/wiki/index.md" ".claude" ".claude/context/index.md" ".claude/wireframes/index.md" ".claude/diagrams/index.md" \
|
|
82
|
+
for path in "CLAUDE.md" ".claude/snippets/decision-help.md" ".claude/standards/prose.md" ".claude/standards/markdown.md" ".claude/wiki/index.md" ".claude" ".claude/context/index.md" ".claude/wireframes/index.md" ".claude/diagrams/index.md" \
|
|
83
83
|
".prettierrc" ".editorconfig" ".lintstagedrc" ".husky/pre-commit" ".github/workflows/verify.yml" "scripts/verify.sh" \
|
|
84
84
|
".claude/rules/core/000-constitution.md"; do
|
|
85
85
|
if [ ! -e "$TARGET_DIR/$path" ]; then
|
package/scripts/core/verify.sh
CHANGED
|
@@ -116,6 +116,28 @@ assert_hero_pair() {
|
|
|
116
116
|
[ "$html_commit" = "$png_commit" ]
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
+
# Whatever stacks the repo currently carries, so a new one is covered without an
|
|
120
|
+
# edit here. A seed root holding no `.claude/` seeds nothing a standard governs.
|
|
121
|
+
collect_seed_roots() {
|
|
122
|
+
local dir
|
|
123
|
+
for dir in "$PROJECT_ROOT"/tooling/*/seeds; do
|
|
124
|
+
[ -d "$dir/.claude" ] || continue
|
|
125
|
+
printf '%s\n' "${dir#"$PROJECT_ROOT"/}"
|
|
126
|
+
done
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
# Entries the audit actually measured, summed across the folders it resolved.
|
|
130
|
+
# `--json` carries one `"entries":<n>` per folder object, and the top-level key
|
|
131
|
+
# of that name holds an array, so the numeric match reaches folders alone.
|
|
132
|
+
#
|
|
133
|
+
# A root can resolve a folder and measure nothing in it, which is a passing gate
|
|
134
|
+
# over an empty set. The stage prints this per root rather than reporting one
|
|
135
|
+
# verdict for every root, or a tree nobody measured reads as a tree that passed.
|
|
136
|
+
seed_entry_count() {
|
|
137
|
+
printf '%s' "$1" | grep -o '"entries":[0-9]\+' | grep -o '[0-9]\+' |
|
|
138
|
+
awk '{ total += $1 } END { print total + 0 }'
|
|
139
|
+
}
|
|
140
|
+
|
|
119
141
|
assert_no_drift() {
|
|
120
142
|
local paths=$1
|
|
121
143
|
local err_msg=$2
|
|
@@ -183,6 +205,67 @@ main() {
|
|
|
183
205
|
run_check "cd $PROJECT_ROOT && bun src/cli.ts context audit --citations-only" "A cited context path does not resolve. Run bun src/cli.ts context audit."
|
|
184
206
|
log_info "Context citations resolve"
|
|
185
207
|
|
|
208
|
+
# The stage above audits this repository. Its seed tree ships into every
|
|
209
|
+
# scaffolded project, so a seed breaking the standard it seeds propagates
|
|
210
|
+
# instead of sitting still, and no rule path reaches the tree to report it.
|
|
211
|
+
# `--gate` fails on the two findings beside citations that are facts, a
|
|
212
|
+
# missing required section and index drift, and leaves the thresholds
|
|
213
|
+
# advisory for the reason the stage above leaves them so. A passing run stays
|
|
214
|
+
# silent because the audit prints a frame that would nest inside this one.
|
|
215
|
+
log_step "Seed standards"
|
|
216
|
+
local seed_roots seed_root seed_output seed_frame seed_entries seed_measured seed_status
|
|
217
|
+
seed_roots=$(collect_seed_roots)
|
|
218
|
+
if [ -z "$seed_roots" ]; then
|
|
219
|
+
log_info "Skipped, no seed root carries .claude/"
|
|
220
|
+
else
|
|
221
|
+
seed_measured=0
|
|
222
|
+
while IFS= read -r seed_root; do
|
|
223
|
+
# `--json` puts the record on stdout and the frame on stderr, so the
|
|
224
|
+
# passing run stays silent and the failing one is re-run for its frame
|
|
225
|
+
# rather than parsed out of a stream this script would have to strip.
|
|
226
|
+
seed_status=0
|
|
227
|
+
seed_output=$(cd "$PROJECT_ROOT" && bun src/cli.ts context audit "$seed_root" --gate --json 2>/dev/null) || seed_status=$?
|
|
228
|
+
|
|
229
|
+
# The audit separates 1 from 2 and they mean opposite things. 2 is a seed
|
|
230
|
+
# breaking the standard it seeds. 1 is the audit refusing, which a seed
|
|
231
|
+
# root carrying no audited folder produces, and reporting that as a
|
|
232
|
+
# violation sends a reader hunting one that does not exist. Discovery is
|
|
233
|
+
# what puts this in reach, since a new stack seeding `.claude/` alone
|
|
234
|
+
# arrives here with no edit to this script.
|
|
235
|
+
case $seed_status in
|
|
236
|
+
0) ;;
|
|
237
|
+
1)
|
|
238
|
+
log_warn "$seed_root: no audited folder under .claude/, nothing measured"
|
|
239
|
+
continue
|
|
240
|
+
;;
|
|
241
|
+
*)
|
|
242
|
+
# `|| true` because the re-run exits non-zero by construction, and
|
|
243
|
+
# `set -e` would take the script down before log_error names the root.
|
|
244
|
+
seed_frame=$(cd "$PROJECT_ROOT" && bun src/cli.ts context audit "$seed_root" --gate 2>&1 || true)
|
|
245
|
+
echo "$seed_frame" | pipe_output
|
|
246
|
+
if [ "$seed_status" -eq 2 ]; then
|
|
247
|
+
log_error "A seed breaks the standard governing the folder it seeds: $seed_root"
|
|
248
|
+
else
|
|
249
|
+
log_error "The seed audit exited $seed_status against $seed_root, which is neither a pass nor a finding."
|
|
250
|
+
fi
|
|
251
|
+
;;
|
|
252
|
+
esac
|
|
253
|
+
|
|
254
|
+
seed_entries=$(seed_entry_count "$seed_output")
|
|
255
|
+
seed_measured=$((seed_measured + seed_entries))
|
|
256
|
+
|
|
257
|
+
if [ "$seed_entries" -eq 0 ]; then
|
|
258
|
+
log_warn "$seed_root: no entry under an audited folder, nothing measured"
|
|
259
|
+
else
|
|
260
|
+
log_info "$seed_root: $seed_entries entries measured"
|
|
261
|
+
fi
|
|
262
|
+
done <<<"$seed_roots"
|
|
263
|
+
|
|
264
|
+
if [ "$seed_measured" -eq 0 ]; then
|
|
265
|
+
log_warn "No seed entry was measured. The stage covered nothing."
|
|
266
|
+
fi
|
|
267
|
+
fi
|
|
268
|
+
|
|
186
269
|
# Presence of a required file is a fact, so it gates. The name, description,
|
|
187
270
|
# folder, and requirement-section measures beside it report and are read from a
|
|
188
271
|
# bare run. `bun src/cli.ts` for the reason the stage above uses it, and the
|