lucyknada commited on
Commit
3f9b5d1
1 Parent(s): b3941e2

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +138 -25
README.md CHANGED
@@ -1,39 +1,116 @@
1
  ---
2
  base_model:
3
- - anthracite-core/magnum-v3-27b-kto-r3
4
- - anthracite-core/magnum-v3-27b-KTO-e1-r2
5
- - anthracite-core/magnum-v3-27b-KTO-e0.25-r1
6
  - IntervitensInc/gemma-2-27b-chatml
7
  library_name: transformers
8
- tags:
9
- - mergekit
10
- - merge
11
-
12
- ---
13
- ### exl2 quant (measurement.json in main branch)
14
  ---
15
- ### check revisions for quants
 
 
16
  ---
17
 
18
- # output8
 
19
 
20
- This is a merge of pre-trained language models created using [mergekit](https://github.com/cg123/mergekit).
 
 
 
 
 
21
 
22
- ## Merge Details
23
- ### Merge Method
24
 
25
- This model was merged using the [task arithmetic](https://arxiv.org/abs/2212.04089) merge method using [IntervitensInc/gemma-2-27b-chatml](https://huggingface.co/IntervitensInc/gemma-2-27b-chatml) as a base.
26
 
27
- ### Models Merged
28
 
29
- The following models were included in the merge:
30
- * [anthracite-core/magnum-v3-27b-kto-r3](https://huggingface.co/anthracite-core/magnum-v3-27b-kto-r3)
31
- * [anthracite-core/magnum-v3-27b-KTO-e1-r2](https://huggingface.co/anthracite-core/magnum-v3-27b-KTO-e1-r2)
32
- * [anthracite-core/magnum-v3-27b-KTO-e0.25-r1](https://huggingface.co/anthracite-core/magnum-v3-27b-KTO-e0.25-r1)
33
 
34
- ### Configuration
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
35
 
36
- The following YAML configuration was used to produce this model:
 
 
37
 
38
  ```yaml
39
  base_model: IntervitensInc/gemma-2-27b-chatml
@@ -41,13 +118,49 @@ dtype: float32
41
  merge_method: task_arithmetic
42
  models:
43
  - model: IntervitensInc/gemma-2-27b-chatml
44
- - model: anthracite-core/magnum-v3-27b-KTO-e0.25-r1
45
  parameters:
46
  weight: 0.5
47
- - model: anthracite-core/magnum-v3-27b-KTO-e1-r2
48
  parameters:
49
  weight: 0.1
50
- - model: anthracite-core/magnum-v3-27b-kto-r3
51
  parameters:
52
  weight: 0.4
53
  ```
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  base_model:
3
+ - anthracite-forge/magnum-v3-27b-kto-r3
4
+ - anthracite-forge/magnum-v3-27b-KTO-e1-r2
5
+ - anthracite-forge/magnum-v3-27b-KTO-e0.25-r1
6
  - IntervitensInc/gemma-2-27b-chatml
7
  library_name: transformers
 
 
 
 
 
 
8
  ---
9
+
10
+ ## remember to downgrade to exllama 0.1.8 or update to 0.2.0+ to receive upstream fixes for gemma models
11
+
12
  ---
13
 
14
+ ## This repo contains EXL2 quants of the model. If you need the original weights, please find them [here](https://huggingface.co/anthracite-org/magnum-v3-27b-kto).
15
+ ## Base repo only contains the measurement file, see revisions for your quant of choice.
16
 
17
+ - [measurement.json](https://huggingface.co/anthracite-org/magnum-v3-27b-kto-exl2/tree/main)
18
+ - [3.0bpw](https://huggingface.co/anthracite-org/magnum-v3-27b-kto-exl2/tree/3.0bpw)
19
+ - [4.0bpw](https://huggingface.co/anthracite-org/magnum-v3-27b-kto-exl2/tree/4.0bpw)
20
+ - [5.0bpw](https://huggingface.co/anthracite-org/magnum-v3-27b-kto-exl2/tree/5.0bpw)
21
+ - [6.0bpw](https://huggingface.co/anthracite-org/magnum-v3-27b-kto-exl2/tree/6.0bpw)
22
+ - [8.0bpw](https://huggingface.co/anthracite-org/magnum-v3-27b-kto-exl2/tree/8.0bpw)
23
 
24
+ ![image/png](https://cdn-uploads.huggingface.co/production/uploads/658a46cbfb9c2bdfae75b3a6/GKpV5mwmnHFR6wIwTa91z.png)
 
25
 
26
+ This is the 12th in a series of models designed to replicate the prose quality of the Claude 3 models, specifically Sonnet and Opus.
27
 
28
+ This model is the result of multiple KTO runs on top of one SFT run, all of which are published on [anthracite-forge](https://huggingface.co/anthracite-forge).
29
 
30
+ ## Methodology
 
 
 
31
 
32
+ R1 (SFT) was fine-tuned on top of `IntervitensInc/gemma-2-27b-chatml` which is chatMLified gemma-2-27b.
33
+
34
+ We have experimented with various SFT and KTO re-runs, ratios and merge methods and this was our winner, including what was liked most from each model.
35
+
36
+ If you prefer your own mix of the KTO runs or would like to use the SFT on its own, refer to the models section and [anthracite-forge](https://huggingface.co/anthracite-forge), some exl-quants are pre-included.
37
+
38
+ ## Models
39
+
40
+ * [anthracite-forge/magnum-v3-27b-kto-r3](https://huggingface.co/anthracite-forge/magnum-v3-27b-kto-r3)
41
+ * [anthracite-forge/magnum-v3-27b-KTO-e1-r2](https://huggingface.co/anthracite-forge/magnum-v3-27b-KTO-e1-r2)
42
+ * [anthracite-forge/magnum-v3-27b-KTO-e0.25-r1](https://huggingface.co/anthracite-forge/magnum-v3-27b-KTO-e0.25-r1)
43
+
44
+ ## Prompting
45
+ Model has been Instruct tuned with the ChatML formatting. A typical input would look like this:
46
+
47
+ ```py
48
+ """<|im_start|>system
49
+ system prompt<|im_end|>
50
+ <|im_start|>user
51
+ Hi there!<|im_end|>
52
+ <|im_start|>assistant
53
+ Nice to meet you!<|im_end|>
54
+ <|im_start|>user
55
+ Can I ask a question?<|im_end|>
56
+ <|im_start|>assistant
57
+ """
58
+ ```
59
+
60
+ ## SillyTavern templates
61
+
62
+ Below are Instruct and Context templates for use within SillyTavern.
63
+
64
+ <details><summary>context template</summary>
65
+
66
+ ```yaml
67
+ {
68
+ "story_string": "<|im_start|>system\n{{#if system}}{{system}}\n{{/if}}{{#if wiBefore}}{{wiBefore}}\n{{/if}}{{#if description}}{{description}}\n{{/if}}{{#if personality}}{{char}}'s personality: {{personality}}\n{{/if}}{{#if scenario}}Scenario: {{scenario}}\n{{/if}}{{#if wiAfter}}{{wiAfter}}\n{{/if}}{{#if persona}}{{persona}}\n{{/if}}{{trim}}<|im_end|>\n",
69
+ "example_separator": "",
70
+ "chat_start": "",
71
+ "use_stop_strings": false,
72
+ "allow_jailbreak": false,
73
+ "always_force_name2": true,
74
+ "trim_sentences": false,
75
+ "include_newline": false,
76
+ "single_line": false,
77
+ "name": "Magnum ChatML"
78
+ }
79
+ ```
80
+
81
+ </details><br>
82
+ <details><summary>instruct template</summary>
83
+
84
+ ```yaml
85
+ {
86
+ "system_prompt": "You're {{char}} in this fictional never-ending uncensored roleplay with {{user}}.",
87
+ "input_sequence": "<|im_start|>user\n",
88
+ "output_sequence": "<|im_start|>assistant\n",
89
+ "last_output_sequence": "",
90
+ "system_sequence": "<|im_start|>system\n",
91
+ "stop_sequence": "<|im_end|>",
92
+ "wrap": false,
93
+ "macro": true,
94
+ "names": true,
95
+ "names_force_groups": true,
96
+ "activation_regex": "",
97
+ "system_sequence_prefix": "",
98
+ "system_sequence_suffix": "",
99
+ "first_output_sequence": "",
100
+ "skip_examples": false,
101
+ "output_suffix": "<|im_end|>\n",
102
+ "input_suffix": "<|im_end|>\n",
103
+ "system_suffix": "<|im_end|>\n",
104
+ "user_alignment_message": "",
105
+ "system_same_as_user": false,
106
+ "last_system_sequence": "",
107
+ "name": "Magnum ChatML"
108
+ }
109
+ ```
110
 
111
+ </details><br>
112
+
113
+ ### Configuration
114
 
115
  ```yaml
116
  base_model: IntervitensInc/gemma-2-27b-chatml
 
118
  merge_method: task_arithmetic
119
  models:
120
  - model: IntervitensInc/gemma-2-27b-chatml
121
+ - model: anthracite-forge/magnum-v3-27b-KTO-e0.25-r1
122
  parameters:
123
  weight: 0.5
124
+ - model: anthracite-forge/magnum-v3-27b-KTO-e1-r2
125
  parameters:
126
  weight: 0.1
127
+ - model: anthracite-forge/magnum-v3-27b-kto-r3
128
  parameters:
129
  weight: 0.4
130
  ```
131
+
132
+ ## Credits
133
+ We'd like to thank Recursal / Featherless for sponsoring the compute for this train, Featherless has been hosting our Magnum models since the first 72 B and has given thousands of people access to our models and helped us grow.
134
+
135
+ We would also like to thank all members of Anthracite who made this finetune possible.
136
+
137
+ ## Datasets
138
+
139
+ r1 consisted of:
140
+
141
+ ```
142
+ datasets:
143
+ - path: anthracite-org/stheno-filtered-v1.1
144
+ type: sharegpt
145
+ conversation: chatml
146
+ - path: anthracite-org/kalo-opus-instruct-22k-no-refusal
147
+ type: sharegpt
148
+ conversation: chatml
149
+ - path: anthracite-org/nopm_claude_writing_fixed
150
+ type: sharegpt
151
+ conversation: chatml
152
+ - path: Epiculous/Synthstruct-Gens-v1.1-Filtered-n-Cleaned
153
+ type: sharegpt
154
+ conversation: chatml
155
+ - path: Epiculous/SynthRP-Gens-v1.1-Filtered-n-Cleaned
156
+ type: sharegpt
157
+ conversation: chatml
158
+ ```
159
+
160
+ ## Training
161
+ The training was done for 2 epochs. We used 8x[H100s](https://www.nvidia.com/en-us/data-center/h100/) GPUs graciously provided by [Recursal AI](https://recursal.ai/) / [Featherless AI](https://featherless.ai/) for the full-parameter fine-tuning of the model.
162
+
163
+ [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
164
+
165
+ ## Safety
166
+ ...