A command-line tool that uses a local or remote LLM to automatically generate meaningful commit messages from git diffs.
- Optionally can use local LLM (deepseek-r1:7b) through Ollama for privacy and speed. OpenAI models are also supported.
- Generates concise, meaningful commit messages
- Easy to integrate with existing git workflows
- Can set up with no external API dependencies
Before you begin, ensure you have the following installed:
- Python 3.11 or higher
- Git
- Ollama
- Clone the repository:
git clone https://github.com/your-username/commitry-cli.git
cd commitry-cli- Create and activate a virtual environment:
python -m venv venv
source venv/bin/activate- Install the dependencies:
pip install -r requirements.txt- Install the package in development mode:
pip install -e .- Install the required Ollama model:
ollama pull deepseek-r1:7b- Ensure Ollama is running:
ollama serve- The tool will automatically connect to Ollama at
http://localhost:11434/v1
- Make a change to your codebase
- Stage your changes with
git add - Run
commitry-clito proces the staged changes and generate a commit message (this will rungit diffand pass the diff to the LLM). You may need to add it to your path. - Commit your changes with the generated message
Feedback and contributions are welcome! Please feel free to submit a PR.
This project is open-sourced under the MIT License - see the LICENSE file for details.