arkgate 4.8.5 → 4.8.6

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 (62) hide show
  1. package/CHANGELOG.md +33 -2
  2. package/README.md +15 -9
  3. package/bin/lib/analysis-engine.mjs +4 -4
  4. package/bin/lib/ark-order-invariants.mjs +163 -14
  5. package/bin/lib/ark-order-types.mjs +3 -0
  6. package/bin/lib/diagnostic-catalog.mjs +5 -4
  7. package/bin/lib/remediation.mjs +11 -5
  8. package/dist/{diagnosticCatalog-DMO30svh.d.ts → diagnosticCatalog-D_DI7qrZ.d.ts} +1 -1
  9. package/dist/eslint/index.cjs +1 -1
  10. package/dist/eslint/index.js +1 -1
  11. package/dist/index.cjs +11 -11
  12. package/dist/index.d.ts +2 -2
  13. package/dist/index.js +10 -10
  14. package/dist/nestjs/index.cjs +5 -5
  15. package/dist/nestjs/index.d.ts +1 -1
  16. package/dist/nestjs/index.js +5 -5
  17. package/dist/order/index.cjs +1 -1
  18. package/dist/order/index.d.ts +61 -10
  19. package/dist/order/index.js +1 -1
  20. package/dist/runtime/index.cjs +11 -11
  21. package/dist/runtime/index.d.ts +3 -3
  22. package/dist/runtime/index.js +11 -11
  23. package/dist/{types-CzE6LMaW.d.ts → types-DrqsOiTY.d.ts} +21 -6
  24. package/docs/README.md +5 -4
  25. package/docs/agent-guide.md +2 -0
  26. package/docs/ai-gates.md +5 -2
  27. package/docs/arkorder.md +32 -14
  28. package/docs/configuration.md +5 -3
  29. package/docs/develop.md +7 -2
  30. package/docs/diagnostics.md +15 -5
  31. package/docs/package-surface.md +13 -10
  32. package/docs/product-voice.md +3 -3
  33. package/docs/use.md +1 -1
  34. package/package.json +1 -1
  35. package/server.json +2 -2
  36. package/templates/agent-skills/README.md +1 -1
  37. package/templates/agent-skills/ark-adopt/SKILL.md +4 -4
  38. package/templates/agent-skills/ark-architect/SKILL.md +1 -1
  39. package/templates/agent-skills/ark-autopilot/SKILL.md +4 -4
  40. package/templates/agent-skills/ark-contract/SKILL.md +1 -1
  41. package/templates/agent-skills/ark-coverage/SKILL.md +3 -2
  42. package/templates/agent-skills/ark-explain/SKILL.md +3 -2
  43. package/templates/agent-skills/ark-explore/SKILL.md +3 -2
  44. package/templates/agent-skills/ark-fix/SKILL.md +1 -1
  45. package/templates/agent-skills/ark-loop/SKILL.md +1 -1
  46. package/templates/agent-skills/ark-place/SKILL.md +8 -8
  47. package/templates/agent-skills/ark-runtime/SKILL.md +3 -0
  48. package/templates/agent-skills/ark-think/SKILL.md +2 -2
  49. package/templates/agent-skills/ark-upgrade/SKILL.md +2 -2
  50. package/templates/skills/ark-adopt.md +4 -4
  51. package/templates/skills/ark-architect.md +1 -1
  52. package/templates/skills/ark-autopilot.md +4 -4
  53. package/templates/skills/ark-contract.md +1 -1
  54. package/templates/skills/ark-coverage.md +3 -2
  55. package/templates/skills/ark-explain.md +3 -2
  56. package/templates/skills/ark-explore.md +3 -2
  57. package/templates/skills/ark-fix.md +1 -1
  58. package/templates/skills/ark-loop.md +1 -1
  59. package/templates/skills/ark-place.md +8 -8
  60. package/templates/skills/ark-runtime.md +3 -0
  61. package/templates/skills/ark-think.md +2 -2
  62. package/templates/skills/ark-upgrade.md +2 -2
package/CHANGELOG.md CHANGED
@@ -3,6 +3,37 @@
3
3
  All notable changes to ArkGate (`arkgate`; formerly `ark-runtime-kernel`) are documented here or
4
4
  in the immutable pre-2.0 archive linked below.
5
5
 
