AI-powered CLI that generates Conventional Commits messages from your staged git changes, using a locally-run language model via Ollama.
No data leaves your machine — the model runs locally.
- Reads your staged git diff and drafts a clear, conventionally-formatted commit message
- Runs entirely on a local LLM through Ollama (no API keys, no cloud calls)
- Interactive flow: accept, regenerate, or cancel each suggestion before committing
- Configurable model via a single environment variable
- Tested with a mocked git/HTTP test suite and a GitHub Actions CI/CD pipeline
- Python 3.12+
- Ollama installed and running
- A pulled model (default:
qwen2.5-coder:3b)
ollama pull qwen2.5-coder:3bpip install dboss-cliStage the changes you want to commit, then run:
git add .
dboss commitdboss will read your staged diff, send it to your local model, and suggest a commit message. You can then:
y— accept and commitr— regenerate a new suggestionn— cancel without committing
Example:
$ dboss commit
Suggested commit message:
feat: add user authentication flow
[y] accept [r] regenerate [n] cancel [y]:
By default, dboss uses the qwen2.5-coder:3b model. To use a different Ollama model, set the DBOSS_MODEL environment variable:
# macOS / Linux
export DBOSS_MODEL="llama3.2:3b"
# Windows (PowerShell)
$env:DBOSS_MODEL = "llama3.2:3b"Clone the repository and install with development dependencies:
git clone https://github.com/zeynepgunall/dboss-cli.git
cd dboss-cli
python -m venv .venv
# Activate the virtual environment, then:
pip install -e ".[dev]"Run the test suite:
pytestdboss commitrunsgit diff --stagedto capture your staged changes.- The diff is wrapped in a prompt instructing the model to produce a single Conventional Commits message.
- The prompt is sent to the local Ollama server (
http://localhost:11434). - The response is cleaned (stray code fences removed) and shown for your approval.
- On accept,
dbossrunsgit commitwith the generated message.
MIT