git-gen
Generate git commit message with a local LLM, which has been fine-tuned on 300K high-quality Python commits and is able to analyze the purposes of the changes
Installation
Required Python 3.10+
To install this package, run:
pip install git-gen
Uses
To generate git commit message in current working directory, run:
git-gen
Generate with custom config:
git-gen --temperature 0.2 --top_k 50 --top_p 0.7
To get all command options, run:
git-gen -h
which should output
Usage: [OPTIONS]
Options:
--path PATH Path to the project, which should contain a '.git' folder. Default to current working directory.
--max_tokens INTEGER RANGE The maximum numbers of tokens to generate. [default: 1024; x>=1]
--temperature FLOAT RANGE Control the overall probabilities of the generation. Prefer lower temperature for higher accuracy and higher temperature for
more varied outputs. [default: 0.7; x>0]
--top_k INTEGER RANGE Limit the number of vocabs to consider. [default: 20; x>=1]
--top_p FLOAT RANGE Limit the set of vocabs by cumulative probability. [default: 0.8; 0<x<=1]
-h, --help Show this message and exit.
FAQ
There are a lot of similar projects. Why would I use this?
A good commit message should reflect the purpose of the changes made concisely. Most LLMs failed to do that at zero-shot learning. This project aims to generate messages that focus on the "why" instead of "what", by using a fine-tuned model on 300K high-quality Python commits.
Moreover, it only uses local LLM. You code is safe from the internet.
License
git-gen is distributed under the terms of the MIT license.
Notes
Build and push project
python -m pip install --upgrade build
python -m build
python -m pip install --upgrade twine
python -m twine upload --repository pypi dist/* --verbose
Metadata
Release files for git-gen-utils 0.0.1
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 |
|---|---|---|---|---|
| git_gen_utils-0.0.1.tar.gz | 7.6 kB | Without provenance | Details for git_gen_utils-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| git_gen_utils-0.0.1-py3-none-any.whl | Python 3 | none | any | Details for git_gen_utils-0.0.1-py3-none-any.whl |
Total release size: 15.2 kB
Release files / git_gen_utils-0.0.1.tar.gz
| Download URL | git_gen_utils-0.0.1.tar.gz |
|---|---|
| Size | 7.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6f458f6a737f41cfafeb702321c47460e379ce5117d9ad84403b9baac04c3b44
|
|
BLAKE2b-256 checksum How to use checksums |
9704480ac85b02fcdb9cfa8ebadc2e39c94d9873b335dc757742b1fe186df10e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.11
|
Release files / git_gen_utils-0.0.1-py3-none-any.whl
| Download URL | git_gen_utils-0.0.1-py3-none-any.whl |
|---|---|
| Size | 7.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9d3596b75d644a605e4dff8be40706ca92dab8b521fe571c6f288bac13eb1632
|
|
BLAKE2b-256 checksum How to use checksums |
c9134087e3a8eeb7f41c89c4345499fc850f8761e8999a9247072aea9d0c0a55
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.10.11
|
Security for git-gen-utils 0.0.1
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.