arkgate 4.8.13 → 4.8.15
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 +219 -4
- package/README.md +33 -22
- package/SECURITY.md +5 -3
- package/bin/ark-check-runtime.mjs +25 -57
- package/bin/ark-mcp-runtime.mjs +111 -2
- package/bin/ark-shared.mjs +140 -11
- package/bin/ark.mjs +7 -25
- package/bin/lib/adr-presence.mjs +97 -0
- package/bin/lib/agent-projection-formatters.mjs +2 -0
- package/bin/lib/agent-skills-package.mjs +241 -8
- package/bin/lib/analysis-completeness.mjs +38 -2
- package/bin/lib/analysis-engine.mjs +6 -6
- package/bin/lib/architecture-scan.mjs +33 -5
- package/bin/lib/ark-order-doctor.mjs +7 -1
- package/bin/lib/ark-order-report.mjs +2 -1
- package/bin/lib/ark-run-doctor.mjs +6 -0
- package/bin/lib/ark-run-report.mjs +6 -2
- package/bin/lib/arkrules-sensors.mjs +81 -0
- package/bin/lib/baseline-key.mjs +4 -1
- package/bin/lib/check-args.mjs +52 -2
- package/bin/lib/ci-and-commands.mjs +7 -2
- package/bin/lib/config-contract.mjs +64 -1
- package/bin/lib/design-smells.mjs +21 -1
- package/bin/lib/diagnostic-catalog.mjs +5 -3
- package/bin/lib/doctor-advisories.mjs +109 -17
- package/bin/lib/doctor-human.mjs +20 -6
- package/bin/lib/doctor-next-actions.mjs +14 -0
- package/bin/lib/doctor-plan.mjs +32 -2
- package/bin/lib/enforcement-honesty.mjs +47 -2
- package/bin/lib/first-run-help.mjs +19 -3
- package/bin/lib/gate-files.mjs +40 -3
- package/bin/lib/host-support-matrix.mjs +9 -1
- package/bin/lib/html-report-depth.mjs +2 -0
- package/bin/lib/html-report.mjs +13 -2
- package/bin/lib/import-resolve.mjs +74 -13
- package/bin/lib/improvement-compass-doctor.mjs +6 -1
- package/bin/lib/improvement-compass-map.mjs +3 -1
- package/bin/lib/install-migrate.mjs +23 -0
- package/bin/lib/layer-description.mjs +90 -8
- package/bin/lib/mcp-hook-payload.mjs +57 -1
- package/bin/lib/no-domain-frontend.mjs +91 -0
- package/bin/lib/presets.mjs +3 -4
- package/bin/lib/product-copy.mjs +19 -0
- package/bin/lib/projected-governed-coverage.mjs +114 -0
- package/bin/lib/recommend-cli.mjs +54 -0
- package/bin/lib/remediation.mjs +6 -2
- package/bin/lib/resolved-candidate-facts.mjs +225 -100
- package/bin/lib/rules-under-contract.mjs +117 -2
- package/bin/lib/scan-files.mjs +39 -0
- package/bin/lib/snippet-analysis.mjs +14 -8
- package/bin/lib/start-preview.mjs +8 -2
- package/bin/lib/states-transitions-presence.mjs +212 -0
- package/bin/lib/status-command.mjs +2 -0
- package/bin/lib/status-transition-catalog.mjs +410 -0
- package/bin/lib/team-parliament-io.mjs +10 -0
- package/bin/lib/upgrade-whats-new.mjs +3 -3
- package/bin/lib/violations.mjs +43 -1
- package/bin/lib/write-path-capabilities.mjs +20 -5
- package/bin/lib/write-path-detect.mjs +27 -2
- package/dist/{configTypes-j7so8B4O.d.ts → configTypes-Dt3DpVbd.d.ts} +19 -0
- package/dist/{diagnosticCatalog-DA565Lja.d.ts → diagnosticCatalog-BEg85XlE.d.ts} +3 -3
- package/dist/eslint/index.cjs +4 -4
- package/dist/eslint/index.d.ts +1 -1
- package/dist/eslint/index.js +4 -4
- package/dist/index.cjs +31 -31
- package/dist/index.d.ts +126 -19
- package/dist/index.js +31 -31
- package/dist/nestjs/index.cjs +5 -5
- package/dist/nestjs/index.d.ts +3 -3
- package/dist/nestjs/index.js +5 -5
- package/dist/runtime/index.cjs +15 -15
- package/dist/runtime/index.d.ts +6 -6
- package/dist/runtime/index.js +15 -15
- package/dist/{types-Djbs3KjE.d.ts → types-CN9tVMPz.d.ts} +3 -1
- package/dist/{types-tGhZUiGX.d.ts → types-TBiv0WHL.d.ts} +1 -1
- package/docs/README.md +8 -6
- package/docs/agent-guide.md +35 -17
- package/docs/ai-gates.md +13 -4
- package/docs/arkorder.md +11 -4
- package/docs/brownfield-adoption.md +4 -1
- package/docs/configuration.md +63 -14
- package/docs/develop.md +4 -1
- package/docs/diagnostics.md +30 -10
- package/docs/enthusiast/README.md +6 -1
- package/docs/enthusiast/how-to-agent-gates.md +5 -0
- package/docs/enthusiast/how-to-gallery-starter.md +2 -1
- package/docs/enthusiast/how-to-pick-shape.md +1 -1
- package/docs/package-surface.md +10 -6
- package/docs/product-voice.md +32 -6
- package/docs/threat-model.md +2 -2
- package/docs/typescript-support.md +3 -3
- package/docs/use.md +23 -11
- package/package.json +1 -1
- package/schemas/ark.config.schema.json +23 -2
- package/server.json +2 -2
- package/templates/agent-skills/README.md +7 -4
- package/templates/agent-skills/ark-adopt/SKILL.md +91 -6
- package/templates/agent-skills/ark-architect/SKILL.md +5 -18
- package/templates/agent-skills/ark-autopilot/SKILL.md +14 -6
- package/templates/agent-skills/ark-contract/SKILL.md +9 -20
- package/templates/agent-skills/ark-coverage/SKILL.md +13 -9
- package/templates/agent-skills/ark-explain/SKILL.md +11 -5
- package/templates/agent-skills/ark-explore/SKILL.md +39 -5
- package/templates/agent-skills/ark-fix/SKILL.md +15 -20
- package/templates/agent-skills/ark-loop/SKILL.md +14 -20
- package/templates/agent-skills/ark-order/SKILL.md +200 -0
- package/templates/agent-skills/ark-place/SKILL.md +49 -11
- package/templates/agent-skills/ark-runtime/SKILL.md +21 -6
- package/templates/agent-skills/ark-think/SKILL.md +24 -126
- package/templates/agent-skills/ark-upgrade/SKILL.md +14 -3
- package/templates/arkrules/DomainModel.json +14 -1
- package/templates/skills/ark-adopt.md +91 -6
- package/templates/skills/ark-architect.md +5 -18
- package/templates/skills/ark-autopilot.md +14 -6
- package/templates/skills/ark-contract.md +9 -20
- package/templates/skills/ark-coverage.md +13 -9
- package/templates/skills/ark-explain.md +11 -5
- package/templates/skills/ark-explore.md +39 -5
- package/templates/skills/ark-fix.md +15 -20
- package/templates/skills/ark-loop.md +14 -20
- package/templates/skills/ark-order.md +200 -0
- package/templates/skills/ark-place.md +49 -11
- package/templates/skills/ark-runtime.md +21 -6
- package/templates/skills/ark-think.md +24 -126
- package/templates/skills/ark-upgrade.md +14 -3
- package/templates/tests/ark-adoption-gaps.test.ts +5 -4
|
@@ -5,13 +5,8 @@ description: Shortcut to /ark-adopt for a new tree. Deprecated as a first-class
|
|
|
5
5
|
|
|
6
6
|
# /ark-architect — Shortcut to /ark-adopt
|
|
7
7
|
|
|
8
|
-
**Not a first-
|
|
9
|
-
Do that job now.
|
|
10
|
-
|
|
11
|
-
## Autonomy contract
|
|
12
|
-
|
|
13
|
-
Invoking this skill **is** the approval to mark the path. Write `ark.config.json` and
|
|
14
|
-
phase-1 dirs in this turn. Then `ark-check`.
|
|
8
|
+
**Not a first-class door.** One-release redirect. Session 0 is **`/ark-adopt`**.
|
|
9
|
+
Do that job now. Contener · Guiar · Ordenar — this leftover name is not a star.
|
|
15
10
|
|
|
16
11
|
## When / not when
|
|
17
12
|
|
|
@@ -40,25 +35,17 @@ restart/retargeting is required. `ark://manifest` never satisfies this preflight
|
|
|
40
35
|
|
|
41
36
|
Then call **`ark_recommend`** with the same bound `project` envelope (or `ark-check --recommend`).
|
|
42
37
|
|
|
43
|
-
## Dual plane — layers + extras (mandatory, except /ark-runtime)
|
|
44
|
-
|
|
45
|
-
Label findings **`[Layer]`** vs **`[ArkRules]`** vs **`[ArkRun]`** vs **`[ArkOrder]`**. Absence of extras is valid and silent. Session-0 extras (advisory `arkRun` / advisory `arkOrder`) live on **`/ark-adopt`**. When ArkOrder is on: first freeze `release()`, later ξ is `proposeRelease` then `apply`; `refreshSigma`; ingest residual `absorb | escalate_up | hold`; capacity pack as data; in-memory `ReleaseStore`; ArkRun `decisionTape`. Do not invent `/ark-run` or `/ark-order`. Skills never enforce.
|
|
46
|
-
|
|
47
38
|
## Subagent fan-out (optional, host-dependent)
|
|
48
39
|
|
|
49
40
|
If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
50
41
|
**fall back to sequential**. Never weaken the gate.
|
|
51
42
|
|
|
52
|
-
## Related onboarding
|
|
53
|
-
|
|
54
|
-
- **Greenfield:** this shortcut → **`/ark-adopt`** + `ark-check --recommend` / `ark start`.
|
|
55
|
-
- **Brownfield:** `/ark-adopt` — do not force a starter preset.
|
|
56
|
-
|
|
57
43
|
## Steps
|
|
58
44
|
|
|
59
45
|
1. Bind MCP (`ark_identity` then `ark_recommend`) or run `ark-check --recommend`.
|
|
60
|
-
2. Execute **`/ark-adopt`**
|
|
61
|
-
3.
|
|
46
|
+
2. Execute **`/ark-adopt`** now (write the path, optional advisory extras).
|
|
47
|
+
3. New file → `/ark-place`. Map → `/ark-explore`. Apply → `/ark-autopilot`.
|
|
48
|
+
Wire ArkRun → `/ark-runtime`. Wire ArkOrder → `/ark-order`.
|
|
62
49
|
|
|
63
50
|
## Completion contract (skill incomplete if missing)
|
|
64
51
|
|
|
@@ -5,6 +5,10 @@ description: Fix illegal imports and one leftover-design refactor. CLI is a sens
|
|
|
5
5
|
|
|
6
6
|
# /ark-autopilot — Apply the path
|
|
7
7
|
|
|
8
|
+
**Contener · Guiar · Ordenar.** In plain words: contain the write, guide the next
|
|
9
|
+
step, order leftover mess. This door is **Guiar**: apply leftover design and illegal
|
|
10
|
+
imports, one small change at a time. Skills never enforce — CLI / hooks / CI do.
|
|
11
|
+
|
|
8
12
|
**When:** the user wants architecture cleaned end-to-end, or leftover design after a map.
|
|
9
13
|
**Not when:** map only (`/ark-explore`), session 0 / config lying (`/ark-adopt`), or one new file (`/ark-place`).
|
|
10
14
|
|
|
@@ -12,6 +16,8 @@ description: Fix illegal imports and one leftover-design refactor. CLI is a sens
|
|
|
12
16
|
|
|
13
17
|
1. Read `arkgate-check --doctor` (do #1).
|
|
14
18
|
2. Fix import-rule debt; if leftover design remains, apply **one** small refactor.
|
|
19
|
+
When doctor JSON has `noDomainFrontend`, that refactor is one pure rule into
|
|
20
|
+
Domain — not another UI helper. Soft. Silent when Domain already has files.
|
|
15
21
|
3. Re-run doctor. Never weaken `ark.config.json`.
|
|
16
22
|
|
|
17
23
|
**This is the apply door.** Invoking it **is** the approval. Run `arkgate-check --doctor` for the next step.
|
|
@@ -28,7 +34,9 @@ Apply plan A (`mechanical-safe` **and** judgment). If leftover design work remai
|
|
|
28
34
|
Composes **explore → sensors → dual plan → write**. Validate with ark-check; never weaken the gate.
|
|
29
35
|
**Team lock:** do not edit `ark.config.json`, `arkrules/*`, or `.ark-baseline.json` in this
|
|
30
36
|
turn unless the user invoked a steward contract session. Feature diffs use
|
|
31
|
-
`ark-check --
|
|
37
|
+
`ark-check --local --base <merge-ref>` or `ark-check --changed --base <merge-ref>`.
|
|
38
|
+
`--local` is the optional cheap path for many worktrees; it cannot combine with
|
|
39
|
+
`--strict-merge`. Growing the baseline is steward-only.
|
|
32
40
|
|
|
33
41
|
**Not a plan grinder.** Empty `--plan` does **not** mean “architecture is healthy” without
|
|
34
42
|
the explore pass and dual-plan section B (pattern / Shape bets).
|
|
@@ -60,7 +68,7 @@ patterns are **out-of-scope** lenses — say so; do not invent Ark enforcement f
|
|
|
60
68
|
| Brownfield or greenfield with apply | Session 0 / config lying → `/ark-adopt` first, then return |
|
|
61
69
|
| User wants A + B planned and **applied** | New file only → `/ark-place` |
|
|
62
70
|
| **Apply** leftover design (one Shape refactor) | User said map only |
|
|
63
|
-
| Extra skip cluster (`ARKRUN_*` / `ARKORDER_*`) after extra is on | Extra off → `/ark-adopt` (advisory); evaluate one bus → `/ark-runtime` |
|
|
71
|
+
| Extra skip cluster (`ARKRUN_*` / `ARKORDER_*`) after extra is on | Extra off → `/ark-adopt` (advisory); evaluate one bus → `/ark-runtime`; evaluate one order-plane candidate → `/ark-order` |
|
|
64
72
|
| Spaghetti under ENFORCE: Shape work (invoke = apply one pilot) | — |
|
|
65
73
|
|
|
66
74
|
**Post-green door:** `/ark-explore` shape-focus → dual-plan B, **then this skill applies one
|
|
@@ -127,8 +135,8 @@ ArkGate has **always-on Layers** plus opt-in extras. The user chooses extras; yo
|
|
|
127
135
|
2. Never call an import-edge violation an “invariant” or an aggregate sensor a “layer deny.”
|
|
128
136
|
3. Absence of `arkRules` is **valid** — do not force ArkRules unless the user wants them or residual inventory clearly wants a pilot.
|
|
129
137
|
4. Editing `arkrules/*` or promoting modes and fixing structure sensors is **this skill** (judgment, never invent `mechanical-safe`).
|
|
130
|
-
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` with `evidence.arkruleId`.
|
|
131
|
-
6. Absence of extras is **valid**. Extra skip clusters grind **here** after the extra is on.
|
|
138
|
+
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` / `INVARIANT_CATALOG_EMPTY` with `evidence.arkruleId`.
|
|
139
|
+
6. Absence of extras is **valid**. Extra skip clusters grind **here** after the extra is on. Evaluate one bus → `/ark-runtime`; evaluate one order-plane candidate → `/ark-order`. Do not invent `/ark-run`. Skills never enforce.
|
|
132
140
|
|
|
133
141
|
|
|
134
142
|
### Autopilot + ArkRules
|
|
@@ -148,7 +156,7 @@ When `arkRun` is present:
|
|
|
148
156
|
### Autopilot + ArkOrder
|
|
149
157
|
When `arkOrder` is present:
|
|
150
158
|
- Grind skip clusters with judgment: `ARKORDER_MISSING_PLANE` / `ARKORDER_KERNEL_IN_DOMAIN` / `ARKORDER_GENERIC_UPDATE` / `ARKORDER_TOO_MANY_PARAMS` / `ARKORDER_INGEST_WRITES_XI` / `ARKORDER_XI_FIELD_WRITE` / `ARKORDER_UNVALVED_RELEASE`. First freeze with `release()`; later ξ change is `proposeRelease` then `apply`. `refreshSigma`; ingest residual `absorb | escalate_up | hold` + `reasonCode`; capacity pack; `createMemoryReleaseStore`; `ingestTravelAction`; ArkRun `decisionTape`. Never `update`/`patch`/`set`. Name `xiKeys`; do not persist those keys from a use-case. Do not “fix” a derived status by adding it to `xiKeys`; that institutionalizes the skip, so derive it on read or fold it from ingest. Doctor / status `arkOrder` is `notAScore`.
|
|
151
|
-
- Extra off → `/ark-adopt` (advisory).
|
|
159
|
+
- Extra off → `/ark-adopt` (advisory). Wire one candidate → `/ark-order`.
|
|
152
160
|
- Skills never enforce.
|
|
153
161
|
|
|
154
162
|
## Subagent fan-out (optional, host-dependent)
|
|
@@ -266,7 +274,7 @@ Status lights from doctor — not settings you choose. Rank residual honestly:
|
|
|
266
274
|
- Claim ENFORCE / “done” when doctor reports `contract-false-green-io-under-application` (adopt first).
|
|
267
275
|
- Claim “done” solely because plan A is empty while explore/B residual remains unlisted.
|
|
268
276
|
- Replace host Nest/DI with the runtime kernel unasked.
|
|
269
|
-
- Invent `/ark-run
|
|
277
|
+
- Invent `/ark-run`. Use `/ark-order` to wire one plane candidate.
|
|
270
278
|
- Auto-apply pattern (B) bets as if they were mechanical-safe.
|
|
271
279
|
- Create origin only after a long cleanup (freezes a polished “before” that never was).
|
|
272
280
|
|
|
@@ -5,21 +5,18 @@ description: Shortcut — edit the rules file or extra rules. Use /ark-adopt or
|
|
|
5
5
|
|
|
6
6
|
# /ark-contract — Shortcut to adopt / autopilot
|
|
7
7
|
|
|
8
|
-
**Not a first-
|
|
8
|
+
**Not a first-class door.** One-release redirect. Writing `ark.config.json` is
|
|
9
9
|
**`/ark-adopt`** at session 0 and **`/ark-autopilot`** afterward. Do that job now.
|
|
10
|
-
|
|
11
|
-
## Autonomy contract
|
|
12
|
-
|
|
13
|
-
Invoking this leftover name **is** the approval to write an honest config. Do not
|
|
14
|
-
preview-only. Never weaken the architecture config.
|
|
10
|
+
Contener · Guiar · Ordenar — this leftover name is not a star.
|
|
15
11
|
|
|
16
12
|
## When / not when
|
|
17
13
|
|
|
18
14
|
| Use this leftover name when… | Prefer instead |
|
|
19
15
|
|------------------------------|----------------|
|
|
20
|
-
| Layers / include / ArkRules /
|
|
16
|
+
| Layers / include / ArkRules / first extra need an edit | **`/ark-adopt`** (path, first `arkRun` / first `arkOrder`) or **`/ark-autopilot`** (tighten) |
|
|
21
17
|
| False-green / concentrated edge | **`/ark-adopt`** — write the honest config |
|
|
22
|
-
|
|
|
18
|
+
| One kernel candidate | **`/ark-runtime`** |
|
|
19
|
+
| One order-plane candidate | **`/ark-order`** |
|
|
23
20
|
|
|
24
21
|
## Dual engine (mandatory)
|
|
25
22
|
|
|
@@ -39,14 +36,6 @@ retain `projectIdentity.projectId`, then pass both `expectedRoot` and `expectedP
|
|
|
39
36
|
uncertain, do not consume MCP analysis: use the workspace-local CLI and report that MCP
|
|
40
37
|
restart/retargeting is required. `ark://manifest` never satisfies this preflight.
|
|
41
38
|
|
|
42
|
-
## Dual plane — layers + extras (mandatory, except /ark-runtime)
|
|
43
|
-
|
|
44
|
-
Label findings **`[Layer]`** vs **`[ArkRules]`** vs **`[ArkRun]`** vs **`[ArkOrder]`**. Absence of extras is valid and silent. First-time extra is **`/ark-adopt`** (advisory). Wire one kernel candidate with **`/ark-runtime`**. New kernel-managed / plane-root file with **`/ark-place`**. Grind skip clusters with **`/ark-autopilot`**. Do not invent `/ark-run` or `/ark-order`. Skills never enforce.
|
|
45
|
-
|
|
46
|
-
Application / Features may declare advisory **`writes-via-aggregate`**: a use-case that imports a persistence driver and calls `.insert` / `.create` / `INSERT INTO` is the skip. Persistence adapters stay the write edge. Do not add `Externals/` or `admission.ts` as contract law.
|
|
47
|
-
|
|
48
|
-
When `arkOrder` is on, name **`xiKeys`** (3–5 slow product decisions). Membership ids and recomputable statuses are not keys: derive a status on read or fold it from ingest instead. A use-case that persists those keys is `ARKORDER_XI_FIELD_WRITE`. First freeze is `release()`; later ξ is `proposeRelease` then `apply`; `refreshSigma`; ingest residual `absorb | escalate_up | hold` + `reasonCode`; capacity pack as data; in-memory `ReleaseStore`; ArkRun `decisionTape`. The billing gallery lives on GitHub, not in the npm tarball: [examples/arkorder-billing](https://github.com/pedroknigge/arkgate/tree/main/examples/arkorder-billing). Rename the three keys. The check remains silent on semantic entailment.
|
|
49
|
-
|
|
50
39
|
## Subagent fan-out (optional, host-dependent)
|
|
51
40
|
|
|
52
41
|
If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
@@ -59,9 +48,9 @@ If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
|
59
48
|
|
|
60
49
|
## Steps
|
|
61
50
|
|
|
62
|
-
1.
|
|
63
|
-
2.
|
|
64
|
-
3. One kernel candidate
|
|
51
|
+
1. Path missing or lying → execute **`/ark-adopt`** (including first advisory `arkRun` / first advisory `arkOrder`).
|
|
52
|
+
2. Path honest and tightening → execute **`/ark-autopilot`**.
|
|
53
|
+
3. One kernel candidate → **`/ark-runtime`**. One order-plane candidate → **`/ark-order`**.
|
|
65
54
|
|
|
66
55
|
## Completion contract (skill incomplete if missing)
|
|
67
56
|
|
|
@@ -73,5 +62,5 @@ Skill incomplete if missing any field below.
|
|
|
73
62
|
- **Result:** one-line outcome
|
|
74
63
|
- **Planes:** one-line split of residual **[Layer]** vs **[ArkRules]** vs **[ArkRun]** vs **[ArkOrder]** (or `n/a` if unused)
|
|
75
64
|
- **Compass:** top residual lenses | `n/a`
|
|
76
|
-
- **Handoff:** `/ark-adopt` / `/ark-autopilot` / `none`
|
|
65
|
+
- **Handoff:** `/ark-adopt` / `/ark-autopilot` / `/ark-order` / `none`
|
|
77
66
|
- **Incomplete?** `no` | `yes — <what is missing>`
|
|
@@ -5,9 +5,13 @@ description: How much of the tree the rules file covers. CLI is a sensor; read t
|
|
|
5
5
|
|
|
6
6
|
# /ark-coverage — Ark adoption fitness (not full recon)
|
|
7
7
|
|
|
8
|
+
**Contener · Guiar · Ordenar.** In plain words: contain the write, guide the next
|
|
9
|
+
step, order leftover mess. This door is **Guiar**: adoption fitness numbers, not a full map.
|
|
10
|
+
Skills never enforce — CLI / hooks / CI do.
|
|
11
|
+
|
|
8
12
|
**Not a first-run door.** Fitness numbers only (governed files, gates, baseline).
|
|
9
13
|
Session 0 → **`/ark-adopt`**. Leftover design → **`/ark-explore`**. Apply → **`/ark-autopilot`**.
|
|
10
|
-
|
|
14
|
+
Wire ArkRun → **`/ark-runtime`**. Wire ArkOrder → **`/ark-order`**.
|
|
11
15
|
|
|
12
16
|
You audit **how this repo uses ArkGate** (coverage, gates, baseline, host write path) and
|
|
13
17
|
what adoption gaps remain. Work autonomously. End with a ranked fitness report.
|
|
@@ -41,7 +45,7 @@ patterns are **out-of-scope** lenses — say so; do not invent Ark enforcement f
|
|
|
41
45
|
| “How adopted is Ark?” governed%, gates, baseline, skills stale | Full product map / what-next architecture → `/ark-explore` |
|
|
42
46
|
| Capability gaps (CI, write path, ESLint, optional layers) | Apply fixes end-to-end → `/ark-autopilot` |
|
|
43
47
|
| Ranked *adoption* opportunities (install, ratchet, contract classify) | Spaghetti pattern plan / golden pattern → `/ark-explore` dual-plan seed |
|
|
44
|
-
| Quick honesty before a release checklist | One design trade-off → `/ark-
|
|
48
|
+
| Quick honesty before a release checklist | One design trade-off → `/ark-explore` (one decision, 2–3 options) |
|
|
45
49
|
|
|
46
50
|
## Dual engine (mandatory)
|
|
47
51
|
|
|
@@ -90,10 +94,10 @@ ArkGate has **always-on Layers** plus opt-in extras. The user chooses extras; yo
|
|
|
90
94
|
1. Prefix each finding or next step with **`[Layer]`** or **`[ArkRules]`** or **`[ArkRun]`** or **`[ArkOrder]`** (or a table with those headers).
|
|
91
95
|
2. Never call an import-edge violation an “invariant” or an aggregate sensor a “layer deny.”
|
|
92
96
|
3. Absence of `arkRules` is **valid** — do not force ArkRules unless the user wants them or residual inventory clearly wants a pilot.
|
|
93
|
-
4. Editing `arkrules/*` or promoting modes is **`/ark-adopt
|
|
94
|
-
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` with `evidence.arkruleId`.
|
|
97
|
+
4. Editing `arkrules/*` or promoting modes is **`/ark-adopt`**; fixing code under a structure sensor is **`/ark-autopilot`** (judgment, never invent mechanical-safe).
|
|
98
|
+
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` / `INVARIANT_CATALOG_EMPTY` with `evidence.arkruleId`.
|
|
95
99
|
5b. Invariant coverage is a **text match, never an execution**: a file walk plus the invariant id in a `describe`/`it` title. Never report `INVARIANT_UNCOVERED: 0` as “the tests pass” or “the tests run” — ArkGate does not run tests and reads no runner config. When the project declares `coverage.coverageRoots`, a covering test found outside them raises the advisory `INVARIANT_COVERAGE_OUTSIDE_ROOTS`; without that declaration ArkGate makes no claim about where tests run.
|
|
96
|
-
6. Extras silent when off. Doctor `arkRun` is `notAScore`. Do not force extras.
|
|
100
|
+
6. Extras silent when off. Doctor `arkRun` / `arkOrder` is `notAScore`. Do not force extras. Wire one kernel candidate via `/ark-runtime`; one order-plane candidate via `/ark-order`. Do not invent `/ark-run`.
|
|
97
101
|
|
|
98
102
|
|
|
99
103
|
### Coverage + ArkRules
|
|
@@ -143,10 +147,10 @@ because governed% is 100% and plan is empty.
|
|
|
143
147
|
|
|
144
148
|
## Related onboarding
|
|
145
149
|
|
|
146
|
-
- **Greenfield:** low governed% → `/ark-
|
|
150
|
+
- **Greenfield:** low governed% → `/ark-adopt` or `ark-check --recommend`.
|
|
147
151
|
- **Brownfield:** `/ark-adopt` for action; this skill for fitness metrics.
|
|
148
152
|
- **Pattern / spaghetti residual:** `/ark-explore` dual-plan seed / shape-focus.
|
|
149
|
-
- **Business rules loose:** note in table; mining action → `/ark-adopt
|
|
153
|
+
- **Business rules loose:** note in table; mining action → `/ark-adopt`.
|
|
150
154
|
|
|
151
155
|
## Checklist (sensor + light code)
|
|
152
156
|
|
|
@@ -159,8 +163,8 @@ because governed% is 100% and plan is empty.
|
|
|
159
163
|
7. **Governed%** + unclassified + `suggestions` from `--coverage --json`.
|
|
160
164
|
8. Concentrated edges in check `summary` → contract smell, not N freezes.
|
|
161
165
|
9. `layersWithoutRules` + empty cores with I/O under Application (false-green).
|
|
162
|
-
On false-green: **STOP — do not continue this skill as complete.** **STOP — false-green: invoke /ark-adopt
|
|
163
|
-
On one-edge wall: **STOP — do not continue this skill as complete.** **STOP — concentrated edge: invoke /ark-
|
|
166
|
+
On false-green: **STOP — do not continue this skill as complete.** **STOP — false-green: invoke /ark-adopt before claiming ENFORCE.** Do not claim goal.met / ENFORCE from type-only cleanup while doctor reports `contract-false-green-io-under-application`.
|
|
167
|
+
On one-edge wall: **STOP — do not continue this skill as complete.** **STOP — concentrated edge: invoke /ark-adopt with source evidence** (do not freeze a wrong contract or grind N freezes).
|
|
164
168
|
10. Runtime kernel / Nest only if deps prove it — never force-fit.
|
|
165
169
|
|
|
166
170
|
## Output format
|
|
@@ -5,9 +5,13 @@ description: Explain the rules file in plain language and generate the HTML repo
|
|
|
5
5
|
|
|
6
6
|
# /ark-explain — Understand this project's architecture
|
|
7
7
|
|
|
8
|
+
**Contener · Guiar · Ordenar.** In plain words: contain the write, guide the next
|
|
9
|
+
step, order leftover mess. This door is **Guiar**: teach the path in plain language.
|
|
10
|
+
Skills never enforce — CLI / hooks / CI do.
|
|
11
|
+
|
|
8
12
|
**Not a first-run door.** Teach / HTML tour only. Session 0 → **`/ark-adopt`**.
|
|
9
13
|
Map → **`/ark-explore`**. Apply → **`/ark-autopilot`**.
|
|
10
|
-
|
|
14
|
+
Wire ArkRun → **`/ark-runtime`**. Wire ArkOrder → **`/ark-order`**.
|
|
11
15
|
|
|
12
16
|
The user wants to understand the architecture, a specific rule, or why the gate blocked them.
|
|
13
17
|
|
|
@@ -75,15 +79,17 @@ ArkGate has **always-on Layers** plus opt-in extras. The user chooses extras; yo
|
|
|
75
79
|
2. Never call an import-edge violation an “invariant” or an aggregate sensor a “layer deny.”
|
|
76
80
|
3. Absence of `arkRules` is **valid** — do not force ArkRules unless the user wants them or residual inventory clearly wants a pilot.
|
|
77
81
|
4. Editing `arkrules/*` or applying structure fixes is **`/ark-adopt`** / **`/ark-autopilot`** (never invent `mechanical-safe`).
|
|
78
|
-
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` with `evidence.arkruleId`.
|
|
79
|
-
6. Extras silent when off. Doctor `arkRun` is `notAScore`. Do not force extras.
|
|
82
|
+
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` / `INVARIANT_CATALOG_EMPTY` with `evidence.arkruleId`.
|
|
83
|
+
6. Extras silent when off. Doctor `arkRun` / `arkOrder` is `notAScore`. Do not force extras. Wire one kernel candidate via `/ark-runtime`; one order-plane candidate via `/ark-order`. Do not invent `/ark-run`.
|
|
80
84
|
|
|
81
85
|
|
|
82
86
|
### Explain + ArkRules
|
|
83
87
|
- HTML/plain tour: section **Layers** and section **Rules under contract (ArkRules)** —
|
|
84
88
|
when `arkRules` is active the showcase lists **per-layer counts**, **structure sensors**
|
|
85
89
|
(id / sensor / mode), **uncovered** invariants (call them out), and a **covered sample**.
|
|
86
|
-
|
|
90
|
+
Compact doctor names ArkRules only when the map is on; absence stays silent.
|
|
91
|
+
Empty `invariants[]` on a populated Domain is residual (`INVARIANT_CATALOG_EMPTY`), not “all covered”.
|
|
92
|
+
Inactive HTML map stays a short opt-in note. Counts are never a score.
|
|
87
93
|
- Spoken tour: name 2–4 real invariant IDs and one structure sensor from this repo’s
|
|
88
94
|
`arkrules/*` (open the files — do not invent). Residual candidates → `--rules-inventory`.
|
|
89
95
|
- **Teach the product model (required when arkRules is active):**
|
|
@@ -217,7 +223,7 @@ when residual signals remain.
|
|
|
217
223
|
|
|
218
224
|
## Related
|
|
219
225
|
|
|
220
|
-
- Onboarding: `/ark-adopt
|
|
226
|
+
- Onboarding: `/ark-adopt`, `ark-check --recommend`, `docs/enthusiast/README.md`
|
|
221
227
|
- Brownfield: `/ark-adopt`, `docs/brownfield-adoption.md`
|
|
222
228
|
- Autopilot: `/ark-autopilot` after the user understands the contract
|
|
223
229
|
|
|
@@ -5,7 +5,12 @@ description: Map import rules and leftover design. No apply. CLI is a sensor; yo
|
|
|
5
5
|
|
|
6
6
|
# /ark-explore — Recon the real project (map only)
|
|
7
7
|
|
|
8
|
-
**
|
|
8
|
+
**Contener · Guiar · Ordenar.** In plain words: contain the write, guide the next
|
|
9
|
+
step, order leftover mess. This door is **Guiar**: map leftover design so you can
|
|
10
|
+
order a messy tree. Do not apply. Skills never enforce — CLI / hooks / CI do.
|
|
11
|
+
|
|
12
|
+
**When:** you need a map, leftover design work remains after imports look green, or
|
|
13
|
+
one bounded decision needs 2–3 enforceable options.
|
|
9
14
|
**Not when:** the user wants edits applied (`/ark-autopilot`) or session 0 (`/ark-adopt`).
|
|
10
15
|
|
|
11
16
|
## Steps
|
|
@@ -17,6 +22,18 @@ description: Map import rules and leftover design. No apply. CLI is a sensor; yo
|
|
|
17
22
|
## Checklist
|
|
18
23
|
|
|
19
24
|
- Doctor #1: if ENFORCE + empty plan A and gates are already installed → **Shape** (`/ark-explore` then `/ark-autopilot`). Do not say install-agent-gates.
|
|
25
|
+
- When `--require-gates` / adopted-strict is on and doctor JSON has `adrPresence`,
|
|
26
|
+
the next step is a short note under `docs/adr/` (or `docs/decisions/`). Soft.
|
|
27
|
+
Not every change. Off when require-gates is off. No `/ark-adr`.
|
|
28
|
+
- When doctor JSON has `statesTransitions` or `statusTransitionCatalog`, the
|
|
29
|
+
next step is a short states → transitions table (or one link) on the domain
|
|
30
|
+
doc already in play. Use catalog names when present. Soft. Silent when that
|
|
31
|
+
doc is absent or Domain has no status vocabulary. No `/ark-states`. Do not
|
|
32
|
+
invent states.
|
|
33
|
+
- When doctor JSON has `noDomainFrontend`, Domain is empty and the UI holds the
|
|
34
|
+
rules. Next: one Domain file (`/ark-place`) then one small refactor
|
|
35
|
+
(`/ark-autopilot`). Soft. Silent when there is no frontend or Domain already
|
|
36
|
+
has files. No `/ark-domain`. Do not invent a Domain house.
|
|
20
37
|
- Distinguish **missing** skills vs **stale** catalog. Installed ≠ stale.
|
|
21
38
|
- Hook green is not tree green (scripted edits bypass PreToolUse).
|
|
22
39
|
- Bug / false green / false red / missing doc / improvable behavior **in ArkGate itself** → draft one upstream GitHub issue (`pedroknigge/arkgate` or the installed package `repository.url`), **ask the human to confirm send**, then `gh issue create`. Never auto-file. Never file ArkGate defects on the consumer product repo.
|
|
@@ -102,7 +119,8 @@ If the consumer tree has a **domain glossary**, prefer its terms for layer/slice
|
|
|
102
119
|
| Map / “what next?” / residual after ENFORCE | User wants edits applied → `/ark-autopilot` |
|
|
103
120
|
| **Primary post-green door:** messy / leftover design work / “clarify for AI” | Skill-shopping coverage or think for the same leftover work |
|
|
104
121
|
| Spaghetti brownfield: patterns concurrent, design-weak under green check | Only “governed% + gates installed?” numbers → `/ark-coverage` |
|
|
105
|
-
| Dual-plan **seed** (A remediation + B pattern bets) without applying |
|
|
122
|
+
| Dual-plan **seed** (A remediation + B pattern bets) without applying | Apply the chosen option → `/ark-autopilot`; new file → `/ark-place` |
|
|
123
|
+
| One bounded decision: 2–3 enforceable options (folded from leftover `/ark-think`) | Full apply → `/ark-autopilot`; extra off → `/ark-adopt`; one kernel candidate → `/ark-runtime`; one order-plane candidate → `/ark-order` |
|
|
106
124
|
| Path-correct vs design-correct honesty | Plain-language tour / HTML report → `/ark-explain` |
|
|
107
125
|
|
|
108
126
|
**Post-green single path:** when doctor `postGreenPath` / ENFORCE · leftover design work is active, **this skill
|
|
@@ -173,20 +191,36 @@ ArkGate has **always-on Layers** plus opt-in extras. The user chooses extras; yo
|
|
|
173
191
|
2. Never call an import-edge violation an “invariant” or an aggregate sensor a “layer deny.”
|
|
174
192
|
3. Absence of `arkRules` is **valid** — do not force ArkRules unless the user wants them or residual inventory clearly wants a pilot.
|
|
175
193
|
4. Editing `arkrules/*` or applying structure fixes is **`/ark-adopt`** / **`/ark-autopilot`** — explore does not write (never invent `mechanical-safe`).
|
|
176
|
-
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` with `evidence.arkruleId`.
|
|
177
|
-
6. Never write `arkRun` or `arkOrder` from this skill. When extras are present, label residual **`[ArkRun]`** / **`[ArkOrder]`**.
|
|
194
|
+
5. CLI helpers: `ark-check --rules-inventory --json`, doctor JSON `rulesUnderContract`, sensors emit `ARKRULE_*` / `INVARIANT_UNCOVERED` / `INVARIANT_CATALOG_EMPTY` with `evidence.arkruleId`.
|
|
195
|
+
6. Never write `arkRun` or `arkOrder` from this skill. When extras are present, label residual **`[ArkRun]`** / **`[ArkOrder]`**. Wire one kernel candidate via `/ark-runtime`; one order-plane candidate via `/ark-order`. Do not invent `/ark-run`.
|
|
178
196
|
|
|
179
197
|
|
|
180
198
|
### Explore + ArkRules
|
|
181
199
|
- Always run sensors for **both** planes when present: coverage/doctor **and** `--rules-inventory` if `arkRules` exists or brownfield may hide spaghetti rules.
|
|
182
200
|
- Ranked table kinds may include `arkrules-opportunity` and `invariant-gap`.
|
|
201
|
+
- Empty `invariants[]` on a populated Domain while `arkRules` is on is residual (`INVARIANT_CATALOG_EMPTY`), not done. Point at `arkrules/<Domain>.json`.
|
|
183
202
|
- Dual-plan **B** may include: place advisory structure rules, extract one inventory candidate to Domain + `arkrules` entry, promote one covered invariant.
|
|
184
203
|
- Field path: note whether starters emit `arkrules/*`.
|
|
185
204
|
|
|
186
205
|
### Explore + extras
|
|
187
206
|
- Map extras when present; never write `arkRun` / `arkOrder`. Extra off → residual `n/a` / silent.
|
|
188
207
|
- When `arkOrder` is on, name the valve: first freeze `release()`; later ξ is `proposeRelease` then `apply`; `refreshSigma`; ingest residual `absorb | escalate_up | hold` + `reasonCode`; capacity pack as data; in-memory `ReleaseStore` (`createMemoryReleaseStore`); thin travel `ingestTravelAction`. ArkRun residual may include information package `decisionTape` `{ xiHash, event, residual }`.
|
|
189
|
-
- Field path may name the ArkOrder gallery on GitHub (`https://github.com/pedroknigge/arkgate/tree/main/examples/arkorder-billing`; not in the npm tarball — map only). First extra write is `/ark-adopt`; grind is `/ark-autopilot`.
|
|
208
|
+
- Field path may name the ArkOrder gallery on GitHub (`https://github.com/pedroknigge/arkgate/tree/main/examples/arkorder-billing`; not in the npm tarball — map only). First extra write is `/ark-adopt`; wire one candidate is `/ark-order`; grind is `/ark-autopilot`.
|
|
209
|
+
|
|
210
|
+
## One decision (2–3 options)
|
|
211
|
+
|
|
212
|
+
When the job is **one** bounded import-rule or ArkRules choice (not a full map), stay here.
|
|
213
|
+
Leftover `/ark-think` redirects here. Do not invent a third door.
|
|
214
|
+
|
|
215
|
+
1. Open ≥5 source files on the decision surface. Name paths.
|
|
216
|
+
2. Propose **2–3 options** that stay enforceable today. Label each by lens impact
|
|
217
|
+
(what residual improves / what stays out-of-scope). Always `notAScore`.
|
|
218
|
+
3. Recommend one option + why it is enforceable. Pilot + kill-switch if the choice
|
|
219
|
+
adds a layer or wall.
|
|
220
|
+
4. Hand off: apply → `/ark-autopilot`; new file → `/ark-place`; extra off → `/ark-adopt`;
|
|
221
|
+
one kernel candidate → `/ark-runtime`; one order-plane candidate → `/ark-order`.
|
|
222
|
+
|
|
223
|
+
Never weaken `ark.config.json` to pass. Never silent judgment auto-apply.
|
|
190
224
|
|
|
191
225
|
## Output mode (pick one — do not invent a fourth)
|
|
192
226
|
|
|
@@ -5,28 +5,25 @@ description: Shortcut to /ark-autopilot for a small illegal-import cluster.
|
|
|
5
5
|
|
|
6
6
|
# /ark-fix — Shortcut to /ark-autopilot
|
|
7
7
|
|
|
8
|
-
**Not a first-
|
|
8
|
+
**Not a first-class door.** One-release redirect. Gate violations are
|
|
9
9
|
**`/ark-autopilot`**. Do that job now. CLI only validates.
|
|
10
|
-
|
|
11
|
-
## Autonomy contract
|
|
12
|
-
|
|
13
|
-
Invoking this leftover name **is** the approval to write the fix. Open importers,
|
|
14
|
-
design the port/move, apply, `ark-check`. Never weaken the config. Never invent
|
|
15
|
-
`mechanical-safe` kinds.
|
|
10
|
+
Contener · Guiar · Ordenar — this leftover name is not a star.
|
|
16
11
|
|
|
17
12
|
## When / not when
|
|
18
13
|
|
|
19
14
|
| Use this leftover name when… | Prefer instead |
|
|
20
15
|
|------------------------------|----------------|
|
|
21
16
|
| One change / small cluster just failed the gate | **`/ark-autopilot`** |
|
|
22
|
-
|
|
|
17
|
+
| Session 0 / false-green | **`/ark-adopt`** |
|
|
18
|
+
| One kernel candidate | **`/ark-runtime`** |
|
|
19
|
+
| One order-plane candidate | **`/ark-order`** |
|
|
23
20
|
|
|
24
21
|
## Plan B one-pilot checklist (when leftover design, not a single edge)
|
|
25
22
|
|
|
26
23
|
Empty plan A + leftover design work is **not** architecture finished. One pilot only.
|
|
27
24
|
Write an **extraction card** (`docs/brownfield-adoption.md` §6) — never mechanical-safe,
|
|
28
25
|
never silent B apply. **Kill-switch** required. `multiPilotBatchForbidden` — never
|
|
29
|
-
multi-pilot batch.
|
|
26
|
+
multi-pilot batch. Execute that work on **`/ark-autopilot`**.
|
|
30
27
|
|
|
31
28
|
## Dual engine (mandatory)
|
|
32
29
|
|
|
@@ -46,10 +43,6 @@ retain `projectIdentity.projectId`, then pass both `expectedRoot` and `expectedP
|
|
|
46
43
|
uncertain, do not consume MCP analysis: use the workspace-local CLI and report that MCP
|
|
47
44
|
restart/retargeting is required. `ark://manifest` never satisfies this preflight.
|
|
48
45
|
|
|
49
|
-
## Dual plane — layers + extras (mandatory, except /ark-runtime)
|
|
50
|
-
|
|
51
|
-
Label findings **`[Layer]`** vs **`[ArkRules]`** vs **`[ArkRun]`** vs **`[ArkOrder]`**. Absence of extras is valid and silent. Extra skip clusters (`ARKRUN_*` / `ARKORDER_*`) are **`/ark-autopilot`**. When ArkOrder is on: later ξ is `proposeRelease` then `apply` (not a second `release()`); `refreshSigma`; ingest residual `absorb | escalate_up | hold`; capacity pack as data; in-memory `ReleaseStore`; ArkRun `decisionTape`. Do not invent `/ark-run` or `/ark-order`. Skills never enforce.
|
|
52
|
-
|
|
53
46
|
## Subagent fan-out (optional, host-dependent)
|
|
54
47
|
|
|
55
48
|
If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
@@ -60,6 +53,15 @@ If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
|
60
53
|
- **Greenfield:** `/ark-adopt` or `ark-check --recommend` / `ark start`.
|
|
61
54
|
- **Brownfield:** `/ark-adopt`.
|
|
62
55
|
|
|
56
|
+
## Mechanical-edit hygiene (outcome gate)
|
|
57
|
+
|
|
58
|
+
Leftover name, same edit bar as `/ark-autopilot` if you still land here.
|
|
59
|
+
|
|
60
|
+
- Header injection must **merge into the existing doc comment**; the kept result has one `/**`, not stacked headers.
|
|
61
|
+
- Route completion or movement must **preserve the original typed `defineRoute<…>(opts, handler)` call**; reconstruct that call instead of extracting untyped opts/handler constants that drop generics or contextual typing.
|
|
62
|
+
- A convention-only `*-data.ts` stub is not a fix: move the real code or **leave the placeholder file uncreated**; never write `import "server-only"; export {}` as an empty naming token.
|
|
63
|
+
- Keep the edit only when the **previously clean file stays typecheck-clean**. Otherwise roll it back and treat the change as judgment.
|
|
64
|
+
|
|
63
65
|
## Steps
|
|
64
66
|
|
|
65
67
|
1. Sensor: `ark-check` / `--plan --json`.
|
|
@@ -68,13 +70,6 @@ If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
|
68
70
|
3. Otherwise execute **`/ark-autopilot`** for the cluster (extraction card if Shape).
|
|
69
71
|
4. Re-check.
|
|
70
72
|
|
|
71
|
-
## Mechanical-edit hygiene (outcome gate)
|
|
72
|
-
|
|
73
|
-
- Header injection must **merge into the existing doc comment**; the kept result has one `/**`, not stacked headers.
|
|
74
|
-
- Route completion or movement must **preserve the original typed `defineRoute<…>(opts, handler)` call**; reconstruct that call instead of extracting untyped opts/handler constants that drop generics or contextual typing.
|
|
75
|
-
- A convention-only `*-data.ts` stub is not a fix: move the real code or **leave the placeholder file uncreated**; never write `import "server-only"; export {}` as an empty naming token.
|
|
76
|
-
- Keep the edit only when the **previously clean file stays typecheck-clean**. Otherwise roll it back and treat the change as judgment.
|
|
77
|
-
|
|
78
73
|
## Completion contract (skill incomplete if missing)
|
|
79
74
|
|
|
80
75
|
Skill incomplete if missing any field below.
|
|
@@ -5,21 +5,17 @@ description: Shortcut to /ark-autopilot for illegal-import fixes. CLI validates
|
|
|
5
5
|
|
|
6
6
|
# /ark-loop — Shortcut to /ark-autopilot
|
|
7
7
|
|
|
8
|
-
**Not a first-
|
|
9
|
-
Do that job now.
|
|
10
|
-
|
|
11
|
-
## Autonomy contract
|
|
12
|
-
|
|
13
|
-
Invoking this leftover name **is** the approval to apply plan A. Open every step file.
|
|
14
|
-
Write. Re-check. Empty plan A + leftover design → **`/ark-explore`** then **`/ark-autopilot`**
|
|
15
|
-
for one extraction card (never mechanical-safe B).
|
|
8
|
+
**Not a first-class door.** One-release redirect. Driving `--plan` to `goal.met` is
|
|
9
|
+
**`/ark-autopilot`**. Do that job now.
|
|
10
|
+
Contener · Guiar · Ordenar — this leftover name is not a star.
|
|
16
11
|
|
|
17
12
|
## When / not when
|
|
18
13
|
|
|
19
14
|
| Use this leftover name when… | Prefer instead |
|
|
20
15
|
|------------------------------|----------------|
|
|
21
16
|
| Plan A has steps; drive to `goal.met` | **`/ark-autopilot`** |
|
|
22
|
-
|
|
|
17
|
+
| Map only | `/ark-explore` |
|
|
18
|
+
| Session 0 | `/ark-adopt` |
|
|
23
19
|
|
|
24
20
|
## Dual engine (mandatory)
|
|
25
21
|
|
|
@@ -41,10 +37,6 @@ restart/retargeting is required. `ark://manifest` never satisfies this preflight
|
|
|
41
37
|
|
|
42
38
|
Atomic multi-file work uses **`ark_prepare_change`** with the same matched `project` envelope.
|
|
43
39
|
|
|
44
|
-
## Dual plane — layers + extras (mandatory, except /ark-runtime)
|
|
45
|
-
|
|
46
|
-
Label findings **`[Layer]`** vs **`[ArkRules]`** vs **`[ArkRun]`** vs **`[ArkOrder]`**. Absence of extras is valid and silent. Extra skip clusters (`ARKRUN_*` / `ARKORDER_*`) are **`/ark-autopilot`**. When ArkOrder is on: later ξ is `proposeRelease` then `apply`; `refreshSigma`; ingest residual `absorb | escalate_up | hold`; capacity pack as data; in-memory `ReleaseStore`; ArkRun `decisionTape`. Never invent `mechanical-safe` kinds. Do not invent `/ark-run` or `/ark-order`. Skills never enforce.
|
|
47
|
-
|
|
48
40
|
## Subagent fan-out (optional, host-dependent)
|
|
49
41
|
|
|
50
42
|
If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
@@ -55,6 +47,15 @@ If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
|
55
47
|
- **Greenfield:** `/ark-adopt` or `ark-check --recommend` / `ark start`.
|
|
56
48
|
- **Brownfield:** `/ark-adopt`.
|
|
57
49
|
|
|
50
|
+
## Mechanical-edit hygiene (outcome gate)
|
|
51
|
+
|
|
52
|
+
Leftover name, same edit bar as `/ark-autopilot` if you still land here.
|
|
53
|
+
|
|
54
|
+
- Header injection must **merge into the existing doc comment**; the kept result has one `/**`, not stacked headers.
|
|
55
|
+
- Route completion or movement must **preserve the original typed `defineRoute<…>(opts, handler)` call**; reconstruct that call instead of extracting untyped opts/handler constants that drop generics or contextual typing.
|
|
56
|
+
- A convention-only `*-data.ts` stub is not a fix: move the real code or **leave the placeholder file uncreated**; never write `import "server-only"; export {}` as an empty naming token.
|
|
57
|
+
- Keep the edit only when the **previously clean file stays typecheck-clean**. Otherwise roll it back and treat the change as judgment.
|
|
58
|
+
|
|
58
59
|
## Steps
|
|
59
60
|
|
|
60
61
|
1. `--plan --json`. Open every `steps[]` file.
|
|
@@ -64,13 +65,6 @@ If the host supports **parallel subagents**, fan out read-only scouts; otherwise
|
|
|
64
65
|
**STOP — false-green:** execute **`/ark-adopt`**.
|
|
65
66
|
4. Else execute **`/ark-autopilot`** (mechanical-safe + judgment). Extraction card for Shape B.
|
|
66
67
|
|
|
67
|
-
## Mechanical-edit hygiene (outcome gate)
|
|
68
|
-
|
|
69
|
-
- Header injection must **merge into the existing doc comment**; the kept result has one `/**`, not stacked headers.
|
|
70
|
-
- Route completion or movement must **preserve the original typed `defineRoute<…>(opts, handler)` call**; reconstruct that call instead of extracting untyped opts/handler constants that drop generics or contextual typing.
|
|
71
|
-
- A convention-only `*-data.ts` stub is not a fix: move the real code or **leave the placeholder file uncreated**; never write `import "server-only"; export {}` as an empty naming token.
|
|
72
|
-
- Keep the edit only when the **previously clean file stays typecheck-clean**. Otherwise roll it back and treat the change as judgment.
|
|
73
|
-
|
|
74
68
|
## Completion contract (skill incomplete if missing)
|
|
75
69
|
|
|
76
70
|
Skill incomplete if missing any field below.
|