Inspiration

What it does

git-audit

The missing history layer for AI-assisted development.

git-audit captures every prompt you send to Claude Code, links it to the code it produced, and generates structured audit cards for every function that changed — automatically, on every commit. The full decision history is committed alongside your code and shared with your entire team via git.


The Problem

AI coding tools generate code faster than teams can trust it. When Claude Code writes a function, the prompt that caused it, the design decisions it made, and the risks it introduced all disappear the moment the session ends.

Git saves what changed. It has no idea why.

This creates compounding problems across your entire workflow:

  • Code review — reviewers reverse-engineer intent from diffs with no context
  • Debugging — bugs in AI-generated code have no traceable decision history
  • Onboarding — new developers inherit functions with no explanation of why they work the way they do
  • Team collaboration — context lives in one developer's head and disappears when they're unavailable

How It Works

Every time you prompt Claude Code, git-audit captures it automatically as a prompt event via MCP. When you commit, the post-commit hook:

  1. Links the prompt to the commit hash
  2. Detects every function that changed at the line level
  3. Generates a structured audit card per function via Claude Code CLI (uses your existing Claude subscription — no separate API key required)
  4. Commits the audit cards alongside your code automatically

Your teammates pull the code — the full context comes with it.

Share this project:

Updates