Merge codex/invariant-service-seam into codex/invariant-service-review-fixes

# Conflicts:
#	.agents/notes/implemented/architecture/2026-07-19-package-invariant-runtime-contracts.i18n.yaml
#	scripts/test-invariants.spec.ts
#	scripts/test-invariants.ts
This commit is contained in:
Tianyi Cui
2026-07-21 00:47:02 +08:00
51 changed files with 3912 additions and 13 deletions

View File

@@ -2,5 +2,5 @@
# side as of the last confirmed-consistent state. Both languages carry equal authority;
# after editing either side, bring the other along and re-record with:
# pnpm run verify-translation-pairing --write
2026-07-19-package-invariant-runtime-contracts.md: ab4301a80b01ac2b4b2870f02c232ab321a6fab1
2026-07-19-package-invariant-runtime-contracts.zh.md: 2e0816b2f381fd8fa51df51d8c482d6d4adf48b4
2026-07-19-package-invariant-runtime-contracts.md: aa67747878654d8958e52357f96f3654ca64df39
2026-07-19-package-invariant-runtime-contracts.zh.md: c0d308f95061a9f579201a72a4b011f98f79f891

View File

@@ -27,7 +27,7 @@ The central `dsh-invariants` service owns only configuration, registration uniqu
### Implemented checks
The current 94-package workspace has 19 executable companions and 75 justified empty companions.
The current 95-package workspace has 20 executable companions and 75 justified empty companions.
| Owner | Runtime relationship |
|---|---|
@@ -43,6 +43,7 @@ The current 94-package workspace has 19 executable companions and 75 justified e
| `dsh-hook-protocol` | Hook invocation/result correlation, dialect, identity, and duration constraints. |
| `dsh-sandbox-policy` | Durable `sandbox/mode` events use the closed sandbox-mode vocabulary. |
| `dsh-fs` | Filesystem decision/observation events carry usable target and version identities. |
| `dsh-goal` | Durable goal snapshots preserve source attribution, rendered content, revisions, lifecycle and timestamp relationships, and sequential admitted rounds. |
| `dsh-subagent` | Provider add/remove and child start/end events preserve identity and pairing. |
| `dsh-permission` | Durable permission decisions name a preset in the active permission table. |
| `dsh-user-approval` | Approval asked/decided records pair by call and use valid outcomes and policies. |

View File

@@ -27,7 +27,7 @@ Status: implemented
### 已实施的检查
当前 94 个包的 workspace 包含 19 个可执行 companion 和 75 个有理由的空 companion。
当前 95 个包的 workspace 包含 20 个可执行 companion 和 75 个有理由的空 companion。
| 所有者 | 运行时关系 |
|---|---|
@@ -43,6 +43,7 @@ Status: implemented
| `dsh-hook-protocol` | hook invocation/result 的关联、dialect、身份和 duration 约束。 |
| `dsh-sandbox-policy` | 持久化 `sandbox/mode` 事件必须使用封闭的 sandbox-mode 词表。 |
| `dsh-fs` | 文件系统决策/观测事件必须携带可用的 target 和 version 身份。 |
| `dsh-goal` | 持久化目标快照保持来源归属、渲染内容、修订号、生命周期和时间戳关系,并保证已准入的目标回合连续编号。 |
| `dsh-subagent` | provider add/remove 和 child start/end 事件必须保持身份与配对。 |
| `dsh-permission` | 持久化 permission 决策必须引用当前 permission 表中的 preset。 |
| `dsh-user-approval` | approval asked/decided 记录按 call 配对,并使用有效 outcome 和 policy。 |