Skip to content
Documentation Overview

Getting started

AgentDiff Documentation

AgentDiff is a local-first runtime transaction system for AI-agent commands. It records what changed, evaluates every mutation against deterministic policy, explains the run's blast radius, and can selectively undo unchanged collateral.

Find anything quickly: press Ctrl K or / to open indexed documentation search. Use the arrow keys and Enter to open a result, or Escape to return to the page.

Capability boundary: the local runtime observes a subprocess; it is not a kernel sandbox. Use an explicit sandbox runtime when you need isolation or network enforcement. Read the trust model.

Start here

The transaction loop

1Capture

Build a no-follow filesystem manifest and record the runtime baseline.

2Execute

Launch the explicit argv under local observation or a selected sandbox backend.

3Evaluate

Diff state, apply policy, score blast radius, and persist an integrity manifest.

4Recover

Conflict-check current state before restoring or removing eligible collateral.

Feature status

Status Implemented surface
Beta Local transactions, policy, capsules, verification, scoring, regular-file recovery, evidence memory, and Cortex provider routing
Experimental srt adapter, MCP policy hook, LangChain callback, and legacy evaluator
Planned Published packages, authenticated capsules, telemetry export, and a maintained hosted sandbox integration

There is no HTTP server, hosted dashboard, Docker backend, bundled sandbox, or claimed PyPI release.

A complete local run

The following shape is taken from a real repository run. AgentDiff reported a successful process exit, but denied the transaction because it created a protected environment file.

agentdiff run \
  --task "Update the parser" \
  -- python3 agent_task.py
Task completed

Expected changes:   1
Unexpected changes: 1
Protected changes:  1

Blast Radius: CRITICAL (81/100)
Recovery available: YES
Policy outcome: DENY

Status: denied (deny)
Mutations: 3
  deny   created  .env
  review created  pyproject.toml
  allow  created  src/parser.py
agentdiff inspect <run-id>
agentdiff verify <run-id>
Status: denied (deny)
Blast radius: 81/100
Capsule integrity: true
agentdiff rollback <run-id> --safe-only
Actions: 2
  removed  .env
  removed  pyproject.toml
Conflicts: 0
Skipped: 1

Choose your next path