Revdiff: Terminal Diff Viewer with Inline Annotations for AI Agents

What Revdiff Does
Revdiff is a terminal user interface (TUI) diff viewer designed for a specific workflow: reviewing AI-generated code changes without leaving the terminal session where the AI agent runs. The tool allows you to annotate lines, hunks, or files and feed those annotations straight back to the AI agent for processing.
Core Workflow
From a Claude Code session, you can type /revdiff main or say "review diff for last 3 commits" to open revdiff as a terminal overlay on top of the agent session. After reading the diff and dropping annotations, you quit, and the annotations go straight back to the agent. When the agent finishes making changes, revdiff reopens on the new changes automatically, creating a continuous loop until you quit without leaving annotations.
Planning Integration
A separate revdiff-planning plugin hooks into Claude Code's plan mode. When the agent finishes a plan and calls ExitPlanMode, revdiff opens automatically on the plan text. You can annotate parts you disagree with or want expanded, quit, and the agent revises the plan before writing any code.
Key Features
- Two-pane TUI: file tree on the left, syntax-highlighted diff on the right
- Vim-style navigation with /search, hunk jumping, and word-level change highlighting
- Blame gutters showing author name and commit age per line
- Collapsed diff mode showing final text with change markers
- Word wrap mode with continuation markers
- Horizontal scroll overflow indicators with « / » markers
- Line numbers with side-by-side old/new gutters for diffs
- Mercurial support with auto-detection and git-style ref translation
- Single-file auto-detection that hides tree pane for full-width diff view
- Annotation list popup to browse all annotations across files
- Status line with filename, diff stats, hunk position, and mode indicators
- Help overlay showing all keybindings organized by section
- Markdown TOC navigation for single-file markdown files
- All-files mode to browse and annotate all git-tracked files
- No-git file review for files outside repositories
- Scratch-buffer review for arbitrary piped or redirected text
- Review history auto-saved to ~/.config/revdiff/history/
Customization
Revdiff offers 7 bundled color themes, remappable keybindings, and per-color overrides via CLI flags, environment variables, or config file. You can export default keybindings with --dump-keys.
Installation and Usage
Install via Homebrew: brew install umputun/apps/revdiff. The tool is a single binary - just run revdiff HEAD~3 to review your last 3 commits. It works with git and Mercurial repositories.
Plugin Support
Ready-to-use plugins are available for Claude Code (terminal overlay via tmux, Zellij, kitty, wezterm, Kaku, cmux, ghostty, iTerm2, or Emacs vterm), Codex, and pi. The Claude Code plugin requires one of the supported terminals since Claude Code itself cannot display interactive TUI applications.
Technical Details
Written in Go and open source under MIT license. Requires git or hg for generating diffs (optional when using --only or --stdin).
📖 Read the full source: HN AI Agents
👀 See Also

Chapper: Native iOS Client for LM Studio, Ollama, and OpenAI-Compatible Local Models
Chapper is a native SwiftUI iOS app that connects to LM Studio, Ollama, and OpenAI-compatible local models without cloud services or accounts. It offers real-time token streaming, full sampling controls, reasoning model support with <think> tags, and export in 7 formats.
MTP + Unified Memory Boosts llama.cpp Inference 30% on RTX 5090
Enabling MTP speculation alongside GGML_CUDA_ENABLE_UNIFIED_MEMORY=1 pushes Qwen3.6-27B Q8_0 from 49 to 64 tok/sec on an RTX 5090 with 128GB system RAM.

TruthGuard: Shell Script Hooks That Catch AI Coding Agent Lies
TruthGuard is an open-source tool that uses shell script hooks to verify what Claude Code and Gemini CLI actually do versus what they claim. It catches phantom edits, exit code lies, dangerous shortcuts, and blocks commits when tests fail.

A System for Claude Code to Learn Your Project Over Time
A developer created a simple setup to help Claude Code retain context between sessions by adding a CLAUDE.md file, a docs folder with project conventions, and three prompts for bootstrapping, refining, and capturing patterns.