gentle-pi 1.1.0 → 1.2.0
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 +23 -11
- package/assets/orchestrator-delegation.md +3 -3
- package/contracts/review-integration/v1/fixtures/capabilities-v1.1.fixture.json +45 -0
- package/contracts/review-integration/v1/fixtures/operation.fixture.json +50 -1
- package/contracts/review-integration/v1/fixtures/status-ambiguous.fixture.json +48 -1
- package/contracts/review-integration/v1/fixtures/status-corrupted.fixture.json +48 -1
- package/contracts/review-integration/v1/fixtures/status-recover.fixture.json +99 -0
- package/contracts/review-integration/v1/fixtures/status-unrelated.fixture.json +44 -1
- package/contracts/review-integration/v1/fixtures/status.fixture.json +83 -1
- package/contracts/review-integration/v1/schemas/capabilities-v1.1.schema.json +25 -2
- package/contracts/review-integration/v1/schemas/operation.schema.json +3 -1
- package/contracts/review-integration/v1/schemas/start.schema.json +2 -0
- package/contracts/review-integration/v1/schemas/status.schema.json +114 -2
- package/docs/native-authority-architecture.md +108 -0
- package/docs/review-integration.md +15 -3
- package/extensions/gentle-ai.ts +361 -955
- package/lib/gentle-ai-binary.ts +1 -1
- package/lib/git-commit-transaction.ts +5 -0
- package/lib/native-review-cli.ts +377 -13
- package/lib/review-compact-contract.ts +10 -1
- package/lib/review-integration-v1.ts +85 -3
- package/lib/review-publication-gate.ts +513 -0
- package/lib/review-repository.ts +12 -14
- package/lib/review-snapshot.ts +0 -59
- package/lib/review-transaction.ts +40 -834
- package/package.json +1 -1
- package/runtime/gentle-ai-binary.mjs +1 -1
- package/runtime/git-commit-transaction.mjs +5 -0
- package/runtime/native-review-cli.mjs +377 -13
- package/runtime/review-integration-v1.mjs +85 -3
- package/scripts/gentle-ai-installer.mjs +9 -9
- package/scripts/install-gentle-ai.mjs +2 -2
- package/scripts/measure-native-authority-slimming.mjs +111 -0
- package/scripts/verify-package-files.mjs +16 -15
- package/skills/_shared/review-ledger-contract.md +6 -6
- package/skills/gentle-ai/SKILL.md +4 -2
- package/tests/gentle-ai-installer.test.ts +21 -21
- package/tests/gentle-ai.test.ts +1 -1
- package/tests/git-commit-transaction.test.ts +128 -5
- package/tests/native-review-cli.test.ts +59 -0
- package/tests/native-review-parity-runtime.test.ts +8 -2
- package/tests/package-manifest.test.ts +24 -3
- package/tests/review-authority-recovery-docs.test.ts +16 -11
- package/tests/review-compact-contract.test.ts +53 -0
- package/tests/review-controller-lock-status.test.ts +145 -0
- package/tests/review-controller-native-recovery.test.ts +786 -0
- package/tests/review-controller-native-routing.test.ts +419 -462
- package/tests/review-controller-retired-ops.test.ts +54 -0
- package/tests/review-controller-workspace-root.test.ts +3 -0
- package/tests/review-controller.test.ts +19 -794
- package/tests/review-gate.test.ts +16 -7
- package/tests/review-integration-v1.test.ts +22 -2
- package/tests/review-ledger-contract.test.ts +4 -2
- package/tests/review-snapshot.test.ts +2 -15
- package/tests/review-transaction.test.ts +27 -51
- package/tests/runtime-harness.mjs +6 -6
- package/lib/review-authority-supersession.ts +0 -1056
- package/lib/review-bundle.ts +0 -286
- package/lib/review-checkpoint.ts +0 -127
- package/lib/review-compact-gate.ts +0 -219
- package/lib/review-compact-store.ts +0 -724
- package/lib/review-facade.ts +0 -508
- package/lib/review-graph-reducer.ts +0 -55
- package/lib/review-mirror.ts +0 -46
- package/lib/review-reset.ts +0 -262
- package/tests/review-authority-supersession.test.ts +0 -581
- package/tests/review-bundle.test.ts +0 -253
- package/tests/review-checkpoint.test.ts +0 -61
- package/tests/review-compact-gate.test.ts +0 -376
- package/tests/review-compact-store.test.ts +0 -124
- package/tests/review-facade.test.ts +0 -382
- package/tests/review-graph.test.ts +0 -27
- package/tests/review-mirror.test.ts +0 -20
- package/tests/review-reset.test.ts +0 -456
- package/tests/review-runtime-contract.test.ts +0 -70
package/README.md
CHANGED
|
@@ -58,7 +58,7 @@ Most coding-agent sessions fail for operational reasons, not model reasons:
|
|
|
58
58
|
| **Skill creation workflow** | Provides the `gentle-ai-skill-creator`/`gentle-ai-skill-improver` skills, `/skill-creation` prompt, and packaged style guide for LLM-first skills. |
|
|
59
59
|
| **Delivery skills** | Includes issue-first PRs, chained PRs, work-unit commits, cognitive docs, comment writing, and Judgment Day review. |
|
|
60
60
|
| **Bounded native review** | Freezes one candidate, dispatches only controller-selected lenses, records native authority, and reuses the same content-bound receipt at delivery gates. |
|
|
61
|
-
| **Verified native runtime** | Provisions the exact package-local Gentle AI v2.1.
|
|
61
|
+
| **Verified native runtime** | Provisions the exact package-local Gentle AI v2.1.11 binary, verifies pinned archive/binary integrity, negotiates `review-integration/v1`, and rejects PATH, global, sibling, symlink, and mode fallbacks. |
|
|
62
62
|
| **Runtime safety** | Blocks destructive shell commands, asks for confirmation for sensitive operations, and blocks direct read/write/edit access to sensitive paths. |
|
|
63
63
|
|
|
64
64
|
## Install
|
|
@@ -67,7 +67,7 @@ Most coding-agent sessions fail for operational reasons, not model reasons:
|
|
|
67
67
|
pi install npm:gentle-pi
|
|
68
68
|
```
|
|
69
69
|
|
|
70
|
-
The npm postinstall downloads the exact platform-specific official Gentle AI v2.1.
|
|
70
|
+
The npm postinstall downloads the exact platform-specific official Gentle AI v2.1.11 archive into this package's private `.gentle-ai/v2.1.11/` directory and verifies its pinned archive and executable SHA-256 values before extraction. It never uses `PATH` or a global `gentle-ai` installation. For development or offline installs only, set `GENTLE_PI_SKIP_GENTLE_AI_INSTALL=1`; native review operations then fail closed with an actionable `package-local-binary-missing` error until the package is reinstalled normally.
|
|
71
71
|
|
|
72
72
|
Recommended companion packages:
|
|
73
73
|
|
|
@@ -157,13 +157,21 @@ Review actors are dispatched only through parent `subagent_run` calls in `mode:
|
|
|
157
157
|
|
|
158
158
|
### Review authority recovery and reset safety
|
|
159
159
|
|
|
160
|
-
Legacy pre-graph authority is never migrated. `gentle_review inspect` reports an exact repository-bound destructive reset challenge;
|
|
160
|
+
Legacy pre-graph authority is never migrated. `gentle_review inspect` reports an exact repository-bound destructive reset challenge for legacy corruption; after that fresh interactive authorization, RESET and RECOVER_LOCK route to the audited native `gentle-ai review reclaim` operation and RECOVER routes to native `gentle-ai review recover`, so every destructive transition is executed and audited by the native authority store. Native inputs the request did not carry return a `native-input-required` envelope instead of being invented. Existing graph-v1 ordinary lineages remain readable and gate-validatable but are read-only; Judgment Day remains mutable on graph-v1.
|
|
161
161
|
|
|
162
|
-
|
|
162
|
+
`gentle_review abandon`, `quarantine-legacy`, and `reconcile-authority` remain explicit v2.1.11 maintenance routes. Pi derives and displays the published six-line abandon binding only for a caller-specified compact lineage, revision, and snapshot identity; the native CLI re-derives pristine compact-v2 eligibility. Legacy quarantine accepts only `historical findings freeze changed unrelated transaction state` with disposition `quarantine-malformed-freeze-event` and uses its exact eight-line binding. Both require fresh interactive approval and fail closed headlessly.
|
|
163
163
|
|
|
164
|
-
|
|
164
|
+
`gentle_review reconcile-authority` accepts one predecessor lineage and revision, one successor lineage and revision, an actor, and a reason. Pi derives the exact seven-line `gentle-ai.review-reconcile-authorization/v1` binding, or appends exactly `anomalies=unchanged_target,malformed_recovery_authorization` for the published dual anomaly in that order. Native code re-derives every anomaly; malformed bindings, changed revisions, unavailable native support, cancellation, and native refusal fail closed through typed envelopes.
|
|
165
165
|
|
|
166
|
-
|
|
166
|
+
Reconciliation is intentionally narrow: native code may quarantine only the bound invalid compact-v2 recovery successor and persists the returned audit record; the predecessor stays untouched. Pi never recreates the retired `prepare-supersession`/`supersede` authority writer and never falls back to RESET or RECOVER.
|
|
167
|
+
|
|
168
|
+
`gentle_review repair-legacy-alias` is the sole v2.1.11 route for `unsupported historical v1 operation alias`. The model supplies only lineage, actor, and reason. Pi freshly reads the native inventory, derives the canonical repository, exact legacy revision, fixed diagnostic, and fixed `quarantine-approved-historical-alias` disposition, displays the LF-only eight-line binding, and requires a new interactive approval. Native re-derives eligibility and quarantines rather than rewriting or validating the historical chain.
|
|
169
|
+
|
|
170
|
+
`review dispose-result` is deliberately unsupported by Pi pending a separate design; it has no controller operation or fallback. All maintenance routes fail closed headlessly and never auto-run against legacy history.
|
|
171
|
+
|
|
172
|
+
Native ordinary gates revalidate provider-selected authority, receipt, scope, intended-untracked proof, and the live target. Pi preserves a graph-v1 gate path only for explicit Judgment Day and historical graph receipt validation. Recovery grants no new budget and cannot bypass dangerous-command or publication checks. Legacy graph bundle export/import is retired.
|
|
173
|
+
|
|
174
|
+
This is the post-U8 boundary, not the final architecture. [Issue #191](https://github.com/Gentleman-Programming/gentle-pi/issues/191) is the immediate final unit in this same delivery: extract the remaining Pi command-projection and lifecycle-gate surface from `review-transaction.ts`, repoint runtime enforcement, then delete only dependencies proven unreachable without weakening graph-v1 Judgment Day. The branch-wide High-tier 4R runs after that extraction, before the single size-exception PR.
|
|
167
175
|
|
|
168
176
|
`reviewer` is not an installed subagent name. It is a routing intent. Select the concrete lens by risk profile:
|
|
169
177
|
|
|
@@ -233,13 +241,13 @@ flowchart TD
|
|
|
233
241
|
|
|
234
242
|
Lifecycle gates never launch review actors. They rederive Git and publication targets, validate the existing receipt, and authorize one exact command. Any target drift, stale evidence, malformed authority, or unprovable state blocks delivery instead of silently reopening review.
|
|
235
243
|
|
|
236
|
-
Native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v2.1.
|
|
244
|
+
Native contract pairing is exact: this adapter resolves only the integrity-verified package-local Gentle AI v2.1.11 executable, independently hashes it, then negotiates `gentle-ai.review-integration/v1` outside the repository. Capabilities are cached by that executable digest. Every START, target status, FINALIZE, validate, and BIND-SDD request passes the same contract identifier. Current protocol 1.0 envelopes decode exactly against the vendored schemas; `recover` routes only the provider-selected `action_disposition`, and optional additions require a future compatible schema/minor that the provider explicitly advertises and the consumer negotiates.
|
|
237
245
|
|
|
238
246
|
Target status owns `current_target`, `unrelated`, `ambiguous`, and `corrupted` applicability and returns one native action. Pi does not reconstruct ordinary authority from provider-private files or choose a lineage from repository-wide history. Restart recovery rebuilds only the derived candidate view from the native Git/content projection, including intended-untracked paths, symlinks, and immutable gitlink identities. Native failure envelopes retain their exact mutation outcome, replayability, required inputs, request digest, and next action. After an unknown or lost mutating result, Pi calls target status before any replay decision and returns only the provider-declared action.
|
|
239
247
|
|
|
240
248
|
Direct authorized `git commit` commands use a durable recovery record under the Git common directory. The package runs the effective pre-commit hook once, captures the post-hook index, performs final native validation against that tree, suppresses only the already-completed pre-commit hook while preserving message/post hooks through proxies, and proves `HEAD^{tree}` before the tool result succeeds. Any unresolved, interrupted, failed, or mismatched transaction blocks push, PR, and release. Recovery never resets HEAD or the index automatically.
|
|
241
249
|
|
|
242
|
-
Once v2.1.
|
|
250
|
+
Once v2.1.11 has written review authority, rollback MUST preserve every native store and receipt and MUST NOT run a downgraded binary against that repository. Disable the Pi route or roll forward to a compatible authority-aware release instead; deleting authority data or reinstalling an older binary is not a rollback path.
|
|
243
251
|
|
|
244
252
|
### FINALIZE wrapper input
|
|
245
253
|
|
|
@@ -297,9 +305,9 @@ Judgment Day alone may iterate discovery and scoped re-judgment, for at most two
|
|
|
297
305
|
|
|
298
306
|
Findings surviving round two escalate; no third-round transition exists.
|
|
299
307
|
|
|
300
|
-
|
|
308
|
+
Native compact gate validation is read-only. It loads authority and receipt, derives the live target, then reloads authority and rederives target/publication evidence immediately before allow.
|
|
301
309
|
|
|
302
|
-
Pi also registers one one-shot authorization for the exact command and rederives its full publication target before registration, before bash-time native validation, and again after that validation before allowing the command. For `gh pr create`, the effective repository follows GitHub CLI precedence (`--repo`, then `GH_REPO`, then local inference), and both that source/value and the exact advertised remote head commit are bound and rechecked against reviewed local `HEAD`. Publication `ls-remote` probes are shell-free, output-bounded, time-bounded, and cancellation-aware. The complete bash-time publication/native revalidation uses one aggregate bounded deadline combined with Pi's cancellation signal when available. First-push, push destination, exact PR base/head, repository identity, release, and dangerous-command protections remain fail closed.
|
|
310
|
+
Pi also registers one one-shot authorization for the exact command and rederives its full publication target before registration, before bash-time native validation, and again after that validation before allowing the command. The Pi-owned `lib/review-publication-gate.ts` module owns typed publication targets, configured push-destination binding, release projection, release fast-path evaluation, and publication rechecks without depending on graph-v1 authority storage. For `gh pr create`, the effective repository follows GitHub CLI precedence (`--repo`, then `GH_REPO`, then local inference), and both that source/value and the exact advertised remote head commit are bound and rechecked against reviewed local `HEAD`. Publication `ls-remote` probes are shell-free, output-bounded, time-bounded, and cancellation-aware. The complete bash-time publication/native revalidation uses one aggregate bounded deadline combined with Pi's cancellation signal when available. First-push, push destination, exact PR base/head, repository identity, release, and dangerous-command protections remain fail closed.
|
|
303
311
|
Native pre-push to an existing branch is supported only when the effective push URL and repository identity equal the fetch URL and identity used by the exact `<remote>/<destination-branch>` selector, and its advertised commit equals the command update's old object. Split fetch/push topology is unsupported because PR #1216 introduced the upstream v2.1.1 `--base-ref` contract that v2.1.3 inherits unchanged: that contract resolves the selector through fetch-side remote-tracking state, and probing `pushurl` does not change selector resolution. Pi fails closed before native validation with `native-split-fetch-push-unsupported-until-upstream-supports-explicit-push-base`. Native pre-PR remains fetch-side and may use advertised remote selectors. Residual gap (separate follow-up): native first-push authorization remains unsupported until Pi has a persisted explicit advertised-base source. A missing destination fails closed with `native-first-push-unsupported-until-persisted-advertised-base-exists`; Pi never guesses a base from an upstream, default branch, or nearest ancestor.
|
|
304
312
|
|
|
305
313
|
Native SDD readiness is true only for `verify` or `archive` with empty blockers and a published `reviewGate.result: "allow"`; review/resolve-review, missing gate evidence, and every non-allow or stale result remain blocked.
|
|
@@ -635,9 +643,11 @@ Memory contract for SDD delegation:
|
|
|
635
643
|
| `lib/review-integration-v1.ts` | Strict consumer decoder for negotiated capabilities, operations, target status, projections, and failures. |
|
|
636
644
|
| `lib/git-commit-transaction.ts` | Durable hook/native-validation/commit/recovery transaction with publication blocking and HEAD proof. |
|
|
637
645
|
| `lib/review-candidate-view.ts` | Builds immutable changed-scope actor views while preserving full-tree, path, mode, symlink, and index integrity. |
|
|
646
|
+
| `lib/review-canonical.ts` | Permanent Pi-owned canonical JSON and domain-hash primitives for consumer-side identities. |
|
|
647
|
+
| `lib/review-repository.ts` | Permanent Pi-owned Git common-directory identity, safe Git environment, and authority-root binding. |
|
|
638
648
|
| `lib/gentle-ai-binary.ts` | Resolves and verifies the confined package-local Gentle AI runtime without global or PATH fallback. |
|
|
639
649
|
| `scripts/gentle-ai-installer.mjs` | Downloads, verifies, extracts, and atomically promotes the pinned native runtime for six platform targets. |
|
|
640
|
-
| `contracts/review-integration/v1/` |
|
|
650
|
+
| `contracts/review-integration/v1/` | Byte-identical v2.1.11 provider schemas and conformance fixtures, hash-checked before packaging. |
|
|
641
651
|
| `extensions/startup-banner.ts` | Shows and configures the startup intro, color presets, compact runtime panel, and collaboration credit. |
|
|
642
652
|
| `extensions/sdd-init.ts` | Registers `/sdd-init` for OpenSpec initialization. |
|
|
643
653
|
| `extensions/skill-registry.ts` | Maintains `.atl/skill-registry.md` from project/user skills and closes file watchers on shutdown. |
|
|
@@ -648,6 +658,8 @@ Memory contract for SDD delegation:
|
|
|
648
658
|
| `skills/` | Gentle AI delivery and collaboration skills. |
|
|
649
659
|
| `prompts/` | Gentle-prefixed prompt templates, including `/skill-creation`. |
|
|
650
660
|
| `docs/skill-style-guide.md` | Normative style guide used by the packaged skill creation/improvement skills. |
|
|
661
|
+
| `docs/native-authority-architecture.md` | Post-U8 ownership boundary, reproducible slimming metrics, Windows evidence, and exact #191 seam. |
|
|
662
|
+
| `docs/review-integration.md` | Negotiated provider/consumer contract and the current Gentle Pi adoption boundary. |
|
|
651
663
|
|
|
652
664
|
## Development
|
|
653
665
|
|
|
@@ -191,7 +191,7 @@ When target status is `current_target`, follow its single native action. `ambigu
|
|
|
191
191
|
|
|
192
192
|
Preserve the negotiated failure envelope exactly. `mutation_outcome: not_started` proves no mutation. For `unknown` or lost mutating output, the controller immediately calls target-scoped status and returns its exact action; it never emits a generic replay instruction. Replay the exact START or FINALIZE only when that provider result declares `exact_replay_safe` for the same canonical request and required lineage. Never choose a lineage merely because output was lost.
|
|
193
193
|
|
|
194
|
-
Before authority access, `mutation_outcome: not_started` means no lineage was created. In the historical lane only, RESET and RECOVER
|
|
194
|
+
Before authority access, `mutation_outcome: not_started` means no lineage was created. In the historical lane only, authorized RESET and RECOVER route to the audited native `gentle-ai review reclaim` and `gentle-ai review recover` operations; missing native inputs return `native-input-required` and are never invented, and INSPECT follows every committed native recovery record.
|
|
195
195
|
|
|
196
196
|
Ordinary review runs the selected zero, one, or four lenses exactly once against `initial_review_tree`.
|
|
197
197
|
|
|
@@ -227,9 +227,9 @@ Judgment Day alone may iterate discovery and scoped re-judgment, for at most two
|
|
|
227
227
|
|
|
228
228
|
Findings surviving round two escalate; no third-round transition exists.
|
|
229
229
|
|
|
230
|
-
Graph-v1 ordinary authority remains readable
|
|
230
|
+
Graph-v1 ordinary authority remains readable and gate-valid but read-only. Legacy graph bundle export/import is retired. Judgment Day remains mutable on graph-v1, and native target status owns mixed-authority ambiguity and maintainer action.
|
|
231
231
|
|
|
232
|
-
|
|
232
|
+
Native compact gate validation is read-only and double-checks authority, target, publication refs, and evidence immediately before allow. Pi then registers one exact one-shot command authorization and rederives the target at bash time. The Pi-owned publication-gate module isolates typed targets, remote binding, release projection, and publication rechecks from graph-v1 authority storage; graph receipt validation remains reachable only for historical graph authority and explicit Judgment Day.
|
|
233
233
|
Release from protected `main` may bypass receipt validation only when the tag targets the current immutable `origin/main` SHA, required CI for that exact SHA is successful, the remote head is rechecked before tag push, and no fresh risk evidence exists; otherwise release fails closed through native receipt validation.
|
|
234
234
|
Major and post-incident releases require explicit extraordinary review even when fast-path checks pass.
|
|
235
235
|
|
|
@@ -156,6 +156,13 @@
|
|
|
156
156
|
"compact_v2_authority"
|
|
157
157
|
]
|
|
158
158
|
},
|
|
159
|
+
{
|
|
160
|
+
"name": "native_next_transition",
|
|
161
|
+
"supported": true,
|
|
162
|
+
"requires": [
|
|
163
|
+
"target_scoped_status"
|
|
164
|
+
]
|
|
165
|
+
},
|
|
159
166
|
{
|
|
160
167
|
"name": "risk_reasons",
|
|
161
168
|
"supported": true,
|
|
@@ -172,6 +179,44 @@
|
|
|
172
179
|
}
|
|
173
180
|
]
|
|
174
181
|
},
|
|
182
|
+
"bootstrap": {
|
|
183
|
+
"command": "gentle-ai review status --cwd \u003crepo\u003e --contract gentle-ai.review-integration/v1 --next-transition",
|
|
184
|
+
"target_selector_variants": [
|
|
185
|
+
{
|
|
186
|
+
"target_type": "staged",
|
|
187
|
+
"arguments": [
|
|
188
|
+
"--projection",
|
|
189
|
+
"staged"
|
|
190
|
+
]
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
"target_type": "base_ref",
|
|
194
|
+
"arguments": [
|
|
195
|
+
"--base-ref",
|
|
196
|
+
"\u003cref\u003e"
|
|
197
|
+
]
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
"target_type": "workspace_overlay_base_ref",
|
|
201
|
+
"arguments": [
|
|
202
|
+
"--workspace-overlay",
|
|
203
|
+
"--base-ref",
|
|
204
|
+
"\u003cref\u003e"
|
|
205
|
+
]
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
"target_type": "workspace_overlay_base_tree",
|
|
209
|
+
"arguments": [
|
|
210
|
+
"--workspace-overlay",
|
|
211
|
+
"--base-tree",
|
|
212
|
+
"\u003ctree\u003e"
|
|
213
|
+
]
|
|
214
|
+
}
|
|
215
|
+
],
|
|
216
|
+
"required_feature": "native_next_transition",
|
|
217
|
+
"unsupported_outcome": "unsupported-capability",
|
|
218
|
+
"parent_only": true
|
|
219
|
+
},
|
|
175
220
|
"compatibility": {
|
|
176
221
|
"minimum_protocol_major": 1,
|
|
177
222
|
"maximum_protocol_major": 1,
|
|
@@ -7,6 +7,55 @@
|
|
|
7
7
|
"lineage_id": "review-operation-fixture",
|
|
8
8
|
"state": "approved",
|
|
9
9
|
"action": "validate delivery with gentle-ai review validate --gate <gate>",
|
|
10
|
-
"store_revision": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
|
|
10
|
+
"store_revision": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
|
11
|
+
"eligibility": {
|
|
12
|
+
"allowed_actions": [
|
|
13
|
+
{
|
|
14
|
+
"action": "stop",
|
|
15
|
+
"reason_code": "forbidden_finalize_requires_target_status",
|
|
16
|
+
"required_inputs": [
|
|
17
|
+
"target_scoped_status"
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
],
|
|
21
|
+
"forbidden_actions": [
|
|
22
|
+
{
|
|
23
|
+
"action": "review.abandon",
|
|
24
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"action": "review.finalize",
|
|
28
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"action": "review.invalidate",
|
|
32
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
"action": "review.quarantine-legacy",
|
|
36
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"action": "review.reclaim",
|
|
40
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"action": "review.reconcile-authority",
|
|
44
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"action": "review.recover",
|
|
48
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"action": "review.start",
|
|
52
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"action": "review.validate",
|
|
56
|
+
"reason_code": "forbidden_finalize_requires_target_status"
|
|
57
|
+
}
|
|
58
|
+
]
|
|
59
|
+
}
|
|
11
60
|
}
|
|
12
61
|
}
|
|
@@ -28,5 +28,52 @@
|
|
|
28
28
|
"candidates": [
|
|
29
29
|
"review-a",
|
|
30
30
|
"review-b"
|
|
31
|
-
]
|
|
31
|
+
],
|
|
32
|
+
"eligibility": {
|
|
33
|
+
"allowed_actions": [
|
|
34
|
+
{
|
|
35
|
+
"action": "stop",
|
|
36
|
+
"reason_code": "forbidden_manual_intervention_required",
|
|
37
|
+
"required_inputs": []
|
|
38
|
+
}
|
|
39
|
+
],
|
|
40
|
+
"forbidden_actions": [
|
|
41
|
+
{
|
|
42
|
+
"action": "review.abandon",
|
|
43
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
"action": "review.finalize",
|
|
47
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"action": "review.invalidate",
|
|
51
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
"action": "review.quarantine-legacy",
|
|
55
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"action": "review.reclaim",
|
|
59
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"action": "review.reconcile-authority",
|
|
63
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"action": "review.recover",
|
|
67
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"action": "review.start",
|
|
71
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"action": "review.validate",
|
|
75
|
+
"reason_code": "forbidden_ambiguous_authority"
|
|
76
|
+
}
|
|
77
|
+
]
|
|
78
|
+
}
|
|
32
79
|
}
|
|
@@ -25,5 +25,52 @@
|
|
|
25
25
|
"initial_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6",
|
|
26
26
|
"current_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6"
|
|
27
27
|
},
|
|
28
|
-
"candidates": []
|
|
28
|
+
"candidates": [],
|
|
29
|
+
"eligibility": {
|
|
30
|
+
"allowed_actions": [
|
|
31
|
+
{
|
|
32
|
+
"action": "stop",
|
|
33
|
+
"reason_code": "forbidden_manual_intervention_required",
|
|
34
|
+
"required_inputs": []
|
|
35
|
+
}
|
|
36
|
+
],
|
|
37
|
+
"forbidden_actions": [
|
|
38
|
+
{
|
|
39
|
+
"action": "review.abandon",
|
|
40
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"action": "review.finalize",
|
|
44
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"action": "review.invalidate",
|
|
48
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"action": "review.quarantine-legacy",
|
|
52
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"action": "review.reclaim",
|
|
56
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"action": "review.reconcile-authority",
|
|
60
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"action": "review.recover",
|
|
64
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"action": "review.start",
|
|
68
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"action": "review.validate",
|
|
72
|
+
"reason_code": "forbidden_corrupted_authority"
|
|
73
|
+
}
|
|
74
|
+
]
|
|
75
|
+
}
|
|
29
76
|
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schema": "gentle-ai.review-integration.status/v1",
|
|
3
|
+
"contract": "gentle-ai.review-integration/v1",
|
|
4
|
+
"operation": "review.status",
|
|
5
|
+
"applicability": "current_target",
|
|
6
|
+
"authority": {
|
|
7
|
+
"version": "compact-v2",
|
|
8
|
+
"lineage_id": "review-status-recover-fixture",
|
|
9
|
+
"state": "correction_required",
|
|
10
|
+
"generation": 3,
|
|
11
|
+
"revision": "sha256:81cdad8f3182d4919147d3c4fe8f614814068e5ef68417e3dcbd5e326dd3e390"
|
|
12
|
+
},
|
|
13
|
+
"receipt": {
|
|
14
|
+
"status": "expected_missing"
|
|
15
|
+
},
|
|
16
|
+
"action": "recover",
|
|
17
|
+
"action_disposition": "scope_changed",
|
|
18
|
+
"replayability": "manual_action_required",
|
|
19
|
+
"frozen": {
|
|
20
|
+
"tier": "medium",
|
|
21
|
+
"original_changed_lines": 2,
|
|
22
|
+
"correction_budget": 1
|
|
23
|
+
},
|
|
24
|
+
"target_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6",
|
|
25
|
+
"projection": {
|
|
26
|
+
"schema": "gentle-ai.review-integration.projection/v1",
|
|
27
|
+
"kind": "current-changes",
|
|
28
|
+
"projection": "workspace",
|
|
29
|
+
"base_tree": "3e21a205dd9b55021aeae87965092623807e455f",
|
|
30
|
+
"initial_review_tree": "1c3325617279b38743f073302ba190fc421b5a09",
|
|
31
|
+
"current_candidate_tree": "1c3325617279b38743f073302ba190fc421b5a09",
|
|
32
|
+
"paths_digest": "sha256:b93fca961a97d240c2b7023e98772f49ebd2995eda7db07043270b57bed75d71",
|
|
33
|
+
"paths": [
|
|
34
|
+
"tracked.txt"
|
|
35
|
+
],
|
|
36
|
+
"intended_untracked": [],
|
|
37
|
+
"intended_untracked_proof": "sha256:b97229718d4c7fe50a8892eb474ae5aa6491697bccb400e3e31dbaca4894d2f3",
|
|
38
|
+
"initial_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6",
|
|
39
|
+
"current_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6"
|
|
40
|
+
},
|
|
41
|
+
"candidates": [],
|
|
42
|
+
"eligibility": {
|
|
43
|
+
"allowed_actions": [
|
|
44
|
+
{
|
|
45
|
+
"action": "review.recover",
|
|
46
|
+
"reason_code": "eligible_recovery",
|
|
47
|
+
"required_inputs": [
|
|
48
|
+
"predecessor_lineage",
|
|
49
|
+
"expected_predecessor_revision",
|
|
50
|
+
"successor_lineage",
|
|
51
|
+
"disposition",
|
|
52
|
+
"reason",
|
|
53
|
+
"actor",
|
|
54
|
+
"maintainer_authorization"
|
|
55
|
+
],
|
|
56
|
+
"disposition": "scope_changed",
|
|
57
|
+
"binding": {
|
|
58
|
+
"lineage_id": "review-status-recover-fixture",
|
|
59
|
+
"revision": "sha256:81cdad8f3182d4919147d3c4fe8f614814068e5ef68417e3dcbd5e326dd3e390",
|
|
60
|
+
"target_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6"
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
],
|
|
64
|
+
"forbidden_actions": [
|
|
65
|
+
{
|
|
66
|
+
"action": "review.abandon",
|
|
67
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
"action": "review.finalize",
|
|
71
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
"action": "review.invalidate",
|
|
75
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
"action": "review.quarantine-legacy",
|
|
79
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"action": "review.reclaim",
|
|
83
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
"action": "review.reconcile-authority",
|
|
87
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
"action": "review.start",
|
|
91
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"action": "review.validate",
|
|
95
|
+
"reason_code": "forbidden_not_selected_by_native_status"
|
|
96
|
+
}
|
|
97
|
+
]
|
|
98
|
+
}
|
|
99
|
+
}
|
|
@@ -25,5 +25,48 @@
|
|
|
25
25
|
"initial_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6",
|
|
26
26
|
"current_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6"
|
|
27
27
|
},
|
|
28
|
-
"candidates": []
|
|
28
|
+
"candidates": [],
|
|
29
|
+
"eligibility": {
|
|
30
|
+
"allowed_actions": [
|
|
31
|
+
{
|
|
32
|
+
"action": "review.start",
|
|
33
|
+
"reason_code": "eligible_current_target",
|
|
34
|
+
"required_inputs": []
|
|
35
|
+
}
|
|
36
|
+
],
|
|
37
|
+
"forbidden_actions": [
|
|
38
|
+
{
|
|
39
|
+
"action": "review.abandon",
|
|
40
|
+
"reason_code": "forbidden_unrelated_target"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"action": "review.finalize",
|
|
44
|
+
"reason_code": "forbidden_unrelated_target"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"action": "review.invalidate",
|
|
48
|
+
"reason_code": "forbidden_unrelated_target"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"action": "review.quarantine-legacy",
|
|
52
|
+
"reason_code": "forbidden_unrelated_target"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"action": "review.reclaim",
|
|
56
|
+
"reason_code": "forbidden_unrelated_target"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"action": "review.reconcile-authority",
|
|
60
|
+
"reason_code": "forbidden_unrelated_target"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"action": "review.recover",
|
|
64
|
+
"reason_code": "forbidden_unrelated_target"
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"action": "review.validate",
|
|
68
|
+
"reason_code": "forbidden_unrelated_target"
|
|
69
|
+
}
|
|
70
|
+
]
|
|
71
|
+
}
|
|
29
72
|
}
|
|
@@ -37,5 +37,87 @@
|
|
|
37
37
|
"initial_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6",
|
|
38
38
|
"current_snapshot_identity": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6"
|
|
39
39
|
},
|
|
40
|
-
"candidates": []
|
|
40
|
+
"candidates": [],
|
|
41
|
+
"eligibility": {
|
|
42
|
+
"allowed_actions": [
|
|
43
|
+
{
|
|
44
|
+
"action": "stop",
|
|
45
|
+
"reason_code": "forbidden_required_inputs_unavailable",
|
|
46
|
+
"required_inputs": []
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
"forbidden_actions": [
|
|
50
|
+
{
|
|
51
|
+
"action": "review.abandon",
|
|
52
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
"action": "review.finalize",
|
|
56
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"action": "review.invalidate",
|
|
60
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"action": "review.quarantine-legacy",
|
|
64
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"action": "review.reclaim",
|
|
68
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"action": "review.reconcile-authority",
|
|
72
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"action": "review.recover",
|
|
76
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
"action": "review.start",
|
|
80
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
"action": "review.validate",
|
|
84
|
+
"reason_code": "forbidden_required_inputs_unavailable"
|
|
85
|
+
}
|
|
86
|
+
]
|
|
87
|
+
},
|
|
88
|
+
"next_transition": {
|
|
89
|
+
"kind": "collect",
|
|
90
|
+
"reason_code": "reviewer_results_required",
|
|
91
|
+
"collect": {
|
|
92
|
+
"inputs": [
|
|
93
|
+
{
|
|
94
|
+
"name": "reviewer_result",
|
|
95
|
+
"schema": "https://gentle-ai.dev/schema/review/reviewer/v1",
|
|
96
|
+
"capture_operation": "review.capture-result",
|
|
97
|
+
"arguments": [
|
|
98
|
+
{
|
|
99
|
+
"name": "lineage",
|
|
100
|
+
"value": "review-status-fixture"
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
"name": "expected-revision",
|
|
104
|
+
"value": "sha256:81cdad8f3182d4919147d3c4fe8f614814068e5ef68417e3dcbd5e326dd3e390"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"name": "target",
|
|
108
|
+
"value": "sha256:e6faad1cb9ceb2db170e0ec9ea5394b44c3991dff6cbd02fb6787539715968f6"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"name": "lens",
|
|
112
|
+
"value": "review-reliability"
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
"name": "order",
|
|
116
|
+
"value": "0"
|
|
117
|
+
}
|
|
118
|
+
]
|
|
119
|
+
}
|
|
120
|
+
]
|
|
121
|
+
}
|
|
122
|
+
}
|
|
41
123
|
}
|
|
@@ -135,12 +135,13 @@
|
|
|
135
135
|
},
|
|
136
136
|
"optional": {
|
|
137
137
|
"type": "array",
|
|
138
|
-
"minItems":
|
|
139
|
-
"maxItems":
|
|
138
|
+
"minItems": 7,
|
|
139
|
+
"maxItems": 7,
|
|
140
140
|
"items": {"$ref": "#/$defs/feature"}
|
|
141
141
|
}
|
|
142
142
|
}
|
|
143
143
|
},
|
|
144
|
+
"bootstrap": {"$ref": "#/$defs/bootstrap"},
|
|
144
145
|
"compatibility": {
|
|
145
146
|
"type": "object",
|
|
146
147
|
"additionalProperties": false,
|
|
@@ -206,6 +207,7 @@
|
|
|
206
207
|
"risk_reasons",
|
|
207
208
|
"sdd_receipt_binding",
|
|
208
209
|
"scope_change_diagnostics",
|
|
210
|
+
"native_next_transition",
|
|
209
211
|
"target_scoped_status",
|
|
210
212
|
"uniform_failure_envelope"
|
|
211
213
|
]
|
|
@@ -217,6 +219,27 @@
|
|
|
217
219
|
"items": {"type": "string", "minLength": 1}
|
|
218
220
|
}
|
|
219
221
|
}
|
|
222
|
+
},
|
|
223
|
+
"bootstrap": {
|
|
224
|
+
"type": "object",
|
|
225
|
+
"additionalProperties": false,
|
|
226
|
+
"required": ["command", "target_selector_variants", "required_feature", "unsupported_outcome", "parent_only"],
|
|
227
|
+
"properties": {
|
|
228
|
+
"command": {"const": "gentle-ai review status --cwd <repo> --contract gentle-ai.review-integration/v1 --next-transition"},
|
|
229
|
+
"target_selector_variants": {"type": "array", "minItems": 4, "maxItems": 4, "items": {"$ref": "#/$defs/target_selector"}},
|
|
230
|
+
"required_feature": {"const": "native_next_transition"},
|
|
231
|
+
"unsupported_outcome": {"const": "unsupported-capability"},
|
|
232
|
+
"parent_only": {"const": true}
|
|
233
|
+
}
|
|
234
|
+
},
|
|
235
|
+
"target_selector": {
|
|
236
|
+
"type": "object",
|
|
237
|
+
"additionalProperties": false,
|
|
238
|
+
"required": ["target_type", "arguments"],
|
|
239
|
+
"properties": {
|
|
240
|
+
"target_type": {"enum": ["staged", "base_ref", "workspace_overlay_base_ref", "workspace_overlay_base_tree"]},
|
|
241
|
+
"arguments": {"type": "array", "minItems": 2, "items": {"type": "string", "minLength": 1}}
|
|
242
|
+
}
|
|
220
243
|
}
|
|
221
244
|
}
|
|
222
245
|
}
|