jrahn commited on
Commit
9862717
1 Parent(s): 6d6296c

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +39 -150
README.md CHANGED
@@ -11,7 +11,8 @@ language:
11
  pipeline_tag: text-generation
12
  ---
13
 
14
- # Model Card for llm.c gpt2_350M trained on 10b fineweb-edu interleaved with OpenHermes 2.5
 
15
 
16
  <!-- Provide a quick summary of what the model is/does. -->
17
 
@@ -20,67 +21,23 @@ pipeline_tag: text-generation
20
 
21
  ## Model Details
22
 
23
- ### Model Description
24
-
25
- <!-- Provide a longer summary of what this model is. -->
26
-
27
- This is the model card of a 🤗 transformers model that has been pushed on the Hub. This model card has been automatically generated.
28
-
29
- - **Developed by:** [More Information Needed]
30
- - **Funded by [optional]:** [More Information Needed]
31
- - **Shared by [optional]:** [More Information Needed]
32
- - **Model type:** [More Information Needed]
33
- - **Language(s) (NLP):** [More Information Needed]
34
- - **License:** [More Information Needed]
35
- - **Finetuned from model [optional]:** [More Information Needed]
36
-
37
- ### Model Sources [optional]
38
-
39
- <!-- Provide the basic links for the model. -->
40
-
41
- - **Repository:** [More Information Needed]
42
- - **Paper [optional]:** [More Information Needed]
43
- - **Demo [optional]:** [More Information Needed]
44
-
45
- ## Uses
46
-
47
- <!-- Address questions around how the model is intended to be used, including the foreseeable users of the model and those affected by the model. -->
48
-
49
- ### Direct Use
50
-
51
- <!-- This section is for the model use without fine-tuning or plugging into a larger ecosystem/app. -->
52
-
53
- [More Information Needed]
54
-
55
- ### Downstream Use [optional]
56
-
57
- <!-- This section is for the model use when fine-tuned for a task, or when plugged into a larger ecosystem/app -->
58
-
59
- [More Information Needed]
60
-
61
- ### Out-of-Scope Use
62
-
63
- <!-- This section addresses misuse, malicious use, and uses that the model will not work well for. -->
64
-
65
- [More Information Needed]
66
-
67
- ## Bias, Risks, and Limitations
68
-
69
- <!-- This section is meant to convey both technical and sociotechnical limitations. -->
70
-
71
- [More Information Needed]
72
-
73
- ### Recommendations
74
-
75
- <!-- This section is meant to convey recommendations with respect to the bias, risk, and technical limitations. -->
76
-
77
- Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. More information needed for further recommendations.
78
 
79
  ## How to Get Started with the Model
80
 
81
  Use the code below to get started with the model.
82
 
83
- [More Information Needed]
 
 
 
 
 
 
 
 
 
 
 
84
 
85
  ## Training Details
86
 
@@ -88,13 +45,13 @@ Use the code below to get started with the model.
88
 
89
  <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
90
 
91
- Fineweb-Edu 10B + OpenHermes 2.5 (chatml)
92
 
93
- Dataset proportions:
94
- Part 1: FWE 4,836,050 + OH 100,000 (2.03%) = 4,936,050
95
- Part 2: FWE 4,336,051 + OH 400,000 (8.45%) = 4,736,051
96
- Part 3: FWE 500,000 + OH 501,551 (50.08%) = 1,001,551
97
- Total documents: 10,669,024
98
 
99
  ### Training Procedure
100
 
@@ -102,120 +59,52 @@ Total documents: 10,669,024
102
 
103
  #### Preprocessing [optional]
104
 
105
- [More Information Needed]
 
 
106
 
107
 
108
  #### Training Hyperparameters
109
 
110
- - **Training regime:** [More Information Needed] <!--fp32, fp16 mixed precision, bf16 mixed precision, bf16 non-mixed precision, fp16 non-mixed precision, fp8 mixed precision -->
 
 
 
 
 
