Git commit messages written by AI, because 'WIP' isn't a verb
A Go CLI that reads your git diff and asks an LLM to write the commit message for you, optionally hooking into git so you never stare at a blank editor again.

What it does
CodeGPT is a Go CLI that generates git commit messages from your staged diff using an LLM. It can also spit out a brief code review summary. Run it manually or install a prepare-commit-msg hook so every commit gets an AI-written first draft automatically.
The interesting bit
The project is less about novelty and more about plumbing: it supports seven different AI backends (OpenAI, Azure, Gemini, Anthropic, Groq, Ollama, OpenRouter) and lets you customize prompt templates, diff context lines, and output language. The api_key_helper option is a nice touch for secret-manager users — it runs a shell command to fetch credentials dynamically instead of leaving keys on disk.
Key highlights
- Formats commits to the conventional commits spec by default
- Hooks into git via
prepare-commit-msgwithcodegpt hook install/uninstall - Supports SOCKS/HTTP proxies, streaming output, and per-repo file exclusion from diffs
- Config lives in
~/.config/codegpt/.codegpt.yaml; override via env vars or CLI flags - Available via Homebrew, Chocolatey, install script,
go install, or VSCode devcontainer feature
Caveats
- The README mentions
gpt-5in one place, which does not exist; the default model isgpt-4o - Token costs can add up if you commit frequently with large diffs and don’t cap
max_tokens
Verdict
Worth a look if you write a lot of commits and hate blank-message paralysis. Skip it if you already have strong commit discipline or don’t want API keys near your git workflow.