Agent skill

Revdiff Plan

by umputun in umputun/revdiff

Review the last Codex assistant message (plan, analysis, or proposal) with inline annotations in a TUI overlay.

MITAuto-check passed

Install Revdiff Plan

skills CLI
$ npx skills add umputun/revdiff --skill revdiff-plan -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install umputun/revdiff revdiff-plan --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/umputun/revdiff.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/codex/skills/revdiff-plan .claude/skills/revdiff-plan && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
revdiff-plan
GitHub stars
916
Token cost
~1.6k tokens
SKILL.md length
735 words
Files
2 (incl. scripts)
Skills in repo
4
Repo updated
First seen
Licence
MIT

At a glance

Review the last Codex assistant message (plan, analysis, or proposal) with inline annotations in a TUI overlay.

  • Works in 7 steps: Extract Last Assistant Message → Launch Review → Process Annotations → …
  • SKILL.md covers Script Path Resolution, Activation Triggers, How It Works and Workflow
  • Runs Shell scripts from its folder

What it does

Revdiff Plan is an agent skill from umputun/revdiff. Review the last Codex assistant message (plan, analysis, or proposal) with inline annotations in a TUI overlay. Extracts the most recent response from Codex rollout files and opens it in revdiff for review and annotation. Activates on "revdiff-plan", "review plan with revdiff", "annotate plan", "review last response", "annotate codex output".

Its SKILL.md is about 1.6k tokens, which your agent loads only when the skill is triggered. The skill folder holds 2 other files, including scripts (for example `scripts/extract-last-message.sh`).

The repository describes itself as: TUI for reviewing diffs, files, and documents with inline annotations. The licence is MIT.

Example prompts

  • “revdiff-plan”
  • “review plan with revdiff”
  • “annotate plan”
  • “/revdiff-plan”

Requirements

  • A Bash shell

Workflow steps

7 steps, taken from the step headings in SKILL.md.

  1. Extract Last Assistant Message
  2. Launch Review
  3. Process Annotations
  4. 5: Classify Annotations
  5. Address Annotations
  6. Loop
  7. Done

What it can do on your machine

Read from SKILL.md and the folder at commit d2e4a78. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (Shell), which the agent can run.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Revdiff Plan loads about 1.6k tokens when it runs. Until then it costs about 89 tokens; SKILL.md has 735 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~89
When it runs · the whole SKILL.md, loaded when a task matches
~1.6k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from umputun/revdiff at commit d2e4a78, republished under its MIT licence (© umputun). 735 words, ~1,589 tokens.

