CommitIA is a command-line tool built in Go that leverages Large Language Models (LLMs) to analyze your Git code changes and automatically generate semantic commit messages.
- 🤖 Automatic commit message generation
- 🌐 Support for both local and remote LLM processing
- 🔄 Easy configuration management
- 🌍 Multi-language commit message support
- 🏷️ Custom commit tag selection
- Go 1.24 or higher
- Docker (optional, for local LLM mode)
If you encounter build errors during installation, you may need to install additional development packages:
Windows
-
Install Scoop package manager (in PowerShell):
Set-ExecutionPolicy RemoteSigned -scope CurrentUser iwr -useb get.scoop.sh | iex
-
Install required dependencies:
scoop install mingw
Ubuntu/Debian-based Systems
sudo apt update
sudo apt install -y \
gcc \
libc6-dev \
libx11-dev \
xorg-dev \
libxtst-dev \
libpng-dev \
libxcursor-dev \
libxrandr-dev \
libxinerama-dev \
libdbus-1-dev \
tesseract-ocr
Arch Linux/Manjaro
sudo pacman -Syu
sudo pacman -S --needed \
gcc \
glibc \
libx11 \
xorg-server-devel \
libxtst \
libpng \
libxcursor \
libxrandr \
libxinerama \
dbus \
tesseract
-
Clone the repository:
git clone https://github.com/HublastX/Commit-IA cd Commit-IA
-
Make the installer executable and run it:
chmod +x ./install.sh ./install.sh
-
Clone the repository:
git clone https://github.com/HublastX/Commit-IA cd Commit-IA
-
Run the installer:
.\install.bat
The binary will be compiled and installed, making commitia
available from anywhere in your system.
After using git add
to stage your changes, you can use CommitIA to generate commit messages.
commitia
CommitIA offers two operating modes:
- Remote Web Mode - Access LLMs remotely without additional configuration (might be slower)
- Local Mode - Run the LLM API locally using Docker (requires provider configuration)
To switch between modes or update configuration:
commitia --update
Option | Description | Example |
---|---|---|
-d |
Add additional context | commitia -d "Added login functionality" |
-l |
Specify commit language | commitia -l "English" |
-t |
Force specific commit tag | commitia -t "feat" |
--update |
Update configuration or switch modes | commitia --update |
Generate a commit with additional context:
commitia -d "Created user login feature with OAuth support"
Generate a commit message in English:
commitia -l "English"
Force a specific commit tag:
commitia -t "feat"
Update configuration or switch between local and web modes:
commitia --update
When selecting the Local mode, follow these steps:
- Select your LLM
provider
(Google, OpenAI, etc.) - Choose an available
model
for your selected provider - Enter your
API key
for the chosen provider - Start the local API server using Docker:
docker compose up --build
The local API server will run on port 6013 by default.
- Web mode uses Google's
gemini-flash-2
model by default - All LLM configurations are stored in the
Bot
directory - Custom configurations (provider, model, API token) are managed in
Bot/config/config.json
Contributions are welcome! Feel free to open issues or submit pull requests.
We recommend using Husky for commit validation:
- Ensure Node.js 22 is installed
- Run
npm install
to set up Husky, which will validate your commits before submission
This project is licensed under the Apache-2.0 license.