A Commitizen plugin that leverages OpenAI's GPT-4o to automatically generate clear, concise, and conventional commit messages based on your staged git changes.
Project description
🤖 AI Commitizen Plugin
A Commitizen plugin that leverages OpenAI's GPT-4o to automatically generate clear, concise, and conventional commit messages based on your staged git changes.
Features
- Analyzes your staged diffs using OpenAI GPT-4o
- Generates commit messages that follow the Conventional Commits specification
- Suggests high-quality messages instantly to save time
- Seamlessly integrates with existing Commitizen workflows
- Choose your preferred OpenAI model (gpt-4o-mini, gpt-4o, etc.)
Prerequisites
- Python 3.x
- Install commitizen
Install
pip install cz-ai
Usage
cz --name cz_ai commit
Terminal Alias
To make it persistent across sessions, add this line to your ~/.bashrc or
~/.bash_profile or /.config/fish/config.fish or ~/.zshrc (depending on your setup):
alias gai='cz --name cz_ai commit'
Development
Install the plugin locally:
pip install -e .
Then check that cz recognizes the plugin:
cz ls
It should appear as cz_ai
Then run this command to test it:
cz commit
Build
python3 -m build
Upload to pypi.org
twine upload dist/*
Author
Adrian C (watadarkstar)
Credits
Generated using this template: https://github.com/commitizen-tools/commitizen_cz_template
📄 License
This project is licensed under the MIT License.
Feel free to use, modify, and distribute it as needed.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file cz_ai-0.7.4.tar.gz.
File metadata
- Download URL: cz_ai-0.7.4.tar.gz
- Upload date:
- Size: 4.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2900c9b626f84e1962699173c7b9a2ffd9acac2b6d560ce92bc42413f8d402f4
|
|
| MD5 |
e07fa596ae82d84a38418b3844c4df54
|
|
| BLAKE2b-256 |
de0980056e9fc24b9fa2ea5a2387c062c8f2f424096f52423e4c02f1b9f2c756
|
Provenance
The following attestation bundles were made for cz_ai-0.7.4.tar.gz:
Publisher:
ci.yml on watadarkstar/cz_ai
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
cz_ai-0.7.4.tar.gz -
Subject digest:
2900c9b626f84e1962699173c7b9a2ffd9acac2b6d560ce92bc42413f8d402f4 - Sigstore transparency entry: 234546131
- Sigstore integration time:
-
Permalink:
watadarkstar/cz_ai@e17f9eb9c6bfa37e6226eb4446209c16b74da695 -
Branch / Tag:
refs/tags/0.7.4 - Owner: https://github.com/watadarkstar
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
ci.yml@e17f9eb9c6bfa37e6226eb4446209c16b74da695 -
Trigger Event:
push
-
Statement type:
File details
Details for the file cz_ai-0.7.4-py3-none-any.whl.
File metadata
- Download URL: cz_ai-0.7.4-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d95759826a3987703ef7fcc4483200b0c2d800e1e673084e43a05a4937e7dba3
|
|
| MD5 |
bdd84eb9846d4a2518d21562d76c036d
|
|
| BLAKE2b-256 |
c440a454b8f546709f25353c26e15869356d215e4f7afa05b454ced983ca1932
|
Provenance
The following attestation bundles were made for cz_ai-0.7.4-py3-none-any.whl:
Publisher:
ci.yml on watadarkstar/cz_ai
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
cz_ai-0.7.4-py3-none-any.whl -
Subject digest:
d95759826a3987703ef7fcc4483200b0c2d800e1e673084e43a05a4937e7dba3 - Sigstore transparency entry: 234546133
- Sigstore integration time:
-
Permalink:
watadarkstar/cz_ai@e17f9eb9c6bfa37e6226eb4446209c16b74da695 -
Branch / Tag:
refs/tags/0.7.4 - Owner: https://github.com/watadarkstar
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
ci.yml@e17f9eb9c6bfa37e6226eb4446209c16b74da695 -
Trigger Event:
push
-
Statement type: