Skip to content

Commit 4644b39

Browse files
spec: V22, clean-up prototyping drift
Promotes V22 as the canonical drift-detection and drift-closure release for ENGI. Proof-source commit: `5c3410df386022bb3f7c9c102c60724be46fe1c1` V22 was driven by detecting real canon-truth drift across the running system, demo shell, generated canon, and promotion path. The drift that was concretely found and closed in this release was: - active canonical pointer truth and runtime/demo posture could diverge - runtime-owned canon constants, policy/version ref, and generated appendix path could drift from `ENGI_SPEC.txt` - `buildInitialState()` / `publicState()` posture could diverge from the active pointer - `/api/state` posture truth could diverge from runtime posture truth - browser shell scaffolding could retain stale hardcoded canon messaging - operator explainer source still carried stale legacy `V15 §...` anchors and `v15-*` explainer keys - demo README posture could drift from active canon and generated appendix truth - V22 generated specifying artifacts were initially being written under `.engi/v21-*` paths because the shared generator still hardcoded V21 artifact names - V22 `_PROVEN_` generation was initially non-deterministic inside promotion because canonical-input validation was computed before the pending V22 `_PROVEN_` and `.engi/v22-*` artifacts existed - real-repo tests still asserted pre-promotion `V21 active / V22 draft` posture after the repo had actually advanced to `V22 active / V23 draft` This release fixes those exact drift surfaces as source, spec, and promotion truth: - `ENGI_SPEC.txt` now advances to `V22` - runtime/demo canon posture is now promotion-coupled and rewritten to `V22 active canon / V23 system draft` - `engi-demo/src/canon-posture.js` is now the executable canon-truth source for: - active canon version - draft target version - active generated appendix path - policy/version ref - operator label and spec label - `engi-demo/src/engi-demo.js` and `engi-demo/src/demo-shell-state.js` now derive posture from that runtime source instead of scattered literals - `engi-demo/server.js` keeps `/api/state` posture truth tied to runtime `SPEC_VERSION` and `buildPublicState(...)` - `engi-demo/public/index.html` now uses canon-posture placeholders instead of stale hardcoded hero posture - `engi-demo/public/app.js` now renders canon posture from runtime state and no longer carries visible stale V15 posture language, legacy `V15 §...` explainer anchors, or `v15-*` explainer keys - `engi-demo/README.md` now states the active canon, current generated appendix, and next draft posture in current-canon terms V22 also adds executable drift detection so the same class of drift now fails closed instead of being found informally: - `engi-demo/src/canonical/v22-canon-posture.js` builds the canonical drift report - `scripts/check-engi-canon-posture-drift.mjs` validates 10 concrete alignment checks: - pointer-active-canon alignment - canon-posture constant alignment - active proven appendix alignment - policy-ref alignment - runtime-state alignment - public-state alignment - server-api alignment - browser-shell placeholder alignment - browser-shell render alignment - README alignment - `.engi/v22-canon-posture-drift-report.json` is now a required canonical generated artifact V22 hardens promotion itself so drift is corrected and then re-validated during canon advancement: - `scripts/prepare-engi-spec-family-promotion.mjs` now supports V22 hand-authored family promotion truth rewriting - `scripts/prepare-engi-runtime-canon-promotion.mjs` rewrites runtime/demo posture to the promoted active canon and next draft - `scripts/promote-engi-canon.mjs` now supports V22 draft checks, runtime preparation, V22 `_PROVEN_` generation, post-generation canonical-input validation, post-promotion spec-family validation, and post-promotion drift validation V22 also fixes the generator defects surfaced by the first live promotion attempt: - shared specifying artifact generation in `engi-demo/src/canonical/v21-specifying.js` now emits version-local artifact paths instead of hardcoded `.engi/v21-*` - canonical-input report generation now supports assumed pending outputs so `_PROVEN_` write/check passes are deterministic inside one promotion sequence - `engi-demo/src/canonical/proven-generator.js` now uses those assumed pending outputs for V21 and V22 generated appendix construction - V22 generated artifact family is now correct and stable: - `.engi/v22-spec-family-report.json` - `.engi/v22-canonical-input-report.json` - `.engi/v22-canon-posture-drift-report.json` - `ENGI_SPEC_V22_PROVEN.md` Specs and parity were updated to make drift detection foundational rather than incidental: - `ENGI_SPEC_V22.md` - `ENGI_SPEC_V22_DELTA.md` - `ENGI_SPEC_V22_PARITY_MATRIX.md` - `ENGI_SPEC_V22_NOTES.md` These now define V22 as runtime/operator canon-truth closure, record the exact drift surfaces, and accept the first-gate boundaries explicitly rather than leaving them implicit. Tests were updated to match promoted truth and to keep V22 drift closure executable: - new `engi-demo/test/v22-canon-drift.test.js` - real-repo drift checks now assert `V22 active / V23 draft` - real-repo promoted spec-family and canonical-input checks now assert `V22` - V22 `_PROVEN_` generation tests now assert the V22 artifact triplet and drift report presence Accepted V22 first-gate boundaries remain explicit: - projection-security matrix expansion stays deferred - full mutation cross-product expansion stays deferred - screenshot-backed visual closure stays deferred V22 closes canon-truth drift and promotion reliability without reopening subsystem design. Validation completed for the promoted V22 payload: - `npm --prefix engi-demo run typecheck` - `npm --prefix engi-demo run test:unit` - `node scripts/generate-engi-proven.mjs --version V22 --commit 5c3410d --worktree-state clean --output ENGI_SPEC_V22_PROVEN.md --check --allow-dirty` - `node scripts/check-engi-canonical-inputs.mjs --current-target V22` - `node scripts/check-engi-spec-family.mjs --version V22 --mode promoted` - `node scripts/check-engi-canon-posture-drift.mjs --active-canon V22 --draft-target V23` - `git diff --check` Earlier in the live V22 promotion path, integration, E2E, inherited V19 reproducible-canon gates, inherited V20 operator-quality gates, and the aggregate non-E2E suite all passed before the post- generation V22 artifact determinism defect was exposed and corrected. V22 canon now makes drift detection a permanent system property: pointer truth, hand-authored canon, generated canon, runtime posture, API posture, browser posture, README posture, and promotion machinery must remain aligned or the release fails closed.
1 parent 5c3410d commit 4644b39

23 files changed

Lines changed: 4014 additions & 194 deletions
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
{
2+
"reportId": "v22-canon-posture-drift-report",
3+
"version": "V22",
4+
"checkedActiveCanonVersion": "V22",
5+
"checkedDraftTargetVersion": "V23",
6+
"pointerVersion": "V22",
7+
"proofSourceCommit": "5c3410df386022bb3f7c9c102c60724be46fe1c1",
8+
"generatedAt": "2026-04-12T19:33:14-03:00",
9+
"generatorId": "engi-demo.proven-generator.v1",
10+
"worktreeState": "clean",
11+
"passed": true,
12+
"checkCount": 10,
13+
"blockingFailureCount": 0,
14+
"blockingFailures": [],
15+
"runtimeSpecVersion": "ENGI Spec V22 active canon / V23 system draft",
16+
"publicSpecVersion": "ENGI Spec V22 active canon / V23 system draft",
17+
"activeProvenAppendixPath": "ENGI_SPEC_V22_PROVEN.md",
18+
"policyRef": "policy://engi/spec-v22-active-v23-system-draft/current",
19+
"checkedFiles": [
20+
"engi-demo/README.md",
21+
"engi-demo/public/index.html",
22+
"engi-demo/public/app.js",
23+
"engi-demo/server.js"
24+
],
25+
"checks": [
26+
{
27+
"checkId": "pointer-active-canon-alignment",
28+
"passed": true,
29+
"detail": "ENGI_SPEC.txt points to V22 while runtime expects V22."
30+
},
31+
{
32+
"checkId": "canon-posture-constant-alignment",
33+
"passed": true,
34+
"detail": "canon-posture constants resolve V22/V23 with operator label V22 active canon / V23 system draft."
35+
},
36+
{
37+
"checkId": "proven-appendix-alignment",
38+
"passed": true,
39+
"detail": "active generated appendix path is ENGI_SPEC_V22_PROVEN.md."
40+
},
41+
{
42+
"checkId": "policy-ref-alignment",
43+
"passed": true,
44+
"detail": "policy reference is policy://engi/spec-v22-active-v23-system-draft/current."
45+
},
46+
{
47+
"checkId": "runtime-state-alignment",
48+
"passed": true,
49+
"detail": "buildInitialState() reports ENGI Spec V22 active canon / V23 system draft with canon posture V22/V23."
50+
},
51+
{
52+
"checkId": "public-state-alignment",
53+
"passed": true,
54+
"detail": "publicState() reports ENGI Spec V22 active canon / V23 system draft with canon posture V22/V23."
55+
},
56+
{
57+
"checkId": "server-api-alignment",
58+
"passed": true,
59+
"detail": "server.js keeps API posture sourced from SPEC_VERSION and buildPublicState(...)."
60+
},
61+
{
62+
"checkId": "browser-shell-placeholder-alignment",
63+
"passed": true,
64+
"detail": "public/index.html exposes canon-posture placeholders and no stale hardcoded hero posture."
65+
},
66+
{
67+
"checkId": "browser-shell-render-alignment",
68+
"passed": true,
69+
"detail": "public/app.js renders canon posture from runtime state and omits stale V15 explainer keys."
70+
},
71+
{
72+
"checkId": "readme-alignment",
73+
"passed": true,
74+
"detail": "README states V22 active canon and ENGI_SPEC_V22_PROVEN.md as the current generated appendix."
75+
}
76+
]
77+
}
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"reportId": "v22-canonical-input-report",
3+
"version": "V22",
4+
"proofSourceCommit": "5c3410df386022bb3f7c9c102c60724be46fe1c1",
5+
"generatedAt": "2026-04-12T19:33:14-03:00",
6+
"generatorId": "engi-demo.proven-generator.v1",
7+
"worktreeState": "clean",
8+
"checkedTargetVersion": "V22",
9+
"pointerVersion": "V22",
10+
"passed": true,
11+
"failureCount": 0,
12+
"failures": [],
13+
"specPath": "ENGI_SPEC_V22.md",
14+
"provenPath": "ENGI_SPEC_V22_PROVEN.md",
15+
"parityPath": "ENGI_SPEC_V22_PARITY_MATRIX.md",
16+
"requiredGeneratedArtifactPaths": [
17+
".engi/v22-spec-family-report.json",
18+
".engi/v22-canonical-input-report.json",
19+
".engi/v22-canon-posture-drift-report.json"
20+
],
21+
"requiredGeneratedArtifactCount": 3
22+
}