6
+ ## 4.8.6 — 2026-08-31
7
+
8
+ **Patch** over **4.8.5**. Phase **LV** — ArkOrder valved loop. First `release()`
9
+ freezes ξ; later pattern change is `proposeRelease` then `apply`. σ identity is
10
+ not ξ identity. ingest returns a closed residual. Capacity is data. ArkRun
11
+ carries the decision tape. **No required config migration.** Does not close
12
+ `K01` / `Z09`. No `/ark-order` skill. Do not npm-publish from this item until
13
+ the maintainer tag.
14
+
15
+ **Status: prepared** (tree ready; npm `latest` remains **4.8.5** until publish).
16
+
17
+ ### Added
18
+ - **`apply(ProposeResult)`** on `createOrderPlane`. Unvalved second freeze of a
19
+ different ξ fails `ARKORDER_UNVALVED_RELEASE` at runtime (not a lexical sensor).
20
+ - **`xiHash` / `sigmaHash` / `refreshSigma`** — saldo refresh does not mint a pattern.
21
+ - **Ingest residual** `absorb | escalate_up | hold` bound to `xiHash` + event
22
+ identity. Closed `reasonCode`: `not-in-pattern` | `stale-sigma` | `pack` |
23
+ `capacity`. `proposed_patch` only on `escalate_up`. `IngestEscalate.target` remains.
24
+ - **Capacity pack as data** (`kind` / `sigmaKey` / `payloadKey` / `op`). No user
25
+ predicates. Over-cap is residual, not a homemade kind.
26
+ - **ArkRun decision tape** on the information package (`{ xiHash, event, residual }`).
27
+ Component snapshot API unchanged. `shadow` / `compare` / `replay` in-process.
28
+ - **`ReleaseStore` port** with in-memory default. Optional catalog digest keyed by
29
+ `catalogReleaseId`. Not durable. Not K01.
30
+ - Thin gallery bridge: absorb may `send`; `escalate_up` human may `raises`.
31
+
32
+ ### Changed
33
+ - Public sentence: **ArkOrder freezes the pattern through a valve. ArkRun is how
34
+ the residual travels.** Skills `/ark-adopt` `/ark-place` `/ark-autopilot` deepen.
35
+ Doctor / status remain `notAScore`.
36
+
6
37
  ## 4.8.5 — 2026-08-31
7
38
 
8
39
  **Patch** over **4.8.4**. Phase **XP** (ArkOrder × ArkRun) plus Antigravity skill
@@ -11,7 +42,7 @@ now has a canonical page. The runtime half (shadow / replay / compare) is
11
42
  ArkRun and in-memory. **No required config migration.** Does not close `K01` /
12
43
  `Z09`.
13
44
 
14
- **Status: prepared** (not yet on npm `latest`).
45
+ **Status: published** (on npm `latest`; see `docs/releases/4.8.5.md`).
15
46
 
16
47
  ### Added
