codex-workflow-v2 2.0.0-beta.12.8 → 2.0.0-beta.13

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 (124) hide show
  1. package/README.md +60 -16
  2. package/dist/reviewer-runtime-build.json +1092 -0
  3. package/dist/src/alpha6/check-support-anchor.d.ts +24 -0
  4. package/dist/src/alpha6/check-support-anchor.js +102 -0
  5. package/dist/src/alpha6/check-support-anchor.js.map +1 -0
  6. package/dist/src/alpha6/component-owner.d.ts +28 -0
  7. package/dist/src/alpha6/component-owner.js +95 -0
  8. package/dist/src/alpha6/component-owner.js.map +1 -0
  9. package/dist/src/alpha6/downstream-proof.js +4 -2
  10. package/dist/src/alpha6/downstream-proof.js.map +1 -1
  11. package/dist/src/alpha6/mechanical-feasibility.js +42 -12
  12. package/dist/src/alpha6/mechanical-feasibility.js.map +1 -1
  13. package/dist/src/alpha6/milestone.d.ts +6 -2
  14. package/dist/src/alpha6/milestone.js +164 -10
  15. package/dist/src/alpha6/milestone.js.map +1 -1
  16. package/dist/src/alpha6/npm-check-contract.d.ts +11 -0
  17. package/dist/src/alpha6/npm-check-contract.js +36 -0
  18. package/dist/src/alpha6/npm-check-contract.js.map +1 -0
  19. package/dist/src/alpha6/plan-integrity.js +157 -27
  20. package/dist/src/alpha6/plan-integrity.js.map +1 -1
  21. package/dist/src/alpha6/plan-risk.js +3 -1
  22. package/dist/src/alpha6/plan-risk.js.map +1 -1
  23. package/dist/src/alpha6/remediation-cause.d.ts +13 -0
  24. package/dist/src/alpha6/remediation-cause.js +77 -0
  25. package/dist/src/alpha6/remediation-cause.js.map +1 -0
  26. package/dist/src/alpha6/remediation.d.ts +15 -4
  27. package/dist/src/alpha6/remediation.js +430 -67
  28. package/dist/src/alpha6/remediation.js.map +1 -1
  29. package/dist/src/alpha6/review.d.ts +6 -0
  30. package/dist/src/alpha6/review.js +46 -4
  31. package/dist/src/alpha6/review.js.map +1 -1
  32. package/dist/src/artifacts.js +6 -0
  33. package/dist/src/artifacts.js.map +1 -1
  34. package/dist/src/cli-actions.d.ts +25 -0
  35. package/dist/src/cli-actions.js +109 -0
  36. package/dist/src/cli-actions.js.map +1 -0
  37. package/dist/src/cli.js +244 -253
  38. package/dist/src/cli.js.map +1 -1
  39. package/dist/src/contracts.d.ts +202 -5
  40. package/dist/src/credential-transport.d.ts +38 -0
  41. package/dist/src/credential-transport.js +156 -0
  42. package/dist/src/credential-transport.js.map +1 -0
  43. package/dist/src/dependency-provenance.d.ts +23 -2
  44. package/dist/src/dependency-provenance.js +239 -36
  45. package/dist/src/dependency-provenance.js.map +1 -1
  46. package/dist/src/domain/completed-step-carryover.d.ts +13 -0
  47. package/dist/src/domain/completed-step-carryover.js +71 -0
  48. package/dist/src/domain/completed-step-carryover.js.map +1 -0
  49. package/dist/src/domain/validation.d.ts +9 -1
  50. package/dist/src/domain/validation.js +86 -0
  51. package/dist/src/domain/validation.js.map +1 -1
  52. package/dist/src/gateway-handshake.d.ts +11 -0
  53. package/dist/src/gateway-handshake.js +92 -0
  54. package/dist/src/gateway-handshake.js.map +1 -0
  55. package/dist/src/git.js +1 -0
  56. package/dist/src/git.js.map +1 -1
  57. package/dist/src/historical-step-provenance.d.ts +20 -0
  58. package/dist/src/historical-step-provenance.js +111 -0
  59. package/dist/src/historical-step-provenance.js.map +1 -0
  60. package/dist/src/index.d.ts +2 -0
  61. package/dist/src/index.js +2 -0
  62. package/dist/src/index.js.map +1 -1
  63. package/dist/src/lifecycle/corrective-replan-binding-manifest.d.ts +5 -0
  64. package/dist/src/lifecycle/corrective-replan-binding-manifest.js +9 -0
  65. package/dist/src/lifecycle/corrective-replan-binding-manifest.js.map +1 -1
  66. package/dist/src/lifecycle/corrective-replan.js +1 -1
  67. package/dist/src/lifecycle/corrective-replan.js.map +1 -1
  68. package/dist/src/lifecycle/semantic-registry.js +1 -1
  69. package/dist/src/observation.js +1 -2
  70. package/dist/src/observation.js.map +1 -1
  71. package/dist/src/observed-routes.d.ts +114 -0
  72. package/dist/src/observed-routes.js +545 -0
  73. package/dist/src/observed-routes.js.map +1 -0
  74. package/dist/src/operational-contract.d.ts +26 -0
  75. package/dist/src/operational-contract.js +94 -0
  76. package/dist/src/operational-contract.js.map +1 -0
  77. package/dist/src/reviewer.d.ts +218 -8
  78. package/dist/src/reviewer.js +927 -25
  79. package/dist/src/reviewer.js.map +1 -1
  80. package/dist/src/state/corrective-replan-executor.js +23 -15
  81. package/dist/src/state/corrective-replan-executor.js.map +1 -1
  82. package/dist/src/state/corrective-replan-public.js +35 -10
  83. package/dist/src/state/corrective-replan-public.js.map +1 -1
  84. package/dist/src/state/corrective-replan-transaction.js +12 -4
  85. package/dist/src/state/corrective-replan-transaction.js.map +1 -1
  86. package/dist/src/state/corrective-yield-transaction.js +11 -2
  87. package/dist/src/state/corrective-yield-transaction.js.map +1 -1
  88. package/dist/src/state/lock.d.ts +1 -0
  89. package/dist/src/state/lock.js +24 -0
  90. package/dist/src/state/lock.js.map +1 -1
  91. package/dist/src/version.d.ts +1 -1
  92. package/dist/src/version.js +1 -1
  93. package/dist/src/version.js.map +1 -1
  94. package/dist/src/workflow.d.ts +70 -4
  95. package/dist/src/workflow.js +1888 -152
  96. package/dist/src/workflow.js.map +1 -1
  97. package/docs/autonomy-guardrails.md +41 -14
  98. package/docs/delegated-approval.md +6 -1
  99. package/docs/development-flow.md +42 -12
  100. package/docs/pdf/codex-workflow-v2-architecture-ru.pdf +0 -0
  101. package/docs/pdf/codex-workflow-v2-chat-only-guide-ru.pdf +0 -0
  102. package/docs/pdf/codex-workflow-v2-technical-reference-ru.pdf +0 -0
  103. package/docs/pdf/sources/codex-workflow-v2-architecture-ru.md +191 -22
  104. package/docs/pdf/sources/codex-workflow-v2-chat-only-guide-ru.md +163 -45
  105. package/docs/pdf/sources/codex-workflow-v2-technical-reference-ru.md +346 -52
  106. package/docs/problem-briefs/01-pre-implementation-integrity.md +11 -7
  107. package/docs/problem-briefs/04-task-dependency-and-structural-replacement-integrity.md +13 -6
  108. package/docs/problem-briefs/README.md +11 -11
  109. package/docs/release.md +89 -9
  110. package/docs/updating-existing-project.md +235 -0
  111. package/docs/validation-report.md +156 -98
  112. package/package.json +12 -3
  113. package/plugins/codex-workflow-gateway/.codex-plugin/plugin.json +1 -1
  114. package/plugins/codex-workflow-gateway/references/protocol.md +9 -0
  115. package/plugins/codex-workflow-gateway/skills/codex-workflow-gateway/SKILL.md +67 -1
  116. package/schemas/authorization-event.schema.json +10 -3
  117. package/schemas/corrective-decision-event.schema.json +164 -9
  118. package/schemas/corrective-replan-credentials.private.schema.json +4 -2
  119. package/schemas/milestone-scope-change-event.schema.json +25 -1
  120. package/schemas/remediation-event.schema.json +17 -1
  121. package/schemas/review-result.schema.json +1 -0
  122. package/schemas/step-review-event.schema.json +15 -0
  123. package/schemas/task.schema.json +104 -1
  124. package/schemas/transition-definition.schema.json +8 -0
