TheBloke commited on
Commit
74aacf5
1 Parent(s): 6801dba

Upload README.md

Browse files
Files changed (1) hide show
  1. README.md +494 -0
README.md ADDED
@@ -0,0 +1,494 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ base_model: deepnight-research/Saily_220B
3
+ datasets:
4
+ - tiiuae/falcon-refinedweb
5
+ - EleutherAI/pile
6
+ - meta-math/MetaMathQA
7
+ inference: false
8
+ language:
9
+ - en
10
+ library_name: transformers
11
+ license: llama2
12
+ model_creator: DEEPNIGHT
13
+ model_name: Saily 220B
14
+ model_type: llama
15
+ prompt_template: 'Below is an instruction that describes a task. Write a response
16
+ that appropriately completes the request.
17
+
18
+
19
+ ### Instruction:
20
+
21
+ {prompt}
22
+
23
+
24
+ ### Response:
25
+
26
+ '
27
+ quantized_by: TheBloke
28
+ ---
29
+ <!-- markdownlint-disable MD041 -->
30
+
31
+ <!-- header start -->
32
+ <!-- 200823 -->
33
+ <div style="width: auto; margin-left: auto; margin-right: auto">
34
+ <img src="https://i.imgur.com/EBdldam.jpg" alt="TheBlokeAI" style="width: 100%; min-width: 400px; display: block; margin: auto;">
35
+ </div>
36
+ <div style="display: flex; justify-content: space-between; width: 100%;">
37
+ <div style="display: flex; flex-direction: column; align-items: flex-start;">
38
+ <p style="margin-top: 0.5em; margin-bottom: 0em;"><a href="https://discord.gg/theblokeai">Chat & support: TheBloke's Discord server</a></p>
39
+ </div>
40
+ <div style="display: flex; flex-direction: column; align-items: flex-end;">
41
+ <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>
42
+ </div>
43
+ </div>
44
+ <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>
45
+ <hr style="margin-top: 1.0em; margin-bottom: 1.0em;">
46
+ <!-- header end -->
47
+
48
+ # Saily 220B - GPTQ
49
+ - Model creator: [DEEPNIGHT](https://huggingface.co/deepnight-research)
50
+ - Original model: [Saily 220B](https://huggingface.co/deepnight-research/Saily_220B)
51
+
52
+ <!-- description start -->
53
+ # Description
54
+
55
+ This repo contains GPTQ model files for [DEEPNIGHT's Saily 220B](https://huggingface.co/deepnight-research/Saily_220B).
56
+
57
+ 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.
58
+
59
+ <!-- description end -->
60
+ <!-- repositories-available start -->
61
+ ## Repositories available
62
+
63
+ * [AWQ model(s) for GPU inference.](https://huggingface.co/TheBloke/Saily_220B-AWQ)
64
+ * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/Saily_220B-GPTQ)
65
+ * [2, 3, 4, 5, 6 and 8-bit GGUF models for CPU+GPU inference](https://huggingface.co/TheBloke/Saily_220B-GGUF)
66
+ * [DEEPNIGHT's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/deepnight-research/Saily_220B)
67
+ <!-- repositories-available end -->
68
+
69
+ <!-- prompt-template start -->
70
+ ## Prompt template: Alpaca
71
+
72
+ ```
73
+ Below is an instruction that describes a task. Write a response that appropriately completes the request.
74
+
75
+ ### Instruction:
76
+ {prompt}
77
+
78
+ ### Response:
79
+
80
+ ```
81
+
82
+ <!-- prompt-template end -->
83
+
84
+
85
+
86
+ <!-- README_GPTQ.md-compatible clients start -->
87
+ ## Known compatible clients / servers
88
+
89
+ GPTQ models are currently supported on Linux (NVidia/AMD) and Windows (NVidia only). macOS users: please use GGUF models.
90
+
91
+ These GPTQ models are known to work in the following inference servers/webuis.
92
+
93
+ - [text-generation-webui](https://github.com/oobabooga/text-generation-webui)
94
+ - [KoboldAI United](https://github.com/henk717/koboldai)
95
+ - [LoLLMS Web UI](https://github.com/ParisNeo/lollms-webui)
96
+ - [Hugging Face Text Generation Inference (TGI)](https://github.com/huggingface/text-generation-inference)
97
+
98
+ This may not be a complete list; if you know of others, please let me know!
99
+ <!-- README_GPTQ.md-compatible clients end -->
100
+
101
+ <!-- README_GPTQ.md-provided-files start -->
102
+ ## Provided files, and GPTQ parameters
103
+
104
+ Multiple quantisation parameters are provided, to allow you to choose the best one for your hardware and requirements.
105
+
106
+ Each separate quant is in a different branch. See below for instructions on fetching from different branches.
107
+
108
+ Most GPTQ files are made with AutoGPTQ. Mistral models are currently made with Transformers.
109
+
110
+ <details>
111
+ <summary>Explanation of GPTQ parameters</summary>
112
+
113
+ - Bits: The bit size of the quantised model.
114
+ - GS: GPTQ group size. Higher numbers use less VRAM, but have lower quantisation accuracy. "None" is the lowest possible value.
115
+ - 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.
116
+ - Damp %: A GPTQ parameter that affects how samples are processed for quantisation. 0.01 is default, but 0.1 results in slightly better accuracy.
117
+ - 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).
118
+ - 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.
119
+ - ExLlama Compatibility: Whether this file can be loaded with ExLlama, which currently only supports Llama and Mistral models in 4-bit.
120
+
121
+ </details>
122
+
123
+ | Branch | Bits | GS | Act Order | Damp % | GPTQ Dataset | Seq Len | Size | ExLlama | Desc |
124
+ | ------ | ---- | -- | --------- | ------ | ------------ | ------- | ---- | ------- | ---- |
125
+ | [main](https://huggingface.co/TheBloke/Saily_220B-GPTQ/tree/main) | 4 | None | Yes | 0.1 | [VMware Open Instruct](https://huggingface.co/datasets/VMware/open-instruct/viewer/) | 4096 | 48.99 GB | Yes | 4-bit, with Act Order. No group size, to lower VRAM requirements. |
126
+ | [gptq-4bit-128g-actorder_True](https://huggingface.co/TheBloke/Saily_220B-GPTQ/tree/gptq-4bit-128g-actorder_True) | 4 | 128 | Yes | 0.1 | [VMware Open Instruct](https://huggingface.co/datasets/VMware/open-instruct/viewer/) | 4096 | 109.20 GB | Yes | 4-bit, with Act Order and group size 128g. Uses even less VRAM than 64g, but with slightly lower accuracy. |
127
+ | [gptq-3bit--1g-actorder_True](https://huggingface.co/TheBloke/Saily_220B-GPTQ/tree/gptq-3bit--1g-actorder_True) | 3 | None | Yes | 0.1 | [VMware Open Instruct](https://huggingface.co/datasets/VMware/open-instruct/viewer/) | 4096 | 48.99 GB | No | 3-bit, with Act Order and no group size. Lowest possible VRAM requirements. May be lower quality than 3-bit 128g. |
128
+ | [gptq-3bit-128g-actorder_True](https://huggingface.co/TheBloke/Saily_220B-GPTQ/tree/gptq-3bit-128g-actorder_True) | 3 | 128 | Yes | 0.1 | [VMware Open Instruct](https://huggingface.co/datasets/VMware/open-instruct/viewer/) | 4096 | 83.00 GB | No | 3-bit, with group size 128g and act-order. Higher quality than 128g-False. |
129
+
130
+ <!-- README_GPTQ.md-provided-files end -->
131
+
132
+ <!-- README_GPTQ.md-download-from-branches start -->
133
+ ## How to download, including from branches
134
+
135
+ ### In text-generation-webui
136
+
137
+ To download from the `main` branch, enter `TheBloke/Saily_220B-GPTQ` in the "Download model" box.
138
+
139
+ To download from another branch, add `:branchname` to the end of the download name, eg `TheBloke/Saily_220B-GPTQ:gptq-4bit-128g-actorder_True`
140
+
141
+ ### From the command line
142
+
143
+ I recommend using the `huggingface-hub` Python library:
144
+
145
+ ```shell
146
+ pip3 install huggingface-hub
147
+ ```
148
+
149
+ To download the `main` branch to a folder called `Saily_220B-GPTQ`:
150
+
151
+ ```shell
152
+ mkdir Saily_220B-GPTQ
153
+ huggingface-cli download TheBloke/Saily_220B-GPTQ --local-dir Saily_220B-GPTQ --local-dir-use-symlinks False
154
+ ```
155
+
156
+ To download from a different branch, add the `--revision` parameter:
157
+
158
+ ```shell
159
+ mkdir Saily_220B-GPTQ
160
+ huggingface-cli download TheBloke/Saily_220B-GPTQ --revision gptq-4bit-128g-actorder_True --local-dir Saily_220B-GPTQ --local-dir-use-symlinks False
161
+ ```
162
+
163
+ <details>
164
+ <summary>More advanced huggingface-cli download usage</summary>
165
+
166
+ 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.
167
+
168
+ The cache location can be changed with the `HF_HOME` environment variable, and/or the `--cache-dir` parameter to `huggingface-cli`.
169
+
170
+ 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).
171
+
172
+ To accelerate downloads on fast connections (1Gbit/s or higher), install `hf_transfer`:
173
+
174
+ ```shell
175
+ pip3 install hf_transfer
176
+ ```
177
+
178
+ And set environment variable `HF_HUB_ENABLE_HF_TRANSFER` to `1`:
179
+
180
+ ```shell
181
+ mkdir Saily_220B-GPTQ
182
+ HF_HUB_ENABLE_HF_TRANSFER=1 huggingface-cli download TheBloke/Saily_220B-GPTQ --local-dir Saily_220B-GPTQ --local-dir-use-symlinks False
183
+ ```
184
+
185
+ Windows Command Line users: You can set the environment variable by running `set HF_HUB_ENABLE_HF_TRANSFER=1` before the download command.
186
+ </details>
187
+
188
+ ### With `git` (**not** recommended)
189
+
190
+ To clone a specific branch with `git`, use a command like this:
191
+
192
+ ```shell
193
+ git clone --single-branch --branch gptq-4bit-128g-actorder_True https://huggingface.co/TheBloke/Saily_220B-GPTQ
194
+ ```
195
+
196
+ 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.)
197
+
198
+ <!-- README_GPTQ.md-download-from-branches end -->
199
+ <!-- README_GPTQ.md-text-generation-webui start -->
200
+ ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui)
201
+
202
+ Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
203
+
204
+ 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.
205
+
206
+ 1. Click the **Model tab**.
207
+ 2. Under **Download custom model or LoRA**, enter `TheBloke/Saily_220B-GPTQ`.
208
+
209
+ - To download from a specific branch, enter for example `TheBloke/Saily_220B-GPTQ:gptq-4bit-128g-actorder_True`
210
+ - see Provided Files above for the list of branches for each option.
211
+
212
+ 3. Click **Download**.
213
+ 4. The model will start downloading. Once it's finished it will say "Done".
214
+ 5. In the top left, click the refresh icon next to **Model**.
215
+ 6. In the **Model** dropdown, choose the model you just downloaded: `Saily_220B-GPTQ`
216
+ 7. The model will automatically load, and is now ready for use!
217
+ 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.
218
+
219
+ - 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`.
220
+
221
+ 9. Once you're ready, click the **Text Generation** tab and enter a prompt to get started!
222
+
223
+ <!-- README_GPTQ.md-text-generation-webui end -->
224
+
225
+ <!-- README_GPTQ.md-use-from-tgi start -->
226
+ ## Serving this model from Text Generation Inference (TGI)
227
+
228
+ 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`
229
+
230
+ Example Docker parameters:
231
+
232
+ ```shell
233
+ --model-id TheBloke/Saily_220B-GPTQ --port 3000 --quantize gptq --max-input-length 3696 --max-total-tokens 4096 --max-batch-prefill-tokens 4096
234
+ ```
235
+
236
+ Example Python code for interfacing with TGI (requires huggingface-hub 0.17.0 or later):
237
+
238
+ ```shell
239
+ pip3 install huggingface-hub
240
+ ```
241
+
242
+ ```python
243
+ from huggingface_hub import InferenceClient
244
+
245
+ endpoint_url = "https://your-endpoint-url-here"
246
+
247
+ prompt = "Tell me about AI"
248
+ prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
249
+
250
+ ### Instruction:
251
+ {prompt}
252
+
253
+ ### Response:
254
+ '''
255
+
256
+ client = InferenceClient(endpoint_url)
257
+ response = client.text_generation(prompt,
258
+ max_new_tokens=128,
259
+ do_sample=True,
260
+ temperature=0.7,
261
+ top_p=0.95,
262
+ top_k=40,
263
+ repetition_penalty=1.1)
264
+
265
+ print(f"Model output: {response}")
266
+ ```
267
+ <!-- README_GPTQ.md-use-from-tgi end -->
268
+ <!-- README_GPTQ.md-use-from-python start -->
269
+ ## Python code example: inference from this GPTQ model
270
+
271
+ ### Install the necessary packages
272
+
273
+ Requires: Transformers 4.33.0 or later, Optimum 1.12.0 or later, and AutoGPTQ 0.4.2 or later.
274
+
275
+ ```shell
276
+ pip3 install --upgrade transformers optimum
277
+ # If using PyTorch 2.1 + CUDA 12.x:
278
+ pip3 install --upgrade auto-gptq
279
+ # or, if using PyTorch 2.1 + CUDA 11.x:
280
+ pip3 install --upgrade auto-gptq --extra-index-url https://huggingface.github.io/autogptq-index/whl/cu118/
281
+ ```
282
+
283
+ 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:
284
+
285
+ ```shell
286
+ pip3 uninstall -y auto-gptq
287
+ git clone https://github.com/PanQiWei/AutoGPTQ
288
+ cd AutoGPTQ
289
+ git checkout v0.5.1
290
+ pip3 install .
291
+ ```
292
+
293
+ ### Example Python code
294
+
295
+ ```python
296
+ from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
297
+
298
+ model_name_or_path = "TheBloke/Saily_220B-GPTQ"
299
+ # To use a different branch, change revision
300
+ # For example: revision="gptq-4bit-128g-actorder_True"
301
+ model = AutoModelForCausalLM.from_pretrained(model_name_or_path,
302
+ device_map="auto",
303
+ trust_remote_code=False,
304
+ revision="main")
305
+
306
+ tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
307
+
308
+ prompt = "Write a story about llamas"
309
+ system_message = "You are a story writing assistant"
310
+ prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
311
+
312
+ ### Instruction:
313
+ {prompt}
314
+
315
+ ### Response:
316
+ '''
317
+
318
+ print("\n\n*** Generate:")
319
+
320
+ input_ids = tokenizer(prompt_template, return_tensors='pt').input_ids.cuda()
321
+ output = model.generate(inputs=input_ids, temperature=0.7, do_sample=True, top_p=0.95, top_k=40, max_new_tokens=512)
322
+ print(tokenizer.decode(output[0]))
323
+
324
+ # Inference can also be done using transformers' pipeline
325
+
326
+ print("*** Pipeline:")
327
+ pipe = pipeline(
328
+ "text-generation",
329
+ model=model,
330
+ tokenizer=tokenizer,
331
+ max_new_tokens=512,
332
+ do_sample=True,
333
+ temperature=0.7,
334
+ top_p=0.95,
335
+ top_k=40,
336
+ repetition_penalty=1.1
337
+ )
338
+
339
+ print(pipe(prompt_template)[0]['generated_text'])
340
+ ```
341
+ <!-- README_GPTQ.md-use-from-python end -->
342
+
343
+ <!-- README_GPTQ.md-compatibility start -->
344
+ ## Compatibility
345
+
346
+ The files provided are tested to work with Transformers. For non-Mistral models, AutoGPTQ can also be used directly.
347
+
348
+ [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.
349
+
350
+ For a list of clients/servers, please see "Known compatible clients / servers", above.
351
+ <!-- README_GPTQ.md-compatibility end -->
352
+
353
+ <!-- footer start -->
354
+ <!-- 200823 -->
355
+ ## Discord
356
+
357
+ For further support, and discussions on these models and AI in general, join us at:
358
+
359
+ [TheBloke AI's Discord server](https://discord.gg/theblokeai)
360
+
361
+ ## Thanks, and how to contribute
362
+
363
+ Thanks to the [chirper.ai](https://chirper.ai) team!
364
+
365
+ Thanks to Clay from [gpus.llm-utils.org](llm-utils)!
366
+
367
+ 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.
368
+
369
+ 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.
370
+
371
+ Donaters will get priority support on any and all AI/LLM/model questions and requests, access to a private Discord room, plus other benefits.
372
+
373
+ * Patreon: https://patreon.com/TheBlokeAI
374
+ * Ko-Fi: https://ko-fi.com/TheBlokeAI
375
+
376
+ **Special thanks to**: Aemon Algiz.
377
+
378
+ **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
379
+
380
+
381
+ Thank you to all my generous patrons and donaters!
382
+
383
+ And thank you again to a16z for their generous grant.
384
+
385
+ <!-- footer end -->
386
+
387
+ # Original model card: DEEPNIGHT's Saily 220B
388
+
389
+ # Saily 220B
390
+ <img src="https://i.ibb.co/rG8S6cF/Saily-220-B.png" style="width: 100%; height: auto;"/>
391
+
392
+ ---
393
+ ## Announcements
394
+ **1.** <b>Date: </b>17th December, 2023
395
+ Releasing v1. Saily_220B is a powerful AI model built on top of Llama2-70B merges.
396
+ We created 10 fine-tuned **Llama2 70B** models. The models were were fine-tuned on a part of Refined-Web Dataset (common for all)
397
+ and individually the models were finetuned on niche specific datasets:
398
+ - Code
399
+ - Humor
400
+ - Maths
401
+ - Logical Understanding
402
+ - Physics
403
+ - Reasoning
404
+ - Psychology
405
+ - Roleplay
406
+
407
+ We created 4 linear merges while keeping **Logical-Understanding** and **Reasoning** models constant in all linear merges.
408
+ and then finally we created a passthrough merge between the models.
409
+
410
+ Public Datasets used:
411
+ 1. [RefinedWeb](https://hf.co/datasets/tiiuae/falcon-refinedweb) (part of it)
412
+ 2. Pile (part of it)
413
+ 3. [MetaMathQA](https://hf.co/datasets/meta-math/MetaMathQA)
414
+ 4. Unnatural Code (Javascript, Python, C++)
415
+
416
+ ### How did we create the private dataset?
417
+ We recorded many internal brain-storming sessions where we just talked about random things.
418
+ We also invited many experts from different fields:
419
+ - Mathematicians
420
+ - Developers
421
+ - Bio-Engineers
422
+ - Authors
423
+ - Psychologists
424
+ - and others...
425
+
426
+ We talked about different things with them and recorded the sessions and then transcribed the audio to create the datasets.
427
+
428
+ ---
429
+
430
+ ### Please don't refer to the config.json in the files, it isn't accurate. You can run:
431
+ ```python
432
+ from transformers import AutoModelForCausalLM as amclm
433
+ model = amclm.from_pretrained("deepnight-research/saily_220b",
434
+ device_map="auto")
435
+
436
+ # print(model.config)
437
+ model.config
438
+ ```
439
+ to check out the model's configuration.
440
+
441
+ ---
442
+
443
+
444
+ ### Try it:
445
+
446
+ You definitely need GPUs here (that goes without saying)
447
+ * We have tried it on **4 x A100 80GB** and **2 x A100 80GB**.
448
+ * You will have to load the model in **4bit** to fit on **2 x A100 (80GB)**.
449
+
450
+ ```python
451
+ from transformers import AutoModelForCausalLM as amclm
452
+ from transformers import AutoTokenizer
453
+
454
+ model_name = "deepnight-research/saily_220b"
455
+ model = amclm.from_pretrained(model_name, device_map="auto")
456
+
457
+ # To load in 8Bit, make sure you have bitsandbytes installed.
458
+ # model = amclm.from_pretrained(model_name,
459
+ # device_map="auto",
460
+ # load_in_8bit=True
461
+ # )
462
+
463
+ # Float16
464
+ # import torch
465
+ # model = amclm.from_pretrained(model_name,
466
+ # device_map="auto",
467
+ # torch_dtype=torch.float16
468
+ # )
469
+
470
+ tokenizer = AutoTokenier.from_pretrained(model_name)
471
+
472
+ input_ids = tokenizer.encode("[INST]\nWrite a poem about cats\n[/INST]\n\n", return_tensors="pt")
473
+
474
+ output = model.generate(input_ids, max_length=128,
475
+ temperature=0.7,
476
+ repetition_penalty=1.1,
477
+ top_p=0.7, top_k=50
478
+ )
479
+
480
+ output_text = tokenizer.decode(output[0], skip_special_tokens=True)
481
+ ```
482
+
483
+ We recommend following **Alpaca Prompt Format**, and if you're trying it out in Text-Generation-WebUI, please use **INSTRUCT** or **CHAT-INSTRUCT** mode.
484
+
485
+
486
+ ---
487
+
488
+ ## Limitations and Bias
489
+ As with all language models, Saily_220B may generate incorrect or biased content. It's important to keep this in mind when using the model.
490
+
491
+ ---
492
+
493
+ ## Wanna Talk?
494
+ Reach out to us at [research@deepnight.tech](mailto:research@deepnight.tech) or [hello@deepnight.tech](mailto:hello@deepnight.tech)