codex-workflow-v2 2.0.0-alpha.7.2.1 → 2.0.0-beta.2
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/README.md +24 -5
- package/dist/src/alpha6/milestone.d.ts +27 -0
- package/dist/src/alpha6/milestone.js +152 -1
- package/dist/src/alpha6/milestone.js.map +1 -1
- package/dist/src/beta1/project-transaction.d.ts +52 -0
- package/dist/src/beta1/project-transaction.js +297 -0
- package/dist/src/beta1/project-transaction.js.map +1 -0
- package/dist/src/cli.js +239 -4
- package/dist/src/cli.js.map +1 -1
- package/dist/src/contracts.d.ts +20 -0
- package/dist/src/diagnostics.d.ts +11 -0
- package/dist/src/diagnostics.js +54 -0
- package/dist/src/diagnostics.js.map +1 -1
- package/dist/src/git.js +2 -5
- package/dist/src/git.js.map +1 -1
- package/dist/src/reviewer.d.ts +4 -0
- package/dist/src/reviewer.js +24 -7
- package/dist/src/reviewer.js.map +1 -1
- package/dist/src/version.d.ts +1 -1
- package/dist/src/version.js +1 -1
- package/dist/src/version.js.map +1 -1
- package/dist/src/workflow.d.ts +28 -1
- package/dist/src/workflow.js +658 -54
- package/dist/src/workflow.js.map +1 -1
- package/docs/autonomy-guardrails.md +11 -3
- package/docs/beta1-stabilization-brief.md +165 -0
- package/docs/beta2-initial-assembly-navigation-brief.md +616 -0
- package/docs/delegated-approval.md +4 -3
- package/docs/development-flow.md +23 -6
- package/docs/project-memory.md +7 -5
- package/docs/release.md +16 -2
- package/docs/split-required-recovery.md +54 -0
- package/docs/stable-release-defect-register.md +597 -0
- package/docs/updating-existing-project.md +2 -0
- package/package.json +2 -2
- package/plugins/codex-workflow-gateway/references/protocol.md +62 -3
- package/plugins/codex-workflow-gateway/skills/codex-workflow-gateway/SKILL.md +53 -2
- package/references/state-machine.md +4 -1
- package/schemas/task.schema.json +3 -1
|
@@ -48,6 +48,9 @@ If the current Plan Risk Audit marks a Step for strict review, `task step-comple
|
|
|
48
48
|
creates the workflow-owned commit, but the Step stays non-terminal and `next` routes to
|
|
49
49
|
`task step-review`. Canonical completion is recorded only after the strict review and the
|
|
50
50
|
reviewer attestation both bind to that exact completion commit.
|
|
51
|
+
When `next` advertises `task step-review`, pass the exact claimant or required actor as
|
|
52
|
+
`--actor`; the isolated reviewer identity is created inside Core and must not be substituted
|
|
53
|
+
into the mutation actor slot.
|
|
51
54
|
|
|
52
55
|
Invalid or stale review sidecars fail closed. The workflow blocks downstream acceptance and
|
|
53
56
|
normal continuation when review evidence is malformed, unverified, or commit-mismatched.
|
|
@@ -88,8 +91,9 @@ not a human approval, while auditor independence remains mandatory.
|
|
|
88
91
|
|
|
89
92
|
## Atomic context refresh
|
|
90
93
|
|
|
91
|
-
When `next
|
|
92
|
-
composite transition
|
|
94
|
+
When `next` returns top-level `action: task context-refresh` with an exact option, a
|
|
95
|
+
project-scoped delegate may run one composite transition and must not run standalone reconcile
|
|
96
|
+
first:
|
|
93
97
|
|
|
94
98
|
```text
|
|
95
99
|
task context-refresh
|
|
@@ -150,7 +154,11 @@ current `MSA-*` code. Without that option the ordinary later-message human gate
|
|
|
150
154
|
## Bounded Milestone autonomy and C1 handoff
|
|
151
155
|
|
|
152
156
|
Initial assembly may materialize every linked Task before one complete `milestone plan-set`;
|
|
153
|
-
the Milestone cannot execute until all reverse memberships are classified.
|
|
157
|
+
the Milestone cannot execute until all reverse memberships are classified. During that exact
|
|
158
|
+
window `next` returns non-executable `milestone initial-assembly` navigation with explicit
|
|
159
|
+
linked-Task Discovery/materialization options; the closing Plan option appears after the first
|
|
160
|
+
linked Task exists. A failed navigation call must not
|
|
161
|
+
be bypassed with a direct Plan command. Ordinary semantic
|
|
154
162
|
scope change remains explicit and human-only through `milestone scope-change-prepare` and
|
|
155
163
|
`milestone scope-change-apply`.
|
|
156
164
|
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
# Codex Workflow V2 2.0.0-beta.1 Stabilization Brief
|
|
2
|
+
|
|
3
|
+
Status: implementation complete; release candidate awaiting user authorization for commit/tag/push/publish
|
|
4
|
+
|
|
5
|
+
Baseline: `v2.0.0-alpha.7.2.1` (`1214b4c`)
|
|
6
|
+
|
|
7
|
+
Primary evidence register: [stable-release-defect-register.md](stable-release-defect-register.md)
|
|
8
|
+
|
|
9
|
+
## Objective
|
|
10
|
+
|
|
11
|
+
Produce one feature-frozen beta release that closes every confirmed workflow defect found during
|
|
12
|
+
the `signal_v4` Milestone 3 alpha.7 replay, resolves or evidence-closes the remaining validation
|
|
13
|
+
concurrency investigation, preserves every alpha.7 regression guard, and proves that a real agent can
|
|
14
|
+
recover a terminal `split-required` Task by creating a replacement Task without reviving or rewriting
|
|
15
|
+
the historical Task.
|
|
16
|
+
|
|
17
|
+
No intermediate npm version is published. `signal_v4` and its external workflow state are read-only
|
|
18
|
+
evidence. Workflow V2 is not used to organize this repository's implementation.
|
|
19
|
+
|
|
20
|
+
## Release scope
|
|
21
|
+
|
|
22
|
+
### B1 — Secret-safe lock recovery (`WF-STABLE-001`)
|
|
23
|
+
|
|
24
|
+
- `locks repair` must never expose a plaintext writer token in ordinary CLI JSON, logs, errors, or
|
|
25
|
+
snapshots.
|
|
26
|
+
- A repaired lease may expose only non-authorizing metadata and a token fingerprint.
|
|
27
|
+
- If ownership recovery needs a new credential, it must use an explicit one-time handoff boundary
|
|
28
|
+
rather than a reusable token in general diagnostics.
|
|
29
|
+
|
|
30
|
+
### B2 — Terminal corrective routing and replacement (`WF-STABLE-002/003`)
|
|
31
|
+
|
|
32
|
+
- `split-required` and `stop-escalate` outrank Project Knowledge reconcile, approval, rebind, context
|
|
33
|
+
refresh, authorization, and Task run.
|
|
34
|
+
- `task knowledge-rebind` and `task context-refresh` reject these postures before their first write.
|
|
35
|
+
- A Project Knowledge change cannot detach a terminal corrective decision from its historical Plan.
|
|
36
|
+
- `next` must expose an explicit replacement route for `split-required`; `stop-escalate` remains a
|
|
37
|
+
hard stop.
|
|
38
|
+
- Replacement must be one journal-recoverable transition that:
|
|
39
|
+
- consumes one ready Task Discovery;
|
|
40
|
+
- materializes a new Task with a new ID and the same active Milestone;
|
|
41
|
+
- changes the old membership from `required` to `cancelled` with a reason;
|
|
42
|
+
- adds the replacement as `required` with an explicit relationship reason;
|
|
43
|
+
- marks the old Task `cancelled` without changing its Plan, Steps, review, remediation, corrective,
|
|
44
|
+
result, or evidence history;
|
|
45
|
+
- revokes the cancelled Task's writer lease in the same recoverable transaction;
|
|
46
|
+
- absorbs exact safe Plan-bound Knowledge drift through the active Milestone Autonomy Grant in
|
|
47
|
+
that transaction, so the replacement Task can be planned without a stranded standalone gate;
|
|
48
|
+
- supersedes Milestone execution authorization and increments membership revision;
|
|
49
|
+
- leaves no orphan Task or partial membership state after process interruption;
|
|
50
|
+
- is idempotently recoverable from its journal.
|
|
51
|
+
- Normal standalone Project Knowledge actions must identify a triggering Task only as diagnostic
|
|
52
|
+
provenance, never as implied Task authorization.
|
|
53
|
+
- When an exact delegated atomic context refresh is eligible, `next` must return it as the top-level
|
|
54
|
+
action and standalone reconcile must fail before writing; an agent cannot create an avoidable
|
|
55
|
+
human-approval gap by selecting the nested Project Knowledge sub-transition.
|
|
56
|
+
|
|
57
|
+
### B3 — Update/base diagnostics and canonical recovery guidance (`WF-STABLE-004/005`)
|
|
58
|
+
|
|
59
|
+
- Update diagnostics must distinguish the current checkout from an active Milestone base branch and
|
|
60
|
+
report exact declared, locked, installed, current-branch, and base-branch workflow versions.
|
|
61
|
+
- Divergence must fail closed before lifecycle work continues and must recommend dependency-only
|
|
62
|
+
transport rather than merging product commits.
|
|
63
|
+
- Documentation must include one canonical `split-required` recovery prompt and exact ordering for
|
|
64
|
+
replacement, membership evolution, Milestone reauthorization, new Task planning, and execution.
|
|
65
|
+
|
|
66
|
+
### B4 — Composite context-refresh durability (`WF-STABLE-006`)
|
|
67
|
+
|
|
68
|
+
- Project Knowledge reconcile/approval, Task Plan rebind, rebound risk-audit evidence, and execution
|
|
69
|
+
authorization must use a recoverable multi-file transaction.
|
|
70
|
+
- All semantic and authority checks happen before the first target write.
|
|
71
|
+
- Crash recovery is deterministic and idempotent at every write boundary.
|
|
72
|
+
- `doctor`, `status`, and `next` detect an incomplete transaction and return the exact recovery action;
|
|
73
|
+
no partial refresh is treated as authorized.
|
|
74
|
+
|
|
75
|
+
### B5 — Deterministic maintainer validation (`WF-STABLE-007`)
|
|
76
|
+
|
|
77
|
+
- Reproduce or disprove shared-output contention between full validation commands.
|
|
78
|
+
- If confirmed, serialize destructive build/test output preparation or isolate per-run artifacts.
|
|
79
|
+
- Concurrent invocation must either complete independently or fail immediately with a clear,
|
|
80
|
+
non-secret diagnostic; it must not hang silently.
|
|
81
|
+
- Child processes and temporary resources are cleaned up after interruption.
|
|
82
|
+
|
|
83
|
+
## Required deterministic evidence
|
|
84
|
+
|
|
85
|
+
1. Exact `signal_v4` replay:
|
|
86
|
+
`split-required -> Knowledge Map 169 active -> next replacement -> replacement transaction -> old
|
|
87
|
+
Task immutable/terminal -> new required Task planning`.
|
|
88
|
+
2. Negative rebind/context-refresh tests for `split-required` and `stop-escalate` proving zero writes.
|
|
89
|
+
3. Replacement rejection tests for wrong Task, wrong Milestone, wrong decision, non-ready Discovery,
|
|
90
|
+
semantic Milestone changes, stale revisions, expired/wrong actor autonomy, corrupt sidecars, and
|
|
91
|
+
duplicate retries.
|
|
92
|
+
4. Crash injection before and after every replacement and context-refresh transaction write.
|
|
93
|
+
5. CLI/output scans proving writer tokens are absent.
|
|
94
|
+
6. Base-version divergence tests for clean and dirty repositories and unrelated product commits.
|
|
95
|
+
7. Concurrent validation reproduction with bounded completion.
|
|
96
|
+
8. All existing unit, integration, milestone, alpha.6, alpha.7, packaging, plugin, downstream smoke,
|
|
97
|
+
release, and root regression checks.
|
|
98
|
+
|
|
99
|
+
## Real-agent acceptance
|
|
100
|
+
|
|
101
|
+
Create a fresh disposable downstream project with isolated `CODEX_HOME`, workflow state, plugin root,
|
|
102
|
+
and a locally packed beta candidate. A real Delegate must complete:
|
|
103
|
+
|
|
104
|
+
1. Discovery and initial Milestone assembly.
|
|
105
|
+
2. A guarded Task with three failed strict reviews, `continue-fix`, and a terminal
|
|
106
|
+
`split-required` decision.
|
|
107
|
+
3. A Project Knowledge change and human-style approval boundary.
|
|
108
|
+
4. The exact replacement transition without rebind of the failed Task.
|
|
109
|
+
5. Replacement Task implementation, review, merge, remaining required Task completion, Milestone
|
|
110
|
+
validation, and final acceptance.
|
|
111
|
+
|
|
112
|
+
The E2E is invalid if the harness injects lifecycle failures, edits external state, reuses a stale
|
|
113
|
+
plugin cache, bypasses `next`, or requires a fourth remediation attempt.
|
|
114
|
+
|
|
115
|
+
## Final evidence
|
|
116
|
+
|
|
117
|
+
- Deterministic package suite: all beta.1 transaction, terminal-routing, Knowledge refresh,
|
|
118
|
+
diagnostics, concurrency, alpha.6, alpha.7, integration, Milestone, and workflow regressions pass.
|
|
119
|
+
- Crash replay covers rollback and dead-process roll-forward at every tested write boundary,
|
|
120
|
+
including deletion of the cancelled Task writer lease.
|
|
121
|
+
- Real-agent disposable run:
|
|
122
|
+
`test-runs/2.0.0-beta.1/replacement-e2e-final`.
|
|
123
|
+
- Historical Task `TASK-01M02N276D6AE83VBVRH17RDQY` ended `cancelled` at revision 18 and links to
|
|
124
|
+
replacement Task `TASK-01M02NMZZBVCA4TZKK6WG724RY`.
|
|
125
|
+
- Replacement Task passed its guarded Step review and independent final review, then merged as
|
|
126
|
+
`c8d45be7f3165731cf891a47e88a112f76d0119f`.
|
|
127
|
+
- Milestone `MS-01M02N1M9M1CT8RHYGSZH8ETHC` reached `accepted` revision 7; final `next` returned
|
|
128
|
+
repository `idle`.
|
|
129
|
+
- The run exposed one additional bounded UX defect: local replacement start initially required a
|
|
130
|
+
manual return from the cancelled Task branch to `main`. The final candidate makes local Task start
|
|
131
|
+
create its branch from the exact declared base ref even when another clean Task branch is checked
|
|
132
|
+
out, with a deterministic regression.
|
|
133
|
+
|
|
134
|
+
## Non-goals
|
|
135
|
+
|
|
136
|
+
- Fixing the downstream `signal_v4` NUL validator in this repository.
|
|
137
|
+
- Deleting historical Milestones, Tasks, branches, chats, worktrees, or append-only evidence.
|
|
138
|
+
- Broadening delegated authority or removing human final acceptance.
|
|
139
|
+
- Publishing, tagging, pushing, or modifying `signal_v4` without separate user authorization.
|
|
140
|
+
- Declaring `2.0.0` stable before the new real `signal_v4` Milestone completes successfully.
|
|
141
|
+
|
|
142
|
+
## Release gate
|
|
143
|
+
|
|
144
|
+
`2.0.0-beta.1` is recommended only when all confirmed findings are closed, every investigation is
|
|
145
|
+
resolved with evidence, deterministic and crash replay pass, the real-agent disposable Milestone
|
|
146
|
+
reaches final acceptance, an independent final audit has no unresolved material finding, and the
|
|
147
|
+
release diff contains no downstream product implementation.
|
|
148
|
+
|
|
149
|
+
## Final audit and residual risks
|
|
150
|
+
|
|
151
|
+
No material requirement gap remains in the beta.1 scope. The final source audit confirmed that
|
|
152
|
+
authority checks precede replacement/context-refresh target writes, cancelled Task authority is
|
|
153
|
+
deleted inside the same recoverable transaction, terminal decisions outrank Knowledge navigation,
|
|
154
|
+
and ordinary CLI output contains no reusable writer credential.
|
|
155
|
+
|
|
156
|
+
Residual beta risks are bounded:
|
|
157
|
+
|
|
158
|
+
- the project journal is a local-process/local-filesystem recovery protocol, not a distributed
|
|
159
|
+
cross-host transaction service; cross-machine synchronization remains outside the package
|
|
160
|
+
contract;
|
|
161
|
+
- the final real-agent run encountered and safely recovered the clean-branch start precondition;
|
|
162
|
+
the final candidate fixes that behavior and covers it deterministically, but the entire long E2E
|
|
163
|
+
was not repeated solely for that Git convenience change;
|
|
164
|
+
- `2.0.0` stable remains gated on a successful new real `signal_v4` Milestone, as stated in the
|
|
165
|
+
non-goals.
|