Diffward
Beta. Diffward is in early testing. Attribution and the "didn't ask about" check
are still being measured, so double-check anything that matters.
Review what your coding agent actually changed — per hunk, with attribution.
Agents write faster than anyone can read. You asked for one thing; twelve files
changed. Somewhere in there is the fix you wanted, and somewhere in there is the
config you didn't. Diffward knows what the agent touched, what you touched, and what
nobody asked for, and lets you keep or throw away each change.
Works with any agent that writes to disk — Claude Code, Codex, Antigravity CLI, OpenCode,
Cursor. No prompt box, no model of its own, no lock-in.
How it works
- Sessions start on their own. Agent lifecycle events or files changing outside the editor make Diffward
snapshots the working tree into
refs/diffward/ (never your index, stash, or
branch) and waits for the agent to go quiet.
- Every hunk gets an origin.
agent, human, or unknown. Diffward records what
you save as line hashes, so anything you didn't write came from somewhere else. When
it can't tell, it says unknown instead of guessing.
- Surprises come first. Files you didn't ask about — CI config, lockfiles, an
unrelated module — are grouped at the top, then high-risk changes: dependencies,
auth, deletions, migrations, code without tests. Formatting-only hunks are folded away.
- Ward or discard, hunk by hunk. Ward keeps a change. Discard reverts it in your
working tree. Undo puts it back. Decisions survive restarts and carry over when the
agent produces the same change again.
- It notices lost work. If the agent overwrote lines you wrote during the session,
you get a warning naming the file.
Using it
- Click the Diffward icon in the activity bar to see every recent session, whenever
you want. Its badge counts the changes still waiting for a decision.
- A notification also appears when a session is ready. Click Review.
- The status bar shows the same count.
In a file, the gutter marks the current session's hunks by who wrote them, and each one
carries Ward / Discard actions. alt+] and alt+[ walk the unreviewed hunks
across the whole session, including files you haven't opened.
In the review panel:
| Key |
Action |
j / k |
Next / previous hunk |
w |
Ward |
d |
Discard |
u |
Undo |
o |
Open in the diff editor |
space |
Expand a folded hunk |
f |
Show formatting-only changes |
Say what you asked for. If Diffward doesn't know the request, add it at the top of
the panel; it re-checks which files you didn't ask about. With Claude Code, Codex,
Antigravity, and OpenCode it reads the request from local session data.
Settings
| Setting |
Default |
|
diffward.sessionIdleTimeoutMs |
20000 |
Quiet time before an unrecognized agent session ends. Recognized active turns ignore this timer. |
diffward.readAgentTranscripts |
true |
Read local Claude Code, Codex, Antigravity, and OpenCode session data for requests, edit tools, and turn boundaries. |
diffward.antigravityBrainPath |
empty |
Override Antigravity's conversation brain directory. |
diffward.openCodeDatabasePath |
empty |
Override OpenCode's database path when OPENCODE_DB or the default location is not used. |
diffward.collateralModel |
off |
vscode uses a chat model you already have in VS Code; anthropic calls the Anthropic API. Both send your request and short excerpts of changed files. |
diffward.anthropicModel |
claude-opus-5 |
Model used when collateralModel is anthropic. |
diffward.notifyOnSessionEnd |
true |
Notification when a session is ready. |
Set an API key with Diffward: Set Anthropic API Key; it's kept in VS Code's secret
storage. ANTHROPIC_API_KEY also works.
Limits
- Git repositories, single-root workspaces, local agents. No merge-conflict states.
- Gitignored files aren't snapshotted. Writes to ignored secret files (
.env, keys)
during a session are listed, but their contents can't be shown or discarded.
- Discarding needs the file saved; files with unsaved changes are left alone.
- Attribution and the "didn't ask about" split are heuristics under evaluation. Treat
unknown as a real answer.
| |