commithink
commithink is an AI-powered CLI tool that generates clean, Conventional Commit messages by analyzing your staged Git changes.
It uses a local LLM via Ollama, works fully offline, and guides you through an interactive workflow so you always stay in control.
AI suggests. You decide.
Features
- AI-generated commit messages (local, via Ollama)
- Follows Conventional Commits
- Interactive mode (accept, regenerate, edit, change type)
- Uses staged changes (
git diff --cached) - No cloud APIs, no API keys
- Project-level configuration
- Fully offline
Requirements
- Python >= 3.10
- Git
- Ollama installed and running locally (ollama.com)
After installation, make sure Ollama is running and that you have at least one model available.
Installation
Recommended (pipx)
pipx installs CLI tools globally in isolated environments.
pipx install commithink
Alternative (pip)
python -m pip install commithink
Basic usage
Stage your changes as usual:
git add .
Then run:
commithink
commithink will analyze the staged diff and guide you through an interactive flow to produce the final commit message.
Interactive controls
| Key | Action |
|---|---|
a |
Accept and commit |
r |
Regenerate the message |
e |
Edit the message manually |
t |
Change commit type |
q |
Abort |
Passing a hint
You can optionally provide a short description of your changes:
commithink "fix validation on user registration"
This helps the model generate a more accurate message.
Dry run
To generate a commit message without committing:
commithink --dry-run
Configuration
commithink supports project-level configuration via a .commithink.toml file in the repository root.
Set configuration values
commithink --config model=qwen2.5-coder:3b
commithink --config language=english
This creates or updates the following file:
model = "qwen2.5-coder:3b"
language = "english"
Configuration precedence
- CLI options (
--model,--lang) .commithink.toml- Built-in defaults
Example output
fix: handle user registration errors correctly
Philosophy
commithink is designed to:
- reduce cognitive load
- improve commit quality
- keep the developer in control
AI assists — the final decision is always yours.
Metadata
Release files for commithink 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| commithink-0.1.3.tar.gz | 6.8 kB | Without provenance | Details for commithink-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| commithink-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for commithink-0.1.3-py3-none-any.whl |
Total release size: 14.8 kB
Release files / commithink-0.1.3.tar.gz
| Download URL | commithink-0.1.3.tar.gz |
|---|---|
| Size | 6.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9de7274e3910c9d7b03119825b0cb468fae9ced666be72e2cd6d6c024fd348e2
|
|
BLAKE2b-256 checksum How to use checksums |
6454c5a866c7a3e3cc59b9237e125c506c42e1809d6db2edb28410dac1b1dfc3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.3
|
Release files / commithink-0.1.3-py3-none-any.whl
| Download URL | commithink-0.1.3-py3-none-any.whl |
|---|---|
| Size | 8.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
51bef5c57b6c627926a5b2acf212e81600bf3957c58a4518fa69f96756041876
|
|
BLAKE2b-256 checksum How to use checksums |
4e045714bf3bef63bab9d2fdf75b1037a7a72a907029d000116066cd432fed81
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.3
|
Security for commithink 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.