← all repositories
git-ai-project/git-ai

Where 'git blame' meets 'Claude did it'

It exists to preserve the intent, requirements, and transcripts behind every line of AI-generated code.

git-ai
Velocity · 7d
+8.7
★ / day
Trend
accelerating
star history

What it does Git AI is a Rust-based Git extension that hooks into supported coding agents—Claude Code, Cursor, Copilot, Codex, and roughly a dozen others—to record exactly which lines they wrote. It stores attribution in Git Notes and links each line back to the model, session, and original prompt transcript, all without altering your normal commit workflow.

The interesting bit Instead of trying to “detect” AI code after the fact—a practice the authors rightly call an anti-pattern—it relies on agents self-reporting their edits via hooks. This means the attribution is precise rather than guessed, and the /ask skill lets you interrogate the original transcript later to understand architectural decisions instead of reverse-engineering intent from the diff.

Key highlights

  • Line-level attribution via git ai blame, a drop-in replacement for git blame that tags the agent and model per line.
  • Runs fully offline with local SQLite storage; optional cloud or self-hosted transcript store for teams with access control and PII filtering.
  • JSON-exportable stats (git ai stats) breaking down human vs. AI additions, acceptance rates, and model-specific contributions across commits.
  • IDE plugins for VS Code, Cursor, Windsurf, and Emacs magit color-code AI authorship in the gutter.
  • Supports an open standard for AI authorship using Git Notes, so transcripts stay out of the repo itself.

Caveats

  • Non-WSL Windows support is currently experimental and under active development.
  • Unsupported agents do not report authorship, so mixed human/AI workflows with unhooked editors will have gaps.

Verdict Worth a look if you are already using Claude Code, Cursor, or similar agents and want auditability without changing your workflow. If you write everything by hand or use unsupported editors, there is nothing here to track.

Frequently asked

What is git-ai-project/git-ai?
It exists to preserve the intent, requirements, and transcripts behind every line of AI-generated code.
Is git-ai open source?
Yes — git-ai-project/git-ai is open source, released under the Apache-2.0 license.
What language is git-ai written in?
git-ai-project/git-ai is primarily written in Rust.
How popular is git-ai?
git-ai-project/git-ai has 2.3k stars on GitHub and is currently accelerating.
Where can I find git-ai?
git-ai-project/git-ai is on GitHub at https://github.com/git-ai-project/git-ai.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.