@sjawhar/claude-envoy 4.11.0 → 4.11.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/.claude-plugin/plugin.json +1 -1
  2. package/.omp-plugin/plugin.json +1 -1
  3. package/AGENTS.md +43 -497
  4. package/dist/envoy-channel.js +1 -1
  5. package/legion/skills/legion-architect/SKILL.md +88 -66
  6. package/legion/skills/legion-architect/references/acceptance.md +89 -258
  7. package/legion/skills/legion-architect/references/decomposition.md +94 -213
  8. package/legion/skills/legion-architect/references/design-gate.md +88 -353
  9. package/legion/skills/legion-architect/references/wake-routing.md +51 -43
  10. package/legion/skills/legion-controller/SKILL.md +50 -181
  11. package/legion/skills/legion-controller/references/admission.md +25 -54
  12. package/legion/skills/legion-controller/references/backlog-stewardship.md +23 -119
  13. package/legion/skills/legion-controller/references/consolidation.md +9 -93
  14. package/legion/skills/legion-controller/references/daily-report.md +21 -99
  15. package/legion/skills/legion-controller/references/escalation.md +16 -118
  16. package/legion/skills/legion-controller/references/finding-asks.md +31 -162
  17. package/legion/skills/legion-controller/references/park-asks.md +33 -0
  18. package/legion/skills/legion-controller/references/parked-decisions.md +20 -264
  19. package/legion/skills/legion-controller/references/session.md +26 -84
  20. package/legion/skills/legion-controller/references/slack-mentions.md +18 -134
  21. package/legion/skills/legion-controller/references/triage.md +18 -89
  22. package/legion/skills/legion-controller/references/wakes.md +22 -549
  23. package/legion/skills/legion-controller/references/weekly-audit.md +9 -90
  24. package/legion/skills/legion-oracle/SKILL.md +19 -28
  25. package/legion/skills/legion-retro/SKILL.md +54 -93
  26. package/legion/skills/legion-retro/references/learnings.md +21 -33
  27. package/legion/skills/legion-retro/references/pr-body-content.md +21 -37
  28. package/legion/skills/legion-worker/SKILL.md +50 -64
  29. package/legion/skills/legion-worker/references/ci-checks.md +16 -84
  30. package/legion/skills/legion-worker/references/conflicts-and-rewrites.md +34 -93
  31. package/legion/skills/legion-worker/references/default-branch-check.md +22 -60
  32. package/legion/skills/legion-worker/references/findings.md +25 -180
  33. package/legion/skills/legion-worker/references/foreign-path.md +14 -22
  34. package/legion/skills/legion-worker/references/gvisor.md +20 -0
  35. package/legion/skills/legion-worker/references/merge-gate.md +43 -419
  36. package/legion/skills/legion-worker/references/plan-tests.md +8 -28
  37. package/legion/skills/legion-worker/references/pr-body.md +19 -218
  38. package/legion/skills/legion-worker/references/review-threads.md +16 -70
  39. package/legion/skills/legion-worker/references/tools.md +31 -578
  40. package/legion/skills/legion-worker/references/withheld-capability.md +12 -163
  41. package/legion/skills/simplify-settled-diff/SKILL.md +23 -41
  42. package/legion/skills/simplify-settled-diff/references/personas/code-quality-reviewer.md +14 -14
  43. package/legion/skills/simplify-settled-diff/references/personas/code-reuse-reviewer.md +4 -4
  44. package/legion/skills/simplify-settled-diff/references/personas/efficiency-reviewer.md +8 -8
  45. package/package.json +1 -1
  46. package/skills/agent-secrets/SKILL.md +46 -312
  47. package/skills/agent-secrets/references/store-a-secret.md +9 -0
  48. package/skills/approval-review/SKILL.md +20 -76
  49. package/skills/asd-ste100/SKILL.md +43 -85
  50. package/skills/asd-ste100/examples/before-after.md +18 -53
  51. package/skills/dispatch/SKILL.md +1 -1
  52. package/skills/dispatch-writing-specs/SKILL.md +1 -1
  53. package/skills/envoy/SKILL.md +56 -126
  54. package/skills/envoy/references/check-settlement.md +26 -43
  55. package/skills/envoy/references/deliveries.md +26 -144
  56. package/skills/envoy/references/legion.md +12 -45
  57. package/skills/envoy/references/roles.md +11 -9
  58. package/skills/envoy/references/sources.md +13 -25
  59. package/skills/outside-message/SKILL.md +24 -81
  60. package/skills/plain-words/SKILL.md +24 -55
  61. package/skills/thermonuclear-code-quality/SKILL.md +16 -26
  62. package/skills/thermonuclear-deep-review/SKILL.md +22 -31
  63. package/legion/skills/legion-worker/references/cleanup-deletion.md +0 -22
  64. package/legion/skills/legion-worker/references/systematic-rename.md +0 -19
  65. package/skills/asd-ste100/references/writing-rules.md +0 -59
  66. package/skills/plain-words/references/mechanics.md +0 -49
@@ -1,247 +1,128 @@
1
1
  # Decomposing a tree
2
2
 
3
- Part of `skill://legion-architect`, section 1. Read it before you read a child's handoff, create or
4
- adopt children, review a child's spec, split a change across repositories, or attach architecture
5
- components.
3
+ Read this before you read a child's handoff, create or adopt children, review a child's spec,
4
+ split work across repositories, record a wait on outside work, or attach architecture components.
6
5
 
7
6
  ## Reading the tree
8
7
 
9
- Read your own issue (the root in a root session, your child in a sub-architect session), its
10
- acceptance criteria, its existing children and their current handoffs.
11
- Your issue record is the `legion` tool's `read_record`. A child's handoffs are records on its
12
- Dispatch issue: read the newest of a phase with
13
- `dispatch handoff-read --issue <child> --phase <word>` (`plan`, `implement`, `test` or `review`),
14
- and an earlier one with `--version <n>`. The child's Conversation lists every version.
8
+ Read your own issue (`read_record`), its criteria, its children and their handoffs:
9
+ `dispatch handoff-read --issue <child> --phase <plan|implement|test|review>`, with `--version <n>`
10
+ for an earlier one.
15
11
 
16
12
  ## Adopting children
17
13
 
18
- Release every adopted child at once with
19
- `legion({ op: "release_children", issues: ["LEGION-41", "LEGION-42"] })`. The daemon runs nothing on
20
- a child until it is released. Once it is released, the daemon moves it to `todo` and, while the
21
- root's design gate is open, starts its first phase itself at the child's own admission slot, and
22
- not while Dispatch shows an open child under that child. When it starts that first phase, it also
23
- starts the child's own architect, which owns the child while it holds its role; while that
24
- architect does not hold its role, the child's notices come to you. You start neither that architect
25
- nor any worker.
26
- A release is accepted whole whatever the `--blocked-by` links say: its
27
- answer names `started` and `held` (each held child with the issues it waits on) beside
28
- `released`, and a held child waits in your tree until Legion starts it.
14
+ Release a child a person created at once and as it is:
15
+ `legion({ op: "release_children", issues: ["LEGION-41", "LEGION-42"] })`. The answer names
16
+ `released`, `started` and `held`, each held child with what it waits on. A refused release writes
17
+ nothing: release the rest again without the child it names.
18
+
19
+ - `CHILD_NOT_ADOPTABLE`: it runs or ran as a tree of its own. Leave it, or ask the controller.
20
+ - `CHILD_IN_OTHER_TREE`: re-parent it back in Dispatch, or ask that tree's architect or the
21
+ controller.
22
+ - `ISSUE_NOT_OWNED`: the issue is another architect's; send the move to the architect above you.
23
+ - `CHILD_UNDER_ACCEPTED_PARENT`: an ancestor is already accepted. Take it back with
24
+ `request_backward_move`, or release once it has closed.
29
25
 
30
26
  ## Creating children
31
27
 
