Model save
Browse files- README.md +56 -0
- all_results.json +8 -0
- merges.txt +0 -0
- model.safetensors +3 -0
- special_tokens_map.json +6 -0
- tokenizer.json +0 -0
- tokenizer_config.json +22 -0
- train_results.json +8 -0
- trainer_state.json +0 -0
- training_args.bin +3 -0
- vocab.json +0 -0
README.md
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
base_model: openai-community/gpt2
|
| 3 |
+
library_name: transformers
|
| 4 |
+
model_name: gpt2-RMT-2
|
| 5 |
+
tags:
|
| 6 |
+
- generated_from_trainer
|
| 7 |
+
licence: license
|
| 8 |
+
---
|
| 9 |
+
|
| 10 |
+
# Model Card for gpt2-RMT-2
|
| 11 |
+
|
| 12 |
+
This model is a fine-tuned version of [openai-community/gpt2](https://huggingface.co/openai-community/gpt2).
|
| 13 |
+
It has been trained using [TRL](https://github.com/huggingface/trl).
|
| 14 |
+
|
| 15 |
+
## Quick start
|
| 16 |
+
|
| 17 |
+
```python
|
| 18 |
+
from transformers import pipeline
|
| 19 |
+
|
| 20 |
+
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?"
|
| 21 |
+
generator = pipeline("text-generation", model="KotshinZ/gpt2-RMT-2", device="cuda")
|
| 22 |
+
output = generator([{"role": "user", "content": question}], max_new_tokens=128, return_full_text=False)[0]
|
| 23 |
+
print(output["generated_text"])
|
| 24 |
+
```
|
| 25 |
+
|
| 26 |
+
## Training procedure
|
| 27 |
+
|
| 28 |
+
[<img src="https://raw.githubusercontent.com/wandb/assets/main/wandb-github-badge-28.svg" alt="Visualize in Weights & Biases" width="150" height="24"/>](https://wandb.ai/s18574s18574-/huggingface/runs/l72fp4oe)
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
This model was trained with SFT.
|
| 32 |
+
|
| 33 |
+
### Framework versions
|
| 34 |
+
|
| 35 |
+
- TRL: 0.16.0.dev0
|
| 36 |
+
- Transformers: 4.50.0.dev0
|
| 37 |
+
- Pytorch: 2.5.1
|
| 38 |
+
- Datasets: 3.3.2
|
| 39 |
+
- Tokenizers: 0.21.0
|
| 40 |
+
|
| 41 |
+
## Citations
|
| 42 |
+
|
| 43 |
+
|
| 44 |
+
|
| 45 |
+
Cite TRL as:
|
| 46 |
+
|
| 47 |
+
```bibtex
|
| 48 |
+
@misc{vonwerra2022trl,
|
| 49 |
+
title = {{TRL: Transformer Reinforcement Learning}},
|
| 50 |
+
author = {Leandro von Werra and Younes Belkada and Lewis Tunstall and Edward Beeching and Tristan Thrush and Nathan Lambert and Shengyi Huang and Kashif Rasul and Quentin Gallouédec},
|
| 51 |
+
year = 2020,
|
| 52 |
+
journal = {GitHub repository},
|
| 53 |
+
publisher = {GitHub},
|
| 54 |
+
howpublished = {\url{https://github.com/huggingface/trl}}
|
| 55 |
+
}
|
| 56 |
+
```
|
all_results.json
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"total_flos": 0.0,
|
| 3 |
+
"train_loss": 3.0764607222270666,
|
| 4 |
+
"train_runtime": 988.267,
|
| 5 |
+
"train_samples": 16610,
|
| 6 |
+
"train_samples_per_second": 92.823,
|
| 7 |
+
"train_steps_per_second": 5.802
|
| 8 |
+
}
|
merges.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
model.safetensors
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d2f151e5f2994e0724ebd407c712b774989cd7fc4dbbf11c4db50a391a6e2c9d
|
| 3 |
+
size 326110968
|
special_tokens_map.json
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"bos_token": "<|endoftext|>",
|
| 3 |
+
"eos_token": "<|endoftext|>",
|
| 4 |
+
"pad_token": "<|endoftext|>",
|
| 5 |
+
"unk_token": "<|endoftext|>"
|
| 6 |
+
}
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"add_prefix_space": false,
|
| 3 |
+
"added_tokens_decoder": {
|
| 4 |
+
"50256": {
|
| 5 |
+
"content": "<|endoftext|>",
|
| 6 |
+
"lstrip": false,
|
| 7 |
+
"normalized": true,
|
| 8 |
+
"rstrip": false,
|
| 9 |
+
"single_word": false,
|
| 10 |
+
"special": true
|
| 11 |
+
}
|
| 12 |
+
},
|
| 13 |
+
"bos_token": "<|endoftext|>",
|
| 14 |
+
"chat_template": "{% for message in messages %}{{ message['role'] }}: {{ message['content'] }}\n{% endfor %}",
|
| 15 |
+
"clean_up_tokenization_spaces": false,
|
| 16 |
+
"eos_token": "<|endoftext|>",
|
| 17 |
+
"extra_special_tokens": {},
|
| 18 |
+
"model_max_length": 1024,
|
| 19 |
+
"pad_token": "<|endoftext|>",
|
| 20 |
+
"tokenizer_class": "GPT2Tokenizer",
|
| 21 |
+
"unk_token": "<|endoftext|>"
|
| 22 |
+
}
|
train_results.json
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"total_flos": 0.0,
|
| 3 |
+
"train_loss": 3.0764607222270666,
|
| 4 |
+
"train_runtime": 988.267,
|
| 5 |
+
"train_samples": 16610,
|
| 6 |
+
"train_samples_per_second": 92.823,
|
| 7 |
+
"train_steps_per_second": 5.802
|
| 8 |
+
}
|
trainer_state.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
training_args.bin
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a0b81dafb8f7db8872c0a749fd0c3ef2993c05ada67a943bbe6d729d6c19ca6d
|
| 3 |
+
size 7352
|
vocab.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|