Skip to content

Align Pi revdiff integration with Claude review workflow #207

Description

@umputun

pi revdiff integration should match Claude Code's normal /revdiff behavior. Current Pi flow stores annotations as pending UI state with apply/rerun/results commands. That is a different UX and makes the standard review loop harder.

scope

  • keep one public command: /revdiff [args]
  • use Pi direct terminal handoff only
  • remove Pi overlay mode and the launch-revdiff.sh dependency from the Pi review path
  • remove overlay options from the Pi command/tool docs and revdiff_review parameters
  • remove pending annotation inbox UI:
    • /revdiff-rerun
    • /revdiff-results
    • /revdiff-apply
    • /revdiff-clear
    • pending annotation status/widget/panel
  • remove the post-edit reminder command from the default Pi package surface
  • keep revdiff_review as the agent tool for rerun loops after fixes
  • use revdiff exit status in automation: 0 means clean, 10 means annotations captured, other nonzero statuses mean failure

target workflow

  • /revdiff [args] launches revdiff through direct terminal handoff
  • no annotations means review is clean
  • captured annotations are sent to the main agent immediately as a user message
  • the agent handles annotations and reruns review with revdiff_review using the same args
  • the loop stops only when revdiff returns no annotations

Claude parity gaps to cover

  • update plugins/pi/skills/revdiff/SKILL.md to document the Claude-style loop
  • classify annotations into explanation requests and code-change directives
  • support the explanation loop with temp markdown files reviewed through revdiff
  • instruct the agent to list planned changes before editing files, without relying on a Pi plan-mode feature
  • document --untracked guidance for agent-created files
  • document --description and --description-file guidance for launches after analysis or refactor work
  • document the existing-history workflow for "use my latest revdiff annotations"
  • document in-session review preload with --annotations=<tempfile>

extension fixes

  • parse use_staged from .claude-plugin/skills/revdiff/scripts/detect-ref.sh
  • auto-add --staged for staged-only no-arg reviews
  • keep generic pass-through for revdiff flags, including:
    • --untracked
    • --description
    • --description-file
    • --annotations
    • --include
    • --exclude
  • keep file review detection for existing files and path-like args
  • treat exit 10 as success-with-annotations and preserve captured output
  • treat nonzero statuses other than 10 as launch failures

out of scope

  • Pi planning integration
  • Claude revdiff-planning parity

acceptance criteria

  • /revdiff [args] starts direct revdiff and hands captured annotations to the agent without an apply step
  • agent reruns review with revdiff_review until no annotations are captured
  • no pending annotation widget or apply/clear/results commands remain in the Pi user workflow
  • staged-only no-arg review opens staged changes correctly
  • Pi skill documents the same normal review loop as Claude Code, minus overlay and planning details

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions