archik 0.19.5 → 0.21.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-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -5
- package/README.md +32 -30
- package/commands/accept.md +21 -47
- package/commands/bootstrap.md +29 -28
- package/commands/evolve.md +19 -50
- package/commands/migrate.md +60 -60
- package/commands/self-evolving.md +8 -7
- package/commands/spawn.md +36 -38
- package/commands/suggest.md +47 -53
- package/dist/cli/archik.mjs +529 -572
- package/dist/ui/assets/index-B9OpuGHk.js +226 -0
- package/dist/ui/assets/index-DUgLHSFs.css +1 -0
- package/dist/ui/index.html +2 -2
- package/docs/templates/CLAUDE.md +73 -150
- package/docs/templates/principles/functional.md +2 -3
- package/docs/templates/principles/oop.md +3 -4
- package/docs/templates/superpowers.md +4 -4
- package/package.json +1 -7
- package/skills/archik/SKILL.md +71 -311
- package/commands/actor.md +0 -89
- package/commands/alpha.md +0 -73
- package/commands/trace.md +0 -57
- package/commands/usecase.md +0 -134
- package/dist/trace.d.ts +0 -18
- package/dist/trace.js +0 -58
- package/dist/ui/assets/index-BrvxaIkh.css +0 -1
- package/dist/ui/assets/index-C1kLj8Cy.js +0 -226
package/commands/migrate.md
CHANGED
|
@@ -1,84 +1,84 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Finish a migration —
|
|
2
|
+
description: Finish a migration — check the result and fix what the migrator flagged
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
# /archik:migrate —
|
|
5
|
+
# /archik:migrate — check what the deterministic migration did
|
|
6
6
|
|
|
7
|
-
`archik upgrade --migrate
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
use cases / sequence diagrams.* Your job is to back-fill those, grounded
|
|
12
|
-
in **both** the current model and the **archived original**.
|
|
7
|
+
`archik migrate` (or `archik upgrade --migrate`, which runs it through
|
|
8
|
+
the newly installed version) already ran the **deterministic** migration:
|
|
9
|
+
it archived the old project, ran each pending step, validated, and
|
|
10
|
+
advanced `.archik/.version`. The current steps are:
|
|
13
11
|
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
- **#1** — move a legacy root `architecture.archik.yaml` into
|
|
13
|
+
`.archik/main.archik.yaml`.
|
|
14
|
+
- **#3** — strip retired node fields (`stereotype`, `seqFiles`) from the
|
|
15
|
+
model files.
|
|
16
|
+
- **#4** — move retired use-case, sequence, actor, alpha and trace files
|
|
17
|
+
to `.archik/retired/`, strip retired fields from pending suggestions,
|
|
18
|
+
and flag code, CI and scripts that still use removed features.
|
|
16
19
|
|
|
17
|
-
|
|
20
|
+
(#2, the old use-case back-fill, is retired and never runs.)
|
|
18
21
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
22
|
+
The deterministic steps are done. Do NOT redo them. Your job is to check
|
|
23
|
+
the result against the **archived original** and fix anything the
|
|
24
|
+
migrator printed as needing judgment. `archik validate` is your gate.
|
|
25
|
+
|
|
26
|
+
## CLI-only for architecture
|
|
27
|
+
|
|
28
|
+
Interact with the architecture diagram only through `npx archik`. Never
|
|
29
|
+
edit `.archik/main.archik.yaml` by hand — changes go through
|
|
30
|
+
`suggest set` → `accept`. **Never delete `.archik.archive/`** — it is the
|
|
31
|
+
developer's only copy of the pre-migration project.
|
|
24
32
|
|
|
25
33
|
## Steps
|
|
26
34
|
|
|
27
|
-
1. **
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
35
|
+
1. **Read the migrator's output.** Any `ⓘ` line it printed is a task for
|
|
36
|
+
you. If it printed none, the steps below are a quick check only.
|
|
37
|
+
The usual ones from 0.19 and older:
|
|
38
|
+
- **moved N retired files to `.archik/retired/`** — tell the user
|
|
39
|
+
they are kept only as history. Ask before deleting them. If a use
|
|
40
|
+
case explains *why* a structure exists, offer to capture that as a
|
|
41
|
+
decision record with the next `/archik:suggest` touching that area.
|
|
42
|
+
- **pending suggestion … has no decision record** — read it with
|
|
43
|
+
`npx archik suggest show`, then either re-stage it with a decision
|
|
44
|
+
record (`/archik:suggest`) or ask the user to reject it.
|
|
45
|
+
- **code imports `archik/trace`** — the recorder is gone. Remove the
|
|
46
|
+
`trace(...)` calls and the import from those test files; keep the
|
|
47
|
+
tests' real assertions. Run the tests afterwards.
|
|
48
|
+
- **workflow uses `trace-fail-on`** — replace it with
|
|
49
|
+
`smells-fail: true` (or drop it). On existing code, offer
|
|
50
|
+
`npx archik smells --update-baseline` first so CI fails only on
|
|
51
|
+
new smells.
|
|
52
|
+
- **package.json scripts call a removed command** — remove the
|
|
53
|
+
script or replace it (`archik smells`, `archik drift`).
|
|
34
54
|
|
|
35
|
-
2. **
|
|
36
|
-
Find the newest archive and read the old project's intent (descriptions,
|
|
37
|
-
any notes, the old structure) so the back-fill reflects what the
|
|
38
|
-
developer actually built, not a generic guess:
|
|
55
|
+
2. **Find the archived original.**
|
|
39
56
|
```bash
|
|
40
57
|
ls -t .archik.archive/ # newest timestamp dir is the pre-migration copy
|
|
41
58
|
```
|
|
42
59
|
Read the files under that dir with the `Read` tool (the archive is a
|
|
43
60
|
plain backup, not a live archik doc — reading it directly is correct).
|
|
61
|
+
Note any old use case, sequence, or stereotype files there: their
|
|
62
|
+
content is no longer modelled. Do not recreate them.
|
|
44
63
|
|
|
45
|
-
3. **
|
|
46
|
-
intent with the live structure:
|
|
47
|
-
```bash
|
|
48
|
-
npx archik q stats
|
|
49
|
-
npx archik q list
|
|
50
|
-
npx archik q edges
|
|
51
|
-
```
|
|
52
|
-
|
|
53
|
-
4. **Author actors first** (if `q actors` was empty). Use cases reference
|
|
54
|
-
actors by id, and validate rejects a use case whose `primaryActor`
|
|
55
|
-
isn't in the actor index. Direct-write `.archik/actors.archik.actors.yaml`
|
|
56
|
-
(schema: `npx archik schema actors`), then `npx archik validate`.
|
|
57
|
-
|
|
58
|
-
5. **Author one use case per real flow.** Direct-write
|
|
59
|
-
`.archik/usecases/<id>.archik.uc.yaml` (schema: `npx archik schema uc`).
|
|
60
|
-
Mark each slice `status: proposed` and give it `tests:` paths only if
|
|
61
|
-
those files exist on disk — otherwise omit `tests` (active slices
|
|
62
|
-
require on-disk tests). Validate after each:
|
|
63
|
-
`npx archik validate .archik/main.archik.yaml`.
|
|
64
|
-
|
|
65
|
-
6. **Author a sequence diagram per primary slice.** Direct-write
|
|
66
|
-
`.archik/<usecase>.<slice>.archik.seq.yaml` (schema: `npx archik schema seq`).
|
|
67
|
-
Every participant `nodeId` must be a real node; add a `realizes` block
|
|
68
|
-
AND point the slice's `realization.seqFile` back at the file
|
|
69
|
-
(bidirectional). Add the seq to each participating node's `seqFiles`
|
|
70
|
-
via the normal `suggest set` → `accept` workflow.
|
|
71
|
-
|
|
72
|
-
7. **Verify and report.** Then propose the natural next step (write the
|
|
73
|
-
tests the slices name, flip them to `active`), don't end on "done":
|
|
64
|
+
3. **Check the live model.**
|
|
74
65
|
```bash
|
|
75
66
|
npx archik validate .archik/main.archik.yaml
|
|
76
|
-
npx archik
|
|
67
|
+
npx archik q stats
|
|
77
68
|
npx archik drift
|
|
69
|
+
npx archik smells
|
|
78
70
|
```
|
|
71
|
+
If `validate` reports `unrecognized key … removed in archik 0.20`,
|
|
72
|
+
the migration did not run with the new version — run
|
|
73
|
+
`npx archik migrate` and check again.
|
|
74
|
+
|
|
75
|
+
4. **Fix gaps through the normal workflow.** If drift or the archive
|
|
76
|
+
shows structure the model misses (a node, an edge, a `parentId`
|
|
77
|
+
container), stage it with `/archik:suggest`. Don't bulk-restructure.
|
|
79
78
|
|
|
80
79
|
## Done when
|
|
81
80
|
|
|
82
|
-
`archik validate` is clean
|
|
83
|
-
|
|
84
|
-
stays untouched as the
|
|
81
|
+
`archik validate` is clean, every `ⓘ` line from the migrator is
|
|
82
|
+
handled, and you proposed the natural next step (fix drift, cut a folder
|
|
83
|
+
loop that `smells` found). The archive stays untouched as the
|
|
84
|
+
developer's rollback.
|
|
@@ -35,8 +35,9 @@ Never `Read`/`Write`/`Edit` files under `.archik/`.
|
|
|
35
35
|
No feedback signal = no evolution loop; help them find one first.
|
|
36
36
|
|
|
37
37
|
3. **Ground in the current diagram** (`npx archik q stats`, `q list`).
|
|
38
|
-
If the project is empty, model the *base system* first —
|
|
39
|
-
|
|
38
|
+
If the project is empty, model the *base system* first — the
|
|
39
|
+
smallest structure for one thing to ship, per the normal archik
|
|
40
|
+
opening move.
|
|
40
41
|
|
|
41
42
|
4. **Map the idea onto the loop.** For each stage, name the concrete
|
|
42
43
|
component in THEIR system:
|
|
@@ -54,12 +55,12 @@ Never `Read`/`Write`/`Edit` files under `.archik/`.
|
|
|
54
55
|
(stages the blueprint as `status: proposed` nodes), then refine
|
|
55
56
|
ids/names with a follow-up `suggest set`.
|
|
56
57
|
- Tailored: author the full end-state and stage via
|
|
57
|
-
`npx archik suggest set --note '…' - <<'YAML' … YAML
|
|
58
|
+
`npx archik suggest set --note '…' - <<'YAML' … YAML`, with a
|
|
59
|
+
decision record under `metadata.suggestion.decision` (required).
|
|
58
60
|
|
|
59
|
-
6. **Wire the
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
each naming test paths.
|
|
61
|
+
6. **Wire the tests.** Name one test per loop step: "corrections are
|
|
62
|
+
recorded", "insights become proposals", "approved change applies".
|
|
63
|
+
Add them to the build plan after accept.
|
|
63
64
|
|
|
64
65
|
7. **Hand over.** Show the canvas URL, summarize which patterns you
|
|
65
66
|
used and why, and point at `npx archik evolution enable` if they
|
package/commands/spawn.md
CHANGED
|
@@ -87,30 +87,12 @@ archik suggest set` stages it.
|
|
|
87
87
|
- **Frontends**: `apps/web`, `apps/mobile`, `client/`,
|
|
88
88
|
`packages/ui` apps that ship a UI → `frontend`.
|
|
89
89
|
|
|
90
|
-
5. **Choose the kind
|
|
90
|
+
5. **Choose the kind for each node.** Default
|
|
91
91
|
kind: `service`. Use the taxonomy from the skill — `function`
|
|
92
92
|
for serverless, `worker` for background consumers, `agent` for
|
|
93
93
|
LLM-driven agents, etc. When unsure, pick the closest fit and
|
|
94
94
|
add a `notes:` entry explaining the inference.
|
|
95
95
|
|
|
96
|
-
For every node that faces a user or external system, also infer
|
|
97
|
-
its ECB `stereotype`:
|
|
98
|
-
- `stereotype: boundary` — accepts requests from actors / external
|
|
99
|
-
systems: API handlers, gateways, adapters, webhook endpoints,
|
|
100
|
-
BFF layers. Rule of thumb: the first thing an actor touches.
|
|
101
|
-
- `stereotype: control` — orchestrates use-case logic: services
|
|
102
|
-
that coordinate domain objects, use-case handlers, workflow
|
|
103
|
-
engines. Rule of thumb: knows *what* to do but delegates *how*.
|
|
104
|
-
- `stereotype: entity` — stores or represents domain data:
|
|
105
|
-
repositories, domain models, DB-backed modules, caches.
|
|
106
|
-
Rule of thumb: knows the data and its invariants.
|
|
107
|
-
|
|
108
|
-
If a node's role is purely infrastructure (`database`, `queue`,
|
|
109
|
-
`external`, `cloud`, etc.) or genuinely ambiguous, omit
|
|
110
|
-
`stereotype` — don't guess. The field is optional and the
|
|
111
|
-
validator only enforces ECB transition rules on seq diagrams
|
|
112
|
-
that carry a `realizes` block.
|
|
113
|
-
|
|
114
96
|
6. **Attach `sourcePath` to every code-bearing node.** This is
|
|
115
97
|
non-negotiable in a normal/suggested file — the validator rejects
|
|
116
98
|
any `service`, `function`, `worker`, `module`, `page`, `component`,
|
|
@@ -173,6 +155,13 @@ archik suggest set` stages it.
|
|
|
173
155
|
name: <Id> Internals
|
|
174
156
|
nodes: [ ... ]
|
|
175
157
|
edges: [ ... ]
|
|
158
|
+
metadata:
|
|
159
|
+
suggestion:
|
|
160
|
+
decision:
|
|
161
|
+
context: <why this split is needed>
|
|
162
|
+
decision: <what you chose>
|
|
163
|
+
alternatives: [<option not chosen>]
|
|
164
|
+
consequences: <what gets easier and harder>
|
|
176
165
|
YAML
|
|
177
166
|
# mechanical: puts sub-file on disk so the main draft's
|
|
178
167
|
# archikFile: pointer validates. NOT the user's review gate
|
|
@@ -209,9 +198,21 @@ archik suggest set` stages it.
|
|
|
209
198
|
# full proposed end-state, with archikFile pointers
|
|
210
199
|
edges:
|
|
211
200
|
# ...
|
|
201
|
+
metadata:
|
|
202
|
+
suggestion:
|
|
203
|
+
decision:
|
|
204
|
+
context: <what the source tree shows and why it is split this way>
|
|
205
|
+
decision: <what you chose>
|
|
206
|
+
alternatives: [<option not chosen>]
|
|
207
|
+
consequences: <what gets easier and harder>
|
|
212
208
|
YAML
|
|
213
209
|
```
|
|
214
210
|
|
|
211
|
+
Every draft needs its decision record — `suggest set` refuses
|
|
212
|
+
one without it. For a spawn, the context is what the source
|
|
213
|
+
tree shows; the alternatives are other ways to cut it (one
|
|
214
|
+
flat file, a different grouping).
|
|
215
|
+
|
|
215
216
|
c. If `suggest set` reports validation errors, re-run with the
|
|
216
217
|
corrected YAML. Never edit the sidecar by hand.
|
|
217
218
|
|
|
@@ -223,27 +224,24 @@ archik suggest set` stages it.
|
|
|
223
224
|
`/archik:evolve` after accepting if you want a cleaner
|
|
224
225
|
bounded-context version."
|
|
225
226
|
|
|
226
|
-
**Offer
|
|
227
|
-
|
|
228
|
-
before framing the offer:
|
|
227
|
+
**Offer a smells check at the end of this step** (not after
|
|
228
|
+
accept — you won't be there). Run it now so the offer is concrete:
|
|
229
229
|
```
|
|
230
|
-
npx archik
|
|
231
|
-
npx archik q usecases
|
|
230
|
+
npx archik smells
|
|
232
231
|
```
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
Do NOT
|
|
245
|
-
|
|
246
|
-
from the user. This note is a prompt, not an action.
|
|
232
|
+
If it finds folder loops or oversized files, close with:
|
|
233
|
+
*"Once you accept, want me to look at the folder loop between
|
|
234
|
+
`<a>` and `<b>`? The cheapest cut is `<file imports "specifier">`."*
|
|
235
|
+
If it finds none, skip this line.
|
|
236
|
+
|
|
237
|
+
Existing code almost always has some debt. Also offer the
|
|
238
|
+
baseline so CI can gate on *new* smells from now on: *"Want me to
|
|
239
|
+
save today's findings as the baseline (`npx archik smells
|
|
240
|
+
--update-baseline`, commit `.archik/smells-baseline.json`)? Then
|
|
241
|
+
`--fail-on-warn` only fails on new loops or growing files."*
|
|
242
|
+
|
|
243
|
+
Do NOT fix smells here — spawn is descriptive, and the fix is a
|
|
244
|
+
separate ask from the user. This note is a prompt, not an action.
|
|
247
245
|
|
|
248
246
|
## Notes
|
|
249
247
|
|
package/commands/suggest.md
CHANGED
|
@@ -26,7 +26,7 @@ the contract with the user.
|
|
|
26
26
|
|
|
27
27
|
The skill defines a 5-phase loop: **Discover → Design → Decide → Build
|
|
28
28
|
→ Verify**. This command covers Discover (grounding) and Design
|
|
29
|
-
(staging the sidecar with
|
|
29
|
+
(staging the sidecar with its decision record), then hands off to the user's
|
|
30
30
|
review and the explicit Decide gate (`/archik:accept` or
|
|
31
31
|
`/archik:reject`). Don't skip clarification just because a slash
|
|
32
32
|
command was typed — clarification is what makes the draft good. Don't
|
|
@@ -37,10 +37,6 @@ start Build phase here; that's gated on accept.
|
|
|
37
37
|
0. **Frame + clarify (entering DESIGN).** Before any CLI call, restate
|
|
38
38
|
the user's intent in one sentence and list 1–3 sharp clarifying
|
|
39
39
|
questions if any of these are ambiguous in `$ARGUMENTS`:
|
|
40
|
-
- **Actor + use case** — which actor initiates this? Does an
|
|
41
|
-
existing use case cover it, or is this a new user-visible
|
|
42
|
-
behaviour? (Check `npx archik q actors` and `q usecases` in
|
|
43
|
-
step 2 before asking if the answer isn't obvious from the brief.)
|
|
44
40
|
- **Boundary** — which existing context owns this, or is it a new
|
|
45
41
|
one? (data ownership = bounded context)
|
|
46
42
|
- **Sync vs async** — request/response (`http_call`) or
|
|
@@ -57,15 +53,6 @@ start Build phase here; that's gated on accept.
|
|
|
57
53
|
don't ask questions for the sake of asking.** When in doubt, ask
|
|
58
54
|
the user "you decide?" so they can defer back if they want.
|
|
59
55
|
|
|
60
|
-
**Before the structural sidecar, check if the feature needs
|
|
61
|
-
requirements artifacts first:**
|
|
62
|
-
- New human-facing flow or actor? Create/update
|
|
63
|
-
`*.archik.actors.yaml` (direct-write) before staging the sidecar.
|
|
64
|
-
- New user-visible behaviour? Author a `*.archik.uc.yaml` under
|
|
65
|
-
`.archik/usecases/` (direct-write) with the flow and at least one
|
|
66
|
-
slice before staging the sidecar. The structural model references
|
|
67
|
-
what the use case requires.
|
|
68
|
-
|
|
69
56
|
1. **Make sure the canvas is running** so the user can review:
|
|
70
57
|
```
|
|
71
58
|
npx archik status
|
|
@@ -85,23 +72,6 @@ start Build phase here; that's gated on accept.
|
|
|
85
72
|
If `$ARGUMENTS` mentions a specific node by name, also run
|
|
86
73
|
`npx archik q describe <id>` for it.
|
|
87
74
|
|
|
88
|
-
If the change is **non-trivial** (new actor, new user-visible
|
|
89
|
-
behaviour, boundary impact, more than one node affected) also
|
|
90
|
-
ground in the requirements model:
|
|
91
|
-
```
|
|
92
|
-
npx archik q actors
|
|
93
|
-
npx archik q usecases
|
|
94
|
-
```
|
|
95
|
-
If any use case looks related, run
|
|
96
|
-
`npx archik q describe-usecase <id>` to see its slices and
|
|
97
|
-
check whether the proposed change extends, modifies, or
|
|
98
|
-
introduces a UC — that determines whether you need to update
|
|
99
|
-
a `*.archik.uc.yaml` before staging the structural sidecar.
|
|
100
|
-
|
|
101
|
-
If step 0 already determined the change is trivially small
|
|
102
|
-
(one node, one edge, no boundary or UC impact), skip the
|
|
103
|
-
actor/UC queries and go straight to step 3.
|
|
104
|
-
|
|
105
75
|
3. **Lock in the schema.** Run this before drafting any YAML —
|
|
106
76
|
the prose in this file describes the workflow, not the field
|
|
107
77
|
shapes. The CLI is the schema:
|
|
@@ -135,18 +105,6 @@ start Build phase here; that's gated on accept.
|
|
|
135
105
|
not just its kind or name. Empty / missing descriptions are
|
|
136
106
|
rejected by the validator.
|
|
137
107
|
|
|
138
|
-
**For nodes that participate in a use case flow**, add a
|
|
139
|
-
`stereotype` field to classify their role in the ECB model:
|
|
140
|
-
- `stereotype: boundary` — accepts requests from actors / external
|
|
141
|
-
systems (adapters, gateways, API handlers)
|
|
142
|
-
- `stereotype: control` — orchestrates the use case logic (services,
|
|
143
|
-
use-case handlers, orchestrators)
|
|
144
|
-
- `stereotype: entity` — stores or represents domain data (repos,
|
|
145
|
-
domain models, DB-backed modules)
|
|
146
|
-
|
|
147
|
-
The validator enforces ECB transition rules on seq diagrams that
|
|
148
|
-
carry a `realizes` block — tag the nodes now so the rules can fire.
|
|
149
|
-
|
|
150
108
|
```bash
|
|
151
109
|
npx archik suggest set --note "$ARGUMENTS" - <<'YAML'
|
|
152
110
|
version: "1.0"
|
|
@@ -155,23 +113,51 @@ start Build phase here; that's gated on accept.
|
|
|
155
113
|
# full proposed end-state — every node, not just the delta
|
|
156
114
|
edges:
|
|
157
115
|
# full proposed end-state — every edge, not just the delta
|
|
116
|
+
metadata:
|
|
117
|
+
suggestion:
|
|
118
|
+
decision:
|
|
119
|
+
context: <the problem and the forces — facts, not the solution>
|
|
120
|
+
decision: <what you chose, 1–2 sentences>
|
|
121
|
+
alternatives:
|
|
122
|
+
- <a real option you weighed and did not choose>
|
|
123
|
+
consequences: <what gets easier AND what gets harder>
|
|
124
|
+
# crossCutting: # REQUIRED when the change adds data, an
|
|
125
|
+
# security: ... # outside system or public traffic
|
|
126
|
+
# observability: ...
|
|
127
|
+
# rollback: ...
|
|
128
|
+
# supersedes: ["0003"] # only when this reverses an earlier record
|
|
158
129
|
YAML
|
|
159
130
|
```
|
|
160
131
|
|
|
132
|
+
The decision record is required — `suggest set` refuses a draft
|
|
133
|
+
without it, and accept writes it to
|
|
134
|
+
`.archik/decisions/NNNN-<slug>.md`. Before writing it, read the
|
|
135
|
+
past records for the area (`ls .archik/decisions/`, they are plain
|
|
136
|
+
markdown). If your change reverses one, list it in `supersedes`.
|
|
137
|
+
|
|
138
|
+
`suggest set` prints whether the change is a **one-way door** (hard
|
|
139
|
+
to undo: a new data store, queue/stream, external system,
|
|
140
|
+
gateway/auth/cdn, cloud or LLM node, a new edge to an external
|
|
141
|
+
system, a new top-level module, a removal, a boundary move) or a
|
|
142
|
+
**two-way door**. If it adds data, an outside system or public
|
|
143
|
+
traffic it refuses the draft until `crossCutting` says how it is
|
|
144
|
+
**secured** (who can reach it, secrets, data exposure),
|
|
145
|
+
**observed** (the signal that shows it working or failing) and
|
|
146
|
+
**rolled back** (how to undo it safely). Write real answers, not
|
|
147
|
+
placeholders — the plan must later land what you promise here.
|
|
148
|
+
|
|
161
149
|
If the command exits non-zero, re-run with the corrected YAML.
|
|
162
150
|
Never write a draft file under `.archik/` and never edit the
|
|
163
151
|
sidecar directly.
|
|
164
152
|
|
|
165
|
-
5. **
|
|
166
|
-
handing off to review
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
-
|
|
171
|
-
|
|
172
|
-
- **
|
|
173
|
-
should default to async).
|
|
174
|
-
- Any **alternative you rejected** and the trade-off.
|
|
153
|
+
5. **Summarise the decision record** in 2–4 short bullets before
|
|
154
|
+
handing off to review — the same content the record holds, so the
|
|
155
|
+
user can judge the *why* next to the diagram (the canvas also shows
|
|
156
|
+
it under **Why** on the review banner). Make sure it covers:
|
|
157
|
+
- Which **boundaries** the change touches and why those boundaries.
|
|
158
|
+
- What each new node owns and why it is its own node.
|
|
159
|
+
- **Async vs sync** choice and the reason.
|
|
160
|
+
- The **alternatives** you rejected and what the choice costs.
|
|
175
161
|
|
|
176
162
|
Keep it tight — bullets, not paragraphs. The diagram does the rest.
|
|
177
163
|
|
|
@@ -183,6 +169,14 @@ start Build phase here; that's gated on accept.
|
|
|
183
169
|
**reject** and tell me what didn't fit (boundary? relationship?
|
|
184
170
|
scope? naming? composition? lifecycle?) so I can revise."
|
|
185
171
|
|
|
172
|
+
Match the gate to the door:
|
|
173
|
+
- **One-way door** — say so ("This is hard to undo: <reasons>")
|
|
174
|
+
and hand off the sidecar alone. The build plan comes after
|
|
175
|
+
accept, as its own approval gate.
|
|
176
|
+
- **Two-way door** — include the numbered build plan in this same
|
|
177
|
+
hand-off, and say that `/archik:accept` approves both the model
|
|
178
|
+
change and the plan.
|
|
179
|
+
|
|
186
180
|
Do NOT pre-emptively start implementing. Wait for `/archik:accept`.
|
|
187
181
|
|
|
188
182
|
## Notes
|