111
 
112
  #### Speeds, Sizes, Times [optional]
113
 
114
  <!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
115
 
116
- Params: 355M -> Checkpoint: 700MB
 
 
 
 
117
 
118
- Tokens: ~10B
119
- Total training time: 30hrs
120
- Hardware: 2x RTX4090
121
- MFU: 71%
122
-
123
- [More Information Needed]
124
 
125
  ## Evaluation
126
 
127
  <!-- This section describes the evaluation protocols and provides the results. -->
128
 
129
- ### Testing Data, Factors & Metrics
130
-
131
- #### Testing Data
132
-
133
- <!-- This should link to a Dataset Card if possible. -->
134
-
135
- [More Information Needed]
136
-
137
- #### Factors
138
-
139
- <!-- These are the things the evaluation is disaggregating by, e.g., subpopulations or domains. -->
140
-
141
- [More Information Needed]
142
-
143
- #### Metrics
144
-
145
- <!-- These are the evaluation metrics being used, ideally with a description of why. -->
146
-
147
- [More Information Needed]
148
-
149
  ### Results
150
 
151
- [More Information Needed]
152
-
153
- #### Summary
154
-
155
-
156
-
157
- ## Model Examination [optional]
158
-
159
- <!-- Relevant interpretability work for the model goes here -->
160
-
161
- [More Information Needed]
162
-
163
- ## Environmental Impact
164
-
165
- <!-- Total emissions (in grams of CO2eq) and additional considerations, such as electricity usage, go here. Edit the suggested text below accordingly -->
166
-
167
- Carbon emissions can be estimated using the [Machine Learning Impact calculator](https://mlco2.github.io/impact#compute) presented in [Lacoste et al. (2019)](https://arxiv.org/abs/1910.09700).
168
-
169
- - **Hardware Type:** [More Information Needed]
170
- - **Hours used:** [More Information Needed]
171
- - **Cloud Provider:** [More Information Needed]
172
- - **Compute Region:** [More Information Needed]
173
- - **Carbon Emitted:** [More Information Needed]
174
 
175
  ## Technical Specifications [optional]
176
 
177
  ### Model Architecture and Objective
178
 
179
- [More Information Needed]
180
 
181
  ### Compute Infrastructure
182
 
183
- [More Information Needed]
184
-
185
  #### Hardware
186
 
187
- [More Information Needed]
188
 
189
  #### Software
190
 
191
- [More Information Needed]
192
-
193
- ## Citation [optional]
194
-
195
- <!-- If there is a paper or blog post introducing the model, the APA and Bibtex information for that should go in this section. -->
196
-
197
- **BibTeX:**
198
-
199
- [More Information Needed]
200
-
201
- **APA:**
202
-
203
- [More Information Needed]
204
-
205
- ## Glossary [optional]
206
-
207
- <!-- If relevant, include terms and calculations in this section that can help readers understand the model or model card. -->
208
-
209
- [More Information Needed]
210
-
211
- ## More Information [optional]
212
-
213
- [More Information Needed]
214
-
215
- ## Model Card Authors [optional]
216
-
217
- [More Information Needed]
218
-
219
- ## Model Card Contact
220
-
221
- [More Information Needed]
 
11
  pipeline_tag: text-generation
12
  ---
13
 
14
+ # Model Card for llm.c GPT2_350M
15
+ ## Instruction Pretraining: Fineweb-edu 10B interleaved with OpenHermes 2.5
16
 
17
  <!-- Provide a quick summary of what the model is/does. -->
18
 
 
21
 
22
  ## Model Details
23
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
24
 
25
  ## How to Get Started with the Model
26
 
27
  Use the code below to get started with the model.
28
 
29
+ ```python
30
+ from transformers import pipeline
31
+ p = pipeline("text-generation", "jrahn/gpt2_350M_edu_hermes")
32
+
33
+ # instruction following
34
+ p("<|im_start|>user\nTeach me to fish.<|im_end|>\n<|im_start|>assistant\n", max_lenght=128)
35
+ #[{'generated_text': '<|im_start|>user\nTeach me to fish.<|im_end|>\n<|im_start|>assistant\nTo fish, you can start by learning the basics of fishing. First, you need to learn how to catch fish. Fish are a type of fish that are found in the ocean. They are also known as sea fish. They are a type of fish that are found in the ocean. They are a type of fish that are found in the ocean. They are a type of fish that are found in the ocean. They are a type of fish that are found in the ocean'}]
36
+
37
+ # text completion
38
+ p("In a shocking finding, scientist discovered a herd of unicorns living in a remote, previously unexplored valley, in the Andes Mountains. Even more surprising to the researchers was the fact that the unicorns spoke perfect English. ", max_length=128)
39
+ # [{'generated_text': 'In a shocking finding, scientist discovered a herd of unicorns living in a remote, previously unexplored valley, in the Andes Mountains. Even more surprising to the researchers was the fact that the unicorns spoke perfect English. \nThe researchers believe that the animals were able to communicate with each other by using a unique vocalization system. The researchers believe that the animals were able to communicate with each other by using a unique vocalization system.\nThe researchers believe that the animals were able to communicate with each other by using a unique vocalization system. The researchers believe that the animals were able to communicate with each other by using a unique'}]
40
+ ```
41
 
42
  ## Training Details
43
 
 
45
 
46
  <!-- This should link to a Dataset Card, perhaps with a short stub of information on what the training data is all about as well as documentation related to data pre-processing or additional filtering. -->
47
 
48
+ Datasets used: Fineweb-Edu 10B + OpenHermes 2.5 (chatml)
49
 
50
+ Dataset proportions:
51
+ - Part 1: FWE 4,836,050 + OH 100,000 (2.03%) = 4,936,050
52
+ - Part 2: FWE 4,336,051 + OH 400,000 (8.45%) = 4,736,051
53
+ - Part 3: FWE 500,000 + OH 501,551 (50.08%) = 1,001,551
54
+ Total documents: 10,669,024
55
 
56
  ### Training Procedure
57
 
 
59
 
60
  #### Preprocessing [optional]
61
 
62
+ - Fineweb-Edu: none, just the "text" feature
63
+ - OpenHermes 2.5: applied ChatML prompt template to "conversations" to create the "text" feature
64
+
65
 
66
 
67
  #### Training Hyperparameters
68
 
69
+ - **Training regime:**
70
+ - bf16
71
+ - per device batch size 16, global batch size 524288, gradient accumulation 16
72
+ - zero stage 1
73
+ - lr 3e-4, cosine schedule, 700 warmup steps
74
+ - more details see [run script](run_gpt2_350M_edu_hermes.sh)
75
 
76
  #### Speeds, Sizes, Times [optional]
77
 
78
  <!-- This section provides information about throughput, start/end time, checkpoint size if relevant, etc. -->
79
 
80
+ Params: 355M -> Checkpoint: 710MB
81
+ Tokens: ~10B
82
+ Total training time: 30hrs
83
+ Hardware: 2x RTX4090
84
+ MFU: 71% (110,000 tok/s)
85
 
 
 
 
 
 
 
86
 
87
  ## Evaluation
88
 
89
  <!-- This section describes the evaluation protocols and provides the results. -->
90
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
91
  ### Results
92
 
93
+ HellaSwag: 34.4
94
+ - more details see [main.log](main.log)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
95
 
96
  ## Technical Specifications [optional]
97
 
98
  ### Model Architecture and Objective
99
 
100
+ GTP2 350M, Causal Language Modeling
101
 
102
  ### Compute Infrastructure
103
 
 
 
104
  #### Hardware
105
 
106
+ 2x RTX4090
107
 
108
  #### Software
109
 
110
+ [llm.c](https://github.com/karpathy/llm.c)