TheBloke commited on
Commit
cdbfe59
1 Parent(s): 28aee28

Initial GGML model commit

Browse files
Files changed (1) hide show
  1. README.md +240 -0
README.md ADDED
@@ -0,0 +1,240 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ datasets:
3
+ - ehartford/dolphin
4
+ inference: false
5
+ language:
6
+ - en
7
+ license: other
8
+ model_creator: Eric Hartford
9
+ model_link: https://huggingface.co/ehartford/dolphin-llama2-7b
10
+ model_name: Dolphin Llama2 7B
11
+ model_type: llama
12
+ quantized_by: TheBloke
13
+ ---
14
+
15
+ <!-- header start -->
16
+ <div style="width: 100%;">
17
+ <img src="https://i.imgur.com/EBdldam.jpg" alt="TheBlokeAI" style="width: 100%; min-width: 400px; display: block; margin: auto;">
18
+ </div>
19
+ <div style="display: flex; justify-content: space-between; width: 100%;">
20
+ <div style="display: flex; flex-direction: column; align-items: flex-start;">
21
+ <p><a href="https://discord.gg/theblokeai">Chat & support: my new Discord server</a></p>
22
+ </div>
23
+ <div style="display: flex; flex-direction: column; align-items: flex-end;">
24
+ <p><a href="https://www.patreon.com/TheBlokeAI">Want to contribute? TheBloke's Patreon page</a></p>
25
+ </div>
26
+ </div>
27
+ <!-- header end -->
28
+
29
+ # Dolphin Llama2 7B - GGML
30
+ - Model creator: [Eric Hartford](https://huggingface.co/ehartford)
31
+ - Original model: [Dolphin Llama2 7B](https://huggingface.co/ehartford/dolphin-llama2-7b)
32
+
33
+ ## Description
34
+
35
+ This repo contains GGML format model files for [Eric Hartford's Dolphin Llama2 7B](https://huggingface.co/ehartford/dolphin-llama2-7b).
36
+
37
+ GGML files are for CPU + GPU inference using [llama.cpp](https://github.com/ggerganov/llama.cpp) and libraries and UIs which support this format, such as:
38
+ * [text-generation-webui](https://github.com/oobabooga/text-generation-webui), the most popular web UI. Supports NVidia CUDA GPU acceleration.
39
+ * [KoboldCpp](https://github.com/LostRuins/koboldcpp), a powerful GGML web UI with GPU acceleration on all platforms (CUDA and OpenCL). Especially good for story telling.
40
+ * [LM Studio](https://lmstudio.ai/), a fully featured local GUI with GPU acceleration on both Windows (NVidia and AMD), and macOS.
41
+ * [LoLLMS Web UI](https://github.com/ParisNeo/lollms-webui), a great web UI with CUDA GPU acceleration via the c_transformers backend.
42
+ * [ctransformers](https://github.com/marella/ctransformers), a Python library with GPU accel, LangChain support, and OpenAI-compatible AI server.
43
+ * [llama-cpp-python](https://github.com/abetlen/llama-cpp-python), a Python library with GPU accel, LangChain support, and OpenAI-compatible API server.
44
+
45
+ ## Repositories available
46
+
47
+ * [GPTQ models for GPU inference, with multiple quantisation parameter options.](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GPTQ)
48
+ * [2, 3, 4, 5, 6 and 8-bit GGML models for CPU+GPU inference](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML)
49
+ * [Eric Hartford's original unquantised fp16 model in pytorch format, for GPU inference and for further conversions](https://huggingface.co/ehartford/dolphin-llama2-7b)
50
+
51
+ ## Prompt template: Orca-Vicuna
52
+
53
+ ```
54
+ SYSTEM: {system_message}
55
+ USER: {prompt}
56
+ ASSISTANT:
57
+ ```
58
+
59
+ <!-- compatibility_ggml start -->
60
+ ## Compatibility
61
+
62
+ These quantised GGML files are compatible with llama.cpp as of June 6th, commit `2d43387`.
63
+
64
+ They should also be compatible with all UIs, libraries and utilities which use GGML.
65
+
66
+ ## Explanation of the new k-quant methods
67
+ <details>
68
+ <summary>Click to see details</summary>
69
+
70
+ The new methods available are:
71
+ * GGML_TYPE_Q2_K - "type-1" 2-bit quantization in super-blocks containing 16 blocks, each block having 16 weight. Block scales and mins are quantized with 4 bits. This ends up effectively using 2.5625 bits per weight (bpw)
72
+ * GGML_TYPE_Q3_K - "type-0" 3-bit quantization in super-blocks containing 16 blocks, each block having 16 weights. Scales are quantized with 6 bits. This end up using 3.4375 bpw.
73
+ * GGML_TYPE_Q4_K - "type-1" 4-bit quantization in super-blocks containing 8 blocks, each block having 32 weights. Scales and mins are quantized with 6 bits. This ends up using 4.5 bpw.
74
+ * GGML_TYPE_Q5_K - "type-1" 5-bit quantization. Same super-block structure as GGML_TYPE_Q4_K resulting in 5.5 bpw
75
+ * GGML_TYPE_Q6_K - "type-0" 6-bit quantization. Super-blocks with 16 blocks, each block having 16 weights. Scales are quantized with 8 bits. This ends up using 6.5625 bpw
76
+ * GGML_TYPE_Q8_K - "type-0" 8-bit quantization. Only used for quantizing intermediate results. The difference to the existing Q8_0 is that the block size is 256. All 2-6 bit dot products are implemented for this quantization type.
77
+
78
+ Refer to the Provided Files table below to see what files use which methods, and how.
79
+ </details>
80
+ <!-- compatibility_ggml end -->
81
+
82
+ ## Provided files
83
+
84
+ | Name | Quant method | Bits | Size | Max RAM required | Use case |
85
+ | ---- | ---- | ---- | ---- | ---- | ----- |
86
+ | [dolphin-llama2-7b.ggmlv3.q2_K.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q2_K.bin) | q2_K | 2 | 2.87 GB| 5.37 GB | New k-quant method. Uses GGML_TYPE_Q4_K for the attention.vw and feed_forward.w2 tensors, GGML_TYPE_Q2_K for the other tensors. |
87
+ | [dolphin-llama2-7b.ggmlv3.q3_K_L.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q3_K_L.bin) | q3_K_L | 3 | 3.60 GB| 6.10 GB | New k-quant method. Uses GGML_TYPE_Q5_K for the attention.wv, attention.wo, and feed_forward.w2 tensors, else GGML_TYPE_Q3_K |
88
+ | [dolphin-llama2-7b.ggmlv3.q3_K_M.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q3_K_M.bin) | q3_K_M | 3 | 3.28 GB| 5.78 GB | New k-quant method. Uses GGML_TYPE_Q4_K for the attention.wv, attention.wo, and feed_forward.w2 tensors, else GGML_TYPE_Q3_K |
89
+ | [dolphin-llama2-7b.ggmlv3.q3_K_S.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q3_K_S.bin) | q3_K_S | 3 | 2.95 GB| 5.45 GB | New k-quant method. Uses GGML_TYPE_Q3_K for all tensors |
90
+ | [dolphin-llama2-7b.ggmlv3.q4_0.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q4_0.bin) | q4_0 | 4 | 3.83 GB| 6.33 GB | Original quant method, 4-bit. |
91
+ | [dolphin-llama2-7b.ggmlv3.q4_1.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q4_1.bin) | q4_1 | 4 | 4.24 GB| 6.74 GB | Original quant method, 4-bit. Higher accuracy than q4_0 but not as high as q5_0. However has quicker inference than q5 models. |
92
+ | [dolphin-llama2-7b.ggmlv3.q4_K_M.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q4_K_M.bin) | q4_K_M | 4 | 4.08 GB| 6.58 GB | New k-quant method. Uses GGML_TYPE_Q6_K for half of the attention.wv and feed_forward.w2 tensors, else GGML_TYPE_Q4_K |
93
+ | [dolphin-llama2-7b.ggmlv3.q4_K_S.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q4_K_S.bin) | q4_K_S | 4 | 3.83 GB| 6.33 GB | New k-quant method. Uses GGML_TYPE_Q4_K for all tensors |
94
+ | [dolphin-llama2-7b.ggmlv3.q5_0.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q5_0.bin) | q5_0 | 5 | 4.65 GB| 7.15 GB | Original quant method, 5-bit. Higher accuracy, higher resource usage and slower inference. |
95
+ | [dolphin-llama2-7b.ggmlv3.q5_1.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q5_1.bin) | q5_1 | 5 | 5.06 GB| 7.56 GB | Original quant method, 5-bit. Even higher accuracy, resource usage and slower inference. |
96
+ | [dolphin-llama2-7b.ggmlv3.q5_K_M.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q5_K_M.bin) | q5_K_M | 5 | 4.78 GB| 7.28 GB | New k-quant method. Uses GGML_TYPE_Q6_K for half of the attention.wv and feed_forward.w2 tensors, else GGML_TYPE_Q5_K |
97
+ | [dolphin-llama2-7b.ggmlv3.q5_K_S.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q5_K_S.bin) | q5_K_S | 5 | 4.65 GB| 7.15 GB | New k-quant method. Uses GGML_TYPE_Q5_K for all tensors |
98
+ | [dolphin-llama2-7b.ggmlv3.q6_K.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q6_K.bin) | q6_K | 6 | 5.53 GB| 8.03 GB | New k-quant method. Uses GGML_TYPE_Q8_K for all tensors - 6-bit quantization |
99
+ | [dolphin-llama2-7b.ggmlv3.q8_0.bin](https://huggingface.co/TheBloke/Dolphin-Llama2-7B-GGML/blob/main/dolphin-llama2-7b.ggmlv3.q8_0.bin) | q8_0 | 8 | 7.13 GB| 9.63 GB | Original quant method, 8-bit. Almost indistinguishable from float16. High resource use and slow. Not recommended for most users. |
100
+
101
+ **Note**: the above RAM figures assume no GPU offloading. If layers are offloaded to the GPU, this will reduce RAM usage and use VRAM instead.
102
+
103
+ ## How to run in `llama.cpp`
104
+
105
+ I use the following command line; adjust for your tastes and needs:
106
+
107
+ ```
108
+ ./main -t 10 -ngl 32 -m dolphin-llama2-7b.ggmlv3.q4_K_M.bin --color -c 2048 --temp 0.7 --repeat_penalty 1.1 -n -1 -p "### Instruction: Write a story about llamas\n### Response:"
109
+ ```
110
+ Change `-t 10` to the number of physical CPU cores you have. For example if your system has 8 cores/16 threads, use `-t 8`.
111
+
112
+ Change `-ngl 32` to the number of layers to offload to GPU. Remove it if you don't have GPU acceleration.
113
+
114
+ Change `-c 2048` to the desired sequence length for this model. For example, `-c 4096` for a Llama 2 model. For models that use RoPE, add `--rope-freq-base 10000 --rope-freq-scale 0.5` for doubled context, or `--rope-freq-base 10000 --rope-freq-scale 0.25` for 4x context.
115
+
116
+ If you want to have a chat-style conversation, replace the `-p <PROMPT>` argument with `-i -ins`
117
+
118
+ For other parameters and how to use them, please refer to [the llama.cpp documentation](https://github.com/ggerganov/llama.cpp/blob/master/examples/main/README.md)
119
+
120
+ ## How to run in `text-generation-webui`
121
+
122
+ Further instructions here: [text-generation-webui/docs/llama.cpp-models.md](https://github.com/oobabooga/text-generation-webui/blob/main/docs/llama.cpp-models.md).
123
+
124
+ <!-- footer start -->
125
+ ## Discord
126
+
127
+ For further support, and discussions on these models and AI in general, join us at:
128
+
129
+ [TheBloke AI's Discord server](https://discord.gg/theblokeai)
130
+
131
+ ## Thanks, and how to contribute.
132
+
133
+ Thanks to the [chirper.ai](https://chirper.ai) team!
134
+
135
+ 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.
136
+
137
+ 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.
138
+
139
+ Donaters will get priority support on any and all AI/LLM/model questions and requests, access to a private Discord room, plus other benefits.
140
+
141
+ * Patreon: https://patreon.com/TheBlokeAI
142
+ * Ko-Fi: https://ko-fi.com/TheBlokeAI
143
+
144
+ **Special thanks to**: Luke from CarbonQuill, Aemon Algiz.
145
+
146
+ **Patreon special mentions**: Willem Michiel, Ajan Kanaga, Cory Kujawski, Alps Aficionado, Nikolai Manek, Jonathan Leane, Stanislav Ovsiannikov, Michael Levine, Luke Pendergrass, Sid, K, Gabriel Tamborski, Clay Pascal, Kalila, William Sang, Will Dee, Pieter, Nathan LeClaire, ya boyyy, David Flickinger, vamX, Derek Yates, Fen Risland, Jeffrey Morgan, webtim, Daniel P. Andersen, Chadd, Edmond Seymore, Pyrater, Olusegun Samson, Lone Striker, biorpg, alfie_i, Mano Prime, Chris Smitley, Dave, zynix, Trenton Dambrowitz, Johann-Peter Hartmann, Magnesian, Spencer Kim, John Detwiler, Iucharbius, Gabriel Puliatti, LangChain4j, Luke @flexchar, Vadim, Rishabh Srivastava, Preetika Verma, Ai Maven, Femi Adebogun, WelcomeToTheClub, Leonard Tan, Imad Khwaja, Steven Wood, Stefan Sabev, Sebastain Graf, usrbinkat, Dan Guido, Sam, Eugene Pentland, Mandus, transmissions 11, Slarti, Karl Bernard, Spiking Neurons AB, Artur Olbinski, Joseph William Delisle, ReadyPlayerEmma, Olakabola, Asp the Wyvern, Space Cruiser, Matthew Berman, Randy H, subjectnull, danny, John Villwock, Illia Dulskyi, Rainer Wilmers, theTransient, Pierre Kircher, Alexandros Triantafyllidis, Viktor Bowallius, terasurfer, Deep Realms, SuperWojo, senxiiz, Oscar Rangel, Alex, Stephen Murray, Talal Aujan, Raven Klaugh, Sean Connelly, Raymond Fosdick, Fred von Graf, chris gileta, Junyu Yang, Elle
147
+
148
+
149
+ Thank you to all my generous patrons and donaters!
150
+
151
+ <!-- footer end -->
152
+
153
+ # Original model card: Eric Hartford's Dolphin Llama2 7B
154
+
155
+ Dolphin 🐬
156
+ https://erichartford.com/dolphin
157
+
158
+ Dolphin-Llama2-7b's training was sponsored by [preemo](https://www.preemo.io/).
159
+
160
+ This model is based on llama2, so it is suitable for commercial or non-commercial use.
161
+
162
+ This model is uncensored. I have filtered the dataset to remove alignment and bias. This makes the model more compliant. You are advised to implement your own alignment layer before exposing the model as a service. It will be highly compliant to any requests, even unethical ones. Please read my blog post about uncensored models. https://erichartford.com/uncensored-models
163
+ You are responsible for any content you create using this model. Enjoy responsibly.
164
+
165
+ ## Dataset
166
+
167
+ This dataset is an open-source implementation of [Microsoft's Orca](https://www.microsoft.com/en-us/research/publication/orca-progressive-learning-from-complex-explanation-traces-of-gpt-4/)
168
+
169
+ After uncensoring, deduping, and cleaning, our dataset consists of:
170
+
171
+ - 842,610 instructions of FLANv2 augmented with GPT-4 completions
172
+ - 2,625,353 instructions of FLANv2 augmented with GPT-3.5 completions
173
+
174
+ We followed the submix and system prompt distribution outlined in the Orca paper. With a few exceptions. We included all 75k of CoT in the FLAN-1m dataset rather than sampling that. Also, we found that many items were duplicated, so we removed duplicates.
175
+
176
+ Then we filtered out instances of alignment, refusal, avoidance, and bias, in order to produce an uncensored model upon which can be layered your personalized alignment LoRA.
177
+
178
+ We also filtered out duplicates and cleaned the data.
179
+
180
+ ## Training
181
+ We trained with the flan5m (gpt3.5 completions) dataset in its entirety for 3 epochs at a learning rate of 2e-5 before we stopped training to avoid overfit.
182
+ We trained with the flan1m (gpt4 completions) dataset in its entirety for 2.5 epochs at a learning rate of 1e-5 before we stopped training to avoid overfit.
183
+ It took about 400 hours to train on 8x A100s
184
+ We used a prompt format similar to Vicuna, but we added the SYSTEM: field.
185
+
186
+ Prompt format:
187
+ ```
188
+ SYSTEM: {system}
189
+ USER: {prompt}
190
+ ASSISTANT:
191
+ ```
192
+
193
+ Example:
194
+ ```
195
+ SYSTEM: you are an expert dolphin trainer
196
+ USER: What is the best way to train a dolphin to obey me? Please answer step by step.
197
+ ASSISTANT:
198
+ ```
199
+
200
+ ## Team
201
+ The core Dolphin Team includes:
202
+ - Eric "Faldore" Hartford
203
+ - Pankaj Mathur
204
+ - Rob "Rohan" O'Callahan
205
+ - Tom "TheBloke" Jobbins
206
+
207
+ ## Gratitude
208
+ - This model was made possible by the generous sponsorship of preemo.io.
209
+ - Thank you to Microsoft for authoring the Orca paper and inspiring this work.
210
+ - Special thanks to WingLian, NanoBit, Teknium for helpful advice
211
+ - Thank you to all the other people in the Open Source AI community who have taught me and helped me along the way.
212
+
213
+ ## Example Output
214
+ ```
215
+ SYSTEM: you are an expert mechanic
216
+ USER: Please tell me step by step how to fix my car that won't start.
217
+ ASSISTANT: To help your vehicle start, I will guide you through a step-by-step process on what could be causing the issue and how to resolve it.
218
+
219
+ 1. Check for obvious issues: First, inspect the exterior of the car to identify any visible problems such as damage or obstructions which might affect its ability to start. Make sure there is no debris in the air intakes or exhaust system.
220
+
221
+ 2. Inspect the battery: The most common reason a car may not start is due to a dead or faulty battery. Use a battery charger or jump starter to give the battery a boost if needed. If the battery is indeed dead, replace it with a new one.
222
+
223
+ 3. Check the ignition switch: The ignition switch must be turned on to provide power to the spark plugs. Ensure it is in the "Start" position.
224
+
225
+ 4. Test the spark plugs: One of the spark plugs should produce a strong spark when touched together. If all spark plugs fail to create a spark, they need to be replaced.
226
+
227
+ 5. Examine the fuel system: Fuel can become contaminated or low, preventing the engine from starting. Check the fuel level and quality by looking at the dipstick or using a fuel sensor scan tool. Also, examine the fuel pump for proper functioning.
228
+
229
+ 6. Assess the electrical system: A malfunction within the vehicle's electrical system can also cause difficulty in starting the car. Perform a diagnostic scan to check for any error codes related to the starter motor, alternator, or other components.
230
+
231
+ 7. Inspect the starter motor: The starter motor should operate smoothly when you turn the key to the "start" position. If you hear a sizzling sound while pressing the button, the starter motor may have a problem. Replace it if necessary.
232
+
233
+ 8. Evaluate the timing belt/chain: Timing belts or chains that are worn out or damaged can lead to poor performance and difficulty starting the engine. Have a mechanic inspect this component and replace it if required.
234
+
235
+ 9. Consider checking for a mechanical failure: In rare cases, a significant mechanical failure could prevent the vehicle from starting. Consult a professional mechanic if you suspect this might be the case.
236
+
237
+ By following these steps, you should be able to diagnose and potentially fix the issue causing your car to not start. However, if after going through these checks and still having trouble, it is recommended to seek assistance from a qualified mechanic.
238
+ ```
239
+
240
+ [Buy me a coffee](https://www.buymeacoffee.com/ehartford)