@@ -1,103 +1,161 @@
1
- # V2 beta.12.8 Validation Report
1
+ # V2 beta.13 Validation Report
2
2
 
3
- Release candidate `2.0.0-beta.12.8` was validated on 2026-08-29 (Europe/Moscow) with
3
+ Release candidate `2.0.0-beta.13` was validated during 2026-09-02--03 (Europe/Moscow) with
4
4
  Node.js 24.17.0.
5
5
 
6
6
  ## Automated release evidence
7
7
 
8
- - `npm ci` completed from the exact lockfile with 0 reported vulnerabilities.
9
- - `npm run validate` passed typecheck and `339/339` sequential tests with no failures, skips,
10
- cancellations, or todos in 1,700,172.265375 ms.
11
- - The focused claimed-Task E2E passed independently. It covers sealed passed final review,
12
- machine-readable `task result-set` writer-token navigation, rejection of a forged token without
13
- Task/lease mutation, successful Result publication, lease-free `awaiting_final_acceptance`, Human
14
- acceptance, fresh credential replacement, merge, and terminal lease release.
15
- - CLI help regression proves that `task result-set` requires `--writer-token` and exposes optional
16
- `--actor` for the exact C1 claimant.
17
- - The full suite retained the Signal-shaped downstream replan E2E, Signal T04 retained-review
18
- recovery, dependency provenance, Plan-integrity recovery, corrective replan, lock hostility,
19
- transaction crash/recovery, Milestone dependency, strict-review, and credential-confinement gates.
20
- - `npm run pack:check` built the exact beta.12.8 package with 275 files, 1.0 MB packed and 4.1 MB
21
- unpacked. The initial sandboxed invocation could not write the user npm cache (`EPERM`); the exact
22
- authorized retry passed.
23
- - `npm run smoke:downstream` packed and installed the tarball in a disposable consumer project and
24
- returned `ok=true`. The sandboxed attempt could not resolve the npm registry (`ENOTFOUND`); the
25
- exact network-authorized retry passed.
26
- - `npm run plugin:check` passed for bundled gateway
27
- `0.1.0+codex.20260829181421`. The plugin-creator manifest validator and skill quick validator also
28
- passed using the system Python runtime that provides PyYAML.
29
- - `npm run docs:pdf:check` reported an empty stale set and exact beta.12.8 package binding.
30
- - `RELEASE_TAG=v2.0.0-beta.12.8 npm run release:check` and `git diff --check` passed.
31
-
32
- ## Root cause corrected by beta.12.8
33
-
34
- `WorkflowService.setTaskResult` previously moved a reviewed Task from `validating` to
35
- `awaiting_final_acceptance` without accepting the active writer credential and without releasing
36
- the Task writer lease. Human final acceptance is intentionally unbounded, so an otherwise successful
37
- Task could wait until the lease expired. Repository-level `next` then truthfully returned
38
- `repair-required / STALE_WRITER_LEASE` instead of `task accept`.
39
-
40
- Increasing review or implementation attempts cannot correct this condition. The implementation and
41
- review had already passed; the defect was ownership lifetime crossing a Human pause.
42
-
43
- ## Implemented lifecycle contract
44
-
45
- - `task result-set` now requires the active `--writer-token`; claimed C1 Tasks also pass the exact
46
- claimant through `--actor`.
47
- - Core verifies the current revision, passed/fresh review, live writer credential, and C1 mutation
48
- authority before staging Result.
49
- - Core releases the exact presented lease before committing the transition to
50
- `awaiting_final_acceptance`. Human wait time therefore cannot create a new stale lease.
51
- - Fresh `next` advertises the writer-token contract and bounded credential recovery for
52
- `task result-set` when needed.
53
- - `task accept` remains a credential-free Human/delegated approval transition. After acceptance,
54
- fresh `next` advertises `task writer-credential-replace`; this acquires a new lease for local merge
55
- or external merge confirmation. The pre-gate token is not reusable.
56
- - The public handshake exposes `task-human-gate-lease-release-v1`.
57
-
58
- ## Exact Signal diagnosis evidence
59
-
60
- At diagnosis time the Signal project `/Users/home-pc/htdocs/projects/signal_v4` was on exact
61
- beta.12.7 with Task `TASK-01M0WXJAD4GZGVNRJ284ND95C6` at revision 126 and
62
- `awaiting_final_acceptance`. The Task checkout was clean at
63
- `f7ba8533314ee27f176968a6314bf3df40285ef2`; Final Task Review was `passed` with no findings.
64
- The Result hash was `89bbbaaef5d2b454ed7ed0e3d9f57484d36c9d86d596e009a32613701003496e`
65
- and Evidence hash was `85f3cb5c16e039ebf40971f88a4388fe1812ef37be8d6b195451aa6a73640c54`.
66
- Repository-level `next` returned only `locks repair` for the expired lease owned by the Task worker.
67
-
68
- The release process did not mutate Signal state or product files. The legacy lease must first be
69
- removed through that exact advertised repair route with revision, HEAD, review, Result, and Evidence
70
- readback. The agent must stop before `task accept`. Only after the repository is lease-free and
71
- `update preflight` is safe should Signal install beta.12.8 and continue through fresh navigation.
72
-
73
- ## PDF release documentation evidence
74
-
75
- - All three tracked Russian PDFs were regenerated from the beta.12.8 Markdown sources.
76
- - Architecture is 8 pages, the delegated chat-only guide is 9 pages, and the technical reference is
77
- 11 pages. Every page was rendered to PNG and visually inspected.
78
- - Titles, version headers, Cyrillic text, tables, code blocks, Human-gate credential sequence,
79
- release checklist, margins, and page footers have no visible clipping, overlap, orphaned tail page,
80
- or unreadable content.
81
-
82
- ## Existing boundaries and non-claims
83
-
84
- - beta.12.8 prevents new `result-set` transitions from retaining a lease. It does not silently delete
85
- a stale lease created by beta.12.7 or earlier; legacy state uses explicit `locks repair`.
86
- - The patch does not auto-accept a Task, bypass final review, widen delegated approval, or turn an
87
- expired bearer into authority.
88
- - Protocol version remains 2 and state schema remains 2; no semantic state migration is introduced.
89
- - Structural replacement remains intentionally disabled. beta.12.8 does not implement P04-B,
90
- topology rewiring, completed-Step adoption, or a wider delegation surface.
91
- - No append-only real-agent lifecycle log was generated for this maintainer release turn because
92
- the package Workflow did not orchestrate its own repository mutation. Transcript validator
93
- semantics remain covered by the complete valid/invalid fixture suite; no synthetic log is
94
- presented as real evidence.
95
- - Validation performed no npm publication, Git commit, tag, remote push, Signal dependency update,
96
- Signal Task acceptance, or local personal-plugin reinstall. Those are separate release/deployment
97
- actions.
98
-
99
- Confidence is high for the package implementation, negative credential behavior, complete claimed
100
- Task continuation, tarball, downstream installation, plugin, and documentation. Confidence that the
101
- live Signal Milestone will continue is conditional on completing the exact legacy stale-lease repair,
102
- observing a safe update preflight, installing the published beta.12.8 package, and following fresh
103
- project-local `status -> next` without skipping the Human gate.
8
+ - A clean `npm ci` completed from the exact lockfile. A network-enabled `npm audit --json` reported
9
+ zero vulnerabilities at every severity across all eight installed dependencies.
10
+ - `npm run validate` passed typecheck and `408/408` sequential tests with no failures, skips,
11
+ cancellations or todos in 2,761,796.900458 ms.
12
+ - `npm run test:signal-t10-check-support-e2e` passed `8/8` after the final clean install in
13
+ 203,155.332125 ms. It covers an impossible selector-less check, machine-derived support scope,
14
+ Knowledge rebind, historical evidence reuse and exact compatibility from both beta.12.11 and
15
+ beta.12.15 into beta.13.
16
+ - `npm run test:signal-remediation-e2e` passed `2/2` in 9,220.225709 ms. The audited remediation
17
+ adds the required upstream Task and resumes the original Task through a later Step without
18
+ auto-approving unrelated Knowledge drift.
19
+ - `npm run test:signal-t03-replan-e2e` passed `1/1` in 45,253.2055 ms. The Signal-shaped flow
20
+ recovers an accidental rebind, replans and completes the consolidated guarded Step.
21
+ - `npm run test:signal-t04-recovery` passed `11/11` in 22,021.439625 ms. It preserves only exact
22
+ reviewed Step provenance and rejects pending, corrupt, unrelated or stale recovery evidence.
23
+ - `npm run pack:check` produced the exact `2.0.0-beta.13` tarball with 309 files, package size
24
+ 1.2 MB and unpacked size 4.8 MB. It includes the shared gateway-handshake module and the
25
+ hash-verifiable reviewer runtime build manifest.
26
+ - `npm run smoke:downstream` packed the release, installed it into an empty project and returned
27
+ `ok=true`. The first sandboxed attempt could not resolve the npm registry; the identical
28
+ network-enabled invocation passed.
29
+ - `npm run plugin:check`, `npm run docs:pdf:check`, `npm run typecheck` and `git diff --check` all
30
+ passed. The PDF checker reported no stale generated document. `npm run release:check` passed
31
+ `103/103` tests in 300,945.515375 ms and returned the exact package/version assertion.
32
+
33
+ ## Release-candidate regressions found and closed
34
+
35
+ The first complete candidate run reported `352/380` passing tests. A common precedence defect was
36
+ found: explicit beta.13 unclassified reviewer findings (`causeBindings: []`) had been confused with
37
+ legacy events where `causeBindings` is absent. The corrected contract keeps the former on the same
38
+ Task, sends only a repeated authoritative cause to root-cause replan, and preserves an explicit
39
+ current corrective decision over ordinary rolling continuation. Read-only remediation observation
40
+ no longer requires a live bearer, while execution still requires exact actor and credential
41
+ authority.
42
+
43
+ The second complete run reported `375/380`. These five failures exposed three release-boundary
44
+ defects that focused tests run before the version bump had missed:
45
+
46
+ - Step comparison still admitted runtime-only fields into Plan semantics and could demote an
47
+ unchanged completed Step to `planned` during replan;
48
+ - a synthetic pre-beta.13 remediation event retained the new `causeBindings` field and therefore
49
+ no longer represented legacy data;
50
+ - the dependency compatibility preflight parsed only `beta.12.<patch>` runners, so the actual
51
+ beta.13 release candidate could not consume the supported beta.12.11+ recovery surface.
52
+
53
+ Production Plan comparison now canonicalizes only executable Step fields in both ordinary and
54
+ journaled replan paths. Legacy recovery remains limited to events where `causeBindings` is absent.
55
+ Compatibility compares the beta train and patch and still requires an exact beta.12 source at or
56
+ after beta.12.11, a newer runner, matching declared/locked/installed/base versions and every existing
57
+ dirty, lease and evidence guard. Repeated focused and parallel regressions passed before the final
58
+ candidate expansion.
59
+
60
+ A later complete run of the expanded candidate reported `387/396`. It exposed four distinct issues
61
+ rather than one product defect:
62
+
63
+ - an autonomous-retry fixture was incorrectly labelled `runtime-composition` and therefore invoked
64
+ the new structural production-edge gate;
65
+ - legacy stop-override fixtures accidentally retained native beta.13 cause bindings;
66
+ - assertions still expected direct submit/merge after credential release and retained a completed
67
+ dependent Step after its predecessor was invalidated;
68
+ - external sealed-review preflight spawned the full CLI graph with 15-second and 60-second deadlines;
69
+ under scheduler pressure a valid exact repository-local runtime could exhaust both deadlines and
70
+ produce a false infrastructure blocker.
71
+
72
+ The first three were corrected only at their stale fixtures/expectations; production authority was
73
+ not weakened. The reviewer defect was fixed structurally: CLI and preflight now share one pure
74
+ gateway descriptor, and preflight synchronously loads the exact installed gateway, reviewer and
75
+ workflow graph through Node after manifest/hash verification. It does not spawn a schedulable child,
76
+ cache trust, install or build dependencies. Missing transitive dependencies, byte drift, unsafe paths,
77
+ symlinks and contract mismatch remain fail-closed. Five concurrent preflights under eight CPU burners
78
+ passed, and the exact five-file regression that had failed passed `88/88`. The final complete run then
79
+ passed `399/399`.
80
+
81
+ An independent agnostic release audit then reproduced one additional production defect in a long-lived
82
+ process: after one successful preflight, Node's warm module cache could hide a subsequently deleted
83
+ transitive dependency and still allow a sealed packet. The fix does not clear or reinterpret the module
84
+ cache. Instead, every preflight now resolves the actual recursive dependency graph from each parent
85
+ package using nested-first Node lookup and re-hashes exact package manifests plus every attested
86
+ `.js`, `.cjs`, `.mjs`, `.json` and `.node` runtime file before any cached module can be trusted. Missing,
87
+ tampered, conflicting, path-escaped or symlink-redirected state fails before load and before packet
88
+ issuance. Exact Ajv runtime transitives are direct pins so the built attestation and npm layout are
89
+ deterministic. Same-process ready-delete-fail-restore-ready, warm tamper, nested version conflict and
90
+ stale nearer-copy regressions expanded the complete suite.
91
+
92
+ A real native reviewer preflight then exposed an API-level Structured Output incompatibility: every
93
+ declared object property must also be present in `required`. The reviewer schema now makes nullable
94
+ optional semantics explicit, while the semantic parser still rejects absent or contradictory
95
+ cause/plan-conflict evidence. The complete suite consequently reached `408/408`, and the expanded
96
+ release check reached `103/103`.
97
+
98
+ The same real-agent exercise corrected the release proof boundary without weakening Core. A nested
99
+ `codex exec` reviewer is not treated as independent production evidence: the Coordinator stops at a
100
+ read-only sealed packet, a distinct Codex App task performs each Step/Task review, and an external
101
+ conductor binds the four-field review object to the packet hash, repository seal and actual reviewer
102
+ task ID before the original persistent Coordinator resumes. The disposable release grant is limited
103
+ to `task.execution_authorize` and `task.final_accept`; both authorizations, credential recovery and
104
+ merge therefore use one delegate actor without an intermediate Human approval. A diagnostic harness
105
+ attempt is never resumed or promoted after a failed binding.
106
+
107
+ The first fully merged delegated fixture also found a fail-closed validator inventory gap:
108
+ `discovery show` was logged as a mutation, so a harmless read between CLI help and fresh `next` was
109
+ rejected as `HELP_REQUIRES_FRESH_NEXT`. The packaged transcript validator now classifies this command
110
+ as a read-only observation and carries a regression for help -> read-only observation -> next ->
111
+ mutation. This changes release-evidence interpretation only; it grants no lifecycle authority.
112
+
113
+ ## Implemented beta.13 contract
114
+
115
+ - Failed Step checks and failed strict Step reviews enter an atomic continuation pause: evidence,
116
+ Task state and writer/C1 release either commit together or recover through the transaction journal.
117
+ - Distinct normalized causes continue in the same Task without a numeric retry ceiling. A repeated
118
+ authoritative cause after a claimed fix requires root-cause replan; volatile output cannot create
119
+ a new cause identity.
120
+ - Corrective replan preserves an unchanged completed Step and its reviewed commit only when every
121
+ dependency is also retained with the exact executable definition. A changed or omitted Step and
122
+ its transitive completed descendants are invalidated rather than silently adopted; independent
123
+ unchanged branches remain retained.
124
+ - For multi-Step runtime composition, structural production edges are independently triggered by
125
+ the PRA classification rather than a planner-owned flag, and checked for a transitive owner,
126
+ consumer and exact executable consumer check. Simple one-Step runtime is exempt. This is bounded
127
+ structural authority, not a claim of full product-semantic correctness.
128
+ - Writer credentials are stored in private local references and are never serialized as raw bearer
129
+ material in public CLI output, status, diagnostics or reviewer packets.
130
+ - Compact status, reviewer runtime preflight, explicit review mode, App-owned operational preflight
131
+ and the observed Signal route matrix are packaged capabilities. Its class-level claim covers all
132
+ 13 route classes observed in Signal with one exact production transition or terminal observation
133
+ per class. Action-level metadata remains explicit about witnessed, unwitnessed and unsupported
134
+ actions; unknown or malformed advertised actions fail closed.
135
+ - Reviewer runtime preflight requires exact declared, locked and installed package versions, a
136
+ hash-verified build manifest, byte equality for the running/installed CLI, gateway, reviewer and
137
+ workflow entrypoints, and a disk-fresh recursive dependency attestation on every call. It loads the
138
+ exact installed runtime graph in-process only after that attestation and issues no sealed review
139
+ packet when any readiness or contract check fails.
140
+
141
+ ## Boundaries and non-claims
142
+
143
+ - beta.13 does not introduce generic shadow-history import, completed-Step adoption from an
144
+ unrelated Task, or unchecked Workflow-state reconstruction.
145
+ - P02 Step-validity authority, P03 generic context reuse and P04-B structural Task replacement remain
146
+ outside this release unless an exact implemented capability says otherwise.
147
+ - App-owned effects such as chat creation, consent UI and polling remain outside Core. Core exposes
148
+ diagnostic preflights but does not claim those effects occurred.
149
+ - The package tests prove the supported compatibility and lifecycle contracts. They do not prove a
150
+ future Milestone's product requirements or replace independent product review.
151
+ - The required real-agent transcript is external release evidence bound to the final tarball and source
152
+ commit. This tracked report does not claim that gate before its append-only log, actual-agent
153
+ cross-check, product test, clean Git boundary and credential-residue checks have all passed.
154
+ - This report does not claim commit/tag/push, npm publication, installation into Signal or Milestone
155
+ 4 readiness until those operations receive exact readback.
156
+
157
+ Confidence is high for package behavior and the stated compatibility boundary: the final `408/408`
158
+ run, `103/103` release check, four Signal-shaped E2E suites, package/downstream smoke, CPU-saturation,
159
+ warm-cache and fail-closed negative cases agree. Live Signal readiness remains conditional on
160
+ publication, exact repository-local installation, safe
161
+ closure of the frozen Milestone 3 authority and a fresh read-only `status`/`next` observation.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codex-workflow-v2",
3
- "version": "2.0.0-beta.12.8",
3
+ "version": "2.0.0-beta.13",
4
4
  "description": "Requirements-first Codex development workflow with local state and explicit Git ownership.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -33,7 +33,10 @@
