aGiTrack

<aGiTrack> every agent turn, committed with its story

aGiTrack wraps Claude Code and OpenCode with Git. You use the agent's own TUI exactly as before. aGiTrack watches the session and turns every completed turn into a commit carrying the full interaction trace, the model, and the token bill.

f3a9c2e <aGiTrack> show, don't tell
agitrack · claude · session-1 → main
$ agitrack
┌ claude · session-1 ──────────────────────────────────┐
> add a --version flag to the cli
  · editing agitrack/cli.py …
  · added --version using importlib.metadata
└──────────────────────────────────────────────────────┘
✓ Created <aGiTrack> commit 4b2f31a.            aGiTrack · Ctrl-G
$ git log --oneline -2
4b2f31a <aGiTrack> add a --version flag to the cli
a91c07e Initial commit
$ git show 4b2f31a --stat
<aGiTrack> add a --version flag to the cli
 agitrack/cli.py | 6 ++++++  trace + model + token cost in the body ↓
9d04e17 why this exists

Agent code without provenance is unreviewable.

A coding agent edits twelve files while you get coffee. A week later nobody can say which prompt produced which change, what the model was told, or what it cost. aGiTrack makes the unit of agent work a commit, so review, blame, bisect, and revert work on agent output the same way they work on yours.

git show: an aGiTrack commit message
<aGiTrack> add a --version flag to the cli

# Interaction Trace

## User
add a --version flag to the cli

## Agent
Added --version using the package metadata; prints and exits.

# aGiTrack Metadata
commit_type: agent
backend: claude
model: claude-opus-4-8
session_name: session-1
context_tokens: 18204
tokens_since_last_commit_input: 411
tokens_since_last_commit_output: 2390
71c5b9a how it works

Your branch only ever moves by merge.

Each session runs in its own git worktree on its own branch, so concurrent sessions never stomp each other or your working tree. Finished turns integrate back into the branch you launched from; conflicts are handed to the agent to resolve, and the resolution is itself a traceable <aGiTrack-merge> commit.

Isolated sessions

One worktree per session, per-turn branches, automatic recovery of anything a crash leaves behind. Run several agents side by side.

Backend-native

No model API keys, no proxy of your tokens. aGiTrack drives the real Claude Code / OpenCode TUI and reads the session's own transcript for the facts.

Costs on the record

Input, output, and cache token counts per commit, straight from the backend's session record: a price tag on every change.

b7e1d09 <aGiTrack> see the whole repo at a glance

A live dashboard of what the agents did.

Run agit -d and aGiTrack serves a live, auto-refreshing dashboard on localhost and opens it in your browser. Every number is computed from commit metadata alone, so it's identical on every clone — no database, no tracking server.

agitrack -d · localhost
The aGiTrack dashboard: coverage, aGiTrack-tracked AI vs non-tracked lines, token totals, and per-backend / model / committer breakdowns, in a CRT terminal theme.

Honest provenance

Lines aGiTrack tracked as the agent's, versus everything else — it never claims a human wrote what the model did, even when a person made the commit.

Filter live

Narrow the whole dashboard to one committer (merged to their GitHub ID), a backend, a model, or a time range — recomputed instantly in the browser.

Cost & drill-down

Token totals and an efficiency ratio, a heads-up when a conversation loops, and a commit log you can click to read the full message and jump to the commit on GitHub.

agitrack -d
serves on localhost and opens your browser; press Ctrl-C to stop
agitrack -d text
prints a one-shot plain-text report instead — handy for piping or pasting into an issue
e8d2fa0 install & run

Three commands to the first traced commit.

pip install agitrack
Python ≥ 3.10 · to contribute, clone the repo and pip install -e .
cd your-repo && agitrack
launches your default backend's TUI (Claude Code or OpenCode) under aGiTrack's watch
Ctrl-G
opens the aGiTrack menu: sessions, backends, staging, user commits, base branch

Prompt the agent as usual. When the turn settles, the commit is already there. git log tells the rest.

HEAD <aGiTrack> your move

Put your agents on the record.

Apache-2.0. Issues, ideas, and first contributions welcome. The issue tracker has good first issue tags waiting.