codex-workflow-v2 2.0.0-beta.11 → 2.0.0-beta.12.1
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 +7 -6
- package/dist/src/alpha6/remediation.d.ts +7 -2
- package/dist/src/alpha6/remediation.js +361 -64
- package/dist/src/alpha6/remediation.js.map +1 -1
- package/dist/src/alpha6/review.d.ts +5 -0
- package/dist/src/alpha6/review.js +110 -2
- package/dist/src/alpha6/review.js.map +1 -1
- package/dist/src/cli.js +19 -1
- package/dist/src/cli.js.map +1 -1
- package/dist/src/contracts.d.ts +55 -0
- package/dist/src/dependency-provenance.js +5 -3
- package/dist/src/dependency-provenance.js.map +1 -1
- package/dist/src/reviewer.d.ts +26 -0
- package/dist/src/reviewer.js +54 -1
- 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 +4 -1
- package/dist/src/workflow.js +163 -71
- package/dist/src/workflow.js.map +1 -1
- package/docs/autonomy-guardrails.md +43 -34
- package/docs/decisions.md +5 -4
- package/docs/delegated-approval.md +5 -4
- package/docs/development-flow.md +7 -6
- package/docs/lifecycle/state-machine-stabilization.md +1 -1
- package/docs/pdf/codex-workflow-v2-architecture-ru.pdf +0 -0
- package/docs/pdf/codex-workflow-v2-chat-only-guide-ru.pdf +0 -0
- package/docs/pdf/codex-workflow-v2-technical-reference-ru.pdf +0 -0
- package/docs/pdf/sources/codex-workflow-v2-architecture-ru.md +21 -9
- package/docs/pdf/sources/codex-workflow-v2-chat-only-guide-ru.md +15 -13
- package/docs/pdf/sources/codex-workflow-v2-technical-reference-ru.md +39 -24
- package/docs/release.md +8 -1
- package/docs/updating-existing-project.md +25 -0
- package/docs/validation-report.md +90 -115
- package/package.json +1 -1
- package/plugins/codex-workflow-gateway/.codex-plugin/plugin.json +1 -1
- package/plugins/codex-workflow-gateway/references/protocol.md +27 -8
- package/plugins/codex-workflow-gateway/skills/codex-workflow-gateway/SKILL.md +23 -3
- package/references/state-machine.md +9 -8
- package/references/validation-and-review.md +11 -4
- package/schemas/review-result.schema.json +17 -1
- package/schemas/step-review-event.schema.json +15 -0
- package/schemas/stop-escalate-override-event.schema.json +45 -0
- package/scripts/generate-pdf-docs.py +2 -1
|
@@ -55,39 +55,47 @@ into the mutation actor slot.
|
|
|
55
55
|
Invalid or stale review sidecars fail closed. The workflow blocks downstream acceptance and
|
|
56
56
|
normal continuation when review evidence is malformed, unverified, or commit-mismatched.
|
|
57
57
|
|
|
58
|
-
## Repeated failed review and remediation
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
58
|
+
## Repeated failed review and continuable remediation
|
|
59
|
+
|
|
60
|
+
A failed final Task review returns the same Task to `needs_fix` and requires a changed or new
|
|
61
|
+
remediation Step. The failed-review count is diagnostic evidence, not a lifecycle limit: another
|
|
62
|
+
Plan does not require a separate corrective Plan Auditor merely because two or more reviews failed.
|
|
63
|
+
Every replacement Plan must preserve the Task objective, requirements, and acceptance; changing
|
|
64
|
+
those commitments requires an explicit scope decision outside ordinary remediation.
|
|
65
|
+
|
|
66
|
+
For guarded Steps, every failed review is recorded in `remediation-events.jsonl`. Attempts one and
|
|
67
|
+
two retain mode `ordinary`; later attempts use mode `corrective`, but the mode does not impose a
|
|
68
|
+
maximum attempt ordinal. `next` continues to return `task run` for the same failed Step, and every
|
|
69
|
+
new completion still requires a fresh strict review bound to its exact commit. Therefore repeated
|
|
70
|
+
fixes cannot create an approval, while a fourth, tenth, or later reviewed attempt remains possible.
|
|
71
|
+
|
|
72
|
+
Each failed review finding may carry `route: fix` or `route: replan`. `fix` is the backward-compatible
|
|
73
|
+
default. `replan` is accepted only with `planConflict.planClause`, `whyFixCannotFit`, and
|
|
74
|
+
`minimalPlanChange`; Core retains that evidence in the hash-chained Step-review event and routes
|
|
75
|
+
the failed Step to `task plan-set`. Replan may change implementation Steps only. Explicit historical
|
|
76
|
+
`continue-fix`, `replan-required`, `split-required`, and `stop-escalate` decisions remain readable;
|
|
77
|
+
an explicit split or stop still outranks ordinary execution except for the narrow beta.11
|
|
78
|
+
attempt-four stop compatibility route below.
|
|
79
|
+
|
|
80
|
+
### Human-confirmed beta.11 attempt-four stop compatibility
|
|
81
|
+
|
|
82
|
+
Beta.12.1 can resume one historical shape that beta.11 stopped mechanically: the same failed
|
|
83
|
+
guarded Step has exactly two `ordinary` remediation events, one `corrective` third event, an exact
|
|
84
|
+
attempt-3 `continue-fix` decision, and an attempt-4 `stop-escalate` decision under the unchanged
|
|
85
|
+
Plan. Fresh `next` advertises `task stop-override-prepare` only for that shape and only on a clean
|
|
86
|
+
local Task branch with no Step in progress, writer lease, Task transaction, or Core operation.
|
|
87
|
+
|
|
88
|
+
Preparation is read-only and binds Task revision, Step, both corrective decisions, all three
|
|
89
|
+
remediation events, Plan hash, Git HEAD, package version, actor, and reason to an `SOO-*`
|
|
90
|
+
confirmation code. In a later explicit user turn, invoke `task stop-override-apply` with the same
|
|
91
|
+
inputs and code. Apply appends `stop-escalate-overrides.jsonl`; it never deletes or rewrites the
|
|
92
|
+
original stop. A stale binding, wrong code, duplicate/conflicting override, or damaged hash chain
|
|
93
|
+
fails before continuation. Delegation is not accepted for this Human gate.
|
|
94
|
+
|
|
95
|
+
This is not a general stop reversal. It does not apply to `split-required`, Plan drift, a different
|
|
96
|
+
attempt ordinal, missing attempt-3 continue authority, or an agent-authored semantic stop outside
|
|
97
|
+
the beta.11 policy shape. After a valid append, attempt four returns to the normal `task run` then
|
|
98
|
+
strict-review cycle; review quality and all later corrective decisions remain unchanged.
|
|
91
99
|
|
|
92
100
|
### First-failure Plan-integrity recovery
|
|
93
101
|
|
|
@@ -108,7 +116,8 @@ The recovery appends one hash-bound `replan-required` decision for attempt ordin
|
|
|
108
116
|
the worktree and does not edit the Plan. A claimed C1 Task must present its current writer token and
|
|
109
117
|
then follow `task corrective-yield`; the replacement Plan still requires the existing independent
|
|
110
118
|
validation, Risk Audit, Human confirmation, journaled execution, readback, and renewed execution
|
|
111
|
-
authorization. Other check failures
|
|
119
|
+
authorization. Other check failures use the normal continuable remediation route; they do not
|
|
120
|
+
receive the narrow Plan-integrity shortcut, but attempt count alone never stops them.
|
|
112
121
|
|
|
113
122
|
## Atomic context refresh
|
|
114
123
|
|
package/docs/decisions.md
CHANGED
|
@@ -64,10 +64,11 @@ This document closes the requirement gaps identified during the V2 design review
|
|
|
64
64
|
fails closed without changing persisted Task state. This changes navigation and
|
|
65
65
|
diagnostics only; state schema 2 and protocol 1 remain unchanged.
|
|
66
66
|
12. **Autonomous correction guardrail.** The initial Plan must make migration,
|
|
67
|
-
concurrency, restart/replay, crash-window, and provider risks visible.
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
67
|
+
concurrency, restart/replay, crash-window, and provider risks visible. Repeated failed reviews
|
|
68
|
+
do not impose an attempt-count stop: findings default to a same-Task fix and may request replan
|
|
69
|
+
only with exact Plan-conflict evidence. Attempts after the second are marked corrective for
|
|
70
|
+
diagnosis, remain executable, and require another strict review. Explicit split/stop decisions
|
|
71
|
+
remain append-only authority and are never inferred from the counter.
|
|
71
72
|
13. **Content-only context refresh.** A delegate may compose reconcile, approval, knowledge
|
|
72
73
|
rebind, and execution reauthorization only when the approved source classification is
|
|
73
74
|
identical and only content hashes changed. Core validates both delegated transitions
|
|
@@ -191,10 +191,11 @@ Plan-declared supporting additions допустимы только когда и
|
|
|
191
191
|
изменении source set, category/authority, gaps или conflicts используй обычный видимый процесс.
|
|
192
192
|
|
|
193
193
|
После submit запусти отдельный Independent Reviewer; Reviewer не использует
|
|
194
|
-
grant и не исправляет код.
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
`
|
|
194
|
+
grant и не исправляет код. Failed review возвращает ту же Task в remediation: добавь или измени
|
|
195
|
+
remediation Step и снова проведи review. Количество failed reviews не требует отдельного
|
|
196
|
+
corrective Plan audit. Для каждого finding Reviewer использует `route=fix` по умолчанию;
|
|
197
|
+
`route=replan` допустим только с точным Plan clause, доказательством невозможности обычного fix и
|
|
198
|
+
минимальным изменением Plan. Objective, requirements и acceptance через remediation не меняются.
|
|
198
199
|
Final acceptance делай
|
|
199
200
|
только при exact task.final_accept option для DGR-ID, затем штатный merge.
|
|
200
201
|
Если option отсутствует, grant истёк, scope не совпал или требуется смысловое
|
package/docs/development-flow.md
CHANGED
|
@@ -83,12 +83,13 @@ to be repeated before merge.
|
|
|
83
83
|
The Technical Planner performs a risk review before authorization. Migration work includes a
|
|
84
84
|
populated forward-upgrade check; concurrent state includes deterministic races; restart,
|
|
85
85
|
replay, and crash claims include restart/crash-window evidence; provider work includes
|
|
86
|
-
failure injection and hidden-default verification.
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
86
|
+
failure injection and hidden-default verification. Repeated failed reviews remain on the same
|
|
87
|
+
Task. They require a new remediation Step for final Task review, or another implementation and
|
|
88
|
+
fresh strict review for a failed guarded Step; they do not require a separate corrective Auditor
|
|
89
|
+
based only on attempt count. Guarded attempts above two are recorded as `corrective` and remain
|
|
90
|
+
executable. A reviewer routes to `replan` only with an exact Plan obstruction and minimal Plan
|
|
91
|
+
change; ordinary findings default to `fix`. Remediation cannot change the Task objective,
|
|
92
|
+
requirements, or acceptance.
|
|
92
93
|
|
|
93
94
|
One bounded exception avoids a deliberately repeated failure for an older authorization without
|
|
94
95
|
P01-A evidence or a contradiction that becomes observable only after execution starts. If the first guarded check failure
|
|
@@ -266,7 +266,7 @@ The explorer must be exhaustive over semantic classes, bounded over cardinality,
|
|
|
266
266
|
| Actor | human, valid delegate, claimant, other |
|
|
267
267
|
| Lease | none, valid-owned, valid-other, stale |
|
|
268
268
|
| Attempts | 0, 1, 2, 3+ |
|
|
269
|
-
| Corrective posture | none,
|
|
269
|
+
| Corrective posture | none, automatic-continue, explicit continue-fix, replan, split, stop, recovery-needed |
|
|
270
270
|
| Knowledge binding | active, stale, awaiting approval, conflicting |
|
|
271
271
|
| Git | clean-bound, clean-diverged, dirty, malformed |
|
|
272
272
|
| Authorization | absent, current, stale, superseded |
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
---
|
|
2
|
-
title: Codex Workflow V2: архитектура beta.
|
|
2
|
+
title: Codex Workflow V2: архитектура beta.12.1
|
|
3
3
|
subtitle: Источники истины, lifecycle, роли, delegation, зависимости Tasks и границы доверия
|
|
4
4
|
part: Часть 1 из 3 | Архитектура
|
|
5
5
|
document_version: 2.0
|
|
6
|
-
date:
|
|
7
|
-
subject: Архитектура и границы Codex Workflow V2 beta.
|
|
6
|
+
date: 27 августа 2026
|
|
7
|
+
subject: Архитектура и границы Codex Workflow V2 beta.12.1
|
|
8
8
|
---
|
|
9
9
|
|
|
10
10
|
# 1. Назначение и граница системы
|
|
@@ -18,7 +18,7 @@ Codex Workflow V2 - локальный state machine поверх Codex App, Git
|
|
|
18
18
|
Система рассчитана на одного пользователя и одну машину. Она не предоставляет distributed locking,
|
|
19
19
|
криптографическую идентификацию actor string или безопасную синхронизацию state между компьютерами.
|
|
20
20
|
|
|
21
|
-
## 1.1. Что beta.
|
|
21
|
+
## 1.1. Что beta.12.1 гарантирует
|
|
22
22
|
|
|
23
23
|
- exact project-local npm package и совместимый handshake до lifecycle действий;
|
|
24
24
|
- Discovery до materialization Task или Milestone;
|
|
@@ -30,7 +30,7 @@ Codex Workflow V2 - локальный state machine поверх Codex App, Git
|
|
|
30
30
|
- state-bound human gates либо ранее выданные bounded delegation contracts;
|
|
31
31
|
- journaled recovery для составных переходов и fail-closed поведение при drift/corruption.
|
|
32
32
|
|
|
33
|
-
## 1.2. Что beta.
|
|
33
|
+
## 1.2. Что beta.12.1 не гарантирует
|
|
34
34
|
|
|
35
35
|
- правильность продуктовой идеи или автоматически выбранного provider Task;
|
|
36
36
|
- semantic sufficiency Plan, если точные факты нельзя доказать поддерживаемым analyzer;
|
|
@@ -213,9 +213,21 @@ execution-authorized Plan и покрытое тем же Milestone Autonomy Con
|
|
|
213
213
|
3. Reviewer возвращает закрытый schema-valid result без mutations.
|
|
214
214
|
4. Core записывает его только если packet и seals не изменились.
|
|
215
215
|
|
|
216
|
-
|
|
217
|
-
`
|
|
218
|
-
|
|
216
|
+
Failed review не ограничивает число попыток. Попытки 1-2 имеют mode `ordinary`, последующие —
|
|
217
|
+
`corrective`; все исполнимы и требуют нового strict review. `route=fix` продолжает Task, а
|
|
218
|
+
`route=replan` допустим только с точным Plan conflict и меняет лишь implementation Steps, не objective,
|
|
219
|
+
requirements или acceptance. Explicit `split-required` и `stop-escalate` остаются stop/redirect decisions.
|
|
220
|
+
|
|
221
|
+
Beta.12.1 добавляет только одну append-only compatibility оговорку: beta.11 attempt-four
|
|
222
|
+
`stop-escalate` после exact `ordinary, ordinary, corrective` и prior attempt-3 `continue-fix` можно
|
|
223
|
+
возобновить через read-only `stop-override-prepare` и отдельный Human-confirmed
|
|
224
|
+
`stop-override-apply`. Исходный stop сохраняется, `split-required` не подходит, а stale revision,
|
|
225
|
+
Plan, HEAD, lease, transaction или повреждённая chain блокируют переход. Попытка 4 снова проходит
|
|
226
|
+
обычный `task run` и новый strict review.
|
|
227
|
+
|
|
228
|
+
Dependency-provenance recovery beta.12.1 также сохраняет ранее закоммиченные Task-local поля
|
|
229
|
+
manifest/lock, даже если base их не содержит. Candidate остаётся dependency-only: после удаления
|
|
230
|
+
только Workflow dependency parent и HEAD обязаны совпасть по всем product-owned полям.
|
|
219
231
|
|
|
220
232
|
beta.11 `task plan-integrity-recover` существует для одного первого checks-failed legacy/late case:
|
|
221
233
|
отсутствует exact root npm script и текущий Step не может изменить package.json. Recovery не меняет
|
|
@@ -226,7 +238,7 @@ worktree или Plan и не создаёт synthetic second failure; он за
|
|
|
226
238
|
# 10. Operational checklist
|
|
227
239
|
|
|
228
240
|
- exact package version установлен, bundled gateway соответствует release и переустановлен;
|
|
229
|
-
- handshake подтверждает protocol 2, state schema 2 и beta.
|
|
241
|
+
- handshake подтверждает protocol 2, state schema 2 и beta.12.1 capabilities;
|
|
230
242
|
- каждый mutation следует свежему `status -> next` и exact option contract;
|
|
231
243
|
- semantic unknowns и human gates не маскируются delegation;
|
|
232
244
|
- Task chats создаёт coordinator, credentials остаются только в памяти;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Codex Workflow V2: delegated chat-only guide
|
|
3
|
-
subtitle: Актуальный beta.
|
|
3
|
+
subtitle: Актуальный beta.12.1 путь от нового Discovery до принятого Milestone без ручного CLI
|
|
4
4
|
part: Часть 2 из 3 | Практика
|
|
5
5
|
document_version: 2.0
|
|
6
|
-
date:
|
|
7
|
-
subject: Практическое руководство по delegated Discovery и Milestone в Workflow V2 beta.
|
|
6
|
+
date: 27 августа 2026
|
|
7
|
+
subject: Практическое руководство по delegated Discovery и Milestone в Workflow V2 beta.12.1
|
|
8
8
|
---
|
|
9
9
|
|
|
10
|
-
# 1. Рабочая модель beta.
|
|
10
|
+
# 1. Рабочая модель beta.12.1
|
|
11
11
|
|
|
12
12
|
Пользователь работает в одном Codex Project и формулирует продуктовый outcome. Coordinator выполняет
|
|
13
13
|
CLI, создаёт отдельные Task/Reviewer chats и ведёт supervision loop. Workflow Core остаётся authority
|
|
@@ -40,7 +40,7 @@ Blocking unknown, scope change, grant issuance или unrecoverable integrity co
|
|
|
40
40
|
# 2. Подготовка проекта перед новым Discovery
|
|
41
41
|
|
|
42
42
|
1. Убедитесь, что checkout чистый и выбран правильный repository root.
|
|
43
|
-
2. Установите beta.
|
|
43
|
+
2. Установите beta.12.1 как точную devDependency после публикации release.
|
|
44
44
|
3. Обновите и переустановите bundled `codex-workflow-gateway` этого release.
|
|
45
45
|
4. Проверьте, что declared и installed package versions равны.
|
|
46
46
|
5. Запустите новый Coordinator chat, не fork старого Milestone conversation.
|
|
@@ -56,7 +56,7 @@ AGENTS.md
|
|
|
56
56
|
-> doctor только как дополнительная диагностика
|
|
57
57
|
```
|
|
58
58
|
|
|
59
|
-
Handshake beta.
|
|
59
|
+
Handshake beta.12.1 должен сообщать `packageVersion=2.0.0-beta.12.1`, `protocolVersion=2`,
|
|
60
60
|
`stateSchemaVersion=2`, dependency DAG, initial Plan transaction, mechanical feasibility,
|
|
61
61
|
Milestone autonomy и structural replacement disabled capabilities.
|
|
62
62
|
|
|
@@ -116,7 +116,7 @@ delegate, scope, transitions и expiry. DGR передаётся только е
|
|
|
116
116
|
```text
|
|
117
117
|
НОВЫЙ COORDINATOR CHAT
|
|
118
118
|
|
|
119
|
-
Проведи новый Milestone через Codex Workflow V2 beta.
|
|
119
|
+
Проведи новый Milestone через Codex Workflow V2 beta.12.1 в delegated режиме.
|
|
120
120
|
Repository: <ABSOLUTE-REPOSITORY-ROOT>.
|
|
121
121
|
Milestone ID: AUTO.
|
|
122
122
|
Delegate actor: agent:milestone-coordinator.
|
|
@@ -282,7 +282,7 @@ Knowledge Map approval path. Milestone grant не разрешает standalone
|
|
|
282
282
|
|---|---|
|
|
283
283
|
| Guarded Step review | `step-review-packet` -> новый Reviewer chat -> `step-review-record` |
|
|
284
284
|
| Submitted Task review | `review-packet` -> новый Final Reviewer chat -> `review-sealed-record` |
|
|
285
|
-
|
|
|
285
|
+
| Explicit corrective disposition (если выбран) | Отдельный read-only Corrective/Plan Auditor chat; не attempt-count gate |
|
|
286
286
|
|
|
287
287
|
Reviewer получает неизменённый packet, проверяет exact commit/diff/evidence и возвращает closed JSON.
|
|
288
288
|
Task chat записывает его только при совпадении packet и repository seal hashes. Reviewer не исправляет код,
|
|
@@ -293,11 +293,12 @@ Task chat записывает его только при совпадении p
|
|
|
293
293
|
| Состояние | Действие |
|
|
294
294
|
|---|---|
|
|
295
295
|
| First proven impossible npm check после legacy/late authorization | Только рекламируемый `task plan-integrity-recover` |
|
|
296
|
-
|
|
|
297
|
-
| `
|
|
298
|
-
| `replan
|
|
296
|
+
| Failed guarded review | Та же Task: исправление и новый strict review без attempt hard stop |
|
|
297
|
+
| Finding `route=fix` | Продолжить тот же Step; count остаётся диагностикой |
|
|
298
|
+
| Finding `route=replan` с exact Plan conflict | `task plan-set`, меняются только implementation Steps |
|
|
299
299
|
| `split-required` | Stop: `STRUCTURAL_REPLACEMENT_REQUIRED`, никаких replacement writes |
|
|
300
|
-
| `stop-escalate`
|
|
300
|
+
| Exact beta.11 attempt-four `stop-escalate` | Только advertised prepare, затем отдельный Human-confirmed apply; исходный stop сохраняется |
|
|
301
|
+
| Любой другой explicit `stop-escalate` | Terminal user attention |
|
|
301
302
|
| Stale dependency binding | Новый handoff/claim только по fresh `next` |
|
|
302
303
|
| Review seal drift | Discard review и создать fresh packet |
|
|
303
304
|
|
|
@@ -321,7 +322,7 @@ Task/project DGR. `dependencyBinding` для standalone handoff равен null.
|
|
|
321
322
|
|
|
322
323
|
# 14. Итоговый checklist пользователя
|
|
323
324
|
|
|
324
|
-
- beta.
|
|
325
|
+
- beta.12.1 exact package и новый bundled gateway установлены;
|
|
325
326
|
- новый Coordinator chat не является fork старого Milestone;
|
|
326
327
|
- bootstrap DGR, если нужен, выдан отдельным exact human confirmation;
|
|
327
328
|
- Discovery не materialized при blocking unknowns;
|
|
@@ -330,5 +331,6 @@ Task/project DGR. `dependencyBinding` для standalone handoff равен null.
|
|
|
330
331
|
- Coordinator сам создаёт и supervises Task/Reviewer chats;
|
|
331
332
|
- credentials не появились в prompts, reports или files;
|
|
332
333
|
- каждый transition пришёл из fresh `next`;
|
|
334
|
+
- beta.11 stop override, если рекламировался, прошёл отдельные prepare и user-confirmed apply без journal rewrite;
|
|
333
335
|
- split-required остановился без replacement mutations;
|
|
334
336
|
- Milestone validation и final acceptance связаны с текущим clean base HEAD.
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
---
|
|
2
|
-
title: Codex Workflow V2: технический справочник beta.
|
|
2
|
+
title: Codex Workflow V2: технический справочник beta.12.1
|
|
3
3
|
subtitle: Protocol 2, state schema 2, transactions, credentials, dependency authority, review и recovery
|
|
4
4
|
part: Часть 3 из 3 | Technical reference
|
|
5
5
|
document_version: 2.0
|
|
6
|
-
date:
|
|
7
|
-
subject: Технический контракт Codex Workflow V2 beta.
|
|
6
|
+
date: 27 августа 2026
|
|
7
|
+
subject: Технический контракт Codex Workflow V2 beta.12.1
|
|
8
8
|
---
|
|
9
9
|
|
|
10
10
|
# 1. Runtime contract
|
|
@@ -13,9 +13,9 @@ Workflow V2 предоставляет локальные revisioned transitions
|
|
|
13
13
|
и `value` либо структурированную ошибку с `code`, `message` и `details`. Chat, PDF и gateway не создают
|
|
14
14
|
authority сами: mutating permission определяется runtime state и свежим `next`.
|
|
15
15
|
|
|
16
|
-
| Параметр beta.
|
|
16
|
+
| Параметр beta.12.1 | Значение |
|
|
17
17
|
|---|---|
|
|
18
|
-
| npm package | `codex-workflow-v2@2.0.0-beta.
|
|
18
|
+
| npm package | `codex-workflow-v2@2.0.0-beta.12.1` |
|
|
19
19
|
| protocolVersion | 2 |
|
|
20
20
|
| stateSchemaVersion | 2 |
|
|
21
21
|
| lifecycle epoch | 2 |
|
|
@@ -37,7 +37,7 @@ Gateway выполняет:
|
|
|
37
37
|
5. вызов только package-local `dist/src/cli.js --repo <root>`;
|
|
38
38
|
6. `gateway handshake` до lifecycle действий.
|
|
39
39
|
|
|
40
|
-
Ключевые beta.
|
|
40
|
+
Ключевые beta.12.1 capabilities:
|
|
41
41
|
|
|
42
42
|
| Группа | Capabilities |
|
|
43
43
|
|---|---|
|
|
@@ -45,8 +45,8 @@ Gateway выполняет:
|
|
|
45
45
|
| Milestone | lifecycle, initial assembly navigation, autonomy, progress, dependency DAG, initial Plan transaction |
|
|
46
46
|
| Task planning | Plan Risk Audit, proof obligations, mechanical feasibility |
|
|
47
47
|
| C1 | handoff sidecar, handoff bundle, derived Worker actor, credential replacement |
|
|
48
|
-
| Reviews | strict reviewer, Step strict review,
|
|
49
|
-
| Recovery | dependency provenance, plan integrity, remediation mode, corrective yield/replan journals |
|
|
48
|
+
| Reviews | strict reviewer, Step strict review, continuable remediation, evidence-bound fix/replan routing |
|
|
49
|
+
| Recovery | Task-local dependency provenance, plan integrity, remediation mode, legacy stop override, corrective yield/replan journals |
|
|
50
50
|
| Replacement | `structural-task-replacement-disabled-v1` |
|
|
51
51
|
|
|
52
52
|
Handshake incompatibility прекращает работу. Запуск global package, `latest`, mutable range или соседней
|
|
@@ -65,7 +65,7 @@ $CODEX_HOME/workflow-state/v2/projects/<project-id>/
|
|
|
65
65
|
tasks/<TASK-ID>/
|
|
66
66
|
brief.md, plan.md, result.md, evidence.json, state.json
|
|
67
67
|
.versions/
|
|
68
|
-
authorization/review/remediation/corrective/handoff sidecars
|
|
68
|
+
authorization/review/remediation/corrective/stop-override/handoff sidecars
|
|
69
69
|
milestones/<MS-ID>/
|
|
70
70
|
plan.json, result.md, evidence.json, state.json
|
|
71
71
|
.versions/ и scope/autonomy sidecars
|
|
@@ -281,21 +281,23 @@ local reviewer внутри Codex App sandbox.
|
|
|
281
281
|
|
|
282
282
|
# 12. Remediation и corrective decisions
|
|
283
283
|
|
|
284
|
-
Guarded Step имеет
|
|
284
|
+
Guarded Step имеет проверяемый, но не ограниченный счётчиком remediation circuit:
|
|
285
285
|
|
|
286
286
|
| Boundary | Разрешение |
|
|
287
287
|
|---|---|
|
|
288
|
-
|
|
|
289
|
-
|
|
|
290
|
-
| `
|
|
291
|
-
|
|
|
292
|
-
| `replan
|
|
293
|
-
| `split-required` | Structural replacement stop |
|
|
294
|
-
| `stop-escalate` |
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
288
|
+
| Failed cycles 1-2 | `ordinary`; та же Task и новый strict review |
|
|
289
|
+
| Failed cycles 3+ | `corrective`; остаются исполнимыми и требуют нового strict review |
|
|
290
|
+
| Finding `route=fix` или route отсутствует | Продолжить ту же Task/Step |
|
|
291
|
+
| Finding `route=replan` с exact Plan conflict | `task plan-set`; меняются только implementation Steps |
|
|
292
|
+
| `route=replan` без exact conflict | Невалидный review result, state не меняется |
|
|
293
|
+
| Explicit `split-required` | Structural replacement stop |
|
|
294
|
+
| Exact beta.11 attempt-four `stop-escalate` | Append-only Human-confirmed compatibility override |
|
|
295
|
+
| Любой другой explicit `stop-escalate` | Terminal user attention |
|
|
296
|
+
|
|
297
|
+
Attempt count является диагностикой, а не lifecycle authority. Explicit corrective-decision journal
|
|
298
|
+
сохраняется для намеренного stop/split и совместимого historical recovery, но не требуется после второй
|
|
299
|
+
ошибки. Replan из review обязан назвать `planClause`, `whyFixCannotFit` и `minimalPlanChange`; objective,
|
|
300
|
+
requirements и acceptance Task при remediation неизменяемы. Новый Plan проходит обычные audit и authorization.
|
|
299
301
|
|
|
300
302
|
# 13. beta.11 Plan-integrity recovery
|
|
301
303
|
|
|
@@ -314,6 +316,19 @@ fresh `next` через corrective yield и обычный Human-confirmed repla
|
|
|
314
316
|
P01-A предотвращает поддерживаемые contradictions до fresh authorization. beta.11 path остаётся для
|
|
315
317
|
pre-P01 authorizations и late/unsupported exact recovery cases.
|
|
316
318
|
|
|
319
|
+
# 13.1. beta.12.1 compatibility transitions
|
|
320
|
+
|
|
321
|
+
`update dependency-provenance-recover` больше не требует полного равенства Task manifest/lock с base.
|
|
322
|
+
Base остаётся version authority, а parent/HEAD candidate сравниваются без единственных Workflow
|
|
323
|
+
dependency entries. Поэтому recorded Task-local scripts сохраняются; payload drift того же candidate
|
|
324
|
+
commit по-прежнему блокируется.
|
|
325
|
+
|
|
326
|
+
`task stop-override-prepare/apply` обслуживает только exact beta.11 attempt-four policy stop. Prepare
|
|
327
|
+
не пишет state и создаёт binding по Task revision, Step, attempt-3 continue, attempt-4 stop, трём
|
|
328
|
+
remediation events, Plan, HEAD, package, human actor и reason. Apply в отдельном user turn добавляет
|
|
329
|
+
`stop-escalate-overrides.jsonl`. Original corrective decision остаётся неизменным. Split, stale binding,
|
|
330
|
+
lease/transaction, дубликат с другим binding и tampering fail closed.
|
|
331
|
+
|
|
317
332
|
# 14. P04-A structural replacement boundary
|
|
318
333
|
|
|
319
334
|
Command shape `task replacement-materialize` retained только для compatibility diagnostics. Любая попытка
|
|
@@ -371,7 +386,7 @@ Graph является навигационным индексом, не Project
|
|
|
371
386
|
После каждой successful mutation обязателен sequential `status`, затем fresh `next`. Failed status/next
|
|
372
387
|
не разрешает direct mutation. Syntax help read-only и не заменяет navigation authority.
|
|
373
388
|
|
|
374
|
-
# 18. Public command surface beta.
|
|
389
|
+
# 18. Public command surface beta.12.1
|
|
375
390
|
|
|
376
391
|
| Область | Actions |
|
|
377
392
|
|---|---|
|
|
@@ -386,7 +401,7 @@ Graph является навигационным индексом, не Project
|
|
|
386
401
|
| Task execution | `start`, `run`, `step-complete`, `submit`, `result-set`, `accept`, `sync-base`, `merge`, `merge-confirm` |
|
|
387
402
|
| C1 | `handoff[-prepare/-replace/-show]`, `claim`, `writer-credential-replace`, `handback[-create]` |
|
|
388
403
|
| Review | review/step-review packet, launch, sealed record и record actions |
|
|
389
|
-
| Corrective | decision/recovery, plan-integrity, remediation-mode, yield и corrective-replan actions |
|
|
404
|
+
| Corrective | decision/recovery, plan-integrity, remediation-mode, stop-override prepare/apply, yield и corrective-replan actions |
|
|
390
405
|
| Replacement | `replacement-materialize` retained, но всегда disabled в P04-A |
|
|
391
406
|
|
|
392
407
|
Exact options берутся из fresh `next`; command help используется только когда
|
|
@@ -398,7 +413,7 @@ Exact options берутся из fresh `next`; command help используе
|
|
|
398
413
|
running Step и active/stale writer lease. External runner допустим только в документированной rescue
|
|
399
414
|
compatibility форме.
|
|
400
415
|
|
|
401
|
-
Перед beta.
|
|
416
|
+
Перед beta.12.1 tag release repository выполняет:
|
|
402
417
|
|
|
403
418
|
1. `npm ci`;
|
|
404
419
|
2. `npm run validate`;
|
package/docs/release.md
CHANGED
|
@@ -27,7 +27,7 @@ The PDF check deterministically regenerates all three Russian documents from
|
|
|
27
27
|
`docs/pdf/sources`, binds the visible package version to the root manifest, and fails when any
|
|
28
28
|
tracked PDF is stale. Source and binary PDFs are one release unit.
|
|
29
29
|
|
|
30
|
-
For beta.
|
|
30
|
+
For beta.12.1, the release gate also relies on `npm run release:check` to fail if:
|
|
31
31
|
|
|
32
32
|
- canonical entity schema 2 shapes drift;
|
|
33
33
|
- protocol 2 is not the active public contract, or intact protocol-1 adoption evidence stops being readable through the bounded compatibility window;
|
|
@@ -44,12 +44,19 @@ For beta.11, the release gate also relies on `npm run release:check` to fail if:
|
|
|
44
44
|
commands are absent from the packaged surface.
|
|
45
45
|
- bounded dependency-provenance recovery, retained passed-review provenance, the exact Signal T04
|
|
46
46
|
revision-26 fixture, or pending/corrupt-review rejection regressions are absent.
|
|
47
|
+
- dependency recovery again requires Task-local manifest/lock fields to equal the Milestone base,
|
|
48
|
+
or a candidate commit can alter any non-Workflow dependency payload.
|
|
47
49
|
- the read-only Milestone progress projection, replacement regression, project-monotonic chat
|
|
48
50
|
registry, title fallback/readback, or long-Cyrillic multi-attempt E2E evidence is absent.
|
|
49
51
|
- bounded first-failure Plan-integrity recovery, exact failed-remediation/manifest/worktree
|
|
50
52
|
bindings, or the no-synthetic-second-failure regression is absent.
|
|
51
53
|
- the P04-A Milestone dependency/initial-Plan transaction capabilities or the P01-A mechanical
|
|
52
54
|
feasibility capability is absent from the packaged handshake.
|
|
55
|
+
- continuable guarded remediation or evidence-bound `fix`/`replan` review routing is absent, or a
|
|
56
|
+
third/later failed review is again converted into an attempt-count stop.
|
|
57
|
+
- the append-only, Human-confirmed beta.11 attempt-four stop override, its exact three-event/
|
|
58
|
+
continue/stop binding, split rejection, stale-confirmation rejection, or tamper detection is
|
|
59
|
+
absent from the package.
|
|
53
60
|
|
|
54
61
|
The separate lifecycle transcript validator fails if the real-agent log contains a mutation that
|
|
55
62
|
bypasses failed `status`/`next`, an unadvertised or failed mutation, an unresolved syntax-only
|
|
@@ -52,6 +52,31 @@ commit остался в Git между `baseCommit` и новым dependency-on
|
|
|
52
52
|
него обязательны последовательные `status` и `next`; выполняйте возвращённый Knowledge reconcile
|
|
53
53
|
или `task context-refresh`, если manifest/lock сделали Knowledge Map stale.
|
|
54
54
|
|
|
55
|
+
В beta.12.1 preflight сравнивает parent и candidate после удаления только записей зависимости
|
|
56
|
+
`codex-workflow-v2`. Поэтому ранее закоммиченные Task-local scripts и другие product-owned поля
|
|
57
|
+
`package.json`/lockfile могут отличаться от Milestone base и сохраняются. Это не ослабляет сам
|
|
58
|
+
candidate: его HEAD обязан менять ровно `package.json` и `package-lock.json`, только точную Workflow
|
|
59
|
+
dependency; любое другое поле, добавленное тем же candidate commit, неизвестный commit, stale base,
|
|
60
|
+
dirty checkout, lease или transaction по-прежнему блокируют recovery.
|
|
61
|
+
|
|
62
|
+
### Исключение beta.12.1 для beta.11 attempt-four stop
|
|
63
|
+
|
|
64
|
+
Если beta.11 записал `stop-escalate` перед четвёртой попыткой только после последовательности
|
|
65
|
+
`ordinary`, `ordinary`, `corrective`, и перед третьей попыткой уже существовал exact
|
|
66
|
+
`continue-fix`, fresh `next` может вернуть `task stop-override-prepare`. Не создавайте новый
|
|
67
|
+
Milestone и не редактируйте sidecar вручную. Сначала выполните только read-only prepare с exact
|
|
68
|
+
Task revision, Step, human actor и содержательной причиной. Проверьте, что ответ связывает тот же
|
|
69
|
+
stop decision, Plan hash, Git HEAD, все три remediation events и policy
|
|
70
|
+
`beta11-attempt4-stop-compatibility-v1`, затем остановитесь перед Human gate.
|
|
71
|
+
|
|
72
|
+
В отдельном пользовательском сообщении разрешите apply с теми же параметрами и возвращённым
|
|
73
|
+
`SOO-*` кодом. `task stop-override-apply` добавляет одну запись в
|
|
74
|
+
`stop-escalate-overrides.jsonl`, сохраняя исходный `stop-escalate`; после него выполните
|
|
75
|
+
последовательные `status` и `next`. Ожидаемый route — `task run` того же Step с последующим новым
|
|
76
|
+
strict review. Этот путь не работает для `split-required`, другого attempt ordinal, изменённого
|
|
77
|
+
Plan/HEAD/revision, отсутствующего attempt-3 continue, active/stale lease, dirty checkout или
|
|
78
|
+
незавершённой Task transaction. Delegated approval для него отсутствует.
|
|
79
|
+
|
|
55
80
|
## 1. Подготовьте отдельный чат обновления
|
|
56
81
|
|
|
57
82
|
Не обновляйте пакет во время выполняющегося Worker Step. Дождитесь завершения текущего ответа
|