task-pipeline-skill 1.9.0 → 1.10.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/CHANGELOG.md CHANGED
@@ -1,5 +1,96 @@
1
1
  # Changelog
2
2
 
3
+ ## v1.10.0 — 2026-08-03
4
+
5
+ ### Added — the entry audit, and a boundary that keeps the workflow portable
6
+
7
+ **`references/setup.md` — the audit that runs *before* the feature.** The ladder in
8
+ `audit.md` runs at the end of a run, over the change; nothing ran at the start, over
9
+ the documentation a project already has. Seven passes, cheapest first — one decision
10
+ home, register integrity, propagation (ratcheted), the matrix's *Checked by* column,
11
+ declared terms, the UX chain, and the gate itself proven against a planted defect.
12
+ Findings carry `file:line`, the minimal fix and **the seam they belong to**, ordered
13
+ by seam rather than by file, because a file-ordered list reads as noise and a
14
+ seam-ordered one names the layer of the project's own process that is leaking. It
15
+ ends in a fix plan, not a lecture, and it **fixes nothing while reading** — that is
16
+ how a pass starts finding its own edits.
17
+
18
+ **Offered once, never imposed.** Stage 0 asks when the doc map is absent or stale;
19
+ the answer, including a refusal, is recorded in the brief and never asked again. A
20
+ check that runs before every feature is a check people learn to dismiss.
21
+
22
+ **`references/portability.md` — the boundary the whole bundle rests on.** A decision
23
+ about *how the pipeline behaves* belongs in the bundle; a decision about *what this
24
+ project decided* belongs in the project. Get it backwards and one of two quiet
25
+ failures follows: an optimisation stranded in one repository, or a skill that has
26
+ learned one project's answers and stopped being project-agnostic.
27
+
28
+ It ships a **manifest** — every workflow decision with its home inside the bundle —
29
+ and a guard that resolves every path. And it names both directions, because a
30
+ comparison needs two sides: *outward*, does every workflow decision have a home here;
31
+ *inward*, is this project holding a rule that would be true in a repository nobody
32
+ has seen. The inward test is one line — **does the rule name a path, a command or a
33
+ person?** If not, it is the bundle's, and keeping it local costs every future project.
34
+
35
+ **The routing rule now travels.** It was hand-installed into an operator's config
36
+ last release, which made it the one workflow decision living outside the bundle —
37
+ neither installer touches any `CLAUDE.md`. It ships as `templates/routing-rule.md`,
38
+ and `setup` **offers** to append it. Offers, never writes: it is the operator's
39
+ configuration.
40
+
41
+ ### Added — three smaller things the same run asked for
42
+
43
+ - **Self-currency.** Preflight compares the installed version with the released one
44
+ and recommends the **launcher** (`npx sshlg-skills update`), never the bare
45
+ per-skill form that re-creates the plain copy which shadows a plugin. Plus three
46
+ staleness signals that are not version numbers: a standing instruction that has not
47
+ fired in five stamps, a doc map older than the last release, a ratchet whose count
48
+ has not moved.
49
+ - **The escalation boundary.** The autonomy sweep gains the rule that lets a run go
50
+ further without stopping: decide alone while the cost of being wrong stays inside
51
+ the repository and is reversible; escalate a price, a legal posture, a promise, money,
52
+ reputation, and any irreversible outward act. **The tell is the cost of being wrong,
53
+ not the size of the change.**
54
+ - **User paths become a stage-2 output.** The contract layer was never the thin one —
55
+ the spec already locks error handling and a module dossier already has edge cases.
56
+ The thin layer was the *conversation*: `brainstorm.md` mentioned edge cases once and
57
+ scenarios not at all. Paths, states and error paths are now named where the design
58
+ is approved, and the gate says so. Scenario IDs stay the chain's job — two sources
59
+ for one scenario is worse than one.
60
+ - **Declared terms.** The seeded doc map gains a *Terms* table, and only terms it
61
+ declares are checked. A heuristic over every capitalised word cries wolf, and a gate
62
+ that cries wolf is removed by the third person who hits it.
63
+
64
+ Three new guards, each with a negative self-test watched failing.
65
+
66
+ ## v1.9.1 — 2026-08-03
67
+
68
+ ### Added — the direction of the artifact map that was missing
69
+
70
+ `references/artifacts.md` mapped **stage → what it writes → who consumes it** and
71
+ nothing the other way. What an agent actually needs at runtime is **what each stage
72
+ reads, and from where** — and that direction had been absent since the file was
73
+ written. It is `references/learned.md` rule 2 (*compute the mapping in both
74
+ directions*) left unapplied to this file itself: the direction that feels redundant
75
+ is the one that finds things.
76
+
77
+ Two tables now sit above the old one:
78
+
79
+ - **Stage → input map** — per stage, the exact inputs and their origin. Stage 9's row
80
+ is the one worth reading twice: it takes **two different lists**, the stage-0 source
81
+ ledger (what the run *read*) and the doc map's propagation matrix (what the run
82
+ *owes*), and the gap between them is where documentation rots.
83
+ - **Project-saved rules, and where each one binds** — the eight files a host project
84
+ owns that change how a run behaves, each with where it is read and where it is
85
+ enforced: `CLAUDE.md`/`AGENTS.md`, `docs/DOCMAP.md`, the retro's standing
86
+ instructions, the brief's autonomy section, the carry-over ledger,
87
+ `docs/ux/scenarios.md`, `.claude/agent-sync.json`, and the operator's global config
88
+ that decides whether a task routes here at all. Plus the precedence rule: for *what
89
+ is*, code wins; for *what should be*, the register wins, and the gap is a finding
90
+ rather than a tie-break.
91
+
92
+ A guard holds all three maps present, with a negative self-test watched failing.
93
+
3
94
  ## v1.9.0 — 2026-08-03
4
95
 
5
96
  ### Added — the adoption track, and default-on inside a stated boundary
package/README.md CHANGED
@@ -490,6 +490,21 @@ now does:
490
490
  discover: author and reviewer are the same person, commits are unsigned, and the
