Mohaaxa commited on
Commit
0c9e87d
·
verified ·
1 Parent(s): b1025c0

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +50 -19
README.md CHANGED
@@ -1,42 +1,73 @@
1
  ---
2
- base_model: []
3
- library_name: transformers
 
4
  tags:
5
- - mergekit
6
  - merge
7
-
 
 
 
 
 
 
 
8
  ---
 
9
  # Qwen2.5-1.5B-R1-SLERP
10
 
11
- This is a merge of pre-trained language models created using [mergekit](https://github.com/cg123/mergekit).
 
 
12
 
13
- ## Merge Details
14
- ### Merge Method
15
 
16
- This model was merged using the [SLERP](https://en.wikipedia.org/wiki/Slerp) merge method.
17
 
18
- ### Models Merged
19
 
20
- The following models were included in the merge:
21
- * /models/qwen2.5-1.5b-instruct
22
- * /models/deepseek-r1-distill-qwen-1.5b
 
 
23
 
24
- ### Configuration
 
25
 
26
- The following YAML configuration was used to produce this model:
27
 
28
  ```yaml
29
-
30
  merge_method: slerp
31
  base_model:
32
- model: /models/qwen2.5-1.5b-instruct
33
  slices:
34
  - sources:
35
- - model: /models/qwen2.5-1.5b-instruct
36
  layer_range: [0, 28]
37
- - model: /models/deepseek-r1-distill-qwen-1.5b
38
  layer_range: [0, 28]
39
  parameters:
40
- t: 0.3
 
 
 
 
 
 
41
 
 
 
 
 
 
 
42
  ```
 
 
 
 
 
 
 
 
1
  ---
2
+ language:
3
+ - en
4
+ license: apache-2.0
5
  tags:
 
6
  - merge
7
+ - mergekit
8
+ - slerp
9
+ - qwen2.5
10
+ - deepseek-r1
11
+ - reasoning
12
+ base_model:
13
+ - Qwen/Qwen2.5-1.5B-Instruct
14
+ - deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B
15
  ---
16
+
17
  # Qwen2.5-1.5B-R1-SLERP
18
 
19
+ A SLERP merge (t=0.5) of:
20
+ - [`Qwen/Qwen2.5-1.5B-Instruct`](https://huggingface.co/Qwen/Qwen2.5-1.5B-Instruct) — strong general instruction following
21
+ - [`deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B`](https://huggingface.co/deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B) — RL-distilled chain-of-thought reasoning
22
 
23
+ Part of a systematic merge study on the Qwen2.5-1.5B family. See also:
24
+ - [`Mohaaxa/Qwen2.5-1.5B-R1-SLERP-AWQ`](https://huggingface.co/Mohaaxa/Qwen2.5-1.5B-R1-SLERP-AWQ) — AWQ 4-bit quantized version
25
 
26
+ ## Benchmarks
27
 
28
+ Evaluated against both parent models on PPL (Wikitext-2) and GSM8K (100 samples):
29
 
30
+ | Model | PPL | GSM8K |
31
+ |-------|-----|-------|
32
+ | Qwen2.5-1.5B-Instruct (parent) | 16.141 | 38.0% |
33
+ | DeepSeek-R1-Distill-Qwen-1.5B (parent) | 107.467 | 3.0% |
34
+ | **Qwen2.5-1.5B-R1-SLERP (this model)** | 1205.427 | 2.0% |
35
 
36
+ PPL delta vs Instruct parent: +1189.286
37
+ GSM8K delta vs Instruct parent: -36.0%
38
 
39
+ ## Merge Config
40
 
41
  ```yaml
 
42
  merge_method: slerp
43
  base_model:
44
+ model: Qwen/Qwen2.5-1.5B-Instruct
45
  slices:
46
  - sources:
47
+ - model: Qwen/Qwen2.5-1.5B-Instruct
48
  layer_range: [0, 28]
49
+ - model: deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B
50
  layer_range: [0, 28]
51
  parameters:
52
+ t: 0.5
53
+ ```
54
+
55
+ ## Usage
56
+
57
+ ```python
58
+ from transformers import AutoModelForCausalLM, AutoTokenizer
59
 
60
+ model = AutoModelForCausalLM.from_pretrained(
61
+ "Mohaaxa/Qwen2.5-1.5B-R1-SLERP",
62
+ torch_dtype="auto",
63
+ device_map="auto",
64
+ )
65
+ tokenizer = AutoTokenizer.from_pretrained("Mohaaxa/Qwen2.5-1.5B-R1-SLERP")
66
  ```
67
+
68
+ ## Notes
69
+
70
+ - t=0.5 gives equal weight to both parents
71
+ - SLERP preserves weight magnitude better than linear interpolation
72
+ - Both parents share identical Qwen2.5 architecture (28 layers, hidden_dim=1536)
73
+ - For a quantized version with ~67% VRAM reduction, use the AWQ variant