32
- ```bash
33
- dispatch issue --project <project> --parent "$LEGION_ISSUE" --title '<child outcome>' --spec-file - <<'EOF'
34
- <the child's spec, written as skill://dispatch-writing-specs says, scaled to the child>
35
- EOF
36
- ```
37
-
38
- - Write each child's spec as `skill://dispatch-writing-specs` says, scaled to the child: its
39
- outline (a few sentences a part for a small child), each requirement marked as a `requirement`
40
- block, a proposed
41
- answer to each point, each term a new reader may not know explained, no item number from another
42
- document (name a requirement of the root by what it says), and no text copied from the root that
43
- does not apply to this child. Write the child's Verification document with it, one `check` block
44
- per thing that must be proved. The child's workers read only this spec and those checks.
45
- - Before `dispatch issue` creates any child, dispatch a fresh red-team subagent
46
- (`task(agent="oracle")`) with your own issue's spec (the root spec in a root session), the
47
- tree's open children with their repositories and pull requests, and the proposed
48
- child list, each child's title and whole spec. Its mandate: *"You did not write this list. Argue
49
- that each child should not exist. Name every child that is a to-do, a fix found in review, a
50
- proof of the acceptance of the issue it is filed under, or a part of the architect's own work,
51
- and say where it folds: that issue's own pull request or an open child's. Weigh each separate
52
- pull request against combining
53
- its work. Size pull requests to deliver the work most efficiently and reliably, with no preference on their number.
54
- Each round tests a large pull request whole again; one failure holds all the work, and the request merges late.
55
- It can also conflict with the default branch.
56
- Many small pull requests each cost a workspace, an admission wait, review, CI, a queue wait and a deploy.
57
- They can conflict with each other, and dependent slices run in sequence."*
58
- `wait` for its verdict, since it runs as a job of its own.
59
- Size pull requests to deliver the work most efficiently and reliably, with no preference on their number.
60
- Each round tests a large pull request whole again; one failure holds all the work, and the request merges late.
61
- It can also conflict with the default branch.
62
- Many small pull requests each cost a workspace, an admission wait, review, CI, a queue wait and a deploy.
63
- They can conflict with each other, and dependent slices run in sequence.
64
- A child may wait on a sibling's merge in the same repository: release it with `--blocked-by` that sibling, and Legion holds it until the sibling is `done`.
65
- A repeated change — the same edit per program, directory or instance of this tree's own work — is one child, never one per instance.
66
- Include deletion of what this tree replaced in this tree's work, sized by those reasons.
67
- Post the verdict, with the folds you made, as one `dispatch comment` on your own issue: the
68
- root in a root session, your child in a sub-architect session. Its first line is exactly
69
- `Red-team verdict for <your issue key>:`, with your own issue's key in place of the
70
- placeholder, so a reader can find it among the issue's comments. The controller's weekly audit
71
- matches that line, and counts no child filed before the release that first asked for it. The
72
- architect who wrote the list reads every child on it as needed, and the comment stops a later
73
- session filing the same children again.
74
- - A child that duplicates another issue and is not yet released is never released: fold it by the
75
- duplicate rule of `skill://dispatch-first`. The daemon records a child at its release and
76
- re-asserts a status only on an issue it has recorded, so that close stands. A released duplicate
77
- goes out with `park_child` instead, because its work is folded into the issue you keep.
78
- Move an issue to `backlog`, `icebox` or `triage` only when a person asked for that move, or when the work is done, folded into another issue or no longer needed, and cite that reason in a comment on the issue:
79
- for a duplicate, name the issue you keep in a `dispatch comment` on the child.
80
- - Then paste each survivor's whole spec into a fresh `task(agent="plan-gap-analyst")` to check it
81
- against `skill://dispatch-writing-specs`, `wait` for its result, and fix what it flags: your own
82
- reread misses the terms
83
- and item numbers you already know. File only the survivors, and reply under the verdict comment
84
- with each one's key.
85
- - Before `release_children`, check that every child you filed is named under a verdict comment,
86
- because a child filed without one skipped the check. A child a human created is adopted as it is
87
- and needs none. Check too that the current version of each child you filed has your approving
88
- `Spec review of` comment ("Reviewing a child's spec", below).
89
- - `--project` is the issue key's prefix before `-<n>` (`LEGSMOKE-3` → `LEGSMOKE`).
90
- - `--parent` is your own issue, `$LEGION_ISSUE`: the root in a root session (it equals
91
- `$LEGION_TREE`), your child in a sub-architect session. Never file below a child of yours:
92
- that child's own architect files its children. The daemon makes the sub-issue link from
93
- `--parent`.
94
- - In a sub-architect session, your child's planner may already be working when you start,
95
- because the daemon starts you both at your child's first phase. Decide first whether your
96
- child needs children of its own. When it does, file and release them. Then tell the planner,
97
- with `envoy_publish`, that your child's plan covers only your child's own part and the join of
98
- its children's work. Your child then runs beside its children, so its sign-off waits for its
99
- last round (`skill://legion-architect`, section 3).
100
- - File every child before you request the root spec's approval, and before `register_gate` under
101
- `gates.design: off`: the gate's opening starts the root's own first phase unless the root waits
102
- on another issue, an open child under it or a `blocked_by` link to an issue that is not `done`,
103
- so a child filed after that leaves the root working beside its children.
104
- - A child may wait on a sibling's merge in the same repository with `--blocked-by`.
105
- Release every child at once with `release_children`:
106
- Legion holds a released child until its last blocker closes, and a child is inert only until it
107
- is released.
108
- Each child the daemon starts takes an admission slot of its own, so four started children can
109
- take four of the deployment's cap; when a child holds none, [Admission and the `legion` label](https://cybermonklabs.github.io/legion/legion/concepts/#admission-and-the-legion-label) says.
110
- - Never release a child `--blocked-by` its own parent: the parent now merges last, so that child
111
- would wait forever.
112
- - Do not pass `--assignee`, because the default keeps the tree's questions in one Inbox: under the
113
- shared token a child inherits its parent's assignee (the human who answers the tree's asks), else
114
- the project's default assignee, which a person sets on the Settings page; under a personal token
115
- it goes to that token's owner (`dispatch whoami`). Set it only when a human told you a specific
116
- person owns that child.
117
- - Write a `check` of each child for the update of
118
- `.dispatch/architecture/<id>.md` for each component whose code its pull request changes, when
119
- the project has architecture components (below).
120
-
121
- A role token's `<project>` is not the `--project` above: it is the daemon's own project. The daemon
122
- encodes a token as `legion-<project>-<key>-<role>` with the key lower-cased, so project `acme`,
123
- issue `LEGION-41`, role `architect` is `legion-acme-legion-41-architect`.
28
+ 1. Write each child's spec as `skill://dispatch-writing-specs` says, scaled to the child, each
29
+ requirement a `requirement` block, with its `verification.md`: its workers read only these.
30
+ Cite no item number of another document and copy no text that does not apply to the child.
31
+ 2. Red-team the list with a fresh `task(agent="oracle")`, and `wait` for its verdict. Give it your
32
+ issue's spec, the tree's open children with their repositories and pull requests, and each
33
+ proposed child's title and whole spec, with this mandate: "You did not write this list. Argue
34
+ that each child should not exist. Name every child that is a to-do, a fix found in review, a
35
+ proof of the acceptance of the issue it is filed under, or a part of the architect's own work,
36
+ and say where it folds. Weigh each separate pull request against combining its work: each round
37
+ tests a large pull request whole again, and each small one costs a workspace, an admission
38
+ wait, review, CI, a queue wait and a deploy." A repeated change is one child, and deleting what
39
+ this tree replaced is this tree's work.
40
+ 3. Post the verdict and your folds as one `dispatch comment` on your own issue whose first line is
41
+ exactly `Red-team verdict for <your issue key>:`. The controller's weekly audit reads that line.
42
+ 4. Check each survivor's spec with a fresh `task(agent="plan-gap-analyst")` against
43
+ `skill://dispatch-writing-specs`, `wait` for it, and fix what it flags.
44
+ 5. File only the survivors, and reply under the verdict with their keys:
45
+
46
+ ```bash
47
+ dispatch issue --project <project> --parent "$LEGION_ISSUE" --title '<child outcome>' --spec-file - <<'EOF'
48
+ <the child's spec>
49
+ EOF
50
+ ```
51
+
52
+ 6. Review the version you filed ("Reviewing a child's spec") before `release_children`.
53
+
54
+ - `--project` is the key's prefix (`LEGSMOKE-3` → `LEGSMOKE`). `--parent` is `$LEGION_ISSUE`,
55
+ never a child of yours: that child's own architect files its children.
56
+ - Pass no `--assignee` unless a person names one: the default keeps the tree's questions in one
57
+ Inbox.
58
+ - A child's own architect starts beside its child's planner: decide first whether the child needs
59
+ children. If it does, file and release them, then tell the planner its plan covers only the
60
+ child's own part and the join of their work.
61
+ - Where the project has architecture components, give each child a `check` for the update of
62
+ `.dispatch/architecture/<id>.md` of each component its pull request changes.
63
+ - A role token is `legion-<project>-<key>-<role>` with the daemon's project and the key
64
+ lower-cased: `legion-acme-legion-41-architect`.
124
65
 