491
491
  eval suite has not been executed.
492
492
 
493
+ ### The entry audit — before the feature, not after
494
+
495
+ `/task-pipeline setup` runs seven passes over the documentation a project already
496
+ has, and hands back a fix plan rather than a lecture: one decision home, register
497
+ integrity, ratcheted propagation, the matrix's *Checked by* column, declared terms,
498
+ the UX chain, and the gate itself proven against a planted defect. Findings carry
499
+ `file:line`, the minimal fix and **the seam** — ordered by seam, because that names
500
+ which layer of your process is leaking.
501
+
502
+ Offered once when the doc map is absent or stale, and the refusal is recorded. It
503
+ also runs the **inward check**: does this project hold a rule that would be true in a
504
+ repository nobody has seen? If it names no path, no command and no person, it is the
505
+ bundle's — and keeping it local costs every future project
506
+ ([`references/portability.md`](plugins/task-pipeline/skills/task-pipeline/references/portability.md)).
507
+
493
508
  ### Adopting it — a new project, and the one you actually have
494
509
 
495
510
  Greenfield is mechanical: stage 0 seeds `docs/DOCMAP.md`, the registers and the gate
package/SKILL-CARD.md CHANGED
@@ -12,7 +12,7 @@ harmless.
12
12
  |---|---|
13
13
  | **Purpose** | Runs a substantial task through ten gated delivery stages — intake grill, docs study, brainstorm, spec, plan, subagent build, tests, lint/deploy, post-deploy, docs+registers, acceptance — refusing to advance until each gate passes |
