Views
No views yet

| Model ID | Average | ARC | HellaSwag | MMLU | TruthfulQA | Winogrande | GSM8K |
|---|---|---|---|---|---|---|---|
| meta-llama/Meta-Llama-3-8B-Instruct 📄 | 66.87 | 60.75 | 78.55 | 67.07 | 51.65 | 74.51 | 68.69 |
| dfurman/Llama-3-8B-Orpo-v0.1 📄 | 64.67 | 60.67 | 82.56 | 66.59 | 50.47 | 79.01 | 48.75 |
| meta-llama/Meta-Llama-3-8B 📄 | 62.35 | 59.22 | 82.02 | 66.49 | 43.95 | 77.11 | 45.34 |
1!pip install -qU transformers accelerate
2
3from transformers import AutoTokenizer
4import transformers
5import torch
6
7if torch.cuda.get_device_capability()[0] >= 8:
8 !pip install -qqq flash-attn
9 attn_implementation = "flash_attention_2"
10 torch_dtype = torch.bfloat16
11else:
12 attn_implementation = "eager"
13 torch_dtype = torch.float16
14
15model = "dfurman/Llama-3-8B-Orpo-v0.1"
16
17tokenizer = AutoTokenizer.from_pretrained(model)
18pipeline = transformers.pipeline(
19 "text-generation",
20 model=model,
21 model_kwargs={
22 "torch_dtype": torch_dtype,
23 "device_map": "auto",
24 "attn_implementation": attn_implementation,
25 }
26)1messages = [
2 {"role": "system", "content": "You are a helpful assistant."},
3 {"role": "user", "content": "Tell me a recipe for a spicy margarita."},
4]
5prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
6print("***Prompt:\n", prompt)
7
8outputs = pipeline(prompt, max_new_tokens=1000, do_sample=True, temperature=0.7, top_k=50, top_p=0.95)
9print("***Generation:\n", outputs[0]["generated_text"][len(prompt):])"""***Prompt:
<|im_start|>system
You are a helpful assistant.<|im_end|>
<|im_start|>user
Tell me a recipe for a spicy margarita.<|im_end|>
<|im_start|>assistant
***Generation:
Sure! Here's a recipe for a spicy margarita:
Ingredients:
- 2 oz silver tequila
- 1 oz triple sec
- 1 oz fresh lime juice
- 1/2 oz simple syrup
- 1/2 oz fresh lemon juice
- 1/2 tsp jalapeño, sliced (adjust to taste)
- Ice cubes
- Salt for rimming the glass
Instructions:
1. Prepare the glass by running a lime wedge around the rim of the glass. Dip the rim into a shallow plate of salt to coat.
2. Combine the tequila, triple sec, lime juice, simple syrup, lemon juice, and jalapeño slices in a cocktail shaker.
3. Add ice cubes to the cocktail shaker and shake vigorously for 30 seconds to 1 minute.
4. Strain the cocktail into the prepared glass.
5. Garnish with a lime wedge and jalapeño slice.
Enjoy! This spicy margarita has a nice balance of sweetness and acidity, with a subtle heat from the jalapeño that builds gradually as you sip."""| Metric | Value |
|---|---|
| Avg. | 11.01 |
| IFEval (0-Shot) | 30.00 |
| BBH (3-Shot) | 13.77 |
| MATH Lvl 5 (4-Shot) | 3.78 |
| GPQA (0-shot) | 1.57 |
| MuSR (0-shot) | 2.73 |
| MMLU-PRO (5-shot) | 14.23 |