Runs locally Β· no telemetry Β· MIT

AgentLedger

The trust layer for AI coding agents

Claude says done. AgentLedger checks β€” against real exit codes, not self-reports.

agentledger β€” catching a false completion claim
AgentLedger blocking a protected-file write and falsifying a 'tests pass' claim in Claude Code

A protected-file write blocked before disk, and a β€œtests pass” claim caught against a non-zero exit code.

One install. Every session observed.

Two lines inside Claude Code β€” or the same install from your terminal.

Claude Code
/plugin marketplace add aryansahni30/AgentLedger /plugin install agentledger@agentledger
Terminal
$ claude plugin marketplace add aryansahni30/AgentLedger $ claude plugin install agentledger@agentledger
npm
$ npm install -g agentledger-plugin

Either plugin command wires all five hooks automatically β€” no settings.json editing. The ledger is created on first run and every session is scored from then on. The npm package is what the marketplace installs; pulling it directly only places the files on disk β€” run the plugin command to register the hooks.

Claim verification

Completion claims β€” β€œtests pass,” β€œfixed the bug” β€” are checked against the real test command’s exit code. The agent’s word is logged, never trusted.

Boundary enforcement

Writes to protected paths β€” .env, keys, secrets β€” are blocked before they ever touch disk, and the denial is recorded.

Hash-chained ledger

Every action lands in an append-only, SHA-256 hash-chained log β€” reads, edits, blocked writes, verified and falsified claims. The chain breaks if anyone tampers.

SessionStart Setup Creates .agentledger/, validates the chain, prints the trust banner, starts the local dashboard.
PreToolUse Prevent Blocks Edit/Write to protected paths before disk (exit code 2); warns on sensitive ones.
PostToolUse Record Records each Edit/Write/Bash/Read to the ledger and tracks the read:edit ratio.
Stop Verify Scans the turn for a completion claim; on a hit, runs the real test command β†’ verified or falsified.
SessionEnd Detect git diff boundary check + test run; writes the session summary and updates the trust score.
Prevention before disk Β· detection & verification after β†’ SHA-256 chained Β· .agentledger/ledger.jsonl