Catalog PyPI
PACKAGE EXPLORERView in registry

ai-git-guardian

PyPI

An AI-powered Git pre-commit hook using Ollama to review code.

aicodereviewgithookllmollama
Versions collected1
Direct dependencies3From release 0.1.0
Last observed21 Oct, 10:49 UTC

README

Version 0.1.0 documentation

🤖 Git Guardian AI

An intelligent Git pre-commit hook that uses a local Ollama LLM to automatically review your code changes before you commit them.

Features

  • Automated Code Review: Catches potential bugs, security flaws, and performance issues.
  • Local & Private: Uses your own Ollama instance, so your code never leaves your machine.
  • Configurable: Easily configure the model, blocking rules, and ignored files.
  • Easy Installation: Get started in any Git repository with two commands.

Installation

You need to have a running Ollama instance with a model pulled (e.g., ollama pull codellama:latest).

Install the package using pip:

pip install git-guardian-ai

Usage

Navigate to your Git repository:

cd /path/to/your/project

Run the install command: This sets up the pre-commit hook in your repository's .git folder.

guardian install

(Optional) Configure Guardian: Create a .guardian.toml file in the root of your repository to customize the settings.

# .guardian.toml
model = "llama3:8b"
block_on = ["security", "logic"]
warn_on = ["performance", "style"]

Now, whenever you run git commit, the Guardian will automatically analyze your staged changes!

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Versions 1

Collected releases
VersionPublishedDirect dependenciesOpen version
0.1.04 Oct 20253

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
nirav0702/git-guardian

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 10:49 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:0f042d4086ccebb5142b880a65e18807da256667519a355edec8bde1679df173