Skip to main content

Add your description here

Project description

gut 🫀

Trust your guts on git — An AI-powered CLI tool that executes git and gh commands from natural language queries.

Transform commands like "add all my changes and commit with a meaningful message" into the exact git commands you need, with AI-powered intelligence and human-in-the-loop validation.

✨ Features

  • 🤖 Natural Language Processing: Describe what you want to do in plain English
  • 🔄 Human-in-the-Loop: Review and approve commands before execution
  • 🎯 Smart Command Selection: Automatically chooses between git and gh commands
  • 📖 Command Explanation: Get clear explanations of what each command does
  • 🎨 Rich Console Interface: Beautiful terminal experience with syntax highlighting

🚀 Quick Start

Installation

Install gut using pip:

pip install gut-ai

Setup

  1. Get a Groq API key
  2. Set your API key as an environment variable:
export GROQ_API_KEY="your_api_key_here"

Or create a .env file in your project directory:

GROQ_API_KEY=your_api_key_here

Usage

Simply run gut and describe what you want to do:

gut-ai

Example interactions:

  • "Add all my current changes to git"
  • "Create a new branch called feature/login"
  • "Push my changes to origin"
  • "Create a pull request"

🔧 Development Setup

Prerequisites

  • uv package manager

Clone and Install

git clone https://github.com/AstraBert/gut
cd gut/
uv sync

Run from Source

uvx --from . gut-ai

🛠️ How It Works

gut uses an AI-powered workflow built with llama-index-workflows that follows these steps:

  1. Command Analysis: Analyzes your natural language input to understand intent
  2. Command Selection: Chooses between git and gh based on your requirements
  3. Parameter Mapping: Determines the specific subcommands and options needed
  4. Explanation Generation: Creates a clear explanation of what the command will do
  5. Human Validation: Shows you the command and explanation for approval
  6. Execution: Runs the command if approved, or restarts the process with your feedback

The entire experience runs in a beautiful Rich console interface with structured inputs and outputs using Pydantic models.

📋 Requirements

  • Groq API Key: Required for AI functionality
  • Git: Must be installed and configured
  • GitHub CLI (optional): Required only for GitHub-related commands (gh)

🤝 Contributing

We welcome contributions! Please read our Contributing Guide to get started.

📄 License

This project is licensed under the MIT License.

🙋‍♀️ Support


Made with ❤️ for developers who want to git things done faster

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gut_ai-0.2.0.tar.gz (72.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gut_ai-0.2.0-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file gut_ai-0.2.0.tar.gz.

File metadata

  • Download URL: gut_ai-0.2.0.tar.gz
  • Upload date:
  • Size: 72.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.0

File hashes

Hashes for gut_ai-0.2.0.tar.gz
Algorithm Hash digest
SHA256 65466d21fe08fb301f656552798098d70e0025af6000fc0c9ee9a841c1cc258d
MD5 206c99cb4b383b8701221d42741d0033
BLAKE2b-256 001a6e4821faef5e84c4592c1d1fdfd173bf19bfbcaebcd4c978fad3c0e64456

See more details on using hashes here.

File details

Details for the file gut_ai-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: gut_ai-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 10.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.0

File hashes

Hashes for gut_ai-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6ce2e51d0697618298e726ad0913dc16c0328593510d235cbd8698af860ef7fb
MD5 9f22f5bfdec9459122cd1fdd515024bf
BLAKE2b-256 a9b0cd63b0b31af2634b1e8e2f282be512223172ce8b4603b6b7a701adca0875

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page