Generate changelog using Git Commits and AI with single Python script (github.com)

🤖 AI Summary
A single-file Python tool (genlog.py) has been released to automatically generate professional changelogs from Git commits using OpenAI-compatible LLMs. Run in a repository root, the script detects the range of new commits since the last changelog, extracts commit metadata (hash, message, author), calls a configured LLM (e.g., gpt-4o-mini or other GPT models/Azure/self-hosted endpoints) and writes a categorized, style-consistent changelog (Features, Fixes, Improvements, etc.) as changelog/YYYYMMDD-COMMITHASH.md. It’s cross-platform, requires only python3 and git (standard library only), supports incremental generation (only new commits), and can be added to CI workflows like GitHub Actions. Required env variables: LLM_API_HOST, LLM_API_KEY, LLM_API_MODEL. For the AI/ML community this streamlines release notes and helps maintain consistent, high-quality documentation using LLMs—saving time on manual curation and enabling reproducible formatting by referencing previous changelogs. Key technical implications: model choice and temperature affect output quality (script modifiable), commit data and messages are sent to the LLM so use of self-hosted or privacy-preserving endpoints is supported, and the tool outputs deterministic filenames with commit hashes for traceability. The project is Apache-2.0 licensed, includes basic error guidance (missing env vars, not a git repo, API failures), and welcomes contributions.
Loading comments...
loading comments...