gpt2-reuters-from-scratch
GPT-2 style causal language model trained from random initialisation on the Reuters articles dataset (title + body concatenated) with the next-token prediction objective. Tokenizer: ingeniumacademy/gpt2-reuters-tokenizer.
| Setting | Value |
|---|---|
| Layers / heads / d_model | 6 / 6 / 384 |
| Context length | 256 |
| Parameters | 30,713,856 |
| Epochs | 5 |
| Batch size / LR | 32 / 0.0005 (cosine, 5% warmup) |
| Training time | 587.5 s |
| Validation loss (ppl) | 4.1740 (64.98) |
| Test loss (ppl) | 3.9745 (53.22) |
Supporting files: training_summary.json, log_history.csv, loss_curve.png.
from transformers import AutoTokenizer, AutoModelForCausalLM
tok = AutoTokenizer.from_pretrained('randeepa02/gpt2-reuters-from-scratch')
model = AutoModelForCausalLM.from_pretrained('randeepa02/gpt2-reuters-from-scratch')