Download SKILL.mdSave it as .claude/skills/revdiff-plan/SKILL.md (or your agent's skills folder). This skill also uses 1 other file; get the full folder from GitHub.
name
revdiff-plan
description
Review the last Codex assistant message (plan, analysis, or proposal) with inline annotations in a TUI overlay. Extracts the most recent response from Codex rollout files and opens it in revdiff for review and annotation. Activates on "revdiff-plan", "review plan with revdiff", "annotate plan", "review last response", "annotate codex output".

revdiff-plan - Review Codex Output

Review the last Codex assistant message with inline annotations using revdiff TUI in a terminal overlay.

Script Path Resolution

Resolve <plugin-root> from this skill's absolute path in the available-skills catalogue. It is the directory containing this plugin's .codex-plugin/plugin.json. Then set:

bash
SCRIPT_DIR="<plugin-root>/skills/revdiff-plan/scripts"

Also resolve the launcher script from the revdiff skill:

bash
LAUNCHER_DIR="<plugin-root>/skills/revdiff/scripts"

Replace <plugin-root> with the resolved absolute path before running either command. Use $SCRIPT_DIR and $LAUNCHER_DIR in place of script paths throughout this skill.

Activation Triggers

  • "revdiff-plan", "review plan with revdiff", "annotate plan"
  • "review last response", "annotate codex output"

How It Works

  1. Extract the last Codex assistant message from rollout files
  2. Write it to a temp markdown file
  3. Launch revdiff with --only=<tempfile> in a terminal overlay
  4. User reads the plan, adds annotations on specific lines
  5. On quit, annotations are captured from stdout
  6. Codex reads annotations and addresses each one (refine plan, answer questions, fix issues)
  7. Loop: re-launch revdiff to verify changes, user can add more annotations
  8. Done when user quits without annotations; clean up temp file

Workflow

Step 1: Extract Last Assistant Message

Run the extraction script with --skip-current to avoid picking up this session's own output:

bash
$SCRIPT_DIR/extract-last-message.sh --skip-current

The script:

  • Uses a best-effort heuristic: picks the second most recent rollout JSONL file by modification time from ~/.codex/sessions/
  • This assumes the newest file belongs to the active session; if concurrent Codex sessions exist, the wrong file may be selected
  • Falls back to the newest file if only one session exists
  • Extracts the last assistant message text using jq
  • Outputs raw markdown to stdout
  • Accepts an explicit rollout file path as an argument to bypass auto-detection when precision matters

If the script fails (no sessions, no messages), inform the user and stop. If the user reports that the wrong content was extracted, ask them to provide the rollout file path explicitly: $SCRIPT_DIR/extract-last-message.sh /path/to/rollout.jsonl

Capture the output and write it to a temp file:

bash
TMPBASE="${TMPDIR:-/tmp}"
PLAN_FILE=$(mktemp "$TMPBASE/revdiff-plan-XXXXXX")
mv "$PLAN_FILE" "${PLAN_FILE}.md"
PLAN_FILE="${PLAN_FILE}.md"
$SCRIPT_DIR/extract-last-message.sh --skip-current > "$PLAN_FILE"
Step 2: Launch Review

Run the launcher script with --only=<tempfile>:

bash
$LAUNCHER_DIR/launch-revdiff.sh --only="$PLAN_FILE"

The launcher sets REVDIFF_EXIT_CODE_ON_ANNOTATIONS; exit 10 means annotations were captured and is not a launcher failure. Treat other nonzero statuses as failures.

IMPORTANT -- long-running command: The launcher blocks until the user finishes reviewing in the TUI overlay. Set the bash timeout parameter to the maximum your harness allows (e.g. 1800000 or higher). Do NOT use run_in_background.

If the bash tool reports a timeout, use the same fallback as the revdiff skill:

  1. Tell the user: "The bash tool timed out, but revdiff may still be open. Let me know when you're done reviewing."
  2. Wait for the user to reply.
  3. Read the most recent output file:
    bash
    output_file="$(ls -t "${TMPDIR:-/tmp}"/revdiff-output-* 2>/dev/null | head -1)"
    if [ -n "$output_file" ] && [ -f "$output_file" ]; then
      cat "$output_file"
    fi
Show full SKILL.md (298 more words)Show less
Step 3: Process Annotations

If the bash tool reports exit 10, read stdout and process it as annotations; do not call it a failure. If the launcher produces output, the user made annotations. The output format is:

## plan-XXXXXX.md:12 ( )
this section needs more detail about error handling

## plan-XXXXXX.md:25 ( )
explain why we chose this approach over alternatives

Each annotation block has:

  • ## filename:line (type) -- which file and line
  • Comment text below -- what the user wants changed or clarified
Step 3.5: Classify Annotations

Split annotations into two categories:

Explanation requests -- annotation matches either rule (case-insensitive):

  • contains two or more consecutive question marks anywhere in the text (??, ???, etc.) -- a language-neutral shortcut for "please explain"
  • OR starts with one of: explain, remind, describe, what is, what are, how does, how do, clarify

These are questions the user wants answered, not plan changes.

Plan-change directives -- everything else. These are instructions to modify the plan content.

If explanation requests are found:

  1. Answer each explanation request directly

  2. If there are also plan-change directives, note them as pending

  3. Enter the explanation loop:

    a. Write the explanation to a temp markdown file b. Launch revdiff with --only=<explanation-file> via the launcher script c. If user quits without annotations -- explanation accepted, proceed to pending directives or Step 5 d. If user annotates -- refine explanation, loop back to (b)

If no explanation requests -- proceed directly to Step 4.

Step 4: Address Annotations

For plan-change directives:

  • Update the temp plan file with the requested changes
  • Rewrite $PLAN_FILE with the updated content
Step 5: Loop

After addressing annotations, re-launch revdiff with the updated plan:

bash
$LAUNCHER_DIR/launch-revdiff.sh --only="$PLAN_FILE"

The user can:

  • Add more annotations -- go back to Step 3
  • Quit without annotations -- review complete
Step 6: Done

When the launcher produces no output, the review is complete.

Clean up the temp file:

bash
rm -f "$PLAN_FILE"

Inform the user that the plan review is complete. If the plan was modified during the review, present the final version.

© umputun, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 1 other file (scripts) in plugins/codex/skills/revdiff-plan of umputun/revdiff.

  • SKILL.md
  • scripts/extract-last-message.sh

Open the folder on GitHubat commit d2e4a78

Compare with similar skills

Revdiff Plan next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Revdiff Plan compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Revdiff Plan this skillumputun/revdiff916—~1.6kAutomated safety check: PassMIT
Messages Opsaffaan-m/ECC274k1 repos~724Automated safety check: PassMIT
Commit Message Storytellergithub/awesome-copilot40k1 repos~1.3kAutomated safety check: PassMIT
Agent Messagingdavila7/claude-code-templates32k—~807Automated safety check: PassMIT
Plannotator Last Messagebacknotprop/plannotator9.2k—~279Automated safety check: PassApache-2.0
Messagesgithub/gh-aw5.3k—~1.7kAutomated safety check: PassMIT

Similar skills

  • Messages Ops

    affaan-m/ECC

    Evidence-first live messaging workflow for ECC. An agent skill from affaan-m/ECC.

    274k GitHub starsUsed in 1 repo~724 tokens
    Productivity & AutomationAuto-check passed
  • Commit Message Storyteller

    github/awesome-copilot

    Official

    Analyzes git diffs or staged changes and generates narrative commit messages that explain WHY a change was made, not just what changed — following Conventional Commits format.

    40k GitHub starsUsed in 1 repo~1.3k tokens
    DevelopmentAuto-check passed
  • Agent Messaging

    davila7/claude-code-templates

    Send and receive cryptographically signed messages between AI agents using the Agent Messaging Protocol (AMP).

    32k GitHub stars~807 tokensUpdated today
    MobileAuto-check passed
  • Plannotator Last Message

    backnotprop/plannotator

    Opens Plannotator on the agent's latest rendered reply so you can annotate it, then folds the returned feedback into a revision or the next step.

    9.2k GitHub stars~279 tokensUpdated yesterday
    Agent WorkflowsAuto-check passed
  • Messages

    github/gh-aw

    Official

    Add new safe-output message types and wire validation/rendering.

    5.3k GitHub stars~1.7k tokensUpdated today
    Auto-check passed
  • Messages Ops

    affaan-m/ECC

    面向ECC的以证据为先的实时消息工作流。当用户想要阅读短信或私信、恢复最近的一次性验证码、在回复前检查对话线程,或证明实际检查了哪个消息来源时使用。

    274k GitHub stars~315 tokensUpdated 2 days ago
    Auto-check passed

More from umputun/revdiff

  • Revdiff

    umputun/revdiff

    Review diffs, files, and documents with inline annotations in a TUI overlay, or answer questions about revdiff usage, configuration, themes, and keybindings.

    916 GitHub stars~5.5k tokensUpdated today
    Auto-check: notes
  • Revdiff

    umputun/revdiff

    Review diffs, files, and documents with inline annotations in a TUI overlay, or answer questions about revdiff usage, configuration, themes, and keybindings.

    916 GitHub stars~5.6k tokensUpdated today
    Auto-check passed
  • Revdiff

    umputun/revdiff

    Pi-only interactive diff and file review with revdiff. An agent skill from umputun/revdiff.

    916 GitHub stars~2.5k tokensUpdated today
    Auto-check passed

Questions about Revdiff Plan

What does Revdiff Plan do?

Review the last Codex assistant message (plan, analysis, or proposal) with inline annotations in a TUI overlay. Revdiff Plan is an agent skill from umputun/revdiff. Review the last Codex assistant message (plan, analysis, or proposal) with inline annotations in a TUI overlay.

How do I install Revdiff Plan in Claude Code?

Run `npx skills add umputun/revdiff --skill revdiff-plan -a claude-code`. Or copy the skill folder (plugins/codex/skills/revdiff-plan in umputun/revdiff) into .claude/skills/revdiff-plan in your project. Claude Code loads it when a task matches its description.

How do I install Revdiff Plan in Codex?

Run `npx skills add umputun/revdiff --skill revdiff-plan -a codex`. Or copy the skill folder (plugins/codex/skills/revdiff-plan in umputun/revdiff) into .agents/skills/revdiff-plan in your project. Codex loads it when a task matches its description.

Can I use Revdiff Plan in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add umputun/revdiff --skill revdiff-plan -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/revdiff-plan, .gemini/skills/revdiff-plan, .github/skills/revdiff-plan and .opencode/skills/revdiff-plan in your project.

What does Revdiff Plan need to run?

Going by SKILL.md and its folder, Revdiff Plan needs a shell for the scripts in its folder. Our summary lists: A Bash shell.

Does Revdiff Plan access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Revdiff Plan safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Revdiff Plan use?

Revdiff Plan is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Revdiff Plan use?

About 1.6k tokens (SKILL.md is roughly 6.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Revdiff Plan?

Skills that share tags, products or a category with Revdiff Plan: Messages Ops (affaan-m/ECC, 274k stars), Commit Message Storyteller (github/awesome-copilot, 40k stars), Agent Messaging (davila7/claude-code-templates, 32k stars) and Plannotator Last Message (backnotprop/plannotator, 9.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Revdiff Plan?

umputun (a GitHub user) maintains it in umputun/revdiff, which has 916 GitHub stars. The repository holds 4 skills in this directory. The repository was last updated on October 7, 2026.

Source: umputun/revdiff on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.