33
33
  "roles",
34
34
  "references",
35
35
  "plugins",
36
- "docs",
36
+ "docs/*.md",
37
+ "docs/lifecycle",
38
+ "docs/pdf",
39
+ "docs/problem-briefs",
37
40
  "scripts/generate-pdf-docs.py",
38
41
  "scripts/run-pdf-docs.mjs",
39
42
  "README.md"
@@ -45,6 +48,8 @@
45
48
  "test": "node scripts/with-validation-lock.mjs test",
46
49
  "test:signal-t04-recovery": "node scripts/with-validation-lock.mjs test-signal-t04",
47
50
  "test:signal-t03-replan-e2e": "node scripts/with-validation-lock.mjs test-signal-t03-replan",
51
+ "test:signal-remediation-e2e": "node scripts/with-validation-lock.mjs test-signal-remediation-topology",
52
+ "test:signal-t10-check-support-e2e": "node scripts/with-validation-lock.mjs test-signal-t10-check-support",
48
53
  "validate": "npm run typecheck && npm test",
49
54
  "pack:check": "npm run build && npm pack --dry-run",
50
55
  "smoke:downstream": "npm run build && node scripts/downstream-smoke.mjs",
@@ -55,7 +60,11 @@
55
60
  "publish:release": "node scripts/publish.mjs"
