Views
No views yet
Qwen/Qwen3.5-2B.Qwen/Qwen3.5-2Bnvidia/OpenMathReasoningjasonrqh/Math-CoT-20k| Benchmark | Raw Base | Merged Model |
|---|---|---|
| GSM8K | 0.66 | 0.74 |
| MATH-500 | 0.27 | 0.33 |
| ARC-Challenge | 0.21 | 0.29 |
| CommonsenseQA | 0.21 | 0.28 |
| BoolQ | 0.75 | 0.74 |
| WinoGrande | 0.52 | 0.51 |
1import torch
2from transformers import AutoModelForCausalLM, AutoTokenizer
3
4model_id = "YOUR_USERNAME/YOUR_MODEL_REPO"
5
6tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
7model = AutoModelForCausalLM.from_pretrained(
8 model_id,
9 torch_dtype=torch.bfloat16 if torch.cuda.is_available() else torch.float16,
10 device_map="auto",
11 trust_remote_code=True,
12)
13
14messages = [
15 {"role": "system", "content": "You are a careful reasoning assistant."},
16 {"role": "user", "content": "Solve: If 3x + 5 = 20, what is x? End with Final answer: <answer>"},
17]
18
19prompt = tokenizer.apply_chat_template(
20 messages,
21 tokenize=False,
22 add_generation_prompt=True,
23)
24
25inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
26
27with torch.inference_mode():
28 outputs = model.generate(
29 **inputs,
30 max_new_tokens=256,
31 do_sample=False,
32 temperature=0.0,
33 pad_token_id=tokenizer.pad_token_id,
34 eos_token_id=tokenizer.eos_token_id,
35 )
36
37generated = outputs[0][inputs["input_ids"].shape[1]:]
38print(tokenizer.decode(generated, skip_special_tokens=True))
39
40## Limitations
41
42- Performance is strongest on reasoning-style prompts close to the SFT data distribution.
43- Gains are not uniform across all reasoning benchmarks.
44- Some benchmark improvements may reflect output-format adaptation as well as reasoning improvement.
45
46## Training / Eval Project
47
48This model was trained and evaluated in a local project with raw-vs-merged comparisons on math and reasoning benchmarks including:
49
50- GSM8K
51- MATH-500
52- Math-CoT-20k
53- MMLU math
54- BoolQ
55- WinoGrande
56- CommonsenseQA
57- ARC-Challenge