TheBloke commited on
Commit
adcad94
1 Parent(s): 4b565af

Upload new GPTQs with varied parameters

Browse files
Files changed (1) hide show
  1. README.md +71 -33
README.md CHANGED
@@ -2,14 +2,15 @@
2
  inference: false
3
  language:
4
  - en
5
- tags:
6
- - llama
7
  license: other
8
  metrics:
9
  - MMLU
10
- - ARC
11
  - HellaSwag
12
  - TruthfulQA
 
 
 
13
  ---
14
 
15
  <!-- header start -->
@@ -28,53 +29,84 @@ metrics:
28
 
29
  # Lilloukas' GPlatty 30B GPTQ
30
 
31
- These files are GPTQ 4bit model files for [Lilloukas' GPlatty 30B](https://huggingface.co/lilloukas/GPlatty-30B).
32
 
33
- It is the result of quantising to 4bit using [GPTQ-for-LLaMa](https://github.com/qwopqwop200/GPTQ-for-LLaMa).
 
 
34
 
35
  ## Repositories available
36
 
37
- * [4-bit GPTQ models for GPU inference](https://huggingface.co/TheBloke/GPlatty-30B-GPTQ)
38
  * [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference](https://huggingface.co/TheBloke/GPlatty-30B-GGML)
39
  * [Unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/lilloukas/GPlatty-30B)
40
 
41
- ## Prompt template
42
 
43
  ```
44
- Below is an instruction that describes a task. Write a response that appropriately completes the request
45
 
46
- ### Instruction: prompt
47
 
48
  ### Response:
49
  ```
50
 
51
- ## How to easily download and use this model in text-generation-webui
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
52
 
53
- Please make sure you're using the latest version of text-generation-webui
54
 
55
  1. Click the **Model tab**.
56
  2. Under **Download custom model or LoRA**, enter `TheBloke/GPlatty-30B-GPTQ`.
 
 
57
  3. Click **Download**.
58
  4. The model will start downloading. Once it's finished it will say "Done"
59
  5. In the top left, click the refresh icon next to **Model**.
60
  6. In the **Model** dropdown, choose the model you just downloaded: `GPlatty-30B-GPTQ`
61
  7. The model will automatically load, and is now ready for use!
62
  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.
63
- * 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`.
64
  9. Once you're ready, click the **Text Generation tab** and enter a prompt to get started!
65
 
66
  ## How to use this GPTQ model from Python code
67
 
68
  First make sure you have [AutoGPTQ](https://github.com/PanQiWei/AutoGPTQ) installed:
69
 
70
- `pip install auto-gptq`
71
 
72
  Then try the following example code:
73
 
74
  ```python
75
  from transformers import AutoTokenizer, pipeline, logging
76
  from auto_gptq import AutoGPTQForCausalLM, BaseQuantizeConfig
77
- import argparse
78
 
79
  model_name_or_path = "TheBloke/GPlatty-30B-GPTQ"
80
  model_basename = "gplatty-30b-GPTQ-4bit--1g.act.order"
@@ -84,17 +116,32 @@ use_triton = False
84
  tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
85
 
86
  model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
87
- model_basename=model_basename,
88
  use_safetensors=True,
89
  trust_remote_code=False,
90
  device="cuda:0",
91
  use_triton=use_triton,
92
  quantize_config=None)
93
 
94
- # Note: check the prompt template is correct for this model.
 
 
 
 
 
 
 
 
 
 
 
95
  prompt = "Tell me about AI"
96
- prompt_template=f'''USER: {prompt}
97
- ASSISTANT:'''
 
 
 
 
98
 
99
  print("\n\n*** Generate:")
100
 
@@ -121,20 +168,11 @@ pipe = pipeline(
121
  print(pipe(prompt_template)[0]['generated_text'])
122
  ```
123
 
124
- ## Provided files
125
-
126
- **gplatty-30b-GPTQ-4bit--1g.act.order.safetensors**
127
-
128
- This will work with AutoGPTQ, ExLlama, and CUDA versions of GPTQ-for-LLaMa. There are reports of issues with Triton mode of recent GPTQ-for-LLaMa. If you have issues, please use AutoGPTQ instead.
129
 
130
- It was created without group_size to lower VRAM requirements, and with --act-order (desc_act) to boost inference accuracy as much as possible.
131
 
132
- * `gplatty-30b-GPTQ-4bit--1g.act.order.safetensors`
133
- * Works with AutoGPTQ in CUDA or Triton modes.
134
- * LLaMa models also work with [ExLlama](https://github.com/turboderp/exllama}, which usually provides much higher performance, and uses less VRAM, than AutoGPTQ.
135
- * Works with GPTQ-for-LLaMa in CUDA mode. May have issues with GPTQ-for-LLaMa Triton mode.
136
- * Works with text-generation-webui, including one-click-installers.
137
- * Parameters: Groupsize = -1. Act Order / desc_act = True.
138
 
139
  <!-- footer start -->
140
  ## Discord
@@ -156,9 +194,9 @@ Donaters will get priority support on any and all AI/LLM/model questions and req
156
  * Patreon: https://patreon.com/TheBlokeAI
157
  * Ko-Fi: https://ko-fi.com/TheBlokeAI
158
 
159
- **Special thanks to**: Luke from CarbonQuill, Aemon Algiz, Dmitriy Samsonov.
160
 
161
- **Patreon special mentions**: Pyrater, WelcomeToTheClub, Kalila, Mano Prime, Trenton Dambrowitz, Spiking Neurons AB, Pierre Kircher, Fen Risland, Kevin Schuppel, Luke, Rainer Wilmers, vamX, Gabriel Puliatti, Alex , Karl Bernard, Ajan Kanaga, Talal Aujan, Space Cruiser, ya boyyy, biorpg, Johann-Peter Hartmann, Asp the Wyvern, Ai Maven, Ghost , Preetika Verma, Nikolai Manek, trip7s trip, John Detwiler, Fred von Graf, Artur Olbinski, subjectnull, John Villwock, Junyu Yang, Rod A, Lone Striker, Chris McCloskey, Iucharbius , Matthew Berman, Illia Dulskyi, Khalefa Al-Ahmad, Imad Khwaja, chris gileta, Willem Michiel, Greatston Gnanesh, Derek Yates, K, Alps Aficionado, Oscar Rangel, David Flickinger, Luke Pendergrass, Deep Realms, Eugene Pentland, Cory Kujawski, terasurfer , Jonathan Leane, senxiiz, Joseph William Delisle, Sean Connelly, webtim, zynix , Nathan LeClaire.
162
 
163
  Thank you to all my generous patrons and donaters!
164
 
@@ -183,7 +221,7 @@ We use state-of-the-art [Language Model Evaluation Harness](https://github.com/E
183
 
184
  ## Model Details
185
 
186
- * **Trained by**: Cole Hunter & Ariel Lee
187
  * **Model type:** **GPlatty-30B** is an auto-regressive language model based on the LLaMA transformer architecture.
188
  * **Language(s)**: English
189
  * **License for base weights**: License for the base LLaMA model's weights is Meta's [non-commercial bespoke license](https://github.com/facebookresearch/llama/blob/main/MODEL_CARD.md).
 
2
  inference: false
3
  language:
4
  - en
 
 
5
  license: other
6
  metrics:
7
  - MMLU
8
+ - ARC
9
  - HellaSwag
10
  - TruthfulQA
11
+ model_type: llama
12
+ tags:
13
+ - llama
14
  ---
15
 
16
  <!-- header start -->
 
29
 
30
  # Lilloukas' GPlatty 30B GPTQ
31
 
32
+ These files are GPTQ model files for [Lilloukas' GPlatty 30B](https://huggingface.co/lilloukas/GPlatty-30B).
33
 
34
+ 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.
35
+
36
+ These models were quantised using hardware kindly provided by [Latitude.sh](https://www.latitude.sh/accelerate).
37
 
38
  ## Repositories available
39
 
40
+ * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/GPlatty-30B-GPTQ)
41
  * [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference](https://huggingface.co/TheBloke/GPlatty-30B-GGML)
42
  * [Unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/lilloukas/GPlatty-30B)
43
 
44
+ ## Prompt template: Alpaca
45
 
46
  ```
47
+ Below is an instruction that describes a task. Write a response that appropriately completes the request.
48
 
49
+ ### Instruction: {prompt}
50
 
51
  ### Response:
52
  ```
53
 
54
+ ## Provided files
55
+
56
+ Multiple quantisation parameters are provided, to allow you to choose the best one for your hardware and requirements.
57
+
58
+ Each separate quant is in a different branch. See below for instructions on fetching from different branches.
59
+
60
+ | Branch | Bits | Group Size | Act Order (desc_act) | File Size | ExLlama Compatible? | Made With | Description |
61
+ | ------ | ---- | ---------- | -------------------- | --------- | ------------------- | --------- | ----------- |
62
+ | 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. |
63
+ | 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. |
64
+ | 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. |
65
+ | 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. |
66
+ | 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. |
67
+ | 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. |
68
+ | 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. |
69
+ | 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. |
70
+
71
+ ## How to download from branches
72
+
73
+ - In text-generation-webui, you can add `:branch` to the end of the download name, eg `TheBloke/GPlatty-30B-GPTQ:gptq-4bit-32g-actorder_True`
74
+ - With Git, you can clone a branch with:
75
+ ```
76
+ git clone --branch gptq-4bit-32g-actorder_True https://huggingface.co/TheBloke/GPlatty-30B-GPTQ`
77
+ ```
78
+ - In Python Transformers code, the branch is the `revision` parameter; see below.
79
+
80
+ ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
81
+
82
+ Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
83
 
84
+ It is strongly recommended to use the text-generation-webui one-click-installers unless you know how to make a manual install.
85
 
86
  1. Click the **Model tab**.
87
  2. Under **Download custom model or LoRA**, enter `TheBloke/GPlatty-30B-GPTQ`.
88
+ - To download from a specific branch, enter for example `TheBloke/GPlatty-30B-GPTQ:gptq-4bit-32g-actorder_True`
89
+ - see Provided Files above for the list of branches for each option.
90
  3. Click **Download**.
91
  4. The model will start downloading. Once it's finished it will say "Done"
92
  5. In the top left, click the refresh icon next to **Model**.
93
  6. In the **Model** dropdown, choose the model you just downloaded: `GPlatty-30B-GPTQ`
94
  7. The model will automatically load, and is now ready for use!
95
  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.
96
+ * Note that you do not need to set GPTQ parameters any more. These are set automatically from the file `quantize_config.json`.
97
  9. Once you're ready, click the **Text Generation tab** and enter a prompt to get started!
98
 
99
  ## How to use this GPTQ model from Python code
100
 
101
  First make sure you have [AutoGPTQ](https://github.com/PanQiWei/AutoGPTQ) installed:
102
 
103
+ `GITHUB_ACTIONS=true pip install auto-gptq`
104
 
105
  Then try the following example code:
106
 
107
  ```python
108
  from transformers import AutoTokenizer, pipeline, logging
109
  from auto_gptq import AutoGPTQForCausalLM, BaseQuantizeConfig
 
110
 
111
  model_name_or_path = "TheBloke/GPlatty-30B-GPTQ"
112
  model_basename = "gplatty-30b-GPTQ-4bit--1g.act.order"
 
116
  tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
117
 
118
  model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
119
+ model_basename=model_basename
120
  use_safetensors=True,
121
  trust_remote_code=False,
122
  device="cuda:0",
123
  use_triton=use_triton,
124
  quantize_config=None)
125
 
126
+ """
127
+ To download from a specific branch, use the revision parameter, as in this example:
128
+
129
+ model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
130
+ revision="gptq-4bit-32g-actorder_True",
131
+ model_basename=model_basename,
132
+ use_safetensors=True,
133
+ trust_remote_code=False,
134
+ device="cuda:0",
135
+ quantize_config=None)
136
+ """
137
+
138
  prompt = "Tell me about AI"
139
+ prompt_template=f'''Below is an instruction that describes a task. Write a response that appropriately completes the request.
140
+
141
+ ### Instruction: {prompt}
142
+
143
+ ### Response:
144
+ '''
145
 
146
  print("\n\n*** Generate:")
147
 
 
168
  print(pipe(prompt_template)[0]['generated_text'])
169
  ```
170
 
171
+ ## Compatibility
 
 
 
 
172
 
173
+ 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.
174
 
175
+ ExLlama works with Llama models in 4-bit. Please see the Provided Files table above for per-file compatibility.
 
 
 
 
 
176
 
177
  <!-- footer start -->
178
  ## Discord
 
194
  * Patreon: https://patreon.com/TheBlokeAI
195
  * Ko-Fi: https://ko-fi.com/TheBlokeAI
196
 
197
+ **Special thanks to**: Luke from CarbonQuill, Aemon Algiz.
198
 
199
+ **Patreon special mentions**: Space Cruiser, Nikolai Manek, Sam, Chris McCloskey, Rishabh Srivastava, Kalila, Spiking Neurons AB, Khalefa Al-Ahmad, WelcomeToTheClub, Chadd, Lone Striker, Viktor Bowallius, Edmond Seymore, Ai Maven, Chris Smitley, Dave, Alexandros Triantafyllidis, Luke @flexchar, Elle, ya boyyy, Talal Aujan, Alex , Jonathan Leane, Deep Realms, Randy H, subjectnull, Preetika Verma, Joseph William Delisle, Michael Levine, chris gileta, K, Oscar Rangel, LangChain4j, Trenton Dambrowitz, Eugene Pentland, Johann-Peter Hartmann, Femi Adebogun, Illia Dulskyi, senxiiz, Daniel P. Andersen, Sean Connelly, Artur Olbinski, RoA, Mano Prime, Derek Yates, Raven Klaugh, David Flickinger, Willem Michiel, Pieter, Willian Hasse, vamX, Luke Pendergrass, webtim, Ghost , Rainer Wilmers, Nathan LeClaire, Will Dee, Cory Kujawski, John Detwiler, Fred von Graf, biorpg, Iucharbius , Imad Khwaja, Pierre Kircher, terasurfer , Asp the Wyvern, John Villwock, theTransient, zynix , Gabriel Tamborski, Fen Risland, Gabriel Puliatti, Matthew Berman, Pyrater, SuperWojo, Stephen Murray, Karl Bernard, Ajan Kanaga, Greatston Gnanesh, Junyu Yang.
200
 
201
  Thank you to all my generous patrons and donaters!
202
 
 
221
 
222
  ## Model Details
223
 
224
+ * **Trained by**: Platypus-30B trained by Cole Hunter & Ariel Lee; gpt4-alpaca-lora-30b by chansung.
225
  * **Model type:** **GPlatty-30B** is an auto-regressive language model based on the LLaMA transformer architecture.
226
  * **Language(s)**: English
227
  * **License for base weights**: License for the base LLaMA model's weights is Meta's [non-commercial bespoke license](https://github.com/facebookresearch/llama/blob/main/MODEL_CARD.md).