.engi/v22-spec-family-report.json

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"reportId": "v22-spec-family-report",
3+
"version": "V22",
4+
"proofSourceCommit": "5c3410df386022bb3f7c9c102c60724be46fe1c1",
5+
"generatedAt": "2026-04-12T19:33:14-03:00",
6+
"generatorId": "engi-demo.proven-generator.v1",
7+
"worktreeState": "clean",
8+
"checkedVersion": "V22",
9+
"mode": "promoted",
10+
"currentTarget": "V22",
11+
"pointerVersion": "V22",
12+
"passed": true,
13+
"failureCount": 0,
14+
"failures": [],
15+
"requiredFiles": [
16+
"ENGI_SPEC_V22.md",
17+
"ENGI_SPEC_V22_DELTA.md",
18+
"ENGI_SPEC_V22_PARITY_MATRIX.md"
19+
],
20+
"supportFiles": [
21+
"ENGI_SPECIFYING.md",
22+
"ENGI_SPEC_TEMPLATEGUIDE.md"
23+
],
24+
"requiredStatusLabelCount": 4,
25+
"requiredPromotedStatusLabelCount": 1,
26+
"requiredSpecSectionCount": 18,
27+
"requiredAppendixSectionCount": 14,
28+
"requiredProofFamilyCount": 9,
29+
"requiredGeneratedArtifactCatalogSectionCount": 10,
30+
"requiredGeneratedArtifactPathCount": 3,
31+
"requiredSubsystemCoverageCount": 18
32+
}

ENGI_SPEC.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
V21
1+
V22

0 commit comments

Comments
 (0)