kxnguyen commited on
Commit
a0fe9f3
·
verified ·
1 Parent(s): bad8c79

Model save

Browse files
Files changed (4) hide show
  1. README.md +57 -0
  2. all_results.json +9 -0
  3. train_results.json +9 -0
  4. trainer_state.json +273 -0
README.md ADDED
@@ -0,0 +1,57 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: Meta-Llama/Meta-Llama-3.1-8B
3
+ library_name: transformers
4
+ model_name: llama-3-1-8b-math-orca-qlora-10k-ep1-frac-50-seed-2
5
+ tags:
6
+ - generated_from_trainer
7
+ - trl
8
+ - sft
9
+ licence: license
10
+ ---
11
+
12
+ # Model Card for llama-3-1-8b-math-orca-qlora-10k-ep1-frac-50-seed-2
13
+
14
+ This model is a fine-tuned version of [Meta-Llama/Meta-Llama-3.1-8B](https://huggingface.co/Meta-Llama/Meta-Llama-3.1-8B).
15
+ It has been trained using [TRL](https://github.com/huggingface/trl).
16
+
17
+ ## Quick start
18
+
19
+ ```python
20
+ from transformers import pipeline
21
+
22
+ 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?"
23
+ generator = pipeline("text-generation", model="kxnguyen/llama-3-1-8b-math-orca-qlora-10k-ep1-frac-50-seed-2", device="cuda")
24
+ output = generator([{"role": "user", "content": question}], max_new_tokens=128, return_full_text=False)[0]
25
+ print(output["generated_text"])
26
+ ```
27
+
28
+ ## Training procedure
29
+
30
+
31
+
32
+ This model was trained with SFT.
33
+
34
+ ### Framework versions
35
+
36
+ - TRL: 0.12.1
37
+ - Transformers: 4.49.0
38
+ - Pytorch: 2.5.1
39
+ - Datasets: 3.1.0
40
+ - Tokenizers: 0.21.1
41
+
42
+ ## Citations
43
+
44
+
45
+
46
+ Cite TRL as:
47
+
48
+ ```bibtex
49
+ @misc{vonwerra2022trl,
50
+ title = {{TRL: Transformer Reinforcement Learning}},
51
+ 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},
52
+ year = 2020,
53
+ journal = {GitHub repository},
54
+ publisher = {GitHub},
55
+ howpublished = {\url{https://github.com/huggingface/trl}}
56
+ }
57
+ ```
all_results.json ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 0.9970501474926253,
3
+ "total_flos": 1.3410656498535629e+17,
4
+ "train_loss": 0.3628283569798667,
5
+ "train_runtime": 1720.2693,
6
+ "train_samples": 5000,
7
+ "train_samples_per_second": 1.574,
8
+ "train_steps_per_second": 0.098
9
+ }
train_results.json ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "epoch": 0.9970501474926253,
3
+ "total_flos": 1.3410656498535629e+17,
4
+ "train_loss": 0.3628283569798667,
5
+ "train_runtime": 1720.2693,
6
+ "train_samples": 5000,
7
+ "train_samples_per_second": 1.574,
8
+ "train_steps_per_second": 0.098
9
+ }
trainer_state.json ADDED
@@ -0,0 +1,273 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "best_metric": null,
3
+ "best_model_checkpoint": null,
4
+ "epoch": 0.9970501474926253,
5
+ "eval_steps": 500,
6
+ "global_step": 169,
7
+ "is_hyper_param_search": false,
8
+ "is_local_process_zero": true,
9
+ "is_world_process_zero": true,
10
+ "log_history": [
11
+ {
12
+ "epoch": 0.029498525073746312,
13
+ "grad_norm": 15.842525482177734,
14
+ "learning_rate": 0.0002,
15
+ "loss": 1.3605,
16
+ "step": 5
17
+ },
18
+ {
19
+ "epoch": 0.058997050147492625,
20
+ "grad_norm": 1.1057137250900269,
21
+ "learning_rate": 0.0002,
22
+ "loss": 0.6189,
23
+ "step": 10
24
+ },
25
+ {
26
+ "epoch": 0.08849557522123894,
27
+ "grad_norm": 0.7712059020996094,
28
+ "learning_rate": 0.0002,
29
+ "loss": 0.4282,
30
+ "step": 15
31
+ },
32
+ {
33
+ "epoch": 0.11799410029498525,
34
+ "grad_norm": 1.1073462963104248,
35
+ "learning_rate": 0.0002,
36
+ "loss": 0.4143,
37
+ "step": 20
38
+ },
39
+ {
40
+ "epoch": 0.14749262536873156,
41
+ "grad_norm": 0.6461352705955505,
42
+ "learning_rate": 0.0002,
43
+ "loss": 0.3758,
44
+ "step": 25
45
+ },
46
+ {
47
+ "epoch": 0.17699115044247787,
48
+ "grad_norm": 0.6348222494125366,
49
+ "learning_rate": 0.0002,
50
+ "loss": 0.3761,
51
+ "step": 30
52
+ },
53
+ {
54
+ "epoch": 0.20648967551622419,
55
+ "grad_norm": 0.558731198310852,
56
+ "learning_rate": 0.0002,
57
+ "loss": 0.3652,
58
+ "step": 35
59
+ },
60
+ {
61
+ "epoch": 0.2359882005899705,
62
+ "grad_norm": 0.5885202884674072,
63
+ "learning_rate": 0.0002,
64
+ "loss": 0.3611,
65
+ "step": 40
66
+ },
67
+ {
68
+ "epoch": 0.26548672566371684,
69
+ "grad_norm": 0.5200619697570801,
70
+ "learning_rate": 0.0002,
71
+ "loss": 0.3584,
72
+ "step": 45
73
+ },
74
+ {
75
+ "epoch": 0.2949852507374631,
76
+ "grad_norm": 0.6615349650382996,
77
+ "learning_rate": 0.0002,
78
+ "loss": 0.3352,
79
+ "step": 50
80
+ },
81
+ {
82
+ "epoch": 0.32448377581120946,
83
+ "grad_norm": 0.6481220126152039,
84
+ "learning_rate": 0.0002,
85
+ "loss": 0.3245,
86
+ "step": 55
87
+ },
88
+ {
89
+ "epoch": 0.35398230088495575,
90
+ "grad_norm": 0.5189281702041626,
91
+ "learning_rate": 0.0002,
92
+ "loss": 0.3277,
93
+ "step": 60
94
+ },
95
+ {
96
+ "epoch": 0.3834808259587021,
97
+ "grad_norm": 0.5450770854949951,
98
+ "learning_rate": 0.0002,
99
+ "loss": 0.3394,
100
+ "step": 65
101
+ },
102
+ {
103
+ "epoch": 0.41297935103244837,
104
+ "grad_norm": 0.5216971635818481,
105
+ "learning_rate": 0.0002,
106
+ "loss": 0.3303,
107
+ "step": 70
108
+ },
109
+ {
110
+ "epoch": 0.4424778761061947,
111
+ "grad_norm": 0.5718809962272644,
112
+ "learning_rate": 0.0002,
113
+ "loss": 0.3503,
114
+ "step": 75
115
+ },
116
+ {
117
+ "epoch": 0.471976401179941,
118
+ "grad_norm": 0.46456339955329895,
119
+ "learning_rate": 0.0002,
120
+ "loss": 0.3363,
121
+ "step": 80
122
+ },
123
+ {
124
+ "epoch": 0.5014749262536873,
125
+ "grad_norm": 0.8590409755706787,
126
+ "learning_rate": 0.0002,
127
+ "loss": 0.3111,
128
+ "step": 85
129
+ },
130
+ {
131
+ "epoch": 0.5309734513274337,
132
+ "grad_norm": 0.4512447714805603,
133
+ "learning_rate": 0.0002,
134
+ "loss": 0.3142,
135
+ "step": 90
136
+ },
137
+ {
138
+ "epoch": 0.56047197640118,
139
+ "grad_norm": 1.0052748918533325,
140
+ "learning_rate": 0.0002,
141
+ "loss": 0.3146,
142
+ "step": 95
143
+ },
144
+ {
145
+ "epoch": 0.5899705014749262,
146
+ "grad_norm": 0.41449859738349915,
147
+ "learning_rate": 0.0002,
148
+ "loss": 0.2949,
149
+ "step": 100
150
+ },
151
+ {
152
+ "epoch": 0.6194690265486725,
153
+ "grad_norm": 4.5440354347229,
154
+ "learning_rate": 0.0002,
155
+ "loss": 0.2879,
156
+ "step": 105
157
+ },
158
+ {
159
+ "epoch": 0.6489675516224189,
160
+ "grad_norm": 0.37434083223342896,
161
+ "learning_rate": 0.0002,
162
+ "loss": 0.2943,
163
+ "step": 110
164
+ },
165
+ {
166
+ "epoch": 0.6784660766961652,
167
+ "grad_norm": 0.3563149571418762,
168
+ "learning_rate": 0.0002,
169
+ "loss": 0.3082,
170
+ "step": 115
171
+ },
172
+ {
173
+ "epoch": 0.7079646017699115,
174
+ "grad_norm": 0.40530529618263245,
175
+ "learning_rate": 0.0002,
176
+ "loss": 0.308,
177
+ "step": 120
178
+ },
179
+ {
180
+ "epoch": 0.7374631268436578,
181
+ "grad_norm": 0.39032211899757385,
182
+ "learning_rate": 0.0002,
183
+ "loss": 0.3079,
184
+ "step": 125
185
+ },
186
+ {
187
+ "epoch": 0.7669616519174042,
188
+ "grad_norm": 0.3619149327278137,
189
+ "learning_rate": 0.0002,
190
+ "loss": 0.2861,
191
+ "step": 130
192
+ },
193
+ {
194
+ "epoch": 0.7964601769911505,
195
+ "grad_norm": 0.3519650995731354,
196
+ "learning_rate": 0.0002,
197
+ "loss": 0.2942,
198
+ "step": 135
199
+ },
200
+ {
201
+ "epoch": 0.8259587020648967,
202
+ "grad_norm": 0.33940911293029785,
203
+ "learning_rate": 0.0002,
204
+ "loss": 0.288,
205
+ "step": 140
206
+ },
207
+ {
208
+ "epoch": 0.855457227138643,
209
+ "grad_norm": 0.31343740224838257,
210
+ "learning_rate": 0.0002,
211
+ "loss": 0.2961,
212
+ "step": 145
213
+ },
214
+ {
215
+ "epoch": 0.8849557522123894,
216
+ "grad_norm": 0.4065489172935486,
217
+ "learning_rate": 0.0002,
218
+ "loss": 0.2824,
219
+ "step": 150
220
+ },
221
+ {
222
+ "epoch": 0.9144542772861357,
223
+ "grad_norm": 0.35969874262809753,
224
+ "learning_rate": 0.0002,
225
+ "loss": 0.2918,
226
+ "step": 155
227
+ },
228
+ {
229
+ "epoch": 0.943952802359882,
230
+ "grad_norm": 0.35074159502983093,
231
+ "learning_rate": 0.0002,
232
+ "loss": 0.285,
233
+ "step": 160
234
+ },
235
+ {
236
+ "epoch": 0.9734513274336283,
237
+ "grad_norm": 0.3305889964103699,
238
+ "learning_rate": 0.0002,
239
+ "loss": 0.2761,
240
+ "step": 165
241
+ },
242
+ {
243
+ "epoch": 0.9970501474926253,
244
+ "step": 169,
245
+ "total_flos": 1.3410656498535629e+17,
246
+ "train_loss": 0.3628283569798667,
247
+ "train_runtime": 1720.2693,
248
+ "train_samples_per_second": 1.574,
249
+ "train_steps_per_second": 0.098
250
+ }
251
+ ],
252
+ "logging_steps": 5,
253
+ "max_steps": 169,
254
+ "num_input_tokens_seen": 0,
255
+ "num_train_epochs": 1,
256
+ "save_steps": 500,
257
+ "stateful_callbacks": {
258
+ "TrainerControl": {
259
+ "args": {
260
+ "should_epoch_stop": false,
261
+ "should_evaluate": false,
262
+ "should_log": false,
263
+ "should_save": true,
264
+ "should_training_stop": true
265
+ },
266
+ "attributes": {}
267
+ }
268
+ },
269
+ "total_flos": 1.3410656498535629e+17,
270
+ "train_batch_size": 8,
271
+ "trial_name": null,
272
+ "trial_params": null
273
+ }