17
48
  - **`docs/arkorder.md`:** named APIs adopters were redesigning (`createOrderPlane`,
@@ -41,7 +72,7 @@ ArkRun and in-memory. **No required config migration.** Does not close `K01` /
41
72
 
42
73
  ## 4.8.4 — 2026-08-30
43
74
 
44
- **Status: published** (on npm `latest`; see `docs/releases/4.8.4.md`).
75
+ **Status: published** (see `docs/releases/4.8.4.md`).
45
76
 
46
77
  **Patch** over **4.8.3**. Invariant coverage stops hiding its own limits: the scan budget and the
47
78
  test globs are config, every discarded file is counted in the diagnostic, and coverage stops
package/README.md CHANGED
@@ -29,13 +29,15 @@ Works with Cursor, Claude, Codex, and Grok.
29
29
 
30
30
  </div>
31
31
 
32
- > **ArkGate 4.8.4** is on npm `latest`. Write. Check. Ship. Adopted = required GitHub
32
+ > **ArkGate 4.8.5** is on npm `latest`. This tree is **4.8.6** (prepared patch; not published).
33
+ > Write. Check. Ship. Adopted = required GitHub
33
34
  > status running `arkgate-check --strict-merge`, or an explicit `advisory-only` stance.
34
35
  > Status is compact (`arkgate-check --doctor`; `--all` for Details). Optional **ArkRun**
35
36
  > (`arkgate/runtime`) is an in-memory runtime — not Postgres. Optional **ArkOrder**
36
- > (`arkgate/order`) stops the agent rewriting the few slow product decisions as CRUD.
37
+ > (`arkgate/order`) stops the agent rewriting the few slow product decisions as CRUD;
38
+ > later pattern change is `proposeRelease` then `apply`.
37
39
  > `@arkgate/runtime` is deprecated.
38
- > [4.8.4](docs/releases/4.8.4.md) · [4.8.3](docs/releases/4.8.3.md) · [4.8.2](docs/releases/4.8.2.md) · [4.8.1](docs/releases/4.8.1.md) · [4.8.0](docs/releases/4.8.0.md) · [Docs hub](docs/README.md) · [Voice](docs/product-voice.md)
40
+ > [4.8.6](docs/releases/4.8.6.md) · [4.8.5](docs/releases/4.8.5.md) · [4.8.4](docs/releases/4.8.4.md) · [4.8.3](docs/releases/4.8.3.md) · [4.8.2](docs/releases/4.8.2.md) · [4.8.1](docs/releases/4.8.1.md) · [4.8.0](docs/releases/4.8.0.md) · [Docs hub](docs/README.md) · [Voice](docs/product-voice.md)
39
41
 
40
42
  ---
41
43
 
@@ -104,7 +106,7 @@ once you adopt. The other three are optional.
104
106
  | **Before merge** | `arkgate-check` as a **required** CI status | Always (ArkGate) |
105
107
  | **ArkRules** | Optional policies *inside* a layer | When you ask |
106
108
  | **ArkRun** | Optional experimental runtime (`arkgate/runtime`) | Off unless you turn it on |
107
- | **ArkOrder** | Stops the agent rewriting the few slow product decisions as CRUD (`arkgate/order`) | Off unless you turn it on |
109
+ | **ArkOrder** | Stops the agent rewriting the few slow product decisions as CRUD (`arkgate/order`). Valve: first `release()`, later ξ is `proposeRelease` then `apply` | Off unless you turn it on |
108
110
 
109
111
  Layers (who may import whom) always run. ArkRules, ArkRun, and ArkOrder change no
110
112
  inter-layer verdict when absent. Label leftovers **`[Layer]`** vs **`[ArkRules]`** vs
@@ -280,10 +282,13 @@ because “what may be the plan” was never a rule.
280
282
 
281
283
  **ArkOrder** (`arkgate/order`) is that rule. Off unless you add `arkOrder`.
282
284
  Name the slow keys (`xiKeys`: plan, protocol, cost-code bound — not `projectId`).
283
- Posting an invoice is absorbed. Changing plan is a new release, with a blast
284
- radius. A generic `update` of the plan does not land. A use-case that PATCHes
285
- those keys through Prisma is named. Same npm package.
285
+ Posting an invoice is absorbed. Changing plan is `proposeRelease` then `apply`.
286
+ `refreshSigma`; ingest residual `absorb | escalate_up | hold` + `reasonCode`;
287
+ capacity pack as data; in-memory `ReleaseStore`; `ingestTravelAction`; ArkRun
288
+ `decisionTape`. A generic `update` of the plan does not land. A use-case that
289
+ PATCHes those keys through Prisma is named. Same npm package.
286
290
  In-memory. Not durable. Does not replace ArkRun.
291
+ **ArkOrder freezes the pattern through a valve. ArkRun is how the residual travels.**
287
292
 
288
293
  Copy [examples/arkorder-billing/](examples/arkorder-billing/) and rename the
289
294
  three keys. Compact starters leave it off. Details:
@@ -304,8 +309,9 @@ three keys. Compact starters leave it off. Details:
304
309
  | Config · package surface · TS | [configuration](docs/configuration.md) · [package-surface](docs/package-surface.md) · [typescript-support](docs/typescript-support.md) |
305
310
  | Brownfield | [docs/brownfield-adoption.md](docs/brownfield-adoption.md) |
306
311
  | Security | [SECURITY.md](SECURITY.md) |
307
- | Current tree (4.8.5 prepared) | [docs/releases/4.8.5.md](docs/releases/4.8.5.md) · [CHANGELOG](CHANGELOG.md) |
308
- | Current published (4.8.4 on npm `latest`) | [docs/releases/4.8.4.md](docs/releases/4.8.4.md) |
312
+ | Tree prepared (4.8.6, not published) | [docs/releases/4.8.6.md](docs/releases/4.8.6.md) · [CHANGELOG](CHANGELOG.md) |
313
+ | Current published (4.8.5 on npm `latest`) | [docs/releases/4.8.5.md](docs/releases/4.8.5.md) · [CHANGELOG](CHANGELOG.md) |
314
+ | Prior published (4.8.4) | [docs/releases/4.8.4.md](docs/releases/4.8.4.md) |
309
315
  | Prior published (4.8.3) | [docs/releases/4.8.3.md](docs/releases/4.8.3.md) |
310
316
  | Prior published (4.8.2) | [docs/releases/4.8.2.md](docs/releases/4.8.2.md) |
311
317
  | Prior published (4.8.1) | [docs/releases/4.8.1.md](docs/releases/4.8.1.md) |