125
66
  ## Reviewing a child's spec
126
67
 
127
- A child's spec is never gated, and no person reads it: its parent's review stands in place of the
128
- gate. Review every version of a child's spec and of its Verification document against your own
129
- spec. Review each version whoever wrote it, and before the child's work goes on with it. Review
130
- the version you file a child with before `release_children`, and a later version when you hear
131
- of it.
132
-
133
- 1. Dispatch a fresh reader, `task(agent="plan-reviewer")`, and tell it the documents are a
134
- child's spec and its Verification document. Give it your own spec: a root's at the version its
135
- gate approved, a child's at the version its own parent's review approved. Give it the child's
136
- two documents at the versions you review. Its mandate: *"Does this version serve each
137
- requirement of the parent spec that it names? Does it narrow or contradict any of them? Does it
138
- add scope the parent spec does not ask for? Does each fact it states hold? Check each fact
139
- against the code, the docs or a read-only command."* `wait` for its result, since it runs as a
140
- job of its own.
141
- 2. Decide from its result and your own reading: approve the version, or request changes. Give a
142
- reason for either.
143
- 3. Post one `dispatch comment` on the child issue. Its first line is exactly one of these two,
144
- with the child's key, the spec's version and your own issue's key in place of the
145
- placeholders:
68
+ No person reads a child's spec: review every version of it and of its Verification document,
69
+ whoever wrote it, before the child's work goes on with that version.
70
+
71
+ 1. Have a fresh `task(agent="plan-reviewer")`, told the documents are a child's spec and its
72
+ Verification document, read them against your own spec (a root's at its approved version, a
73
+ child's at the version its parent approved) with this mandate: "Does this version serve each
74
+ requirement of the parent spec that it names? Does it narrow or contradict any? Does it add
75
+ scope the parent spec does not ask for? Check each fact it states against the code, the docs or
76
+ a read-only command." `wait` for its result.
77
+ 2. Approve or request changes, with a reason either way.
78
+ 3. Post one `dispatch comment` on the child whose first line is exactly one of these, and whose
79
+ second line is `Verification document v<m>`; then tell the child's architect with
80
+ `envoy_publish`:
146
81
 
147
82
  ```text
148
83
  Spec review of <child key> v<n> by <parent key>: approved
149
84
  Spec review of <child key> v<n> by <parent key>: changes requested
150
85
  ```
151
86
 
152
- Its second line names the version of the Verification document you read:
153
- `Verification document v<m>`. Your reasons follow.
154
- 4. Tell the child's architect with `envoy_publish` to its role topic (the token rule above). An
155
- architect starts on a child at the child's first phase, so before then the comment is the
156
- record that architect reads when it starts.
157
-
158
- If you are the child's architect:
159
-
160
- - Register no design gate, and call no `dispatch request-approval`.
161
- - When you write a new version of your spec or of your Verification document, tell the
162
- architect above you with `envoy_publish`, naming each document and its version. Its topic is
163
- on your `Legion addressing` line.
164
- - Tell your own workers of that version only after the approving comment. Until then, they keep
165
- to the last version the architect above approved. The newest approving `Spec review of`
166
- comment on your issue names that version.
167
- - On `changes requested`, write a new version that answers each reason, and tell the architect
168
- above again.
169
- - A decision only a person can make is never a decision block in your spec. Send it to the
170
- architect above you with `envoy_publish`. That architect sends it up the same way, and the
171
- root architect asks it on the root (`skill://legion-architect`, "Every turn").
87
+ As the child's architect: tell the architect above you of each new version, naming each document
88
+ and its version; tell your workers of it only after its approving comment; answer
89
+ `changes requested` with a new version. A decision only a person can make goes to the architect
90
+ above you, never into your spec.
172
91
 
173
92
  ## Across repositories
174
93
 
175
- Split a change across repositories into children, each in one repository.
176
- Size their pull requests by the reasons above.
177
- Create each child with:
178
- `dispatch issue --project <project> --parent "$LEGION_ISSUE" --repo <owner/name> …`.
179
- Choose the repository at creation, because the daemon fixes it when it records the child.
180
-
181
- Release a child that depends on another repository's change only after that change's pull request
182
- merges, because the child's work must build on the merged change. Name the merged commit in its
183
- task (`gh api repos/<owner>/<repo>/pulls/<n> --jq .merge_commit_sha`); for a repository that pins the
184
- other one by commit (a lock file or dependency pin), the pin is that commit. Do not hold such a
185
- child with `--blocked-by` instead, because Legion would start it at the blocker's close, before you
186
- name the merged commit. Read another repository with your gh, which reaches every repository your
187
- role's App is installed on (`-R owner/repo`).
94
+ Split a change across repositories into children of one repository each, choosing it at creation
95
+ (`dispatch issue … --repo <owner/name>`). Release a child that builds on another repository's
96
+ change only after that pull request merges, never by `--blocked-by`, which starts it at the
97
+ blocker's close, and name the merged commit in its task
98
+ (`gh api repos/<owner>/<repo>/pulls/<n> --jq .merge_commit_sha`); for a repository that pins the
99
+ other one by commit (a lock file or dependency pin), the pin is that merged commit. Your `gh` reads
100
+ every repository your App is installed on (`-R owner/repo`).
188
101
 
189
102
  ## Recording a wait on other work
190
103
 
191
- Set an issue's `blocked_by` list when its work must wait on an issue outside this tree, of any
192
- Dispatch project (`dispatch issue-update --issue <key> --blocked-by <a> --blocked-by <b>`, which
193
- replaces the whole list, so read the issue's existing links first); Dispatch refuses a link to
194
- another project's issue only to a credential that names one project (`PROJECT_SCOPE`).
195
- That list is how Legion learns of the wait.
196
- An issue the daemon has already started returns its admission slot while a blocker of it is not
197
- `done`, so the deployment's cap goes to work that can move,
198
- except for three roots that keep it: one in `awaiting_person`, one at `admitted` whose design gate has never opened,
199
- and one that arrived from another tree carrying the row it held there
200
- ([Admission and the `legion` label](https://cybermonklabs.github.io/legion/legion/concepts/#admission-and-the-legion-label));
201
- nothing of the waiting issue stops — its workers stay live, its phase does not move, and its
202
- Dispatch status is not written — and it takes one again by itself;
203
- you do nothing for it.
204
-
205
- A blocker's close is the blocker's own Dispatch issue reaching `done`, and nothing more.
206
- It is not a merge of that work, and it is not a deployment of it.
207
- So pick a blocker whose close is the fact the waiting issue needs, and where the fact arrives
208
- later than the close, set the list again at that point rather than letting the issue start early.
209
-
210
- This does not change the rule above:
211
- a child that waits on another repository's merged change is released after that merge, not held by
212
- a link, because a link starts the child no earlier than its blocker's close, which is before you
213
- can name the merged commit.
214
- Releasing a child too early starts work that cannot build;
215
- a `blocked_by` link on a started issue takes a slot from work already under way, which stops
216
- nothing.
104
+ Set an issue's `blocked_by` list when it must wait on an issue outside this tree
105
+ (`dispatch issue-update --issue <key> --blocked-by <a> --blocked-by <b>`, which replaces the whole
106
+ list; a credential scoped to one project cannot link another project's issue: `PROJECT_SCOPE`). A
107
+ blocker's close is its Dispatch issue reaching `done`, not a merge or a deploy: pick a blocker
108
+ whose close is the fact the issue needs. Legion starts the issue once its blockers close.
217
109
 
218
110
  ## A root with no code of its own
219
111
 
220
- When every change of the tree lands through its children, the root's branch has no commit of its
221
- own, and GitHub opens no pull request for a branch with no commits ahead of its base: implementing
222
- would never end. The root's implementer then pushes one empty commit
223
- (`jj new -m '<KEY>: the root of its children; no code of its own'`), writes no trailer itself,
224
- and opens the pull request on it, as its role prompt says; that push starts the required checks
225
- like any other.
226
- Plan no code for the root in that case, and do not create a child only to give the root a commit.
112
+ When every change lands through children, the root's implementer opens its pull request on an empty
113
+ commit. Plan no code for the root, and create no child only to give it a commit.
227
114
 
228
115
  ## Architecture components
229
116
 
230
- A project's architecture sources are the repositories whose `.dispatch/architecture/` files
231
- Dispatch imports as its components (`skill://dispatch`, "Architecture components").
117
+ A project's components are the `.dispatch/architecture/` files Dispatch imports from its source
118
+ repositories (`skill://dispatch`).
232
119
 
233
- - **The components exist:** attach the root before you decompose, so every child inherits it:
120
+ - They exist: attach the root before you decompose, so every child inherits them:
234
121
  `dispatch issue-update --issue <root> --components-json '{"mode":"explicit","ids":[…]}'`.
235
- - **They do not exist yet (bootstrap):** in the root's first PR (the implement worker pushes it),
236
- write `.dispatch/architecture/<id>.md` files for the planned components — front matter `title`,
237
- `parent`, `depends_on`, `external`; no `paths` yet. A project may have several sources, one per
238
- repository, and its model is all of their components together: the file goes in the branch of
239
- the source whose repository holds it, `parent` and `depends_on` name components of that same
240
- source only, and its id must be one no other source of the project uses (a repeated id fails that
241
- source's import, naming the repository that has it). The importer reads the source branch's
242
- head, so leave the root on `inherit` until that PR has merged: an attach before then answers
243
- `400 COMPONENTS_INPUT`, since the component does not exist. After the merge, run
244
- `dispatch architecture-sync --project <KEY>` (every source; `--repo <owner/name>` syncs that one
245
- alone) and attach the root; children created before then inherit it.
246
- - Give a child its own `--components-json` only when it changes a narrower set, and
247
- `{"mode":"none","reason":"…"}` when it changes no code or file a component describes.
122
+ - They do not: the root's first pull request writes `.dispatch/architecture/<id>.md` for each
123
+ planned component (front matter `title`, `parent`, `depends_on`, `external`; no `paths`) in the
124
+ repository that holds it, with an id no other source uses. Leave the root on `inherit` until it
125
+ merges (an earlier attach answers `400 COMPONENTS_INPUT`), then run
126
+ `dispatch architecture-sync --project <KEY>` and attach.
127
+ - Give a child its own `--components-json` only for a narrower set, and
128
+ `{"mode":"none","reason":"…"}` when it changes no code a component describes.