56
61
  },
57
62
  "dependencies": {
58
- "ajv": "8.20.0"
63
+ "ajv": "8.20.0",
64
+ "fast-deep-equal": "3.1.3",
65
+ "fast-uri": "3.1.7",
66
+ "json-schema-traverse": "1.0.0",
67
+ "require-from-string": "2.0.2"
59
68
  },
60
69
  "devDependencies": {
61
70
  "@types/node": "24.10.1",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codex-workflow-gateway",
3
- "version": "0.1.0+codex.20260829181421",
3
+ "version": "0.1.0+codex.20260830183000",
4
4
  "description": "Thin personal Codex gateway for exact project-local Codex Workflow V2 packages and codebase-memory-mcp.",
5
5
  "author": {
6
6
  "name": "Codex Workflow Maintainers"
@@ -33,6 +33,15 @@
33
33
  `retainedHistoricalCommits`.
34
34
  Task-local manifest/lock fields from recorded history may differ from the base, but the candidate
35
35
  commit must preserve them exactly while changing only the Workflow dependency entries.
36
+ - `task historical-step-provenance-preflight --id <TASK-ID>` is read-only. The matching
37
+ `task historical-step-provenance-recover` is available only for one unexpected product commit
38
+ with an intact passed strict-review chain, matching prior final acceptance, no lease or pending
39
+ operation, and dirty files confined to the current active Step. It retains historical authority
40
+ without changing Git, worktree bytes, or the current Plan.
41
+ - `update historical-step-dependency-preflight/recover` handles the same proof when the beta.12.9
42
+ dependency-only commit is the unregistered HEAD. It binds the exact dependency candidate and the
43
+ reviewed historical Step commit in one recovery record, preserves active product bytes, and then
44
+ requires fresh `status` and `next`.
36
45
  - `task stop-override-prepare` is a read-only Human gate for the exact beta.11 attempt-four stop
37
46
  shape. `task stop-override-apply` requires the same Task revision, Step, actor, reason, Plan, HEAD,
38
47
  evidence binding, and returned `SOO-*` code in a later user turn. It appends evidence without
@@ -50,6 +50,31 @@ pending/corrupt transaction. After success run sequential `status` then `next` a
50
50
  returned lifecycle action; Knowledge reconciliation or atomic Task context refresh may legitimately
51
51
  be next because the dependency files changed.
52
52
 
53
+ When beta.12.9 fresh `next` advertises `task historical-step-provenance-recover`, Core has found
54
+ exactly one product commit that a corrective Plan omitted from current Step evidence even though the
55
+ commit still has a complete hash-valid passed strict Step Review chain and a matching prior final
56
+ acceptance. First run the advertised read-only `task historical-step-provenance-preflight --id
57
+ <TASK-ID>` and require `eligible=true`, the exact Task revision/Plan/Brief/HEAD, the advertised
58
+ commit SHA, no lease/transaction/Core operation, and dirty files confined to the one active Step's
59
+ `allowedWrites`. Invoke recovery with that exact commit, actor, and a substantive reason. The
60
+ transition records the commit as invalidated historical Step authority plus an audit record; it does
61
+ not adopt the completed Step into the current Plan and does not create, remove, amend, reset, rebase,
62
+ or merge Git commits. Reject multiple or arbitrary unexpected commits, pending/failed review,
63
+ mismatched final acceptance, unrelated dirty files, or damaged sidecars. After success run
64
+ sequential `status` then `next`; the active corrective Step should resume through its ordinary
65
+ credential and `task step-complete` route.
66
+
67
+ When beta.12.9 must itself be installed while this exact historical Step blocker is active, preserve
68
+ the Task worktree and create only two dependency transport commits: one on the active Milestone base
69
+ and one at Task-branch HEAD, each changing exactly `package.json` and `package-lock.json` to the exact
70
+ beta.12.9 package. Do not switch the dirty Task checkout to update the base; use a separate temporary
71
+ worktree. Install the repository-local target package, then require fresh `next` to advertise
72
+ `update historical-step-dependency-recover`. Run the matching read-only preflight and require the
73
+ exact dependency HEAD/parent, Task revision, active Step/Plan, retained historical SHA, dirty-file
74
+ set and dirty-worktree hash, with no lease or pending operation. The matching recover registers both
75
+ authorities without modifying product bytes or Git. After recovery run sequential `status` and
76
+ `next`; do not substitute ordinary dependency recovery, manual state edits, rebase, reset, or amend.
77
+
53
78
  Beta.12.1 permits product-owned manifest/lock fields already present in the exact recorded Task
54
79
  history to differ from the Milestone base. Core compares candidate parent to candidate HEAD after
55
80
  removing only the Workflow dependency entries, so the dependency commit must preserve every such
@@ -107,6 +132,46 @@ into Plan `acceptance` as exact array members; semantic prose may be added but c
107
132
  IDs. Bind the Plan to the returned `briefHash` and active `knowledgeMap` revision/hash. Stop if the
108
133
  contract is absent or conflicts with the current Task/Knowledge state.
109
134
 
135
+ When fresh repository `next` reports `planRiskAuditDecision.state=recorded-blocking`, decision
136
+ `stop-escalate`, and an `auditedRemediation` object, do not retry authorization and do not invent a
137
+ free-form Milestone scope change. Follow only the advertised route:
138
+
139
+ 1. If action is `discovery start`, create one Discovery for the exact missing upstream capability
140
+ proved by the audit. Preserve the current Milestone outcome, success signal, acceptance, checks,
141
+ and original Task scope. Resolve factual unknowns from repository evidence; a genuine unresolved
142
+ product decision remains a semantic blocker.
143
+ 2. If action is `discovery update`, complete that same remediation Discovery until it is
144
+ `ready_to_materialize`; do not reuse an unrelated Discovery.
145
+ 3. If action is `milestone remediation-materialize`, use its exact Milestone/Task revisions and
146
+ audit binding. The JSON input contains only `discoveryId`, `expectedDiscoveryRevision`, `title`,
147
+ and `predecessorTaskIds`; the predecessor list must exactly equal
148
+ `auditedRemediation.requiredPredecessorTaskIds`. No actor, confirmation code, delegation grant,
149
+ replacement Milestone Plan, or human approval is accepted.
150
+ 4. Run sequential `status` then repository `next`. Core must prioritize the new remediation Task.
151
+ Plan, audit, hand off, implement, review, accept, and merge it normally. At Task execution
152
+ authorization and final acceptance, use the exact `correctiveDerivedApproval.actor` returned by
153
+ fresh `next`; `humanApprovalRequired` must be false. Do not pass a delegation grant.
154
+ 5. After the remediation Task is `merged`, fresh `next` must return the original blocked Task to
155
+ `task plan-set` with `auditedRemediation.state=merged-replan-required`. Replace its rejected Plan,
156
+ record a fresh Risk Audit, use the same current derived approval only when advertised, and
157
+ continue through at least the next ordinary Step boundary.
158
+
159
+ An exact package update may make the approved Knowledge Map stale while this route is active. Continue
160
+ without a Human approval only when fresh `next` includes
161
+ `auditedRemediation.dependencyKnowledgeRefresh.eligible=true`. Core must prove that `package.json` is
162
+ the sole changed Knowledge source, every version surface equals the repository-local runtime, and every
163
+ Git commit that changed the approved manifest content altered only the exact Workflow dependency in
164
+ `package.json`/`package-lock.json`. Do not run standalone reconcile first. The refresh is committed
165
+ atomically by `milestone remediation-materialize` with corrective-derived evidence. Any other Knowledge
166
+ path, classification, gap, conflict, dirty checkout, unaligned version or wider commit returns to the
167
+ ordinary explicit Knowledge flow.
168
+
169
+ This is an idempotent, additive topology transition bound to one exact Plan Risk Audit. Dirty Git,
170
+ any lease/transaction/Core operation, a started blocked Task, stale Task/Milestone/audit bindings,
171
+ non-merged or non-exact predecessors, duplicate use of the audit, or any changed Milestone semantic
172
+ field is a hard stop. Generic `stop-escalate` shapes without `auditedRemediation` remain terminal
173
+ user attention. Final Milestone acceptance remains an ordinary human/delegated gate.
174
+
110
175
  When `next` returns top-level `action: task context-refresh`, use only that atomic action for
111
176
  the returned Task/map revisions, actor, and grant. Do not run standalone `project-memory reconcile`
112
177
  first: Core rejects it because it would create a human-approval gap and strand the Task. A
@@ -480,7 +545,8 @@ Plan audit based only on count. Follow fresh `next`: ordinary findings default t
480
545
  `route=replan` is valid only with the exact Plan clause, obstruction, and minimal Plan change
481
546
  retained by Core. A remediation Plan may change implementation Steps but must preserve the Task
482
547
  objective, requirements, and acceptance. Explicit split or stop decisions still stop ordinary
483
- continuation.
548
+ continuation; only an exact Core-advertised audited-remediation route may turn a pre-execution
549
+ `stop-escalate` into additive upstream work.
484
550
 
485
551
  When `next.strictStepReview.recommendedMode` is `external-sealed`, do not launch the nested local
486
552
  reviewer from inside a Codex App sandbox. Run the advertised read-only `task step-review-packet`,
@@ -19,7 +19,7 @@
19
19
  "evidenceHash": { "$ref": "#/$defs/nullableHash" },
20
20
  "headCommit": { "$ref": "#/$defs/nullableHash" },
21
21
  "reason": { "type": "string" },
22
- "authorizationMode": { "enum": ["human", "delegated"] },
22
+ "authorizationMode": { "enum": ["human", "delegated", "corrective-derived"] },
23
23
  "delegation": { "$ref": "#/$defs/delegation" },
24
24
  "mechanicalFeasibility": { "$ref": "#/$defs/mechanicalFeasibility" }
25
25
  },
@@ -30,6 +30,13 @@
30
30
  "required": ["authorizationMode"]
31
31
  },
