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. When files change outside the editor, 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
- A notification appears when a session is ready. Click Review.
- The Diffward Sessions view in Source Control lists recent sessions.
- The status bar shows how many changes are waiting.
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 it reads
the request from Claude Code's local transcripts.
Settings
| Setting |
Default |
|
diffward.sessionIdleTimeoutMs |
20000 |
Quiet time before a session ends. Agents pause while thinking. |
diffward.readAgentTranscripts |
true |
Read Claude Code transcripts for your request and the files its edit tools wrote. Read-only, local. |
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.
| |