đ CodeTrans Model for Git Commit Message Generation
A pre - trained model on git commit using the T5 base model architecture, designed to generate accurate git commit messages.
đ Quick Start
This CodeTrans model is a pre - trained model on git commit, utilizing the t5 - base
model architecture. It was first released in this repository. This model is trained on tokenized git commits and performs best with such input.
⨠Features
- Based on the
t5 - base
model with its own SentencePiece vocabulary model.
- Trained using single - task training on the Git Commit Message Generation dataset.
- Can generate git commit messages for commit changes and be fine - tuned on other relevant tasks.
- Can handle unparsed and untokenized commit changes, but performs better with tokenized input.
đĻ Installation
No specific installation steps are provided in the original README.
đģ Usage Examples
Basic Usage
Here is how to use this model to generate git commit messages using the Transformers SummarizationPipeline:
from transformers import AutoTokenizer, AutoModelWithLMHead, SummarizationPipeline
pipeline = SummarizationPipeline(
model=AutoModelWithLMHead.from_pretrained("SEBIS/code_trans_t5_base_commit_generation"),
tokenizer=AutoTokenizer.from_pretrained("SEBIS/code_trans_t5_base_commit_generation", skip_special_tokens=True),
device=0
)
tokenized_code = "new file mode 100644 index 000000000 . . 892fda21b Binary files / dev / null and b / src / plugins / gateway / lib / joscar . jar differ"
pipeline([tokenized_code])
You can run this example in colab notebook.
đ Documentation
Model Description
This CodeTrans model is based on the t5 - base
model. It has its own SentencePiece vocabulary model and was trained using single - task training on the Git Commit Message Generation dataset.
Intended Uses & Limitations
The model can be used to generate git commit messages for commit changes or be fine - tuned on other relevant tasks. It can handle unparsed and untokenized commit changes, but the performance is better when the changes are tokenized.
đ§ Technical Details
The supervised training tasks datasets can be downloaded from Link
đ License
No license information is provided in the original README.
Evaluation Results
For the git commit message generation task, different models achieve the following results on different programming languages (in BLEU score):
Property |
Details |
Model Type |
CodeTrans models (CodeTrans - ST - Small, CodeTrans - ST - Base, etc.) |
Training Data |
Can be downloaded from Link |
Test results:
Language / Model |
Java |
CodeTrans - ST - Small |
39.61 |
CodeTrans - ST - Base |
38.67 |
CodeTrans - TF - Small |
44.22 |
CodeTrans - TF - Base |
44.17 |
CodeTrans - TF - Large |
44.41 |
CodeTrans - MT - Small |
36.17 |
CodeTrans - MT - Base |
39.25 |
CodeTrans - MT - Large |
41.18 |
CodeTrans - MT - TF - Small |
43.96 |
CodeTrans - MT - TF - Base |
44.19 |
CodeTrans - MT - TF - Large |
44.34 |
State of the art |
32.81 |
Created by Ahmed Elnaggar | LinkedIn and Wei Ding | LinkedIn