32
32
  "then": { "required": ["delegation"] }
33
+ },
34
+ {
35
+ "if": {
36
+ "properties": { "authorizationMode": { "const": "corrective-derived" } },
37
+ "required": ["authorizationMode"]
38
+ },
39
+ "then": { "not": { "required": ["delegation"] } }
33
40
  }
34
41
  ],
35
42
  "$defs": {
@@ -91,7 +98,7 @@
91
98
  "required": ["analyzerId", "analyzerVersion"],
92
99
  "properties": {
93
100
  "analyzerId": {
94
- "enum": ["wf2.root-npm-script", "wf2.exact-output-path", "wf2.exact-predecessor-path"]
101
+ "enum": ["wf2.root-npm-script", "wf2.root-npm-script-arguments", "wf2.check-support-anchor", "wf2.exact-output-path", "wf2.exact-predecessor-path"]
95
102
  },
96
103
  "analyzerVersion": { "const": 1 }
97
104
  }
@@ -104,7 +111,7 @@
104
111
  ],
105
112
  "properties": {
106
113
  "analyzerId": {
107
- "enum": ["wf2.root-npm-script", "wf2.exact-output-path", "wf2.exact-predecessor-path"]
114
+ "enum": ["wf2.root-npm-script", "wf2.root-npm-script-arguments", "wf2.check-support-anchor", "wf2.exact-output-path", "wf2.exact-predecessor-path"]
108
115
  },
109
116
  "analyzerVersion": { "const": 1 },
110
117
  "result": { "enum": ["pass", "blocked", "unverified"] },