14
14
  | **Owner** | ssheleg ([github.com/ssheleg/task-pipeline](https://github.com/ssheleg/task-pipeline)) |
15
- | **Version** | 1.9.0 |
15
+ | **Version** | 1.10.0 |
16
16
  | **Surface** | Claude Code (filesystem skill + plugin) and the vercel `skills` CLI. **Not** uploaded to the Skills API; custom Skills do not sync across surfaces |
17
17
  | **Dependencies** | None required. Optional: `context7` (MCP), `figma` (MCP), super-ux, agent-sync, graphify, obsidian-wiki. Every stage's doctrine ships in-repo; the one conditional requirement is super-ux for the stage-3 UX track on a user-facing task |
18
18
  | **Evaluation status** | Suite authored (15 evals, 5 categories). **Never executed** — see [`evals/RESULTS.md`](evals/RESULTS.md) |
@@ -34,11 +34,11 @@ apply.
34
34
 
35
35
  ## What to check before you trust it
36
36
 
37
- 1. Read `SKILL.md` and the 24 files under `references/` — that is the whole
37
+ 1. Read `SKILL.md` and the 26 files under `references/` — that is the whole
38
38
  instruction surface, and every one is linked directly from `SKILL.md`.
39
39
  2. Read `templates/docgate.sh` before seeding it; it is the only shipped script a
40
40
  host project will run on its own repository.
41
- 3. Run `npm run test:all` — 55 guards, each with a negative self-test that plants a
41
+ 3. Run `npm run test:all` — 59 guards, each with a negative self-test that plants a
42
42
  defect and requires rejection.
43
43
  4. Run `python3 evals/run.py` for the behavioural protocol, and read
44
44
  `evals/RESULTS.md` for what has actually been observed.
@@ -54,7 +54,7 @@ apply.
54
54
  - **Versions are pinned by git tag** and mirrored into `sshlg-skills`'s catalogue.
55
55
  Rollback is `git checkout v<previous>` or pinning the previous plugin version;
56
56
  the previous version is never deleted.
57
- - **Behavioural evidence is missing, not merely thin.** 55 structural guards prove
57
+ - **Behavioural evidence is missing, not merely thin.** 59 structural guards prove
58
58
  the skill is well-formed. Until `evals/RESULTS.md` carries a dated run, nothing in
59
59
  this repository proves it *behaves* — triggers correctly, stays quiet on a
60
60
  question, or performs the steps it documents.
package/evals/RESULTS.md CHANGED
@@ -37,9 +37,9 @@ or it belongs in a check.
37
37
  | Dated runs recorded | **0** | 2026-08-03 |
38
38
 
39
39
  The bottom two numbers are the honest state of this skill's behavioural evidence.
40
- Everything else in this repository is proven by 55 structural guards that check the
40
+ Everything else in this repository is proven by 59 structural guards that check the
41
41
  *form*; these are the only checks that would speak to the *behaviour*, and they have
42
- not been run yet. Printed here so "55 of 55 green" is never read as "the skill is
42
+ not been run yet. Printed here so "59 of 59 green" is never read as "the skill is
43
43
  known to work".
44
44
 
45
45
  ## Runs
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "task-pipeline-skill",
3
- "version": "1.9.0",
3
+ "version": "1.10.0",
4
4
  "description": "Full-cycle delivery pipeline for coding agents: a mandatory built-in intake grill, then 10 gated stages (docs, brainstorm+decompose, spec, plan, build, tests, lint/deploy, post-deploy, docs/wiki, acceptance). Every stage's doctrine ships inside the skill — no companion plugin required. This package is the installer CLI.",
5
5
  "bin": {
6
6
  "task-pipeline": "bin/task-pipeline.js"
@@ -2,7 +2,7 @@
2
2
  "name": "task-pipeline",
3
3
  "displayName": "Task Pipeline",
4
4
  "description": "Runs a substantial task through a mandatory built-in intake grill, then 10 gated stages (docs, brainstorm+decompose, spec, plan, subagent build, tests, lint/deploy, post-deploy, docs/wiki, acceptance). Every stage's doctrine is built into the skill — no companion plugin required — with typed auto/manual gates, a frozen requirement spine that must close with evidence, a loop guard that breaks churn, one provider-agnostic model confirmed up front, and an optional super-ux UX track for user-facing work.",
5
- "version": "1.9.0",
5
+ "version": "1.10.0",
6
6
  "author": {
7
7
  "name": "ssheleg",
8
8
  "url": "https://x.com/sshlg93"
@@ -43,3 +43,9 @@ Idempotent entry — inspect state first, never restart blindly:
43
43
  **resume** from the first incomplete stage instead of starting over.
44
44
  - Otherwise, begin at stage 0 (intake grill). If no task is given above, the
45
45
  grill's first question asks the operator for the task in one line.
46
+
47
+ **`/task-pipeline setup`** — the entry audit instead of a feature. Runs seven passes
48
+ over the documentation this project already has, reports findings as `file:line` + the
49
+ minimal fix ordered by seam, and hands back a fix plan the pipeline can run. Offered
50
+ once at stage 0 when the doc map is absent or stale; run it directly any time.
51
+ Doctrine: `references/setup.md`.
@@ -62,6 +62,8 @@ gate stops until it is installed.
62
62
  | 10 Retrospective (the run's last act) | [`references/retrospective.md`](references/retrospective.md) |
63
63
  | 10 + any audit (what's *missing*) | [`references/audit.md`](references/audit.md) |
64
64
  | **first run in a project** (new or existing) | [`references/adoption.md`](references/adoption.md) |
65
+ | **first run · the entry audit** (offered once) | [`references/setup.md`](references/setup.md) |
66
+ | **what travels with the bundle vs stays in a project** | [`references/portability.md`](references/portability.md) |
65
67
  | any repeating loop | [`references/loop-guard.md`](references/loop-guard.md) |
66
68
 
67
69
  **Optional bridge.** If the operator already runs an equivalent skill set (e.g.
@@ -332,6 +334,11 @@ automation is on — `pipeline.schema.json` is the only contract.
332
334
  - `references/tdd.md` — stages 5–6: the iron law, red/green/refactor, the suite gate
333
335
  - `references/stages.md` — per-stage detail + exact gate criteria + gate types
334
336
  - `references/model-tiering.md` — model map, ids, the `/model` reminder mechanic, override
337
+ - `references/setup.md` — the entry audit: seven passes over the docs you already
338
+ have, offered once, output as a fix plan; plus the inward check for rules that
339
+ belong upstream
340
+ - `references/portability.md` — the manifest of workflow decisions and their homes
341
+ inside the bundle, and the boundary against a project's own answers
335
342
  - `references/adoption.md` — the first run in a project: greenfield seeding, and the
336
343
  brownfield walkthrough whose third step baselines the ratchets at today
337
344
  - `references/conventions.md` — how stages 6–10 read the host project's CLAUDE.md
@@ -8,6 +8,7 @@ shape.
8
8
  ## Contents
9
9
 
10
10
  - In the host project
11
+ - Stage → input map — where each stage's information comes from
11
12
  - Stage → artifact map
12
13
  - This repo (task-pipeline itself), for reference
13
14
 
@@ -65,6 +66,52 @@ Stage 5 also creates a **git-ignored** scratch workspace per plan at
65
66
  review packages. It is deleted when the final review is clean; git history is the
66
67
  record (see `build.md`).
67
68
 
69
+ ## Stage → input map — where each stage's information comes from
70
+
71
+ The map below this one answers *what a stage writes*. This one answers *what it
72
+ reads, and from where* — the direction that was missing, which is
73
+ [`learned.md`](learned.md) rule 2 (*compute the mapping in both directions*) applied
74
+ to this file itself. A stage whose inputs are unnamed is a stage that will read
75
+ whatever the context happens to hold.
76
+
77
+ | Stage | Reads | From where |
78
+ |---|---|---|
79
+ | **0 Harvest** | the project's own knowledge about this task | code · the code graph (`graphify-out/`) · `CLAUDE.md`/`AGENTS.md` · `CONTEXT.md`/`docs/adr/` · `docs/` + `docs/ux/` · past briefs and carry-over ledgers · the retro's standing instructions **in full** · the wiki · any doc repo or hosted system the project names |
80
+ | **0 Inventory (1b)** | the documentation regime | `docs/DOCMAP.md` — registers, single homes, propagation matrix, gate commands, ratchet floors. Absent ⇒ seeded ([`adoption.md`](adoption.md)) |
81
+ | **0 Reconcile (1c)** | intent vs as-built | git (how it *should* be) against the run record (how it *turned out*) |
82
+ | **0 Grill** | the operator | the interview — every answer checked against the harvest, which is what makes it checkable rather than confident |
83
+ | **1 Docs study** | external library/API contracts | `context7:resolve-library-id` → `context7:query-docs`; web search where it cannot resolve. **Never from recall** |
84
+ | **2 Brainstorm** | what is already settled | the brief (scope, constraints, done-criteria) + the codebase. Re-asking what the grill answered is this stage's most common waste |
85
+ | **3 Spec** | the approved design + the UX chain | stage-2 design · `docs/ux/{foundation,flows,screens,scenarios}.md` (UI only) · the Figma canonical record in `docs/ux/foundation.md` → *Design tooling* · `DOCMAP.md` for where a settled contract is recorded |
86
+ | **4 Plan** | the spec and the frozen list | the spec's locked contracts and **Global Constraints** · the brief's REQ ids (the gate is a set comparison against them) |
87
+ | **5 Dev** | one task at a time | the plan task · the spec's Global Constraints, copied verbatim · host test/lint commands · the brief's branch policy. **A subagent reads only its own file-based brief** — that is the whole of its context |
88
+ | **6 Tests** | the host's runner | `CLAUDE.md`/`AGENTS.md` → *Lint + test*, else detection ([`conventions.md`](conventions.md)) |
89
+ | **7 Lint + deploy** | the host's lint and deploy path, and the authorization | host conventions · the brief's autonomy sweep, where a standing go must name target **and** preconditions |
90
+ | **8 Post-deploy** | where health lives | the brief's autonomy sweep (app name, endpoint, workflow) |
91
+ | **9 Docs + registers** | two different lists | the stage-0 **source ledger** (what this run *read*) **and** `DOCMAP.md`'s **propagation matrix** (what this run *owes*). They are not the same list, and the gap between them is where documentation rots |
92
+ | **10 Acceptance** | everything the run produced | the brief's REQ table · the carry-over ledger **in full** · plan task statuses · `git log` · the final suite output · stage-8 notes · stage-9 changes · `docs/ux/scenarios.md` + `/ux-lint` for UI |
93
+
94
+ ### Project-saved rules, and where each one binds
95
+
96
+ These are the files a **host project** owns that change how a run behaves. An agent
97
+ that has not read them is running the pipeline's defaults, not this project's.
98
+
99
+ | Rule file | What it binds | Read at | Enforced at |
100
+ |---|---|---|---|
101
+ | `CLAUDE.md` / `AGENTS.md` | commands, deploy path, house rules, which docs exist and where | 0 | 6–10 |
102
+ | `docs/DOCMAP.md` | the decision home, each fact's single home, the propagation matrix, the gate and its ratchet floors | 0 (1b) | 9 |
103
+ | `docs/superpowers/retro.md` | standing instructions — the rules no check can decide. Capped at ten, **read in full**, stamped the moment one fires | 0 | pruned at 10 |
104
+ | `specs/<topic>-brief.md` → *Autonomy* | every pre-resolved decision; stages 1→10 **answer from it instead of asking** | 0 | 1–10 |
105
+ | `specs/<topic>-carryover.md` | everything deferred, parked or half-done; appended the moment it is said | all | read in full at 10 |
106
+ | `docs/ux/scenarios.md` | the source of truth for user-facing behaviour (super-ux) | 3 | 3, 7, 9, 10 |
107
+ | `.claude/agent-sync.json` | which registers are guarded, and by whose lease | 0 | every guarded write |
108
+ | the operator's global `CLAUDE.md` | whether a task routes here at all, and the opt-out phrase | before stage 0 | — |
109
+
110
+ **Precedence when two of them disagree.** For *what is*: code, then host docs and
111
+ ADRs, then the wiki, then memory. For *what should be*: the register outranks the
112
+ code, because a decision not yet built is still the decision — and the gap between
113
+ them is a finding, not a tie-break ([`knowledge-sources.md`](knowledge-sources.md)).
114
+
68
115
  ## Stage → artifact map
69
116
 
70
117
  | Stage | Writes | Consumed by |
@@ -21,6 +21,7 @@ approved design — not at code.
21
21
  - Working in an existing codebase
22
22
  - UI detection — a required output
23
23
  - The approved design is a set of decisions — record them
24
+ - User paths are a design output, not a spec detail
24
25
  - GATE (manual)
25
26
  - Rationalizations
26
27
 
@@ -112,10 +113,32 @@ The cost of skipping it is specific: a design approved in conversation and recor
112
113
  only in the spec dies with that spec, and the next run re-opens a question the
113
114
  operator already answered.
114
115
 
116
+ ## User paths are a design output, not a spec detail
117
+
118
+ For anything with a user-facing surface, the design is not done when the components
119
+ are named. Three things come out of **this** stage and feed the stage-3 chain:
120
+
121
+ 1. **The paths** — how a user actually reaches this, start to finish, including the
122
+ route they take when they arrive from somewhere unexpected.
123
+ 2. **The states** — every screen or command has more than the happy one: loading,
124
+ empty, partial, denied, expired, offline. Name them here; naming them in the spec
125
+ means the design was approved without them.
126
+ 3. **The error paths** — what the user sees when it fails, what they can do next, and
127
+ what the system says out loud versus logs quietly.
128
+
129
+ **Why here and not at stage 3.** The spec already locks *Error handling and
130
+ degradation*, and a module dossier already has *Edge and failure cases* — the
131
+ contract layer is not the thin one. What was thin is the conversation: a design
132
+ approved without its error paths is a design whose hardest third is invented later by
133
+ whoever implements it, alone, at stage 5.
134
+
135
+ Feed them into [`spec.md`](spec.md)'s UX track — super-ux turns them into flows,
136
+ screens and traced scenarios. **Do not draft scenario IDs here**; that is the
137
+ chain's job, and two sources for one scenario is worse than one.
138
+
115
139
  ## GATE (manual)
116
140
 
117
- The operator approves the design **and** the UI verdict is recorded **and every REQ
118
- in the brief is answered by the design** — a requirement the design doesn't address
141
+ The operator approves the design, **the UI verdict is recorded**, and — where that verdict is *yes* — **the paths, the states and the error paths are named** (above) rather than deferred to the spec. **Every REQ in the brief is answered by the design** — a requirement the design doesn't address
119
142
  is either covered now or explicitly dropped by the operator, with the drop written
120
143
  into the carry-over ledger. For a platform, the module map
121
144
  ([`decomposition.md`](decomposition.md)) is committed and approved as part of this
@@ -14,6 +14,7 @@ better, plus one that is required only for user-facing work.
14
14
  - The matrix
15
15
  - Optional bridge — substituting an external skill set
16
16
  - Preflight (emit before stage 0)
17
+ - Is this skill itself current?
17
18
  - Credit
18
19
  - Hand-off the other direction
19
20
 
@@ -144,6 +145,39 @@ Rules:
144
145
  - The model answer goes into the brief. Don't ask again per stage
145
146
  (`model-tiering.md` → *Mechanic*).
146
147
 
148
+ ## Is this skill itself current?
149
+
150
+ Preflight's other question, asked once beside the companion block. A pipeline running
151
+ on a stale copy of its own doctrine repeats a class of failure that was already fixed
152
+ upstream — and nothing in a run would ever reveal it.
153
+
154
+ ```bash
155
+ npx --yes sshlg-skills@latest list # what the current release of each member is
156
+ ```
157
+
158
+ Compare it with what is installed. Behind → offer the **launcher**, never the bare
159
+ per-skill form:
160
+
161
+ ```bash
162
+ npx --yes sshlg-skills@latest update
163
+ ```
164
+
165
+ The launcher moves the whole family, updates plugins and agent copies together, and
166
+ prunes the plain `~/.claude/skills/<name>/` copies that otherwise shadow a plugin and
167
+ serve the version they were copied from, forever. A bare `npx skills update <name>`
168
+ re-creates exactly that shadow.
169
+
170
+ **Three staleness signals worth naming**, because none of them is a version number:
171
+
172
+ | Signal | What it means |
173
+ |---|---|
174
+ | A standing instruction that has not fired in five run stamps | the rule was situational; the prune retires it ([`retrospective.md`](retrospective.md)) |
175
+ | A doc map older than the project's last release | the regime was decided for a project that has since changed shape — `setup` offers the entry audit ([`setup.md`](setup.md)) |
176
+ | A ratchet whose count has not moved in months | either the backlog is genuinely frozen, or nobody is looking at the number printed beside every verdict |
177
+
178
+ Recommend once, then continue. **Never a gate** — a run blocked on its own updater is
179
+ a run that cannot ship a fix to the updater.
180
+
147
181
  ## Credit
148
182
 
149
183
  The built-in doctrine is **ported, not depended on**:
@@ -141,6 +141,8 @@ explicit "stop and ask me here":
141
141
  |---|---|
142
142
  | run-wide | the model decision ([`model-tiering.md`](model-tiering.md)); what to decide autonomously vs escalate |
143
143
  | 0 Harvest | doc sources beyond this repo — other repos, hosted doc systems, the knowledge wiki, **the code graph** ([`knowledge-graph.md`](knowledge-graph.md): built / installed-not-built / absent) — and whether stage 9 may write to them (another repo is outward: propose + PR, never a direct push) |
144
+ | 0 Setup audit | doc map absent or stale: run the entry audit over the existing documentation before building on it ([`setup.md`](setup.md))? Asked once; a refusal is recorded and never re-asked |
145
+ | run-wide Escalation | cost of being wrong: decide alone while it stays inside the repository and reversible; escalate price, legal posture, promise, money, reputation, irreversible outward acts. Project exceptions? |
144
146
  | 0 Docs regime | where settled things live (the decision home — **one** per project, and an existing `docs/adr/` **is** it), who may write it, whether a lease mechanism is present or the run is `ungated`, the gate command and its ratchet floors, and whether this run may raise a floor ([`documentation.md`](documentation.md)) |
145
147
  | 1 Docs | external libs/APIs/SDKs in play; any private ones context7 can't resolve → where their docs live |
146
148
  | 2 Decompose | is this a platform (several capabilities/surfaces) or one module? if platform: deploy cadence — per module or once at the end |
@@ -0,0 +1,115 @@
1
+ # Portability — what travels with the bundle, and what must not
2
+
3
+ **One job: keep every decision about *how the pipeline behaves* inside the bundle, and
4
+ every decision about *what a project decided* inside that project.** Get this backwards
5
+ in either direction and something breaks quietly: a workflow optimisation stranded in
6
+ one repository, or a skill that has quietly learned one project's answers.
7
+
8
+ ## Contents
9
+
10
+ - The boundary
11
+ - The manifest — every workflow decision and its home
12
+ - The two checks, in both directions
13
+ - What a host project is allowed to hold
14
+ - Rationalizations
15
+
16
+ ## The boundary
17
+
18
+ | Kind of decision | Example | Lives in | Travels? |
19
+ |---|---|---|---|
20
+ | **Workflow** — how the pipeline behaves anywhere | the gate types, the loop-guard caps, the Doc Loop's seven steps, the escalation rule, the routing boundary | `references/*.md`, `templates/*`, `pipeline.example.json` | **yes — this is the bundle** |
21
+ | **Project answer** — what *this* repository decided | which register it uses, its propagation matrix, its ratchet floors, its standing instructions | `docs/DOCMAP.md`, the register, `docs/superpowers/retro.md`, the brief | **no — and correctly so** |
22
+
23
+ Two failures follow from confusing them, and they look nothing alike:
24
+
25
+ - **A workflow decision left in a project** is a fork of the doctrine that nobody
26
+ named. The next project starts without it and nobody notices, because the first
27
+ project still works.
28
+ - **A project answer absorbed into the skill** ends project-agnosticism. The bundle
29
+ starts asserting things that are true in one repository and false in the next.
30
+
31
+ **The tell is the question it answers.** *"How does the pipeline behave?"* → bundle.
32
+ *"What did we decide here?"* → project. A rule that would be true in a repository you
33
+ have never seen belongs in the bundle even if you learned it in one.
34
+
35
+ ## The manifest — every workflow decision and its home
36
+
37
+ Every row's home is a path **inside this skill**. A guard checks each one resolves;
38
+ a row pointing outside the bundle is the defect this file exists to catch.
39
+
40
+ | Workflow decision | Home |
41
+ |---|---|
42
+ | The stage list, ids, names, gate types | `pipeline.example.json` |
43
+ | Per-stage criteria, freedom levels, the run checklist | `references/stages.md` |
44
+ | What the intake grill asks, and the autonomy sweep | `references/grill.md` |
45
+ | **The escalation boundary** — what an agent may settle alone | `references/grill.md` |
46
+ | The knowledge harvest and its source ledger | `references/knowledge-sources.md` |
47
+ | The documentation system, the Doc Loop, supersede semantics | `references/documentation.md` |
48
+ | Gate types, the enforcement ladder, degrees of freedom, probing | `references/gates.md` |
49
+ | The Claude Code hook contract | `references/hooks.md` |
50
+ | First run in a project: greenfield and brownfield | `references/adoption.md` |
51
+ | The entry audit and what it inspects | `references/setup.md` |
52
+ | The ladder, seams, axis rotation, ratchets | `references/audit.md` |
53
+ | Loop detection and its caps | `references/loop-guard.md` |
54
+ | The retro: prune, cap, commits, archive | `references/retrospective.md` |
55
+ | Rules earned by failure | `references/learned.md` |
56
+ | **The routing default and its boundary** | `templates/routing-rule.md` |
57
+ | The seeded doc map, registers and gate | `templates/docmap.md`, `templates/decisions.md`, `templates/open-questions.md`, `templates/docgate.sh` |
58
+ | What a stage reads, and which host files bind it | `references/artifacts.md` |
59
+ | This boundary | `references/portability.md` |
60
+
61
+ **The routing rule is the row worth watching.** A skill's `description` raises the
62
+ odds it is selected and cannot make selection mandatory — only an instruction in a
63
+ `CLAUDE.md` can. That instruction is therefore *installed*, not shipped, which is
64
+ exactly how a workflow decision ends up living outside the bundle. The template above
65
+ is the fix: the rule travels as a file, and [`setup.md`](setup.md) **offers** to
66
+ append it. Offers, not writes — it is the operator's configuration.
67
+
68
+ ## The two checks, in both directions
69
+
70
+ One direction is not enough, for the same reason
71
+ [`learned.md`](learned.md) rule 2 gives: a comparison needs two sides and an absence
72
+ has one.
73
+
74
+ **Outward — does every workflow decision have a home here?** Mechanical: every path
75
+ in the manifest resolves inside the bundle, and no row names a path outside it. Run
76
+ by the validator on every commit. This catches *"we decided it and forgot to put it
77
+ anywhere portable"*.
78
+
79
+ **Inward — is this project holding something universal?** Judgemental, and it is
80
+ [`setup.md`](setup.md)'s job: read the host's `CLAUDE.md`/`AGENTS.md`, its doc map
81
+ and its standing instructions, and ask of each rule — *would this be true in a
82
+ repository I have never seen?* If yes, it is a workflow decision wearing a project's
83
+ clothes, and it should be proposed upstream rather than copied to the next project by
84
+ hand. This catches *"the optimisation lives in one repo and dies there"*.
85
+
86
+ Neither check can be skipped in favour of the other. The outward one is cheap and
87
+ constant; the inward one runs when a project is audited, and it is the only one that
88
+ can find a rule nobody ever wrote down as portable.
89
+
90
+ ## What a host project is allowed to hold
91
+
92
+ Not a restriction — a list of what *should* stay local, so the inward check does not
93
+ flag it:
94
+
95
+ - the answers in `docs/DOCMAP.md`: which register, which homes, which matrix rows;
96
+ - the ratchet **values** — floors are measurements of one repository's history;
97
+ - standing instructions that name this project's paths, commands or people;
98
+ - the deploy target, the test command, the branch policy;
99
+ - everything in `docs/ux/` — this project's users, flows and scenarios.
100
+
101
+ A standing instruction that names **no** path, command or person is a candidate for
102
+ the bundle. That is the cheapest inward test there is, and
103
+ [`retrospective.md`](retrospective.md) already states the rule it serves: a lesson
104
+ true in any repository belongs in the pipeline's own doctrine, not in one project's
105
+ retro.
106
+
107
+ ## Rationalizations
108
+
109
+ | Excuse | Reality |
110
+ |---|---|
111
+ | "It's in our CLAUDE.md, that's good enough" | Good enough for this repository on this machine. The next project starts without it, and nobody notices because this one still works. |
112
+ | "I'll copy the rule into the next project when I get there" | That is the fork, performed by hand, once per project, until two of them disagree and neither is wrong. |
113
+ | "The skill should just learn our conventions" | Then it stops working for anyone else, including you on the next repository. Conventions are answers; the bundle carries questions and procedures. |
114
+ | "This rule is obviously universal, it doesn't need a home" | Every rule is obvious to the person who just learned it. The manifest is one line; the fork is permanent. |
115
+ | "The manifest will go stale" | It is checked, not trusted: every path resolves or the build fails. A stale row is a red build, not a quiet lie. |
@@ -0,0 +1,124 @@
1
+ # Setup — the entry audit, before the first feature
2
+
3
+ **One job: find out what is already wrong with this project's documentation before
4
+ building on top of it.** [`audit.md`](audit.md)'s ladder runs at the *end* of a run,
5
+ over the change. This runs at the *start*, over what is already there — and until
6
+ this file existed, nothing did.
7
+
8
+ **Offered, never imposed.** Stage 0 asks once, when `docs/DOCMAP.md` is absent or its
9
+ regime line is older than the project's last release. The answer — including "no" —
10
+ is recorded in the brief's autonomy sweep and never asked again.
11
+
12
+ ## Contents
13
+
14
+ - When it runs
15
+ - What it inspects
16
+ - The finding shape
17
+ - The output is a fix plan, not a lecture
18
+ - The inward check — what this project holds that belongs upstream
19
+ - The offer to install the routing rule
20
+ - Rationalizations
21
+
22
+ ## When it runs
23
+
24
+ | Situation | What happens |
25
+ |---|---|
26
+ | First run in a repository, no `docs/DOCMAP.md` | [`adoption.md`](adoption.md) seeds; this audit runs against what the seeding found |
27
+ | Existing project, doc map present but stale | offered once at stage 0 |
28
+ | The operator asks for it — `/task-pipeline setup` | runs as the whole task; stages 3–5 produce findings and fixes rather than a feature |
29
+ | Every subsequent run | **not offered again.** The recorded answer stands until the doc map changes |
30
+
31
+ **Never as a recurring tax.** A check that runs before every feature is a check people
32
+ learn to dismiss. Once per project state, then it is the gate's job.
33
+
34
+ ## What it inspects
35
+
36
+ Seven passes, cheapest first. Each either reports `ok`, a finding, or **`skipped —
37
+ <why>`**; a silent pass is indistinguishable from a clean one.
38
+
39
+ 1. **The decision home.** Exactly one, and the doc map names it. Two homes is a fork;
40
+ zero is a project whose decisions live only in commit messages.
41
+ 2. **Register integrity.** Ids unique and never renumbered · status vocabulary closed
42
+ · supersede/contradict targets annotated · no resolved question deleted.
43
+ 3. **Propagation.** Every document named in an entry's `Consequences / affects:` line
44
+ cites that entry — ratcheted, so history is a printed number and not a wall of
45
+ failures ([`adoption.md`](adoption.md) → *Baseline the ratchets*).
46
+ 4. **The matrix.** Every row has a *Checked by* cell — a check, or `review` **with the
47
+ reason no check can decide it**. An empty cell is a finding, not a blank.
48
+ 5. **Terms.** Every term the doc map declares resolves to exactly one definition, and
49
+ the definition's home actually contains it. **Only declared terms are checked** —
50
+ a heuristic over every capitalised word cries wolf, and a gate that cries wolf is
51
+ removed by the third person who hits it ([`gates.md`](gates.md) → *The
52
+ false-positive budget*).
53
+ 6. **The UX chain**, when the project has a user-facing surface: scenarios exist,
54
+ trace to stories and flows, and the linter passes. A project with screens and no
55
+ scenarios is building interface before behaviour.
56
+ 7. **The gate itself.** It exists, it runs, it exits non-zero on a planted defect, and
57
+ its verdict prints its ratchets. **An unproven gate's green is worth nothing** —
58
+ plant one defect and watch it fail before quoting it as evidence.
59
+
60
+ ## The finding shape
61
+
62
+ Every finding carries three things and nothing else:
63
+
64
+ ```
65
+ docs/ARCHITECTURE.md:214 cites DEC-0081 (retired, superseded twice) without saying so
66
+ → add the marker beside the citation, or replace it with the live decision
67
+ seam: L1→L2 (the decision reached the doc and then stopped being true)
68
+ ```
69
+
70
+ `file:line` · the minimal fix · the seam it belongs to. **Ordered by seam, never by
71
+ file** — a file-ordered list reads as noise; a seam-ordered one tells you which layer
72
+ of the project's own process is leaking.
73
+
74
+ ## The output is a fix plan, not a lecture
75
+
76
+ The audit ends with `docs/superpowers/plans/YYYY-MM-DD-doc-audit.md` — the findings
77
+ turned into tasks the pipeline can run, in the order that makes them terminate:
78
+
79
+ 1. everything the gate can enforce **after** the fix, so the class stops recurring;
80
+ 2. the ratchet floors, baselined at today;
81
+ 3. the rest, largest seam first.
82
+
83
+ An audit that hands over a list and no plan is a list somebody will read once.
84
+
85
+ **Nothing is fixed during the audit.** Reading and repairing in one pass is how a
86
+ pass starts finding its own edits ([`audit.md`](audit.md) → *Every pass changes the axis, not the effort*).
87
+
88
+ ## The inward check — what this project holds that belongs upstream
89
+
90
+ The other direction, and the one nobody runs by themselves
91
+ ([`portability.md`](portability.md) → *The two checks*).
92
+
93
+ Read the host's `CLAUDE.md`/`AGENTS.md`, its doc map and its standing instructions,
94
+ and ask of each rule: **would this be true in a repository I have never seen?**
95
+
96
+ - **Names a path, a command, a person, a service** → it is this project's answer.
97
+ Leave it.
98
+ - **Names none of those** → it is a workflow decision wearing a project's clothes.
99
+ Report it, and propose it upstream to the bundle rather than copying it by hand
100
+ into the next project.
101
+
102
+ That hand-copy is the fork: performed once per project, until two of them disagree and
103
+ neither is wrong.
104
+
105
+ ## The offer to install the routing rule
106
+
107
+ If the operator's configuration carries no routing rule, offer to append
108
+ [`../templates/routing-rule.md`](../templates/routing-rule.md) — the version that
109
+ travels with the bundle.
110
+
111
+ **Offer, never write.** It is the operator's configuration, and appending to it
112
+ without asking is the same class of act as pushing to a repository nobody asked you
113
+ to touch. Print the diff, ask once, record the answer.
114
+
115
+ ## Rationalizations
116
+
117
+ | Excuse | Reality |
118
+ |---|---|
119
+ | "The docs are fine, we'd know" | You would know about the contradictions. Absences have one side, and nobody notices a decision that was never written. |
120
+ | "Let's audit after we ship this feature" | Then the feature is built on the part that was wrong, and the audit's first finding is the feature. |
121
+ | "This will take a week" | Seven passes, most of them mechanical, and the ratchet step means you fix nothing today. What takes a week is the fix plan — and that is work you were going to do blind otherwise. |
122
+ | "We'll fix things as we find them" | Then the pass starts finding its own edits and never terminates. Read, then plan, then fix. |
123
+ | "The gate is green, so the docs are good" | The gate proves what it checks. Read its scope header, and plant a defect before quoting its green. |
124
+ | "Our conventions are ours, upstream doesn't need them" | Some of them are, and the inward check leaves those alone. The ones naming no path and no command are the pipeline's, and keeping them local costs you every future project. |
@@ -107,6 +107,12 @@ never that the work was skipped quietly.
107
107
  existing `docs/adr/` *is* the register and is recorded as such, never duplicated.
108
108
  The gate is seeded so that it exits `0` on its own seeds; a project that starts
109
109
  red learns on day one that the gate is noise.
110
+ - **Phase 1b+ — offer the entry audit, once** ([`setup.md`](setup.md)). When
111
+ `docs/DOCMAP.md` is absent or its regime line predates the project's last release,
112
+ ask whether to audit the documentation that already exists **before** building on
113
+ it. Record the answer — including a refusal — in the brief's autonomy sweep and
114
+ never ask again. `audit.md`'s ladder runs at the *end* over the change; this runs
115
+ at the *start* over what is already there.
110
116
  - **Phase 1c — reconcile intent against as-built.** Git says how it *should* be;
111
117
  the run record says how it *turned out*. Read both for the area you are about to
112
118
  touch and resolve every divergence — the document is stale, the record is wrong,
@@ -18,6 +18,7 @@ from `super-ux`.
18
18
  | `open-questions.md` | `docs/OPEN_QUESTIONS.md` | 0 seeds it, the Doc Loop resolves rows |
19
19
  | `docgate.sh` | `scripts/check-docs.sh` | 0 seeds it · 9 runs it · 10 proves it |
20
20
  | `hooks.example.json` | the project's `.claude/settings.json` | 0 — offered, never installed silently |
21
+ | `routing-rule.md` | the operator's `CLAUDE.md` — **offered by `setup`, never written silently** | 0 / `setup` |
21
22
  | `retro.md` | `docs/superpowers/retro.md` — **one per project, not per run** | 10 writes (prune → stamp → entry), 0 reads it in full |
22
23
  | `retro-archive.md` | `docs/superpowers/retro/YYYY-QN.md` | 10 rotates into it, 0 **queries** it |
23
24
 
@@ -103,8 +103,10 @@ is not neutral — it is a scheduled interruption.
103
103
  | Stage | Question | Answer |
104
104
  |---|---|---|
105
105
  | run-wide | Model for this run | … (most capable available unless overridden; per-stage overrides here) |
106
+ | run-wide Escalation | … | cost of being wrong: decide alone while it stays inside the repository and reversible; escalate price, legal posture, promise, money, reputation, irreversible outward acts. Project exceptions? |
106
107
  | run-wide | Decide autonomously vs escalate to me | … |
107
108
  | 0 Harvest | Doc sources beyond this repo — other repos, hosted docs, the knowledge wiki, the code graph; and may stage 9 write to them? | … (another repo is outward: propose + PR, never a direct push; graph built / not built) |
109
+ | 0 Setup audit | … (yes / no — recorded either way) | doc map absent or stale: run the entry audit over the existing documentation before building on it (the skill's `references/setup.md`)? Asked once; a refusal is recorded and never re-asked |
108
110
  | 0 Docs regime | Where settled things live (register or ADR set — one home, never both); who may write it; lease mechanism present, or is this run `ungated`? Gate command + ratchet floors; may this run raise a floor? | … |
109
111
  | 1 Docs | External libs/APIs/SDKs in play; any context7 can't resolve → where their docs live | … |
110
112
  | 2 Decompose | Platform (several capabilities/surfaces) or one module? If platform — deploy cadence: per module, or once at the end | … |
@@ -78,6 +78,21 @@ Raising a floor is a decision and belongs in the register.
78
78
  | Propagation backlog | `PROP_FLOOR` | 0 | <YYYY-MM-DD> |
79
79
  | `<fill me>` | … | … | … |
80
80
 
81
+ ## Terms
82
+
83
+ Only terms **declared here** are checked. A heuristic over every capitalised word
84
+ cries wolf, and a gate that cries wolf is removed by the third person who hits it —
85
+ so this table is the project's own list, and it may start with three rows.
86
+
87
+ | Term | Definition lives in | Anchor |
88
+ |---|---|---|
89
+ | `<Entity>` | `docs/DATA_MODEL.md` | `#entity` |
90
+ | `<fill me>` | `<the one document that defines it>` | `#anchor` |
91
+
92
+ Rules: **one definition per term**, the anchor resolves, and a document that uses the
93
+ term links to that anchor rather than restating it. A term with two definitions is
94
+ the same defect as a fact with two homes.
95
+
81
96
  ## Navigation
82
97
 
83
98
  - One definition per entity, with an explicit anchor.
@@ -0,0 +1,50 @@
1
+ # Routing rule — the portable version
2
+
3
+ **Copy this into the operator's `CLAUDE.md`** (global `~/.claude/CLAUDE.md`, or a
4
+ project's, or both). `setup` **offers** to append it; it never writes to an
5
+ operator's configuration silently.
6
+
7
+ **Why it is a file and not just the skill's description.** A skill's `description`
8
+ raises the odds the model selects it and cannot make selection mandatory — the choice
9
+ stays with the model, case by case. Only an instruction makes routing binding. That
10
+ instruction therefore has to be *installed*, which is exactly how a workflow decision
11
+ ends up living outside the bundle ([`../references/portability.md`](../references/portability.md)).
12
+ Shipping it as a template is what lets it travel.
13
+
14
+ **Keep the exclusions identical** to the skill's `description` and to the
15
+ `should_not_trigger` evaluations. Three copies of one boundary that drift are worse
16
+ than no boundary.
17
+
18
+ ---
19
+
20
+ ## Routing — repo-changing work goes through the pipeline
21
+
22
+ **When `task-pipeline` is installed, any work that CHANGES THE REPOSITORY goes
23
+ through it** — without being asked for. A feature, a fix, a refactor, a migration, an
24
+ integration, a rewrite, an adoption, a hardening pass; in any language and any
25
+ phrasing. Saying *"run this through the pipeline"* is an accelerator, not a
26
+ precondition.
27
+
28
+ **The boundary is "changes the repository", and it cuts both ways.** Not through the
29
+ pipeline:
30
+
31
+ - a question and its answer, an explanation, reading or mapping code;
32
+ - a typo, a one-line edit, a mechanical rename;
33
+ - reconnaissance or measurement that commits nothing.
34
+
35
+ Running ten gated stages for one character is the fastest way to teach an agent to
36
+ route around the pipeline entirely.
37
+
38
+ **The opt-out is "без пайплайна" or "quick".** It applies to a task that *would*
39
+ qualify: do it directly, and **say out loud** that the cycle was skipped at the
40
+ operator's request — never silently.
41
+
42
+ **A borderline case is named, not silently chosen.** *"Clean up the error handling"*
43
+ can be a two-line fix or a day's refactor. State which route you are taking and why,
44
+ in one line.
45
+
46
+ **Escalation while running.** Decide alone while the cost of being wrong stays inside
47
+ the repository and is reversible. Escalate a price, a legal posture, a promise made to
48
+ somebody outside the team, anything that spends money or reputation, any change to
49
+ what a customer's data is used for, and any irreversible outward act. The tell is the
50
+ **cost of being wrong**, not the size of the change.