saurabh5 commited on
Commit
7d4fa93
·
verified ·
1 Parent(s): 48683df

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +49 -0
README.md CHANGED
@@ -165,6 +165,55 @@ Moo Moo the cow would certinaly win.
165
  - reinforcement learning from verifiable rewards on the Dolci-Think-RL-7B dataset. This dataset consits of math, code, instruction-following, and general chat queries.
166
  - Datasets: [Dolci-Think-RL-7B](https://huggingface.co/datasets/allenai/Dolci-Think-RL-7B), [Dolci-Instruct-RL-7B](https://huggingface.co/datasets/allenai/Dolci-Instruct-RL-7B)
167
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
168
 
169
  ## Bias, Risks, and Limitations
170
  Like any base language model or fine-tuned model without safety filtering, these models can easily be prompted by users to generate harmful and sensitive content. Such content may also be produced unintentionally, especially in cases involving bias, so we recommend that users consider the risks when applying this technology. Additionally, many statements from OLMo or any LLM are often inaccurate, so facts should be verified.
 
165
  - reinforcement learning from verifiable rewards on the Dolci-Think-RL-7B dataset. This dataset consits of math, code, instruction-following, and general chat queries.
166
  - Datasets: [Dolci-Think-RL-7B](https://huggingface.co/datasets/allenai/Dolci-Think-RL-7B), [Dolci-Instruct-RL-7B](https://huggingface.co/datasets/allenai/Dolci-Instruct-RL-7B)
167
 
168
+ ## Inference & Recommended Settings
169
+ We evaluated our models on the following settings. We also recommend using them for generation:
170
+ - **temperature:** `0.6`
171
+ - **top_p:** `0.95`
172
+ - **max_tokens:** `32768`
173
+
174
+ ### transformers Example
175
+ ```python
176
+ from transformers import AutoModelForCausalLM, AutoTokenizer
177
+
178
+ model_id = "allenai/Olmo-3-7B-Instruct"
179
+ tokenizer = AutoTokenizer.from_pretrained(model_id)
180
+ model = AutoModelForCausalLM.from_pretrained(
181
+ model_id,
182
+ device_map="auto",
183
+ )
184
+
185
+ prompt = "Who would in in a fight - a dinosaur of a cow named MooMoo?"
186
+ inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
187
+
188
+ outputs = model.generate(
189
+ **inputs,
190
+ temperature=0.6,
191
+ top_p=0.95,
192
+ max_new_tokens=32768,
193
+ )
194
+
195
+ print(tokenizer.decode(outputs[0], skip_special_tokens=True))
196
+ ```
197
+
198
+ ### vllm Example
199
+ ```python
200
+ from vllm import LLM, SamplingParams
201
+
202
+ model_id = "allenai/Olmo-3-7B-Instruct"
203
+ llm = LLM(model=model_id)
204
+
205
+ sampling_params = SamplingParams(
206
+ temperature=0.6,
207
+ top_p=0.95,
208
+ max_tokens=32768,
209
+ )
210
+
211
+ prompt = "Who would in in a fight - a dinosaur of a cow named MooMoo?"
212
+
213
+ outputs = llm.generate(prompt, sampling_params)
214
+ print(outputs[0].outputs[0].text)
215
+ ```
216
+
217
 
218
  ## Bias, Risks, and Limitations
219
  Like any base language model or fine-tuned model without safety filtering, these models can easily be prompted by users to generate harmful and sensitive content. Such content may also be produced unintentionally, especially in cases involving bias, so we recommend that users consider the risks when applying this technology. Additionally, many statements from OLMo or any LLM are often inaccurate, so facts should be verified.