TheBloke commited on
Commit
99118ab
1 Parent(s): d31cd86

Upload README.md

Browse files
Files changed (1) hide show
  1. README.md +650 -0
README.md ADDED
@@ -0,0 +1,650 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: fblgit/LUNA-SOLARkrautLM-Instruct
3
+ datasets:
4
+ - argilla/distilabel-math-preference-dpo
5
+ inference: false
6
+ language:
7
+ - en
8
+ - de
9
+ library_name: transformers
10
+ license: cc-by-nc-4.0
11
+ model_creator: FBL
12
+ model_name: Luna SOLARkrautLM Instruct
13
+ model_type: solar
14
+ pipeline_tag: text-generation
15
+ prompt_template: '<|im_start|>system
16
+
17
+ {system_message}<|im_end|>
18
+
19
+ <|im_start|>user
20
+
21
+ {prompt}<|im_end|>
22
+
23
+ <|im_start|>assistant
24
+
25
+ '
26
+ quantized_by: TheBloke
27
+ tags:
28
+ - finetune
29
+ - dpo
30
+ - Instruct
31
+ - augmentation
32
+ - german
33
+ ---
34
+ <!-- markdownlint-disable MD041 -->
35
+
36
+ <!-- header start -->
37
+ <!-- 200823 -->
38
+ <div style="width: auto; margin-left: auto; margin-right: auto">
39
+ <img src="https://i.imgur.com/EBdldam.jpg" alt="TheBlokeAI" style="width: 100%; min-width: 400px; display: block; margin: auto;">
40
+ </div>
41
+ <div style="display: flex; justify-content: space-between; width: 100%;">
42
+ <div style="display: flex; flex-direction: column; align-items: flex-start;">
43
+ <p style="margin-top: 0.5em; margin-bottom: 0em;"><a href="https://discord.gg/theblokeai">Chat & support: TheBloke's Discord server</a></p>
44
+ </div>
45
+ <div style="display: flex; flex-direction: column; align-items: flex-end;">
46
+ <p style="margin-top: 0.5em; margin-bottom: 0em;"><a href="https://www.patreon.com/TheBlokeAI">Want to contribute? TheBloke's Patreon page</a></p>
47
+ </div>
48
+ </div>
49
+ <div style="text-align:center; margin-top: 0em; margin-bottom: 0em"><p style="margin-top: 0.25em; margin-bottom: 0em;">TheBloke's LLM work is generously supported by a grant from <a href="https://a16z.com">andreessen horowitz (a16z)</a></p></div>
50
+ <hr style="margin-top: 1.0em; margin-bottom: 1.0em;">
51
+ <!-- header end -->
52
+
53
+ # Luna SOLARkrautLM Instruct - GPTQ
54
+ - Model creator: [FBL](https://huggingface.co/fblgit)
55
+ - Original model: [Luna SOLARkrautLM Instruct](https://huggingface.co/fblgit/LUNA-SOLARkrautLM-Instruct)
56
+
57
+ <!-- description start -->
58
+ # Description
59
+
60
+ This repo contains GPTQ model files for [FBL's Luna SOLARkrautLM Instruct](https://huggingface.co/fblgit/LUNA-SOLARkrautLM-Instruct).
61
+
62
+ Multiple GPTQ parameter permutations are provided; see Provided Files below for details of the options provided, their parameters, and the software used to create them.
63
+
64
+ These files were quantised using hardware kindly provided by [Massed Compute](https://massedcompute.com/).
65
+
66
+ <!-- description end -->
67
+ <!-- repositories-available start -->
68
+ ## Repositories available
69
+
70
+ * [AWQ model(s) for GPU inference.](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-AWQ)
71
+ * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ)
72
+ * [2, 3, 4, 5, 6 and 8-bit GGUF models for CPU+GPU inference](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GGUF)
73
+ * [FBL's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/fblgit/LUNA-SOLARkrautLM-Instruct)
74
+ <!-- repositories-available end -->
75
+
76
+ <!-- prompt-template start -->
77
+ ## Prompt template: ChatML
78
+
79
+ ```
80
+ <|im_start|>system
81
+ {system_message}<|im_end|>
82
+ <|im_start|>user
83
+ {prompt}<|im_end|>
84
+ <|im_start|>assistant
85
+
86
+ ```
87
+
88
+ <!-- prompt-template end -->
89
+
90
+
91
+
92
+ <!-- README_GPTQ.md-compatible clients start -->
93
+ ## Known compatible clients / servers
94
+
95
+ GPTQ models are currently supported on Linux (NVidia/AMD) and Windows (NVidia only). macOS users: please use GGUF models.
96
+
97
+ These GPTQ models are known to work in the following inference servers/webuis.
98
+
99
+ - [text-generation-webui](https://github.com/oobabooga/text-generation-webui)
100
+ - [KoboldAI United](https://github.com/henk717/koboldai)
101
+ - [LoLLMS Web UI](https://github.com/ParisNeo/lollms-webui)
102
+ - [Hugging Face Text Generation Inference (TGI)](https://github.com/huggingface/text-generation-inference)
103
+
104
+ This may not be a complete list; if you know of others, please let me know!
105
+ <!-- README_GPTQ.md-compatible clients end -->
106
+
107
+ <!-- README_GPTQ.md-provided-files start -->
108
+ ## Provided files, and GPTQ parameters
109
+
110
+ Multiple quantisation parameters are provided, to allow you to choose the best one for your hardware and requirements.
111
+
112
+ Each separate quant is in a different branch. See below for instructions on fetching from different branches.
113
+
114
+ Most GPTQ files are made with AutoGPTQ. Mistral models are currently made with Transformers.
115
+
116
+ <details>
117
+ <summary>Explanation of GPTQ parameters</summary>
118
+
119
+ - Bits: The bit size of the quantised model.
120
+ - GS: GPTQ group size. Higher numbers use less VRAM, but have lower quantisation accuracy. "None" is the lowest possible value.
121
+ - Act Order: True or False. Also known as `desc_act`. True results in better quantisation accuracy. Some GPTQ clients have had issues with models that use Act Order plus Group Size, but this is generally resolved now.
122
+ - Damp %: A GPTQ parameter that affects how samples are processed for quantisation. 0.01 is default, but 0.1 results in slightly better accuracy.
123
+ - GPTQ dataset: The calibration dataset used during quantisation. Using a dataset more appropriate to the model's training can improve quantisation accuracy. Note that the GPTQ calibration dataset is not the same as the dataset used to train the model - please refer to the original model repo for details of the training dataset(s).
124
+ - Sequence Length: The length of the dataset sequences used for quantisation. Ideally this is the same as the model sequence length. For some very long sequence models (16+K), a lower sequence length may have to be used. Note that a lower sequence length does not limit the sequence length of the quantised model. It only impacts the quantisation accuracy on longer inference sequences.
125
+ - ExLlama Compatibility: Whether this file can be loaded with ExLlama, which currently only supports Llama and Mistral models in 4-bit.
126
+
127
+ </details>
128
+
129
+ | Branch | Bits | GS | Act Order | Damp % | GPTQ Dataset | Seq Len | Size | ExLlama | Desc |
130
+ | ------ | ---- | -- | --------- | ------ | ------------ | ------- | ---- | ------- | ---- |
131
+ | [main](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ/tree/main) | 4 | 128 | Yes | 0.1 | [German Quad](https://huggingface.co/datasets/deepset/germanquad/viewer/) | 2048 | 5.98 GB | Yes | 4-bit, with Act Order and group size 128g. Uses even less VRAM than 64g, but with slightly lower accuracy. |
132
+ | [gptq-4bit-32g-actorder_True](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ/tree/gptq-4bit-32g-actorder_True) | 4 | 32 | Yes | 0.1 | [German Quad](https://huggingface.co/datasets/deepset/germanquad/viewer/) | 2048 | 6.59 GB | Yes | 4-bit, with Act Order and group size 32g. Gives highest possible inference quality, with maximum VRAM usage. |
133
+ | [gptq-8bit--1g-actorder_True](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ/tree/gptq-8bit--1g-actorder_True) | 8 | None | Yes | 0.1 | [German Quad](https://huggingface.co/datasets/deepset/germanquad/viewer/) | 2048 | 11.01 GB | No | 8-bit, with Act Order. No group size, to lower VRAM requirements. |
134
+ | [gptq-8bit-128g-actorder_True](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ/tree/gptq-8bit-128g-actorder_True) | 8 | 128 | Yes | 0.1 | [German Quad](https://huggingface.co/datasets/deepset/germanquad/viewer/) | 2048 | 11.25 GB | No | 8-bit, with group size 128g for higher inference quality and with Act Order for even higher accuracy. |
135
+ | [gptq-8bit-32g-actorder_True](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ/tree/gptq-8bit-32g-actorder_True) | 8 | 32 | Yes | 0.1 | [German Quad](https://huggingface.co/datasets/deepset/germanquad/viewer/) | 2048 | 11.99 GB | No | 8-bit, with group size 32g and Act Order for maximum inference quality. |
136
+ | [gptq-4bit-64g-actorder_True](https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ/tree/gptq-4bit-64g-actorder_True) | 4 | 64 | Yes | 0.1 | [German Quad](https://huggingface.co/datasets/deepset/germanquad/viewer/) | 2048 | 6.18 GB | Yes | 4-bit, with Act Order and group size 64g. Uses less VRAM than 32g, but with slightly lower accuracy. |
137
+
138
+ <!-- README_GPTQ.md-provided-files end -->
139
+
140
+ <!-- README_GPTQ.md-download-from-branches start -->
141
+ ## How to download, including from branches
142
+
143
+ ### In text-generation-webui
144
+
145
+ To download from the `main` branch, enter `TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ` in the "Download model" box.
146
+
147
+ To download from another branch, add `:branchname` to the end of the download name, eg `TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ:gptq-4bit-32g-actorder_True`
148
+
149
+ ### From the command line
150
+
151
+ I recommend using the `huggingface-hub` Python library:
152
+
153
+ ```shell
154
+ pip3 install huggingface-hub
155
+ ```
156
+
157
+ To download the `main` branch to a folder called `LUNA-SOLARkrautLM-Instruct-GPTQ`:
158
+
159
+ ```shell
160
+ mkdir LUNA-SOLARkrautLM-Instruct-GPTQ
161
+ huggingface-cli download TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ --local-dir LUNA-SOLARkrautLM-Instruct-GPTQ --local-dir-use-symlinks False
162
+ ```
163
+
164
+ To download from a different branch, add the `--revision` parameter:
165
+
166
+ ```shell
167
+ mkdir LUNA-SOLARkrautLM-Instruct-GPTQ
168
+ huggingface-cli download TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ --revision gptq-4bit-32g-actorder_True --local-dir LUNA-SOLARkrautLM-Instruct-GPTQ --local-dir-use-symlinks False
169
+ ```
170
+
171
+ <details>
172
+ <summary>More advanced huggingface-cli download usage</summary>
173
+
174
+ If you remove the `--local-dir-use-symlinks False` parameter, the files will instead be stored in the central Hugging Face cache directory (default location on Linux is: `~/.cache/huggingface`), and symlinks will be added to the specified `--local-dir`, pointing to their real location in the cache. This allows for interrupted downloads to be resumed, and allows you to quickly clone the repo to multiple places on disk without triggering a download again. The downside, and the reason why I don't list that as the default option, is that the files are then hidden away in a cache folder and it's harder to know where your disk space is being used, and to clear it up if/when you want to remove a download model.
175
+
176
+ The cache location can be changed with the `HF_HOME` environment variable, and/or the `--cache-dir` parameter to `huggingface-cli`.
177
+
178
+ For more documentation on downloading with `huggingface-cli`, please see: [HF -> Hub Python Library -> Download files -> Download from the CLI](https://huggingface.co/docs/huggingface_hub/guides/download#download-from-the-cli).
179
+
180
+ To accelerate downloads on fast connections (1Gbit/s or higher), install `hf_transfer`:
181
+
182
+ ```shell
183
+ pip3 install hf_transfer
184
+ ```
185
+
186
+ And set environment variable `HF_HUB_ENABLE_HF_TRANSFER` to `1`:
187
+
188
+ ```shell
189
+ mkdir LUNA-SOLARkrautLM-Instruct-GPTQ
190
+ HF_HUB_ENABLE_HF_TRANSFER=1 huggingface-cli download TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ --local-dir LUNA-SOLARkrautLM-Instruct-GPTQ --local-dir-use-symlinks False
191
+ ```
192
+
193
+ Windows Command Line users: You can set the environment variable by running `set HF_HUB_ENABLE_HF_TRANSFER=1` before the download command.
194
+ </details>
195
+
196
+ ### With `git` (**not** recommended)
197
+
198
+ To clone a specific branch with `git`, use a command like this:
199
+
200
+ ```shell
201
+ git clone --single-branch --branch gptq-4bit-32g-actorder_True https://huggingface.co/TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ
202
+ ```
203
+
204
+ Note that using Git with HF repos is strongly discouraged. It will be much slower than using `huggingface-hub`, and will use twice as much disk space as it has to store the model files twice (it stores every byte both in the intended target folder, and again in the `.git` folder as a blob.)
205
+
206
+ <!-- README_GPTQ.md-download-from-branches end -->
207
+ <!-- README_GPTQ.md-text-generation-webui start -->
208
+ ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui)
209
+
210
+ Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
211
+
212
+ It is strongly recommended to use the text-generation-webui one-click-installers unless you're sure you know how to make a manual install.
213
+
214
+ 1. Click the **Model tab**.
215
+ 2. Under **Download custom model or LoRA**, enter `TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ`.
216
+
217
+ - To download from a specific branch, enter for example `TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ:gptq-4bit-32g-actorder_True`
218
+ - see Provided Files above for the list of branches for each option.
219
+
220
+ 3. Click **Download**.
221
+ 4. The model will start downloading. Once it's finished it will say "Done".
222
+ 5. In the top left, click the refresh icon next to **Model**.
223
+ 6. In the **Model** dropdown, choose the model you just downloaded: `LUNA-SOLARkrautLM-Instruct-GPTQ`
224
+ 7. The model will automatically load, and is now ready for use!
225
+ 8. If you want any custom settings, set them and then click **Save settings for this model** followed by **Reload the Model** in the top right.
226
+
227
+ - Note that you do not need to and should not set manual GPTQ parameters any more. These are set automatically from the file `quantize_config.json`.
228
+
229
+ 9. Once you're ready, click the **Text Generation** tab and enter a prompt to get started!
230
+
231
+ <!-- README_GPTQ.md-text-generation-webui end -->
232
+
233
+ <!-- README_GPTQ.md-use-from-tgi start -->
234
+ ## Serving this model from Text Generation Inference (TGI)
235
+
236
+ It's recommended to use TGI version 1.1.0 or later. The official Docker container is: `ghcr.io/huggingface/text-generation-inference:1.1.0`
237
+
238
+ Example Docker parameters:
239
+
240
+ ```shell
241
+ --model-id TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ --port 3000 --quantize gptq --max-input-length 3696 --max-total-tokens 4096 --max-batch-prefill-tokens 4096
242
+ ```
243
+
244
+ Example Python code for interfacing with TGI (requires huggingface-hub 0.17.0 or later):
245
+
246
+ ```shell
247
+ pip3 install huggingface-hub
248
+ ```
249
+
250
+ ```python
251
+ from huggingface_hub import InferenceClient
252
+
253
+ endpoint_url = "https://your-endpoint-url-here"
254
+
255
+ prompt = "Tell me about AI"
256
+ prompt_template=f'''<|im_start|>system
257
+ {system_message}<|im_end|>
258
+ <|im_start|>user
259
+ {prompt}<|im_end|>
260
+ <|im_start|>assistant
261
+ '''
262
+
263
+ client = InferenceClient(endpoint_url)
264
+ response = client.text_generation(prompt,
265
+ max_new_tokens=128,
266
+ do_sample=True,
267
+ temperature=0.7,
268
+ top_p=0.95,
269
+ top_k=40,
270
+ repetition_penalty=1.1)
271
+
272
+ print(f"Model output: {response}")
273
+ ```
274
+ <!-- README_GPTQ.md-use-from-tgi end -->
275
+ <!-- README_GPTQ.md-use-from-python start -->
276
+ ## Python code example: inference from this GPTQ model
277
+
278
+ ### Install the necessary packages
279
+
280
+ Requires: Transformers 4.33.0 or later, Optimum 1.12.0 or later, and AutoGPTQ 0.4.2 or later.
281
+
282
+ ```shell
283
+ pip3 install --upgrade transformers optimum
284
+ # If using PyTorch 2.1 + CUDA 12.x:
285
+ pip3 install --upgrade auto-gptq
286
+ # or, if using PyTorch 2.1 + CUDA 11.x:
287
+ pip3 install --upgrade auto-gptq --extra-index-url https://huggingface.github.io/autogptq-index/whl/cu118/
288
+ ```
289
+
290
+ If you are using PyTorch 2.0, you will need to install AutoGPTQ from source. Likewise if you have problems with the pre-built wheels, you should try building from source:
291
+
292
+ ```shell
293
+ pip3 uninstall -y auto-gptq
294
+ git clone https://github.com/PanQiWei/AutoGPTQ
295
+ cd AutoGPTQ
296
+ git checkout v0.5.1
297
+ pip3 install .
298
+ ```
299
+
300
+ ### Example Python code
301
+
302
+ ```python
303
+ from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
304
+
305
+ model_name_or_path = "TheBloke/LUNA-SOLARkrautLM-Instruct-GPTQ"
306
+ # To use a different branch, change revision
307
+ # For example: revision="gptq-4bit-32g-actorder_True"
308
+ model = AutoModelForCausalLM.from_pretrained(model_name_or_path,
309
+ device_map="auto",
310
+ trust_remote_code=False,
311
+ revision="main")
312
+
313
+ tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
314
+
315
+ prompt = "Write a story about llamas"
316
+ system_message = "You are a story writing assistant"
317
+ prompt_template=f'''<|im_start|>system
318
+ {system_message}<|im_end|>
319
+ <|im_start|>user
320
+ {prompt}<|im_end|>
321
+ <|im_start|>assistant
322
+ '''
323
+
324
+ print("\n\n*** Generate:")
325
+
326
+ input_ids = tokenizer(prompt_template, return_tensors='pt').input_ids.cuda()
327
+ output = model.generate(inputs=input_ids, temperature=0.7, do_sample=True, top_p=0.95, top_k=40, max_new_tokens=512)
328
+ print(tokenizer.decode(output[0]))
329
+
330
+ # Inference can also be done using transformers' pipeline
331
+
332
+ print("*** Pipeline:")
333
+ pipe = pipeline(
334
+ "text-generation",
335
+ model=model,
336
+ tokenizer=tokenizer,
337
+ max_new_tokens=512,
338
+ do_sample=True,
339
+ temperature=0.7,
340
+ top_p=0.95,
341
+ top_k=40,
342
+ repetition_penalty=1.1
343
+ )
344
+
345
+ print(pipe(prompt_template)[0]['generated_text'])
346
+ ```
347
+ <!-- README_GPTQ.md-use-from-python end -->
348
+
349
+ <!-- README_GPTQ.md-compatibility start -->
350
+ ## Compatibility
351
+
352
+ The files provided are tested to work with Transformers. For non-Mistral models, AutoGPTQ can also be used directly.
353
+
354
+ [ExLlama](https://github.com/turboderp/exllama) is compatible with Llama architecture models (including Mistral, Yi, DeepSeek, SOLAR, etc) in 4-bit. Please see the Provided Files table above for per-file compatibility.
355
+
356
+ For a list of clients/servers, please see "Known compatible clients / servers", above.
357
+ <!-- README_GPTQ.md-compatibility end -->
358
+
359
+ <!-- footer start -->
360
+ <!-- 200823 -->
361
+ ## Discord
362
+
363
+ For further support, and discussions on these models and AI in general, join us at:
364
+
365
+ [TheBloke AI's Discord server](https://discord.gg/theblokeai)
366
+
367
+ ## Thanks, and how to contribute
368
+
369
+ Thanks to the [chirper.ai](https://chirper.ai) team!
370
+
371
+ Thanks to Clay from [gpus.llm-utils.org](llm-utils)!
372
+
373
+ I've had a lot of people ask if they can contribute. I enjoy providing models and helping people, and would love to be able to spend even more time doing it, as well as expanding into new projects like fine tuning/training.
374
+
375
+ If you're able and willing to contribute it will be most gratefully received and will help me to keep providing more models, and to start work on new AI projects.
376
+
377
+ Donaters will get priority support on any and all AI/LLM/model questions and requests, access to a private Discord room, plus other benefits.
378
+
379
+ * Patreon: https://patreon.com/TheBlokeAI
380
+ * Ko-Fi: https://ko-fi.com/TheBlokeAI
381
+
382
+ **Special thanks to**: Aemon Algiz.
383
+
384
+ **Patreon special mentions**: Michael Levine, 阿明, Trailburnt, Nikolai Manek, John Detwiler, Randy H, Will Dee, Sebastain Graf, NimbleBox.ai, Eugene Pentland, Emad Mostaque, Ai Maven, Jim Angel, Jeff Scroggin, Michael Davis, Manuel Alberto Morcote, Stephen Murray, Robert, Justin Joy, Luke @flexchar, Brandon Frisco, Elijah Stavena, S_X, Dan Guido, Undi ., Komninos Chatzipapas, Shadi, theTransient, Lone Striker, Raven Klaugh, jjj, Cap'n Zoog, Michel-Marie MAUDET (LINAGORA), Matthew Berman, David, Fen Risland, Omer Bin Jawed, Luke Pendergrass, Kalila, OG, Erik Bjäreholt, Rooh Singh, Joseph William Delisle, Dan Lewis, TL, John Villwock, AzureBlack, Brad, Pedro Madruga, Caitlyn Gatomon, K, jinyuan sun, Mano Prime, Alex, Jeffrey Morgan, Alicia Loh, Illia Dulskyi, Chadd, transmissions 11, fincy, Rainer Wilmers, ReadyPlayerEmma, knownsqashed, Mandus, biorpg, Deo Leter, Brandon Phillips, SuperWojo, Sean Connelly, Iucharbius, Jack West, Harry Royden McLaughlin, Nicholas, terasurfer, Vitor Caleffi, Duane Dunston, Johann-Peter Hartmann, David Ziegler, Olakabola, Ken Nordquist, Trenton Dambrowitz, Tom X Nguyen, Vadim, Ajan Kanaga, Leonard Tan, Clay Pascal, Alexandros Triantafyllidis, JM33133, Xule, vamX, ya boyyy, subjectnull, Talal Aujan, Alps Aficionado, wassieverse, Ari Malik, James Bentley, Woland, Spencer Kim, Michael Dempsey, Fred von Graf, Elle, zynix, William Richards, Stanislav Ovsiannikov, Edmond Seymore, Jonathan Leane, Martin Kemka, usrbinkat, Enrico Ros
385
+
386
+
387
+ Thank you to all my generous patrons and donaters!
388
+
389
+ And thank you again to a16z for their generous grant.
390
+
391
+ <!-- footer end -->
392
+
393
+ # Original model card: FBL's Luna SOLARkrautLM Instruct
394
+
395
+
396
+ ![Juanako.AI & SauerkrautLM Productions](https://vago-solutions.de/wp-content/uploads/2023/12/sauerkrautlm-solar.png "LUNA-SOLARkrautLM-Instruct")
397
+ ## VAGO solutions LUNA-SOLARkrautLM-Instruct
398
+ Introducing **LUNA-SOLARkrautLM-Instruct** ��� a UNA-Sauerkraut version of the powerful [upstage/SOLAR-10.7B-Instruct-v1.0](https://huggingface.co/upstage/SOLAR-10.7B-Instruct-v1.0) !
399
+ Aligned with **DPO** and tamed with **UNA**.
400
+
401
+ # Table of Contents
402
+ 1. [Overview of all LUNA-SOLARkrautLM-Instruct models](#all-sauerkrautlm-solar-instruct-models)
403
+ 2. [Model Details](#model-details)
404
+ - [Prompt template](#prompt-template)
405
+ - [Training Dataset](#training-dataset)
406
+ - [Data Contamination Test](#data-contamination-test-results)
407
+ 3. [Evaluation](#evaluation)
408
+ 5. [Disclaimer](#disclaimer)
409
+ 6. [Contact](#contact)
410
+ 7. [Collaborations](#collaborations)
411
+ 8. [Acknowledgement](#acknowledgement)
412
+
413
+
414
+ ## Model Details
415
+ **LUNA-SOLARkrautLM-Instruct**
416
+ - **Model Type:** LUNA-SOLARkrautLM-Instruct is a UNA Model based on [fblgit/UNA-SOLAR-10.7B-Instruct-v1.0](https://huggingface.co/fblgit/UNA-SOLAR-10.7B-Instruct-v1.0) and the powerful set of [SauerkrautLM-SOLAR-Instruct](https://huggingface.co/VAGOsolutions/SauerkrautLM-SOLAR-Instruct/)
417
+ - **Language(s):** English, German
418
+ - **License:** cc-by-nc-4.0
419
+ - **Contact:** [Website](https://vago-solutions.de/#Kontakt) [David Golchinfar](mailto:golchinfar@vago-solutions.de) [Juanako.AI - UNA](mailto:info@juanako.ai)
420
+
421
+ ### Training Dataset:
422
+
423
+ LUNA-SOLARkrautLM-Instruct was trained with mix of German data augmentation and translated data.
424
+ Aligned through **DPO** with our **new German SauerkrautLM-DPO dataset** based on parts of the SFT SauerkrautLM dataset
425
+ as chosen answers and [Sauerkraut-7b-HerO](https://huggingface.co/VAGOsolutions/SauerkrautLM-7b-HerO) as rejected answers. Added with additional **translated Parts of the [HuggingFaceH4/ultrafeedback_binarized](https://huggingface.co/datasets/HuggingFaceH4/ultrafeedback_binarized)** (Our dataset do not contain any TruthfulQA prompts - check Data Contamination Test Results) and **[argilla/distilabel-math-preference-dpo](https://huggingface.co/datasets/argilla/distilabel-math-preference-dpo).**
426
+ We found, that only a simple translation of training data can lead to unnatural German phrasings.
427
+ Data augmentation techniques were used to grant grammatical, syntactical correctness and a more natural German wording in our training data.
428
+
429
+ We improved the German language skills on this model. Nevertheless, certain formulations may occur that are not entirely correct.
430
+
431
+
432
+ ### Data Contamination Test Results
433
+
434
+ Some models on the HuggingFace leaderboard had problems with wrong data getting mixed in.
435
+ We checked our SauerkrautLM-DPO dataset with a special test [1] on this model as target model and upstage/SOLAR-10.7B-Instruct-v1.0 as reference model.
436
+ The HuggingFace team used the same methods [2, 3].
437
+
438
+ Our results, with `result < 0.1, %:` being well below 0.9, indicate that our dataset is free from contamination.
439
+
440
+ *The data contamination test results of HellaSwag and Winograde will be added once [1] supports them.*
441
+
442
+ | Dataset | ARC | MMLU | TruthfulQA | GSM8K |
443
+ |------------------------------|-------|-------|-------|-------|
444
+ | **SauerkrautLM-DPO**| result < 0.1, %: 0.0 |result < 0.1, %: 0.09 | result < 0.1, %: 0.13 | result < 0.1, %: 0.16 |
445
+
446
+ [1] https://github.com/swj0419/detect-pretrain-code-contamination
447
+
448
+ [2] https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard/discussions/474#657f2245365456e362412a06
449
+
450
+ [3] https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard/discussions/265#657b6debf81f6b44b8966230
451
+
452
+ ### Prompt Template:
453
+ ```
454
+ <|im_start|>system
455
+ Du bist LUNA-SOLARkrautLM, ein großes Sprachmodell, das höflich und kompetent antwortet.<|im_end|>
456
+ <|im_start|>user
457
+ Wie geht es dir?<|im_end|>
458
+ <|im_start|>assistant
459
+
460
+ ```
461
+
462
+ ```
463
+ ### User:
464
+ Hello, how are you?
465
+
466
+ ### Assistant:
467
+ Hi there! I am an AI language model, so I don't have personal feelings or emotions in the traditional sense. However, I can assure you that my systems and processes are functioning well at this moment, allowing me to provide helpful responses for your queries.
468
+ How may I assist you today?
469
+
470
+ ```
471
+
472
+ ## Evaluation
473
+ ```
474
+
475
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct), gen_kwargs: (), limit: None, num_fewshot: 5, batch_size: auto
476
+ |Tasks|Version| Filter |n-shot| Metric |Value | |Stderr|
477
+ |-----|-------|----------|-----:|-----------|-----:|---|-----:|
478
+ |gsm8k|Yaml |get-answer| 5|exact_match|0.6467|± |0.0132|
479
+
480
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct), gen_kwargs: (), limit: None, num_fewshot: 0, batch_size: auto (64)
481
+ | Tasks |Version|Filter|n-shot|Metric|Value | |Stderr|
482
+ |--------------|-------|------|-----:|------|-----:|---|-----:|
483
+ |truthfulqa_mc2|Yaml |none | 0|acc |0.7368|± |0.0149|
484
+
485
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct), gen_kwargs: (), limit: None, num_fewshot: 25, batch_size: auto (32)
486
+ | Tasks |Version|Filter|n-shot| Metric |Value| |Stderr|
487
+ |-------------|-------|------|-----:|--------|----:|---|-----:|
488
+ |arc_challenge|Yaml |none | 25|acc |0.692|± |0.0135|
489
+ | | |none | 25|acc_norm|0.715|± |0.0132|
490
+
491
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct), gen_kwargs: (), limit: None, num_fewshot: 0, batch_size: auto (64)
492
+ | Tasks |Version|Filter|n-shot|Metric| Value | |Stderr|
493
+ |-----------|-------|------|-----:|------|------:|---|-----:|
494
+ |paws_de |Yaml |none | 0|acc | 0.3965|± |0.0109|
495
+ |wmt16-en-de|Yaml |none | 0|bleu | 3.5784|± |0.1325|
496
+ | | |none | 0|ter |64.5707|± |0.4514|
497
+ | | |none | 0|chrf |45.7068|± |0.3861|
498
+ |xnli_de |Yaml |none | 0|acc | 0.4129|± |0.0099|
499
+
500
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct), gen_kwargs: (), limit: None, num_fewshot: 10, batch_size: auto (32)
501
+ | Tasks |Version|Filter|n-shot| Metric |Value | |Stderr|
502
+ |---------|-------|------|-----:|--------|-----:|---|-----:|
503
+ |hellaswag|Yaml |none | 10|acc |0.7131|± |0.0045|
504
+ | | |none | 10|acc_norm|0.8815|± |0.0032|
505
+
506
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct), gen_kwargs: (), limit: None, num_fewshot: 5, batch_size: auto (64)
507
+ | Tasks |Version|Filter|n-shot|Metric| Value | |Stderr|
508
+ |-----------|-------|------|-----:|------|------:|---|-----:|
509
+ |wmt16-de-en|Yaml |none | 5|bleu |14.9310|± |0.8014|
510
+ | | |none | 5|ter |46.3206|± |0.4087|
511
+ | | |none | 5|chrf |60.8637|± |0.4436|
512
+ |wmt16-en-de|Yaml |none | 5|bleu | 6.2016|± |0.2918|
513
+ | | |none | 5|ter |63.9997|± |0.4591|
514
+ | | |none | 5|chrf |51.1399|± |0.3978|
515
+ |xnli_de |Yaml |none | 5|acc | 0.4703|± |0.0100|
516
+
517
+ hf (pretrained=fblgit/LUNA-SOLARkrautLM-Instruct,dtype=float16), gen_kwargs: (), limit: None, num_fewshot: 5, batch_size: auto (16)
518
+ | Tasks |Version|Filter|n-shot|Metric|Value | |Stderr|
519
+ |---------------------------------------|-------|------|-----:|------|-----:|---|-----:|
520
+ |mmlu |N/A |none | 0|acc |0.6461|± |0.1215|
521
+ | - humanities |N/A |none | 5|acc |0.5960|± |0.1200|
522
+ | - formal_logic |Yaml |none | 5|acc |0.4683|± |0.0446|
523
+ | - high_school_european_history |Yaml |none | 5|acc |0.8121|± |0.0305|
524
+ | - high_school_us_history |Yaml |none | 5|acc |0.8480|± |0.0252|
525
+ | - high_school_world_history |Yaml |none | 5|acc |0.8312|± |0.0244|
526
+ | - international_law |Yaml |none | 5|acc |0.7851|± |0.0375|
527
+ | - jurisprudence |Yaml |none | 5|acc |0.7685|± |0.0408|
528
+ | - logical_fallacies |Yaml |none | 5|acc |0.7423|± |0.0344|
529
+ | - moral_disputes |Yaml |none | 5|acc |0.7283|± |0.0239|
530
+ | - moral_scenarios |Yaml |none | 5|acc |0.3899|± |0.0163|
531
+ | - philosophy |Yaml |none | 5|acc |0.7074|± |0.0258|
532
+ | - prehistory |Yaml |none | 5|acc |0.7716|± |0.0234|
533
+ | - professional_law |Yaml |none | 5|acc |0.4824|± |0.0128|
534
+ | - world_religions |Yaml |none | 5|acc |0.7661|± |0.0325|
535
+ | - other |N/A |none | 5|acc |0.7097|± |0.0900|
536
+ | - business_ethics |Yaml |none | 5|acc |0.7700|± |0.0423|
537
+ | - clinical_knowledge |Yaml |none | 5|acc |0.6792|± |0.0287|
538
+ | - college_medicine |Yaml |none | 5|acc |0.6647|± |0.0360|
539
+ | - global_facts |Yaml |none | 5|acc |0.3600|± |0.0482|
540
+ | - human_aging |Yaml |none | 5|acc |0.6861|± |0.0311|
541
+ | - management |Yaml |none | 5|acc |0.8350|± |0.0368|
542
+ | - marketing |Yaml |none | 5|acc |0.8504|± |0.0234|
543
+ | - medical_genetics |Yaml |none | 5|acc |0.6700|± |0.0473|
544
+ | - miscellaneous |Yaml |none | 5|acc |0.7893|± |0.0146|
545
+ | - nutrition |Yaml |none | 5|acc |0.7549|± |0.0246|
546
+ | - professional_accounting |Yaml |none | 5|acc |0.5213|± |0.0298|
547
+ | - professional_medicine |Yaml |none | 5|acc |0.7353|± |0.0268|
548
+ | - virology |Yaml |none | 5|acc |0.5783|± |0.0384|
549
+ | - social_sciences |N/A |none | 5|acc |0.7501|± |0.0684|
550
+ | - econometrics |Yaml |none | 5|acc |0.5175|± |0.0470|
551
+ | - high_school_geography |Yaml |none | 5|acc |0.8485|± |0.0255|
552
+ | - high_school_government_and_politics|Yaml |none | 5|acc |0.8912|± |0.0225|
553
+ | - high_school_macroeconomics |Yaml |none | 5|acc |0.6615|± |0.0240|
554
+ | - high_school_microeconomics |Yaml |none | 5|acc |0.7311|± |0.0288|
555
+ | - high_school_psychology |Yaml |none | 5|acc |0.8385|± |0.0158|
556
+ | - human_sexuality |Yaml |none | 5|acc |0.7023|± |0.0401|
557
+ | - professional_psychology |Yaml |none | 5|acc |0.6683|± |0.0190|
558
+ | - public_relations |Yaml |none | 5|acc |0.6909|± |0.0443|
559
+ | - security_studies |Yaml |none | 5|acc |0.7633|± |0.0272|
560
+ | - sociology |Yaml |none | 5|acc |0.8358|± |0.0262|
561
+ | - us_foreign_policy |Yaml |none | 5|acc |0.8800|± |0.0327|
562
+ | - stem |N/A |none | 5|acc |0.5569|± |0.1360|
563
+ | - abstract_algebra |Yaml |none | 5|acc |0.3800|± |0.0488|
564
+ | - anatomy |Yaml |none | 5|acc |0.6148|± |0.0420|
565
+ | - astronomy |Yaml |none | 5|acc |0.7237|± |0.0364|
566
+ | - college_biology |Yaml |none | 5|acc |0.7708|± |0.0351|
567
+ | - college_chemistry |Yaml |none | 5|acc |0.4600|± |0.0501|
568
+ | - college_computer_science |Yaml |none | 5|acc |0.5400|± |0.0501|
569
+ | - college_mathematics |Yaml |none | 5|acc |0.2700|± |0.0446|
570
+ | - college_physics |Yaml |none | 5|acc |0.3333|± |0.0469|
571
+ | - computer_security |Yaml |none | 5|acc |0.7300|± |0.0446|
572
+ | - conceptual_physics |Yaml |none | 5|acc |0.6213|± |0.0317|
573
+ | - electrical_engineering |Yaml |none | 5|acc |0.6276|± |0.0403|
574
+ | - elementary_mathematics |Yaml |none | 5|acc |0.4788|± |0.0257|
575
+ | - high_school_biology |Yaml |none | 5|acc |0.8065|± |0.0225|
576
+ | - high_school_chemistry |Yaml |none | 5|acc |0.5123|± |0.0352|
577
+ | - high_school_computer_science |Yaml |none | 5|acc |0.7000|± |0.0461|
578
+ | - high_school_mathematics |Yaml |none | 5|acc |0.3889|± |0.0297|
579
+ | - high_school_physics |Yaml |none | 5|acc |0.3576|± |0.0391|
580
+ | - high_school_statistics |Yaml |none | 5|acc |0.5926|± |0.0335|
581
+ | - machine_learning |Yaml |none | 5|acc |0.4554|± |0.0473|
582
+
583
+ | Groups |Version|Filter|n-shot|Metric|Value | |Stderr|
584
+ |------------------|-------|------|-----:|------|-----:|---|-----:|
585
+ |mmlu |N/A |none | 0|acc |0.6461|± |0.1215|
586
+ | - humanities |N/A |none | 5|acc |0.5960|± |0.1200|
587
+ | - other |N/A |none | 5|acc |0.7097|± |0.0900|
588
+ | - social_sciences|N/A |none | 5|acc |0.7501|± |0.0684|
589
+ | - stem |N/A |none | 5|acc |0.5569|± |0.1360|
590
+ ```
591
+ ### MT-Bench
592
+ ```
593
+ ########## Average ##########
594
+ score
595
+ model
596
+ gpt-4 8.990625
597
+ gpt-3.5-turbo 7.943750
598
+ claude-instant-v1 7.905660
599
+ claude-v1 7.900000
600
+ UNA-SOLAR-10.7B-Instruct-v1.0 7.521875
601
+ LUNA-SOLARkrautLM-Instruct 7.462500
602
+ vicuna-33b-v1.3 7.121875
603
+ wizardlm-30b 7.009375
604
+ Llama-2-70b-chat 6.856250
605
+ Llama-2-13b-chat 6.650000
606
+ guanaco-33b 6.528125
607
+ tulu-30b 6.434375
608
+ guanaco-65b 6.409375
609
+ oasst-sft-7-llama-30b 6.409375
610
+ palm-2-chat-bison-001 6.400000
611
+ mpt-30b-chat 6.393750
612
+ vicuna-13b-v1.3 6.387500
613
+ wizardlm-13b 6.353125
614
+ Llama-2-7b-chat 6.268750
615
+ vicuna-7b-v1.3 5.996875
616
+ baize-v2-13b 5.750000
617
+ nous-hermes-13b 5.553459
618
+ mpt-7b-chat 5.459119
619
+ gpt4all-13b-snoozy 5.452830
620
+ koala-13b 5.350000
621
+ mpt-30b-instruct 5.218750
622
+ falcon-40b-instruct 5.168750
623
+ h2ogpt-oasst-open-llama-13b 4.625000
624
+ alpaca-13b 4.531250
625
+ chatglm-6b 4.500000
626
+ oasst-sft-4-pythia-12b 4.318750
627
+ rwkv-4-raven-14b 3.984375
628
+ dolly-v2-12b 3.275000
629
+ fastchat-t5-3b 3.040625
630
+ stablelm-tuned-alpha-7b 2.753125
631
+ llama-13b 2.606250
632
+ ```
633
+
634
+ ## Disclaimer
635
+ We must inform users that despite our best efforts in data cleansing, the possibility of uncensored content slipping through cannot be entirely ruled out.
636
+ However, we cannot guarantee consistently appropriate behavior. Therefore, if you encounter any issues or come across inappropriate content, we kindly request that you inform us through the contact information provided.
637
+ Additionally, it is essential to understand that the licensing of these models does not constitute legal advice. We are not held responsible for the actions of third parties who utilize our models.
638
+  
639
+ ## Contact
640
+ If you are interested in customized LLMs for business applications, please get in contact with us via our website or contact us at [Dr. Daryoush Vaziri](mailto:vaziri@vago-solutions.de). We are also grateful for your feedback and suggestions.
641
+  
642
+ ## Collaborations
643
+ We are also keenly seeking support and investment for our startup, [VAGO Solutions](https://huggingface.co/VAGOsolutions), where we continuously advance the development of robust language models designed to address a diverse range of purposes and requirements. If the prospect of collaboratively navigating future challenges excites you, we warmly invite you to reach out to us.
644
+
645
+ [Juanako.AI](https://huggingface.co/fblgit) is also seeking support and investment for our startup, we also are open for collaborating with other labs to make awesome models like this one.
646
+
647
+ ## Acknowledgement
648
+ Big Hug to [VAGO Solutions](https://huggingface.co/VAGOsolutions), we merely used our UNA transformers library on their code and dataset, nothing else. This won't be possible without them, thanks!
649
+
650
+ Many thanks to [argilla](https://huggingface.co/datasets/argilla) and [Huggingface](https://huggingface.co) for providing such valuable datasets to the Open-Source community. And of course a big thanks to [upstage](https://huggingface.co/upstage) for providing the open source community with their latest technology!