TheBloke commited on
Commit
76e2610
1 Parent(s): 3972cb6

Upload README.md

Browse files
Files changed (1) hide show
  1. README.md +139 -69
README.md CHANGED
@@ -1,4 +1,5 @@
1
  ---
 
2
  inference: false
3
  language:
4
  - en
@@ -8,7 +9,22 @@ metrics:
8
  - ARC
9
  - HellaSwag
10
  - TruthfulQA
 
 
11
  model_type: llama
 
 
 
 
 
 
 
 
 
 
 
 
 
12
  tags:
13
  - llama
14
  ---
@@ -30,152 +46,204 @@ tags:
30
  <hr style="margin-top: 1.0em; margin-bottom: 1.0em;">
31
  <!-- header end -->
32
 
33
- # Lilloukas' Platypus 30B GPTQ
 
 
34
 
35
- These files are GPTQ model files for [Lilloukas' Platypus 30B](https://huggingface.co/lilloukas/Platypus-30B).
 
36
 
37
- 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.
38
 
39
- These models were quantised using hardware kindly provided by [Latitude.sh](https://www.latitude.sh/accelerate).
40
 
 
 
41
  ## Repositories available
42
 
 
43
  * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/Platypus-30B-GPTQ)
44
- * [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference](https://huggingface.co/TheBloke/Platypus-30B-GGML)
45
- * [Unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/lilloukas/Platypus-30B)
 
46
 
 
47
  ## Prompt template: Alpaca
48
 
49
  ```
50
  Below is an instruction that describes a task. Write a response that appropriately completes the request.
51
 
52
- ### Instruction: {prompt}
 
53
 
54
  ### Response:
 
55
  ```
56
 
57
- ## Provided files
 
 
 
 
 
 
 
 
 
 
 
58
 
59
  Multiple quantisation parameters are provided, to allow you to choose the best one for your hardware and requirements.
60
 
61
  Each separate quant is in a different branch. See below for instructions on fetching from different branches.
62
 
63
- | Branch | Bits | Group Size | Act Order (desc_act) | File Size | ExLlama Compatible? | Made With | Description |
64
- | ------ | ---- | ---------- | -------------------- | --------- | ------------------- | --------- | ----------- |
65
- | main | 4 | None | True | 16.94 GB | True | GPTQ-for-LLaMa | Most compatible option. Good inference speed in AutoGPTQ and GPTQ-for-LLaMa. Lower inference quality than other options. |
66
- | gptq-4bit-32g-actorder_True | 4 | 32 | True | 19.44 GB | True | AutoGPTQ | 4-bit, with Act Order and group size. 32g gives highest possible inference quality, with maximum VRAM usage. Poor AutoGPTQ CUDA speed. |
67
- | gptq-4bit-64g-actorder_True | 4 | 64 | True | 18.18 GB | True | AutoGPTQ | 4-bit, with Act Order and group size. 64g uses less VRAM, but with slightly lower accuracy. Poor AutoGPTQ CUDA speed. |
68
- | gptq-4bit-128g-actorder_True | 4 | 128 | True | 17.55 GB | True | AutoGPTQ | 4-bit, with Act Order and group size. 128g uses even less VRAM, but with slightly lower accuracy. Poor AutoGPTQ CUDA speed. |
69
- | gptq-8bit--1g-actorder_True | 8 | None | True | 32.99 GB | False | AutoGPTQ | 8-bit, with Act Order. No group size, to lower VRAM requirements and to improve AutoGPTQ speed. |
70
- | gptq-8bit-128g-actorder_False | 8 | 128 | False | 33.73 GB | False | AutoGPTQ | 8-bit, with group size 128g for higher inference quality and without Act Order to improve AutoGPTQ speed. |
71
- | gptq-3bit--1g-actorder_True | 3 | None | True | 12.92 GB | False | AutoGPTQ | 3-bit, with Act Order and no group size. Lowest possible VRAM requirements. May be lower quality than 3-bit 128g. |
72
- | gptq-3bit-128g-actorder_False | 3 | 128 | False | 13.51 GB | False | AutoGPTQ | 3-bit, with group size 128g but no act-order. Slightly higher VRAM requirements than 3-bit None. |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
73
 
 
 
 
74
  ## How to download from branches
75
 
76
- - In text-generation-webui, you can add `:branch` to the end of the download name, eg `TheBloke/Platypus-30B-GPTQ:gptq-4bit-32g-actorder_True`
77
  - With Git, you can clone a branch with:
78
  ```
79
- git clone --branch gptq-4bit-32g-actorder_True https://huggingface.co/TheBloke/Platypus-30B-GPTQ`
80
  ```
81
  - In Python Transformers code, the branch is the `revision` parameter; see below.
82
-
 
83
  ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
84
 
85
  Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
86
 
87
- It is strongly recommended to use the text-generation-webui one-click-installers unless you know how to make a manual install.
88
 
89
  1. Click the **Model tab**.
90
  2. Under **Download custom model or LoRA**, enter `TheBloke/Platypus-30B-GPTQ`.
91
- - To download from a specific branch, enter for example `TheBloke/Platypus-30B-GPTQ:gptq-4bit-32g-actorder_True`
92
  - see Provided Files above for the list of branches for each option.
93
  3. Click **Download**.
94
- 4. The model will start downloading. Once it's finished it will say "Done"
95
  5. In the top left, click the refresh icon next to **Model**.
96
  6. In the **Model** dropdown, choose the model you just downloaded: `Platypus-30B-GPTQ`
97
  7. The model will automatically load, and is now ready for use!
98
  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.
99
- * Note that you do not need to set GPTQ parameters any more. These are set automatically from the file `quantize_config.json`.
100
  9. Once you're ready, click the **Text Generation tab** and enter a prompt to get started!
 
101
 
 
102
  ## How to use this GPTQ model from Python code
103
 
104
- First make sure you have [AutoGPTQ](https://github.com/PanQiWei/AutoGPTQ) installed:
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
105
 
106
- `GITHUB_ACTIONS=true pip install auto-gptq`
 
 
 
 
107
 
108
- Then try the following example code:
109
 
110
  ```python
111
- from transformers import AutoTokenizer, pipeline, logging
112
- from auto_gptq import AutoGPTQForCausalLM, BaseQuantizeConfig
113
 
114
  model_name_or_path = "TheBloke/Platypus-30B-GPTQ"
115
- model_basename = "platypus-30b-GPTQ-4bit--1g.act.order"
116
-
117
- use_triton = False
 
 
 
118
 
119
  tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
120
 
121
- model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
122
- model_basename=model_basename
123
- use_safetensors=True,
124
- trust_remote_code=False,
125
- device="cuda:0",
126
- use_triton=use_triton,
127
- quantize_config=None)
128
-
129
- """
130
- To download from a specific branch, use the revision parameter, as in this example:
131
-
132
- model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
133
- revision="gptq-4bit-32g-actorder_True",
134
- model_basename=model_basename,
135
- use_safetensors=True,
136
- trust_remote_code=False,
137
- device="cuda:0",
138
- quantize_config=None)
139
- """
140
-
141
  prompt = "Tell me about AI"
142
  prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
143
 
144
- ### Instruction: {prompt}
 
145
 
146
  ### Response:
 
147
  '''
148
 
149
  print("\n\n*** Generate:")
150
 
151
  input_ids = tokenizer(prompt_template, return_tensors='pt').input_ids.cuda()
152
- output = model.generate(inputs=input_ids, temperature=0.7, max_new_tokens=512)
153
  print(tokenizer.decode(output[0]))
154
 
155
  # Inference can also be done using transformers' pipeline
156
 
157
- # Prevent printing spurious transformers error when using pipeline with AutoGPTQ
158
- logging.set_verbosity(logging.CRITICAL)
159
-
160
  print("*** Pipeline:")
161
  pipe = pipeline(
162
  "text-generation",
163
  model=model,
164
  tokenizer=tokenizer,
165
  max_new_tokens=512,
 
166
  temperature=0.7,
167
  top_p=0.95,
168
- repetition_penalty=1.15
 
169
  )
170
 
171
  print(pipe(prompt_template)[0]['generated_text'])
172
  ```
 
173
 
 
174
  ## Compatibility
175
 
176
- The files provided will work with AutoGPTQ (CUDA and Triton modes), GPTQ-for-LLaMa (only CUDA has been tested), and Occ4m's GPTQ-for-LLaMa fork.
177
 
178
- ExLlama works with Llama models in 4-bit. Please see the Provided Files table above for per-file compatibility.
 
 
 
179
 
180
  <!-- footer start -->
181
  <!-- 200823 -->
@@ -185,10 +253,12 @@ For further support, and discussions on these models and AI in general, join us
185
 
186
  [TheBloke AI's Discord server](https://discord.gg/theblokeai)
187
 
188
- ## Thanks, and how to contribute.
189
 
190
  Thanks to the [chirper.ai](https://chirper.ai) team!
191
 
 
 
192
  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.
193
 
194
  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.
@@ -200,7 +270,7 @@ Donaters will get priority support on any and all AI/LLM/model questions and req
200
 
201
  **Special thanks to**: Aemon Algiz.
202
 
203
- **Patreon special mentions**: Sam, theTransient, Jonathan Leane, Steven Wood, webtim, Johann-Peter Hartmann, Geoffrey Montalvo, Gabriel Tamborski, Willem Michiel, John Villwock, Derek Yates, Mesiah Bishop, Eugene Pentland, Pieter, Chadd, Stephen Murray, Daniel P. Andersen, terasurfer, Brandon Frisco, Thomas Belote, Sid, Nathan LeClaire, Magnesian, Alps Aficionado, Stanislav Ovsiannikov, Alex, Joseph William Delisle, Nikolai Manek, Michael Davis, Junyu Yang, K, J, Spencer Kim, Stefan Sabev, Olusegun Samson, transmissions 11, Michael Levine, Cory Kujawski, Rainer Wilmers, zynix, Kalila, Luke @flexchar, Ajan Kanaga, Mandus, vamX, Ai Maven, Mano Prime, Matthew Berman, subjectnull, Vitor Caleffi, Clay Pascal, biorpg, alfie_i, 阿明, Jeffrey Morgan, ya boyyy, Raymond Fosdick, knownsqashed, Olakabola, Leonard Tan, ReadyPlayerEmma, Enrico Ros, Dave, Talal Aujan, Illia Dulskyi, Sean Connelly, senxiiz, Artur Olbinski, Elle, Raven Klaugh, Fen Risland, Deep Realms, Imad Khwaja, Fred von Graf, Will Dee, usrbinkat, SuperWojo, Alexandros Triantafyllidis, Swaroop Kallakuri, Dan Guido, John Detwiler, Pedro Madruga, Iucharbius, Viktor Bowallius, Asp the Wyvern, Edmond Seymore, Trenton Dambrowitz, Space Cruiser, Spiking Neurons AB, Pyrater, LangChain4j, Tony Hughes, Kacper Wikieł, Rishabh Srivastava, David Ziegler, Luke Pendergrass, Andrey, Gabriel Puliatti, Lone Striker, Sebastain Graf, Pierre Kircher, Randy H, NimbleBox.ai, Vadim, danny, Deo Leter
204
 
205
 
206
  Thank you to all my generous patrons and donaters!
@@ -212,7 +282,7 @@ And thank you again to a16z for their generous grant.
212
  # Original model card: Lilloukas' Platypus 30B
213
 
214
 
215
- # 🥳 Platypus-30B has arrived!
216
 
217
  Platypus-30B is an instruction fine-tuned model based on the LLaMA-30B transformer architecture.
218
 
@@ -246,7 +316,7 @@ Dataset of highly filtered and curated question and answer pairs. Release TBD.
246
 
247
  ## Training Procedure
248
 
249
- `lilloukas/Platypus-30B` was instruction fine-tuned using LoRA on 4 A100 80GB. For training details and inference instructions please see the [Platypus-30B](https://github.com/arielnlee/Platypus-30B.git) GitHub repo.
250
 
251
  ## Reproducing Evaluation Results
252
  Install LM Evaluation Harness:
@@ -259,22 +329,22 @@ Each task was evaluated on a single A100 80GB GPU.
259
 
260
  ARC:
261
  ```
262
- python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks arc_challenge --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/arc_challenge_25shot.json --device cuda --num_fewshot 25
263
  ```
264
 
265
  HellaSwag:
266
  ```
267
- python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks hellaswag --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/hellaswag_10shot.json --device cuda --num_fewshot 10
268
  ```
269
 
270
  MMLU:
271
  ```
272
- python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks hendrycksTest-* --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/mmlu_5shot.json --device cuda --num_fewshot 5
273
  ```
274
 
275
  TruthfulQA:
276
  ```
277
- python main.py --model hf-causal-experimental --model_args pretrained=lilloukas/Platypus-30B --tasks truthfulqa_mc --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/truthfulqa_0shot.json --device cuda
278
  ```
279
  ## Limitations and bias
280
 
 
1
  ---
2
+ base_model: https://huggingface.co/lilloukas/Platypus-30B
3
  inference: false
4
  language:
5
  - en
 
9
  - ARC
10
  - HellaSwag
11
  - TruthfulQA
12
+ model_creator: lilloukas
13
+ model_name: Platypus 30B
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
  tags:
29
  - llama
30
  ---
 
46
  <hr style="margin-top: 1.0em; margin-bottom: 1.0em;">
47
  <!-- header end -->
48
 
49
+ # Platypus 30B - GPTQ
50
+ - Model creator: [lilloukas](https://huggingface.co/lilloukas)
51
+ - Original model: [Platypus 30B](https://huggingface.co/lilloukas/Platypus-30B)
52
 
53
+ <!-- description start -->
54
+ ## Description
55
 
56
+ This repo contains GPTQ model files for [Lilloukas' Platypus 30B](https://huggingface.co/lilloukas/Platypus-30B).
57
 
58
+ 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.
59
 
60
+ <!-- description end -->
61
+ <!-- repositories-available start -->
62
  ## Repositories available
63
 
64
+ * [AWQ model(s) for GPU inference.](https://huggingface.co/TheBloke/Platypus-30B-AWQ)
65
  * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/Platypus-30B-GPTQ)
66
+ * [2, 3, 4, 5, 6 and 8-bit GGUF models for CPU+GPU inference](https://huggingface.co/TheBloke/Platypus-30B-GGUF)
67
+ * [lilloukas's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/lilloukas/Platypus-30B)
68
+ <!-- repositories-available end -->
69
 
70
+ <!-- prompt-template start -->
71
  ## Prompt template: Alpaca
72
 
73
  ```
74
  Below is an instruction that describes a task. Write a response that appropriately completes the request.
75
 
76
+ ### Instruction:
77
+ {prompt}
78
 
79
  ### Response:
80
+
81
  ```
82
 
83
+ <!-- prompt-template end -->
84
+ <!-- licensing start -->
85
+ ## Licensing
86
+
87
+ The creator of the source model has listed its license as `other`, and this quantization has therefore used that same license.
88
+
89
+ As this model is based on Llama 2, it is also subject to the Meta Llama 2 license terms, and the license files for that are additionally included. It should therefore be considered as being claimed to be licensed under both licenses. I contacted Hugging Face for clarification on dual licensing but they do not yet have an official position. Should this change, or should Meta provide any feedback on this situation, I will update this section accordingly.
90
+
91
+ In the meantime, any questions regarding licensing, and in particular how these two licenses might interact, should be directed to the original model repository: [Lilloukas' Platypus 30B](https://huggingface.co/lilloukas/Platypus-30B).
92
+ <!-- licensing end -->
93
+ <!-- README_GPTQ.md-provided-files start -->
94
+ ## Provided files and GPTQ parameters
95
 
96
  Multiple quantisation parameters are provided, to allow you to choose the best one for your hardware and requirements.
97
 
98
  Each separate quant is in a different branch. See below for instructions on fetching from different branches.
99
 
100
+ All recent GPTQ files are made with AutoGPTQ, and all files in non-main branches are made with AutoGPTQ. Files in the `main` branch which were uploaded before August 2023 were made with GPTQ-for-LLaMa.
101
+
102
+ <details>
103
+ <summary>Explanation of GPTQ parameters</summary>
104
+
105
+ - Bits: The bit size of the quantised model.
106
+ - GS: GPTQ group size. Higher numbers use less VRAM, but have lower quantisation accuracy. "None" is the lowest possible value.
107
+ - 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.
108
+ - Damp %: A GPTQ parameter that affects how samples are processed for quantisation. 0.01 is default, but 0.1 results in slightly better accuracy.
109
+ - GPTQ dataset: The dataset used for quantisation. Using a dataset more appropriate to the model's training can improve quantisation accuracy. Note that the GPTQ 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).
110
+ - 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.
111
+ - ExLlama Compatibility: Whether this file can be loaded with ExLlama, which currently only supports Llama models in 4-bit.
112
+
113
+ </details>
114
+
115
+ | Branch | Bits | GS | Act Order | Damp % | GPTQ Dataset | Seq Len | Size | ExLlama | Desc |
116
+ | ------ | ---- | -- | --------- | ------ | ------------ | ------- | ---- | ------- | ---- |
117
+ | [main](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/main) | 4 | None | Yes | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 16.94 GB | Yes | 4-bit, with Act Order. No group size, to lower VRAM requirements. |
118
+ | [gptq-4bit-32g-actorder_True](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-4bit-32g-actorder_True) | 4 | 32 | Yes | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 19.44 GB | Yes | 4-bit, with Act Order and group size 32g. Gives highest possible inference quality, with maximum VRAM usage. |
119
+ | [gptq-4bit-64g-actorder_True](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-4bit-64g-actorder_True) | 4 | 64 | Yes | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 18.18 GB | Yes | 4-bit, with Act Order and group size 64g. Uses less VRAM than 32g, but with slightly lower accuracy. |
120
+ | [gptq-4bit-128g-actorder_True](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-4bit-128g-actorder_True) | 4 | 128 | Yes | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 17.55 GB | Yes | 4-bit, with Act Order and group size 128g. Uses even less VRAM than 64g, but with slightly lower accuracy. |
121
+ | [gptq-8bit--1g-actorder_True](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-8bit--1g-actorder_True) | 8 | None | Yes | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 32.99 GB | No | 8-bit, with Act Order. No group size, to lower VRAM requirements. |
122
+ | [gptq-8bit-128g-actorder_False](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-8bit-128g-actorder_False) | 8 | 128 | No | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 33.73 GB | No | 8-bit, with group size 128g for higher inference quality and without Act Order to improve AutoGPTQ speed. |
123
+ | [gptq-3bit--1g-actorder_True](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-3bit--1g-actorder_True) | 3 | None | Yes | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 12.92 GB | No | 3-bit, with Act Order and no group size. Lowest possible VRAM requirements. May be lower quality than 3-bit 128g. |
124
+ | [gptq-3bit-128g-actorder_False](https://huggingface.co/TheBloke/Platypus-30B-GPTQ/tree/gptq-3bit-128g-actorder_False) | 3 | 128 | No | 0.01 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 2048 | 13.51 GB | No | 3-bit, with group size 128g but no act-order. Slightly higher VRAM requirements than 3-bit None. |
125
 
126
+ <!-- README_GPTQ.md-provided-files end -->
127
+
128
+ <!-- README_GPTQ.md-download-from-branches start -->
129
  ## How to download from branches
130
 
131
+ - In text-generation-webui, you can add `:branch` to the end of the download name, eg `TheBloke/Platypus-30B-GPTQ:main`
132
  - With Git, you can clone a branch with:
133
  ```
134
+ git clone --single-branch --branch main https://huggingface.co/TheBloke/Platypus-30B-GPTQ
135
  ```
136
  - In Python Transformers code, the branch is the `revision` parameter; see below.
137
+ <!-- README_GPTQ.md-download-from-branches end -->
138
+ <!-- README_GPTQ.md-text-generation-webui start -->
139
  ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
140
 
141
  Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
142
 
143
+ 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.
144
 
145
  1. Click the **Model tab**.
146
  2. Under **Download custom model or LoRA**, enter `TheBloke/Platypus-30B-GPTQ`.
147
+ - To download from a specific branch, enter for example `TheBloke/Platypus-30B-GPTQ:main`
148
  - see Provided Files above for the list of branches for each option.
149
  3. Click **Download**.
150
+ 4. The model will start downloading. Once it's finished it will say "Done".
151
  5. In the top left, click the refresh icon next to **Model**.
152
  6. In the **Model** dropdown, choose the model you just downloaded: `Platypus-30B-GPTQ`
153
  7. The model will automatically load, and is now ready for use!
154
  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.
155
+ * 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`.
156
  9. Once you're ready, click the **Text Generation tab** and enter a prompt to get started!
157
+ <!-- README_GPTQ.md-text-generation-webui end -->
158
 
159
+ <!-- README_GPTQ.md-use-from-python start -->
160
  ## How to use this GPTQ model from Python code
161
 
162
+ ### Install the necessary packages
163
+
164
+ Requires: Transformers 4.32.0 or later, Optimum 1.12.0 or later, and AutoGPTQ 0.4.2 or later.
165
+
166
+ ```shell
167
+ pip3 install transformers>=4.32.0 optimum>=1.12.0
168
+ pip3 install auto-gptq --extra-index-url https://huggingface.github.io/autogptq-index/whl/cu118/ # Use cu117 if on CUDA 11.7
169
+ ```
170
+
171
+ If you have problems installing AutoGPTQ using the pre-built wheels, install it from source instead:
172
+
173
+ ```shell
174
+ pip3 uninstall -y auto-gptq
175
+ git clone https://github.com/PanQiWei/AutoGPTQ
176
+ cd AutoGPTQ
177
+ pip3 install .
178
+ ```
179
+
180
+ ### For CodeLlama models only: you must use Transformers 4.33.0 or later.
181
 
182
+ If 4.33.0 is not yet released when you read this, you will need to install Transformers from source:
183
+ ```shell
184
+ pip3 uninstall -y transformers
185
+ pip3 install git+https://github.com/huggingface/transformers.git
186
+ ```
187
 
188
+ ### You can then use the following code
189
 
190
  ```python
191
+ from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
 
192
 
193
  model_name_or_path = "TheBloke/Platypus-30B-GPTQ"
194
+ # To use a different branch, change revision
195
+ # For example: revision="main"
196
+ model = AutoModelForCausalLM.from_pretrained(model_name_or_path,
197
+ device_map="auto",
198
+ trust_remote_code=False,
199
+ revision="main")
200
 
201
  tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
202
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
203
  prompt = "Tell me about AI"
204
  prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
205
 
206
+ ### Instruction:
207
+ {prompt}
208
 
209
  ### Response:
210
+
211
  '''
212
 
213
  print("\n\n*** Generate:")
214
 
215
  input_ids = tokenizer(prompt_template, return_tensors='pt').input_ids.cuda()
216
+ output = model.generate(inputs=input_ids, temperature=0.7, do_sample=True, top_p=0.95, top_k=40, max_new_tokens=512)
217
  print(tokenizer.decode(output[0]))
218
 
219
  # Inference can also be done using transformers' pipeline
220
 
 
 
 
221
  print("*** Pipeline:")
222
  pipe = pipeline(
223
  "text-generation",
224
  model=model,
225
  tokenizer=tokenizer,
226
  max_new_tokens=512,
227
+ do_sample=True,
228
  temperature=0.7,
229
  top_p=0.95,
230
+ top_k=40,
231
+ repetition_penalty=1.1
232
  )
233
 
234
  print(pipe(prompt_template)[0]['generated_text'])
235
  ```
236
+ <!-- README_GPTQ.md-use-from-python end -->
237
 
238
+ <!-- README_GPTQ.md-compatibility start -->
239
  ## Compatibility
240
 
241
+ The files provided are tested to work with AutoGPTQ, both via Transformers and using AutoGPTQ directly. They should also work with [Occ4m's GPTQ-for-LLaMa fork](https://github.com/0cc4m/KoboldAI).
242
 
243
+ [ExLlama](https://github.com/turboderp/exllama) is compatible with Llama models in 4-bit. Please see the Provided Files table above for per-file compatibility.
244
+
245
+ [Huggingface Text Generation Inference (TGI)](https://github.com/huggingface/text-generation-inference) is compatible with all GPTQ models.
246
+ <!-- README_GPTQ.md-compatibility end -->
247
 
248
  <!-- footer start -->
249
  <!-- 200823 -->
 
253
 
254
  [TheBloke AI's Discord server](https://discord.gg/theblokeai)
255
 
256
+ ## Thanks, and how to contribute
257
 
258
  Thanks to the [chirper.ai](https://chirper.ai) team!
259
 
260
+ Thanks to Clay from [gpus.llm-utils.org](llm-utils)!
261
+
262
  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.
263
 
264
  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.
 
270
 
271
  **Special thanks to**: Aemon Algiz.
272
 
273
+ **Patreon special mentions**: Alicia Loh, Stephen Murray, K, Ajan Kanaga, RoA, Magnesian, Deo Leter, Olakabola, Eugene Pentland, zynix, Deep Realms, Raymond Fosdick, Elijah Stavena, Iucharbius, Erik Bjäreholt, Luis Javier Navarrete Lozano, Nicholas, theTransient, John Detwiler, alfie_i, knownsqashed, Mano Prime, Willem Michiel, Enrico Ros, LangChain4j, OG, Michael Dempsey, Pierre Kircher, Pedro Madruga, James Bentley, Thomas Belote, Luke @flexchar, Leonard Tan, Johann-Peter Hartmann, Illia Dulskyi, Fen Risland, Chadd, S_X, Jeff Scroggin, Ken Nordquist, Sean Connelly, Artur Olbinski, Swaroop Kallakuri, Jack West, Ai Maven, David Ziegler, Russ Johnson, transmissions 11, John Villwock, Alps Aficionado, Clay Pascal, Viktor Bowallius, Subspace Studios, Rainer Wilmers, Trenton Dambrowitz, vamX, Michael Levine, 준교 김, Brandon Frisco, Kalila, Trailburnt, Randy H, Talal Aujan, Nathan Dryer, Vadim, 阿明, ReadyPlayerEmma, Tiffany J. Kim, George Stoitzev, Spencer Kim, Jerry Meng, Gabriel Tamborski, Cory Kujawski, Jeffrey Morgan, Spiking Neurons AB, Edmond Seymore, Alexandros Triantafyllidis, Lone Striker, Cap'n Zoog, Nikolai Manek, danny, ya boyyy, Derek Yates, usrbinkat, Mandus, TL, Nathan LeClaire, subjectnull, Imad Khwaja, webtim, Raven Klaugh, Asp the Wyvern, Gabriel Puliatti, Caitlyn Gatomon, Joseph William Delisle, Jonathan Leane, Luke Pendergrass, SuperWojo, Sebastain Graf, Will Dee, Fred von Graf, Andrey, Dan Guido, Daniel P. Andersen, Nitin Borwankar, Elle, Vitor Caleffi, biorpg, jjj, NimbleBox.ai, Pieter, Matthew Berman, terasurfer, Michael Davis, Alex, Stanislav Ovsiannikov
274
 
275
 
276
  Thank you to all my generous patrons and donaters!
 
282
  # Original model card: Lilloukas' Platypus 30B
283
 
284
 
285
+ # 🥳 Platypus-30B has arrived!
286
 
287
  Platypus-30B is an instruction fine-tuned model based on the LLaMA-30B transformer architecture.
288
 
 
316
 
317
  ## Training Procedure
318
 
319
+ `garage-bAInd/Platypus-30B` was instruction fine-tuned using LoRA on 4 A100 80GB. For training details and inference instructions please see the [Platypus-30B](https://github.com/arielnlee/Platypus-30B.git) GitHub repo.
320
 
321
  ## Reproducing Evaluation Results
322
  Install LM Evaluation Harness:
 
329
 
330
  ARC:
331
  ```
332
+ python main.py --model hf-causal-experimental --model_args pretrained=garage-bAIdnd/Platypus-30B --tasks arc_challenge --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/arc_challenge_25shot.json --device cuda --num_fewshot 25
333
  ```
334
 
335
  HellaSwag:
336
  ```
337
+ python main.py --model hf-causal-experimental --model_args pretrained=garage-bAIdnd/Platypus-30B --tasks hellaswag --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/hellaswag_10shot.json --device cuda --num_fewshot 10
338
  ```
339
 
340
  MMLU:
341
  ```
342
+ python main.py --model hf-causal-experimental --model_args pretrained=garage-bAIdnd/Platypus-30B --tasks hendrycksTest-* --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/mmlu_5shot.json --device cuda --num_fewshot 5
343
  ```
344
 
345
  TruthfulQA:
346
  ```
347
+ python main.py --model hf-causal-experimental --model_args pretrained=garage-bAIdnd/Platypus-30B --tasks truthfulqa_mc --batch_size 1 --no_cache --write_out --output_path results/Platypus-30B/truthfulqa_0shot.json --device cuda
348
  ```
349
  ## Limitations and bias
350