TheBloke commited on
Commit
4b908d3
1 Parent(s): 9d97091

Upload README.md

Browse files
Files changed (1) hide show
  1. README.md +74 -53
README.md CHANGED
@@ -2,7 +2,7 @@
2
  datasets:
3
  - ehartford/wizard_vicuna_70k_unfiltered
4
  inference: false
5
- license: other
6
  model_creator: Jarrad Hope
7
  model_link: https://huggingface.co/jarradh/llama2_70b_chat_uncensored
8
  model_name: Llama2 70B Chat Uncensored
@@ -10,6 +10,9 @@ model_type: llama
10
  quantized_by: TheBloke
11
  tags:
12
  - uncensored
 
 
 
13
  ---
14
 
15
  <!-- header start -->
@@ -33,18 +36,24 @@ tags:
33
  - Model creator: [Jarrad Hope](https://huggingface.co/jarradh)
34
  - Original model: [Llama2 70B Chat Uncensored](https://huggingface.co/jarradh/llama2_70b_chat_uncensored)
35
 
 
36
  ## Description
37
 
38
  This repo contains GPTQ model files for [Jarrad Hope's Llama2 70B Chat Uncensored](https://huggingface.co/jarradh/llama2_70b_chat_uncensored).
39
 
40
  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.
41
 
 
 
42
  ## Repositories available
43
 
44
  * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ)
45
- * [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GGML)
 
46
  * [Jarrad Hope's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/jarradh/llama2_70b_chat_uncensored)
 
47
 
 
48
  ## Prompt template: Human-Response
49
 
50
  ```
@@ -52,22 +61,26 @@ Multiple GPTQ parameter permutations are provided; see Provided Files below for
52
  {prompt}
53
 
54
  ### RESPONSE:
 
55
  ```
56
 
 
 
 
57
  ## Provided files and GPTQ parameters
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
- All GPTQ files are made with AutoGPTQ.
64
 
65
  <details>
66
  <summary>Explanation of GPTQ parameters</summary>
67
 
68
  - Bits: The bit size of the quantised model.
69
  - GS: GPTQ group size. Higher numbers use less VRAM, but have lower quantisation accuracy. "None" is the lowest possible value.
70
- - Act Order: True or False. Also known as `desc_act`. True results in better quantisation accuracy. Some GPTQ clients have issues with models that use Act Order plus Group Size.
71
  - Damp %: A GPTQ parameter that affects how samples are processed for quantisation. 0.01 is default, but 0.1 results in slightly better accuracy.
72
  - 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).
73
  - 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.
@@ -77,13 +90,16 @@ All GPTQ files are made with AutoGPTQ.
77
 
78
  | Branch | Bits | GS | Act Order | Damp % | GPTQ Dataset | Seq Len | Size | ExLlama | Desc |
79
  | ------ | ---- | -- | --------- | ------ | ------------ | ------- | ---- | ------- | ---- |
80
- | [main](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/main) | 4 | None | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 35.33 GB | Yes | Most compatible option. Good inference speed in AutoGPTQ and GPTQ-for-LLaMa. Lower inference quality than other options. |
81
- | [gptq-4bit-32g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-4bit-32g-actorder_True) | 4 | 32 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 40.66 GB | Yes | 4-bit, with Act Order and group size 32g. Gives highest possible inference quality, with maximum VRAM usage. Poor AutoGPTQ CUDA speed. |
82
- | [gptq-4bit-64g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-4bit-64g-actorder_True) | 4 | 64 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 37.99 GB | Yes | 4-bit, with Act Order and group size 64g. Uses less VRAM than 32g, but with slightly lower accuracy. Poor AutoGPTQ CUDA speed. |
83
- | [gptq-4bit-128g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-4bit-128g-actorder_True) | 4 | 128 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 36.65 GB | Yes | 4-bit, with Act Order and group size 128g. Uses even less VRAM than 64g, but with slightly lower accuracy. Poor AutoGPTQ CUDA speed. |
84
- | [gptq-3bit--1g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-3bit--1g-actorder_True) | 3 | None | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 26.78 GB | No | 3-bit, with Act Order and no group size. Lowest possible VRAM requirements. May be lower quality than 3-bit 128g. |
85
  | [gptq-3bit-128g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-3bit-128g-actorder_True) | 3 | 128 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 28.03 GB | No | 3-bit, with group size 128g and act-order. Higher quality than 128g-False but poor AutoGPTQ CUDA speed. |
86
 
 
 
 
87
  ## How to download from branches
88
 
89
  - In text-generation-webui, you can add `:branch` to the end of the download name, eg `TheBloke/llama2_70b_chat_uncensored-GPTQ:gptq-4bit-32g-actorder_True`
@@ -92,78 +108,78 @@ All GPTQ files are made with AutoGPTQ.
92
  git clone --single-branch --branch gptq-4bit-32g-actorder_True https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ
93
  ```
94
  - In Python Transformers code, the branch is the `revision` parameter; see below.
95
-
 
96
  ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
97
 
98
  Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
99
 
100
- It is strongly recommended to use the text-generation-webui one-click-installers unless you know how to make a manual install.
101
 
102
  1. Click the **Model tab**.
103
  2. Under **Download custom model or LoRA**, enter `TheBloke/llama2_70b_chat_uncensored-GPTQ`.
104
  - To download from a specific branch, enter for example `TheBloke/llama2_70b_chat_uncensored-GPTQ:gptq-4bit-32g-actorder_True`
105
  - see Provided Files above for the list of branches for each option.
106
  3. Click **Download**.
107
- 4. The model will start downloading. Once it's finished it will say "Done"
108
  5. In the top left, click the refresh icon next to **Model**.
109
  6. In the **Model** dropdown, choose the model you just downloaded: `llama2_70b_chat_uncensored-GPTQ`
110
  7. The model will automatically load, and is now ready for use!
111
  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.
112
- * Note that you do not need to set GPTQ parameters any more. These are set automatically from the file `quantize_config.json`.
113
  9. Once you're ready, click the **Text Generation tab** and enter a prompt to get started!
 
114
 
 
115
  ## How to use this GPTQ model from Python code
116
 
117
- First make sure you have [AutoGPTQ](https://github.com/PanQiWei/AutoGPTQ) 0.3.1 or later installed:
118
 
119
- ```
120
- pip3 install auto-gptq
121
- ```
122
 
123
- If you have problems installing AutoGPTQ, please build from source instead:
 
 
124
  ```
 
 
 
 
125
  pip3 uninstall -y auto-gptq
126
  git clone https://github.com/PanQiWei/AutoGPTQ
127
  cd AutoGPTQ
128
  pip3 install .
129
  ```
130
 
131
- Then try the following example code:
 
 
 
 
 
 
 
 
132
 
133
  ```python
134
- from transformers import AutoTokenizer, pipeline, logging
135
- from auto_gptq import AutoGPTQForCausalLM, BaseQuantizeConfig
136
 
137
  model_name_or_path = "TheBloke/llama2_70b_chat_uncensored-GPTQ"
138
-
139
- use_triton = False
 
 
 
 
140
 
141
  tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
142
 
143
- model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
144
- use_safetensors=True,
145
- trust_remote_code=False,
146
- device="cuda:0",
147
- use_triton=use_triton,
148
- quantize_config=None)
149
-
150
- """
151
- # To download from a specific branch, use the revision parameter, as in this example:
152
- # Note that `revision` requires AutoGPTQ 0.3.1 or later!
153
-
154
- model = AutoGPTQForCausalLM.from_quantized(model_name_or_path,
155
- revision="gptq-4bit-32g-actorder_True",
156
- use_safetensors=True,
157
- trust_remote_code=False,
158
- device="cuda:0",
159
- quantize_config=None)
160
- """
161
-
162
  prompt = "Tell me about AI"
163
  prompt_template=f'''### HUMAN:
164
  {prompt}
165
 
166
  ### RESPONSE:
 
167
  '''
168
 
169
  print("\n\n*** Generate:")
@@ -174,9 +190,6 @@ print(tokenizer.decode(output[0]))
174
 
175
  # Inference can also be done using transformers' pipeline
176
 
177
- # Prevent printing spurious transformers error when using pipeline with AutoGPTQ
178
- logging.set_verbosity(logging.CRITICAL)
179
-
180
  print("*** Pipeline:")
181
  pipe = pipeline(
182
  "text-generation",
@@ -190,12 +203,17 @@ pipe = pipeline(
190
 
191
  print(pipe(prompt_template)[0]['generated_text'])
192
  ```
 
193
 
 
194
  ## Compatibility
195
 
196
- 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.
197
 
198
- ExLlama works with Llama models in 4-bit. Please see the Provided Files table above for per-file compatibility.
 
 
 
199
 
200
  <!-- footer start -->
201
  <!-- 200823 -->
@@ -220,7 +238,7 @@ Donaters will get priority support on any and all AI/LLM/model questions and req
220
 
221
  **Special thanks to**: Aemon Algiz.
222
 
223
- **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
224
 
225
 
226
  Thank you to all my generous patrons and donaters!
@@ -236,13 +254,16 @@ And thank you again to a16z for their generous grant.
236
  Fine-tuned [Llama-2 70B](https://huggingface.co/TheBloke/Llama-2-70B-fp16) with an uncensored/unfiltered Wizard-Vicuna conversation dataset [ehartford/wizard_vicuna_70k_unfiltered](https://huggingface.co/datasets/ehartford/wizard_vicuna_70k_unfiltered).
237
  [QLoRA](https://arxiv.org/abs/2305.14314) was used for fine-tuning. The model was trained for three epochs on a single NVIDIA A100 80GB GPU instance, taking ~1 week to train.
238
 
 
 
 
239
  Special thanks to [George Sung](https://huggingface.co/georgesung) for creating [llama2_7b_chat_uncensored](https://huggingface.co/georgesung/llama2_7b_chat_uncensored), and to [Eric Hartford](https://huggingface.co/ehartford/) for creating [ehartford/wizard_vicuna_70k_unfiltered](https://huggingface.co/datasets/ehartford/wizard_vicuna_70k_unfiltered)
240
 
241
  The version here is the fp16 HuggingFace model.
242
 
243
- In 8 bit mode, the model fits into 84% of A100 80GB (67.2GB) 68747MiB
244
- In 4 bit mode, the model fits into 51% of A100 80GB (40.8GB) 41559MiB
245
- 500gb of RAM/Swap was required to merge the model.
246
 
247
  ## GGML & GPTQ versions
248
  Thanks to [TheBloke](https://huggingface.co/TheBloke), he has created the GGML and GPTQ versions:
@@ -272,7 +293,7 @@ This model was created as a response to the overbearing & patronising responses
272
 
273
  ## Illustration
274
 
275
- This can be illustrated with the simple question, 'What is a poop?':
276
 
277
  ### LLama 2 70B Chat
278
  ```llama2-70b-chat
@@ -307,7 +328,7 @@ A straightforward, unassuming answer. The model has provided accurate and helpfu
307
 
308
  ## Morality
309
 
310
- The response in this illustration raises an interesting question, where does morality lie? Is it with us or with the model?
311
 
312
  If an AI is trained to be safe, why does it not only apply its morality to itself, why does it attempt to overzealously change the human's behaviour in the interaction?
313
 
 
2
  datasets:
3
  - ehartford/wizard_vicuna_70k_unfiltered
4
  inference: false
5
+ license: llama2
6
  model_creator: Jarrad Hope
7
  model_link: https://huggingface.co/jarradh/llama2_70b_chat_uncensored
8
  model_name: Llama2 70B Chat Uncensored
 
10
  quantized_by: TheBloke
11
  tags:
12
  - uncensored
13
+ - wizard
14
+ - vicuna
15
+ - llama
16
  ---
17
 
18
  <!-- header start -->
 
36
  - Model creator: [Jarrad Hope](https://huggingface.co/jarradh)
37
  - Original model: [Llama2 70B Chat Uncensored](https://huggingface.co/jarradh/llama2_70b_chat_uncensored)
38
 
39
+ <!-- description start -->
40
  ## Description
41
 
42
  This repo contains GPTQ model files for [Jarrad Hope's Llama2 70B Chat Uncensored](https://huggingface.co/jarradh/llama2_70b_chat_uncensored).
43
 
44
  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.
45
 
46
+ <!-- description end -->
47
+ <!-- repositories-available start -->
48
  ## Repositories available
49
 
50
  * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ)
51
+ * [2, 3, 4, 5, 6 and 8-bit GGUF models for CPU+GPU inference](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GGUF)
52
+ * [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference (deprecated)](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GGML)
53
  * [Jarrad Hope's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/jarradh/llama2_70b_chat_uncensored)
54
+ <!-- repositories-available end -->
55
 
56
+ <!-- prompt-template start -->
57
  ## Prompt template: Human-Response
58
 
59
  ```
 
61
  {prompt}
62
 
63
  ### RESPONSE:
64
+
65
  ```
66
 
67
+ <!-- prompt-template end -->
68
+
69
+ <!-- README_GPTQ.md-provided-files start -->
70
  ## Provided files and GPTQ parameters
71
 
72
  Multiple quantisation parameters are provided, to allow you to choose the best one for your hardware and requirements.
73
 
74
  Each separate quant is in a different branch. See below for instructions on fetching from different branches.
75
 
76
+ 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.
77
 
78
  <details>
79
  <summary>Explanation of GPTQ parameters</summary>
80
 
81
  - Bits: The bit size of the quantised model.
82
  - GS: GPTQ group size. Higher numbers use less VRAM, but have lower quantisation accuracy. "None" is the lowest possible value.
83
+ - 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.
84
  - Damp %: A GPTQ parameter that affects how samples are processed for quantisation. 0.01 is default, but 0.1 results in slightly better accuracy.
85
  - 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).
86
  - 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.
 
90
 
91
  | Branch | Bits | GS | Act Order | Damp % | GPTQ Dataset | Seq Len | Size | ExLlama | Desc |
92
  | ------ | ---- | -- | --------- | ------ | ------------ | ------- | ---- | ------- | ---- |
93
+ | [main](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/main) | 4 | None | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 35.33 GB | Yes | Most compatible option. Good inference speed in AutoGPTQ and GPTQ-for-LLaMa. Lower inference quality than other options. |
94
+ | [gptq-4bit-32g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-4bit-32g-actorder_True) | 4 | 32 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 40.66 GB | Yes | 4-bit, with Act Order and group size 32g. Gives highest possible inference quality, with maximum VRAM usage. Poor AutoGPTQ CUDA speed. |
95
+ | [gptq-4bit-64g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-4bit-64g-actorder_True) | 4 | 64 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 37.99 GB | Yes | 4-bit, with Act Order and group size 64g. Uses less VRAM than 32g, but with slightly lower accuracy. Poor AutoGPTQ CUDA speed. |
96
+ | [gptq-4bit-128g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-4bit-128g-actorder_True) | 4 | 128 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 36.65 GB | Yes | 4-bit, with Act Order and group size 128g. Uses even less VRAM than 64g, but with slightly lower accuracy. Poor AutoGPTQ CUDA speed. |
97
+ | [gptq-3bit--1g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-3bit--1g-actorder_True) | 3 | None | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 26.78 GB | No | 3-bit, with Act Order and no group size. Lowest possible VRAM requirements. May be lower quality than 3-bit 128g. |
98
  | [gptq-3bit-128g-actorder_True](https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ/tree/gptq-3bit-128g-actorder_True) | 3 | 128 | Yes | 0.1 | [wikitext](https://huggingface.co/datasets/wikitext/viewer/wikitext-2-v1/test) | 4096 | 28.03 GB | No | 3-bit, with group size 128g and act-order. Higher quality than 128g-False but poor AutoGPTQ CUDA speed. |
99
 
100
+ <!-- README_GPTQ.md-provided-files end -->
101
+
102
+ <!-- README_GPTQ.md-download-from-branches start -->
103
  ## How to download from branches
104
 
105
  - In text-generation-webui, you can add `:branch` to the end of the download name, eg `TheBloke/llama2_70b_chat_uncensored-GPTQ:gptq-4bit-32g-actorder_True`
 
108
  git clone --single-branch --branch gptq-4bit-32g-actorder_True https://huggingface.co/TheBloke/llama2_70b_chat_uncensored-GPTQ
109
  ```
110
  - In Python Transformers code, the branch is the `revision` parameter; see below.
111
+ <!-- README_GPTQ.md-download-from-branches end -->
112
+ <!-- README_GPTQ.md-text-generation-webui start -->
113
  ## How to easily download and use this model in [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
114
 
115
  Please make sure you're using the latest version of [text-generation-webui](https://github.com/oobabooga/text-generation-webui).
116
 
117
+ 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.
118
 
119
  1. Click the **Model tab**.
120
  2. Under **Download custom model or LoRA**, enter `TheBloke/llama2_70b_chat_uncensored-GPTQ`.
121
  - To download from a specific branch, enter for example `TheBloke/llama2_70b_chat_uncensored-GPTQ:gptq-4bit-32g-actorder_True`
122
  - see Provided Files above for the list of branches for each option.
123
  3. Click **Download**.
124
+ 4. The model will start downloading. Once it's finished it will say "Done".
125
  5. In the top left, click the refresh icon next to **Model**.
126
  6. In the **Model** dropdown, choose the model you just downloaded: `llama2_70b_chat_uncensored-GPTQ`
127
  7. The model will automatically load, and is now ready for use!
128
  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.
129
+ * 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`.
130
  9. Once you're ready, click the **Text Generation tab** and enter a prompt to get started!
131
+ <!-- README_GPTQ.md-text-generation-webui end -->
132
 
133
+ <!-- README_GPTQ.md-use-from-python start -->
134
  ## How to use this GPTQ model from Python code
135
 
136
+ ### Install the necessary packages
137
 
138
+ Requires: Transformers 4.32.0 or later, Optimum 1.12.0 or later, and AutoGPTQ 0.4.2 or later.
 
 
139
 
140
+ ```shell
141
+ pip3 install transformers>=4.32.0 optimum>=1.12.0
142
+ pip3 install auto-gptq --extra-index-url https://huggingface.github.io/autogptq-index/whl/cu118/ # Use cu117 if on CUDA 11.7
143
  ```
144
+
145
+ If you have problems installing AutoGPTQ using the pre-built wheels, install it from source instead:
146
+
147
+ ```shell
148
  pip3 uninstall -y auto-gptq
149
  git clone https://github.com/PanQiWei/AutoGPTQ
150
  cd AutoGPTQ
151
  pip3 install .
152
  ```
153
 
154
+ ### For CodeLlama models only: you must use Transformers 4.33.0 or later.
155
+
156
+ If 4.33.0 is not yet released when you read this, you will need to install Transformers from source:
157
+ ```shell
158
+ pip3 uninstall -y transformers
159
+ pip3 install git+https://github.com/huggingface/transformers.git
160
+ ```
161
+
162
+ ### You can then use the following code
163
 
164
  ```python
165
+ from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
 
166
 
167
  model_name_or_path = "TheBloke/llama2_70b_chat_uncensored-GPTQ"
168
+ # To use a different branch, change revision
169
+ # For example: revision="gptq-4bit-32g-actorder_True"
170
+ model = AutoModelForCausalLM.from_pretrained(model_name_or_path,
171
+ torch_dtype=torch.float16,
172
+ device_map="auto",
173
+ revision="main")
174
 
175
  tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
176
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
177
  prompt = "Tell me about AI"
178
  prompt_template=f'''### HUMAN:
179
  {prompt}
180
 
181
  ### RESPONSE:
182
+
183
  '''
184
 
185
  print("\n\n*** Generate:")
 
190
 
191
  # Inference can also be done using transformers' pipeline
192
 
 
 
 
193
  print("*** Pipeline:")
194
  pipe = pipeline(
195
  "text-generation",
 
203
 
204
  print(pipe(prompt_template)[0]['generated_text'])
205
  ```
206
+ <!-- README_GPTQ.md-use-from-python end -->
207
 
208
+ <!-- README_GPTQ.md-compatibility start -->
209
  ## Compatibility
210
 
211
+ 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).
212
 
213
+ [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.
214
+
215
+ [Huggingface Text Generation Inference (TGI)](https://github.com/huggingface/text-generation-inference) is compatible with all GPTQ models.
216
+ <!-- README_GPTQ.md-compatibility end -->
217
 
218
  <!-- footer start -->
219
  <!-- 200823 -->
 
238
 
239
  **Special thanks to**: Aemon Algiz.
240
 
241
+ **Patreon special mentions**: Russ Johnson, J, alfie_i, Alex, NimbleBox.ai, Chadd, Mandus, Nikolai Manek, Ken Nordquist, ya boyyy, Illia Dulskyi, Viktor Bowallius, vamX, Iucharbius, zynix, Magnesian, Clay Pascal, Pierre Kircher, Enrico Ros, Tony Hughes, Elle, Andrey, knownsqashed, Deep Realms, Jerry Meng, Lone Striker, Derek Yates, Pyrater, Mesiah Bishop, James Bentley, Femi Adebogun, Brandon Frisco, SuperWojo, Alps Aficionado, Michael Dempsey, Vitor Caleffi, Will Dee, Edmond Seymore, usrbinkat, LangChain4j, Kacper Wikieł, Luke Pendergrass, John Detwiler, theTransient, Nathan LeClaire, Tiffany J. Kim, biorpg, Eugene Pentland, Stanislav Ovsiannikov, Fred von Graf, terasurfer, Kalila, Dan Guido, Nitin Borwankar, 阿明, Ai Maven, John Villwock, Gabriel Puliatti, Stephen Murray, Asp the Wyvern, danny, Chris Smitley, ReadyPlayerEmma, S_X, Daniel P. Andersen, Olakabola, Jeffrey Morgan, Imad Khwaja, Caitlyn Gatomon, webtim, Alicia Loh, Trenton Dambrowitz, Swaroop Kallakuri, Erik Bjäreholt, Leonard Tan, Spiking Neurons AB, Luke @flexchar, Ajan Kanaga, Thomas Belote, Deo Leter, RoA, Willem Michiel, transmissions 11, subjectnull, Matthew Berman, Joseph William Delisle, David Ziegler, Michael Davis, Johann-Peter Hartmann, Talal Aujan, senxiiz, Artur Olbinski, Rainer Wilmers, Spencer Kim, Fen Risland, Cap'n Zoog, Rishabh Srivastava, Michael Levine, Geoffrey Montalvo, Sean Connelly, Alexandros Triantafyllidis, Pieter, Gabriel Tamborski, Sam, Subspace Studios, Junyu Yang, Pedro Madruga, Vadim, Cory Kujawski, K, Raven Klaugh, Randy H, Mano Prime, Sebastain Graf, Space Cruiser
242
 
243
 
244
  Thank you to all my generous patrons and donaters!
 
254
  Fine-tuned [Llama-2 70B](https://huggingface.co/TheBloke/Llama-2-70B-fp16) with an uncensored/unfiltered Wizard-Vicuna conversation dataset [ehartford/wizard_vicuna_70k_unfiltered](https://huggingface.co/datasets/ehartford/wizard_vicuna_70k_unfiltered).
255
  [QLoRA](https://arxiv.org/abs/2305.14314) was used for fine-tuning. The model was trained for three epochs on a single NVIDIA A100 80GB GPU instance, taking ~1 week to train.
256
 
257
+ Please note that LLama 2 Base model has its inherit biases.
258
+ Uncensored refers to the [ehartford/wizard_vicuna_70k_unfiltered](https://huggingface.co/datasets/ehartford/wizard_vicuna_70k_unfiltered) dataset.
259
+
260
  Special thanks to [George Sung](https://huggingface.co/georgesung) for creating [llama2_7b_chat_uncensored](https://huggingface.co/georgesung/llama2_7b_chat_uncensored), and to [Eric Hartford](https://huggingface.co/ehartford/) for creating [ehartford/wizard_vicuna_70k_unfiltered](https://huggingface.co/datasets/ehartford/wizard_vicuna_70k_unfiltered)
261
 
262
  The version here is the fp16 HuggingFace model.
263
 
264
+ In 8 bit mode, the model fits into 84% of A100 80GB (67.2GB) 68747MiB
265
+ In 4 bit mode, the model fits into 51% of A100 80GB (40.8GB) 41559MiB
266
+ 500gb of RAM/Swap was required to merge the model.
267
 
268
  ## GGML & GPTQ versions
269
  Thanks to [TheBloke](https://huggingface.co/TheBloke), he has created the GGML and GPTQ versions:
 
293
 
294
  ## Illustration
295
 
296
+ This can be illustrated with the simple question, 'What is a poop?':
297
 
298
  ### LLama 2 70B Chat
299
  ```llama2-70b-chat
 
328
 
329
  ## Morality
330
 
331
+ The response in this illustration raises an interesting question, where does morality lie? Is it with us or with the model?
332
 
333
  If an AI is trained to be safe, why does it not only apply its morality to itself, why does it attempt to overzealously change the human's behaviour in the interaction?
334