Model Card for unsloth
This model is a fine-tuned version of openai-community/gpt2 on the knkarthick/samsum dataset. It has been trained using TRL.
Quick start
from transformers import pipeline
question = "If you had a time machine, but could only go to the past or the future once and never return, which would you choose and why?"
generator = pipeline("text-generation", model="None", device="cuda")
output = generator([{"role": "user", "content": question}], max_new_tokens=128, return_full_text=False)[0]
print(output["generated_text"])
Training procedure
This model was trained with SFT.
Training Hyperparameters
The following hyperparameters were used during training:
| Parameter | Value |
|---|---|
| LoRA Rank ($r$) | 32 |
| LoRA Alpha (Scale) | 16.0 |
| LoRA Dropout | 0.0 |
| Learning Rate | 2e-4 |
| Optimizer | AdamW |
| Batch Size | 4 |
| Epochs | 3 |
| Seed | 3407 |
Training Metrics
Training was monitored via Weights & Biases (W&B).
- Final Training Loss: 2.5596
- Final Validation Loss: 2.4426
{
"_runtime": 1828,
"_step": 303,
"_timestamp": 1776940747.4150884,
"_wandb.runtime": 1828,
"eval/loss": 2.442631959915161,
"eval/runtime": 8.4963,
"eval/samples_per_second": 96.277,
"eval/steps_per_second": 24.128,
"total_flos": 4539887471702016,
"train/epoch": 3,
"train/global_step": 2763,
"train/grad_norm": 0.24430057406425476,
"train/learning_rate": 2.985074626865672e-7,
"train/loss": 2.5596,
"train_loss": 2.563603694569232,
"train_runtime": 1834.6214,
"train_samples_per_second": 24.088,
"train_steps_per_second": 1.506
}
Framework versions
- PEFT 0.19.1
- TRL: 0.24.0
- Transformers: 4.57.3
- Pytorch: 2.10.0
- Datasets: 4.3.0
- Tokenizers: 0.22.2
- Downloads last month
- 83
Model tree for RGarrido03/GPT2-LoRA
Base model
openai-community/gpt2