Skip to content

fix(review): expose immutable candidate diff and changed-path manifest from START #1454

Description

@AndySabina

Pre-flight Checklist

  • I have searched existing issues, including open and closed results, and this is not a duplicate
  • I understand that PRs will be rejected if the linked issue does not have status:approved

📝 Bug Description

Gentle AI 2.1.8 ordinary compact review start does not expose the exact immutable candidate diff and changed-path manifest, or public content-bound artifact references to them, even though the shipped review ledger contract requires orchestrators to append both inputs before launching each selected lens and to stop when they are unavailable.

PR #1395 partially fixed #1394 by emitting target_identity and lens_bindings and preserving full lens names. It did not expose the immutable diff, changed-path manifest, or public references cryptographically bound to those exact contents. This remaining gap was documented in a comment on #1394, but #1394 was closed after the partial fix and no active issue tracks the remaining contract mismatch.

This is not a duplicate of:

🔄 Steps to Reproduce

  1. Install and sync Gentle AI 2.1.8.
  2. In a disposable Git repository, create and stage an ordinary executable-code change.
  3. Run gentle-ai review capabilities --contract gentle-ai.review-integration/v1.
  4. Run gentle-ai review start --cwd <repo> --projection staged.
  5. Inspect only the public START response and supported public review status output.
  6. Attempt to obtain the exact immutable candidate diff and changed-path manifest, or public content-bound references to them, without reading private .git/gentle-ai implementation storage or reconstructing inputs from mutable Git state.
  7. Observe that START provides identity and lens bindings but no supported public immutable diff/manifest inputs.
  8. Follow internal/assets/skills/_shared/review-ledger-contract.md, which requires both inputs before every lens and says if unavailable, stop.

✅ Expected Behavior

Every created, resumed, or continued compact START that selects lenses should expose public, immutable, content-bound lens inputs:

  • the exact candidate diff;
  • the canonical changed-path manifest, including modes, deletions, and intended-untracked paths where applicable;
  • or stable public artifact references carrying native hashes/signatures that bind those exact bytes to the returned target_identity, lineage, projection, base tree, and candidate tree.

The interface should let an orchestrator launch lenses exclusively from supported START output without reading private authority storage or reconstructing evidence from mutable repository state.

❌ Actual Behavior

START emits target_identity and lens_bindings, but not the exact immutable candidate diff, changed-path manifest, or public content-bound references to either artifact.

The shipped orchestration contract therefore requires a conformant orchestrator to stop before launching reviewers. With no captured lens results, no receipt can be finalized, and lifecycle validation later reports that the facade review receipt is unavailable.

Gentle AI Version

v2.1.8

Operating System

Linux

Agent / Client

OpenCode

📋 Affected Area

CLI / review integration contract / OpenCode review orchestration

Shell

bash

💡 Logs / Error Output

review start: target identity and lens bindings emitted; immutable diff/manifest inputs unavailable
orchestration contract: "Before each lens, append the exact immutable candidate diff and changed-path manifest from START; if unavailable, stop."
review validate --gate pre-commit: Error: facade review receipt is not available

Additional Context

Relevant sources and history:

No private repository paths, candidate code, active lineage identifiers, or private hashes are included in this report.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstatus:approvedApproved for implementation — PRs can now be opened

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions