andrijdavid commited on
Commit
86df886
1 Parent(s): 24d91af

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +241 -0
README.md ADDED
@@ -0,0 +1,241 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+
3
+ ---
4
+ license: apache-2.0
5
+ tags:
6
+ - merge
7
+ - mergekit
8
+ - lazymergekit
9
+ - abacusai/Smaug-72B-v0.1
10
+ - MTSAIR/MultiVerse_70B
11
+ - GGUF
12
+ quantized_by: andrijdavid
13
+ ---
14
+ # Le_Triomphant-ECE-TW3-GGUF
15
+ - Original model: [Le_Triomphant-ECE-TW3](https://huggingface.co/paloalma/Le_Triomphant-ECE-TW3)
16
+
17
+ <!-- description start -->
18
+ ## Description
19
+
20
+ This repo contains GGUF format model files for [Le_Triomphant-ECE-TW3](https://huggingface.co/paloalma/Le_Triomphant-ECE-TW3).
21
+
22
+ <!-- description end -->
23
+ <!-- README_GGUF.md-about-gguf start -->
24
+ ### About GGUF
25
+ GGUF is a new format introduced by the llama.cpp team on August 21st 2023. It is a replacement for GGML, which is no longer supported by llama.cpp.
26
+ Here is an incomplete list of clients and libraries that are known to support GGUF:
27
+ * [llama.cpp](https://github.com/ggerganov/llama.cpp). This is the source project for GGUF, providing both a Command Line Interface (CLI) and a server option.
28
+ * [text-generation-webui](https://github.com/oobabooga/text-generation-webui), Known as the most widely used web UI, this project boasts numerous features and powerful extensions, and supports GPU acceleration.
29
+ * [Ollama](https://github.com/jmorganca/ollama) Ollama is a lightweight and extensible framework designed for building and running language models locally. It features a simple API for creating, managing, and executing models, along with a library of pre-built models for use in various applications​
30
+ * [KoboldCpp](https://github.com/LostRuins/koboldcpp), A comprehensive web UI offering GPU acceleration across all platforms and architectures, particularly renowned for storytelling.
31
+ * [GPT4All](https://gpt4all.io), This is a free and open source GUI that runs locally, supporting Windows, Linux, and macOS with full GPU acceleration.
32
+ * [LM Studio](https://lmstudio.ai/) An intuitive and powerful local GUI for Windows and macOS (Silicon), featuring GPU acceleration.
33
+ * [LoLLMS Web UI](https://github.com/ParisNeo/lollms-webui). A notable web UI with a variety of unique features, including a comprehensive model library for easy model selection.
34
+ * [Faraday.dev](https://faraday.dev/), An attractive, user-friendly character-based chat GUI for Windows and macOS (both Silicon and Intel), also offering GPU acceleration.
35
+ * [llama-cpp-python](https://github.com/abetlen/llama-cpp-python), A Python library equipped with GPU acceleration, LangChain support, and an OpenAI-compatible API server.
36
+ * [candle](https://github.com/huggingface/candle), A Rust-based ML framework focusing on performance, including GPU support, and designed for ease of use.
37
+ * [ctransformers](https://github.com/marella/ctransformers), A Python library featuring GPU acceleration, LangChain support, and an OpenAI-compatible AI server.
38
+ * [localGPT](https://github.com/PromtEngineer/localGPT) An open-source initiative enabling private conversations with documents.
39
+ <!-- README_GGUF.md-about-gguf end -->
40
+
41
+ <!-- compatibility_gguf start -->
42
+ ## Explanation of quantisation methods
43
+ <details>
44
+ <summary>Click to see details</summary>
45
+ The new methods available are:
46
+
47
+ * 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)
48
+ * 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.
49
+ * 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.
50
+ * GGML_TYPE_Q5_K - "type-1" 5-bit quantization. Same super-block structure as GGML_TYPE_Q4_K resulting in 5.5 bpw
51
+ * 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.
52
+ </details>
53
+ <!-- compatibility_gguf end -->
54
+
55
+ <!-- README_GGUF.md-how-to-download start -->
56
+ ## How to download GGUF files
57
+
58
+ **Note for manual downloaders:** You almost never want to clone the entire repo! Multiple different quantisation formats are provided, and most users only want to pick and download a single folder.
59
+
60
+ The following clients/libraries will automatically download models for you, providing a list of available models to choose from:
61
+
62
+ * LM Studio
63
+ * LoLLMS Web UI
64
+ * Faraday.dev
65
+
66
+ ### In `text-generation-webui`
67
+
68
+ Under Download Model, you can enter the model repo: LiteLLMs/Le_Triomphant-ECE-TW3-GGUF and below it, a specific filename to download, such as: Q4_0/Q4_0-00001-of-00009.gguf.
69
+
70
+ Then click Download.
71
+
72
+ ### On the command line, including multiple files at once
73
+
74
+ I recommend using the `huggingface-hub` Python library:
75
+
76
+ ```shell
77
+ pip3 install huggingface-hub
78
+ ```
79
+
80
+ Then you can download any individual model file to the current directory, at high speed, with a command like this:
81
+
82
+ ```shell
83
+ huggingface-cli download LiteLLMs/Le_Triomphant-ECE-TW3-GGUF Q4_0/Q4_0-00001-of-00009.gguf --local-dir . --local-dir-use-symlinks False
84
+ ```
85
+
86
+ <details>
87
+ <summary>More advanced huggingface-cli download usage (click to read)</summary>
88
+
89
+ You can also download multiple files at once with a pattern:
90
+
91
+ ```shell
92
+ huggingface-cli download LiteLLMs/Le_Triomphant-ECE-TW3-GGUF --local-dir . --local-dir-use-symlinks False --include='*Q4_K*gguf'
93
+ ```
94
+
95
+ For more documentation on downloading with `huggingface-cli`, please see: [HF -> Hub Python Library -> Download files -> Download from the CLI](https://huggingface.co/docs/huggingface_hub/guides/download#download-from-the-cli).
96
+
97
+ To accelerate downloads on fast connections (1Gbit/s or higher), install `hf_transfer`:
98
+
99
+ ```shell
100
+ pip3 install huggingface_hub[hf_transfer]
101
+ ```
102
+
103
+ And set environment variable `HF_HUB_ENABLE_HF_TRANSFER` to `1`:
104
+
105
+ ```shell
106
+ HF_HUB_ENABLE_HF_TRANSFER=1 huggingface-cli download LiteLLMs/Le_Triomphant-ECE-TW3-GGUF Q4_0/Q4_0-00001-of-00009.gguf --local-dir . --local-dir-use-symlinks False
107
+ ```
108
+
109
+ Windows Command Line users: You can set the environment variable by running `set HF_HUB_ENABLE_HF_TRANSFER=1` before the download command.
110
+ </details>
111
+ <!-- README_GGUF.md-how-to-download end -->
112
+ <!-- README_GGUF.md-how-to-run start -->
113
+ ## Example `llama.cpp` command
114
+
115
+ Make sure you are using `llama.cpp` from commit [d0cee0d](https://github.com/ggerganov/llama.cpp/commit/d0cee0d36d5be95a0d9088b674dbb27354107221) or later.
116
+
117
+ ```shell
118
+ ./main -ngl 35 -m Q4_0/Q4_0-00001-of-00009.gguf --color -c 8192 --temp 0.7 --repeat_penalty 1.1 -n -1 -p "<PROMPT>"
119
+ ```
120
+
121
+ Change `-ngl 32` to the number of layers to offload to GPU. Remove it if you don't have GPU acceleration.
122
+
123
+ Change `-c 8192` to the desired sequence length. For extended sequence models - eg 8K, 16K, 32K - the necessary RoPE scaling parameters are read from the GGUF file and set by llama.cpp automatically. Note that longer sequence lengths require much more resources, so you may need to reduce this value.
124
+
125
+ If you want to have a chat-style conversation, replace the `-p <PROMPT>` argument with `-i -ins`
126
+
127
+ 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)
128
+
129
+ ## How to run in `text-generation-webui`
130
+
131
+ Further instructions can be found in the text-generation-webui documentation, here: [text-generation-webui/docs/04 ‐ Model Tab.md](https://github.com/oobabooga/text-generation-webui/blob/main/docs/04%20%E2%80%90%20Model%20Tab.md#llamacpp).
132
+
133
+ ## How to run from Python code
134
+
135
+ You can use GGUF models from Python using the [llama-cpp-python](https://github.com/abetlen/llama-cpp-python) or [ctransformers](https://github.com/marella/ctransformers) libraries. Note that at the time of writing (Nov 27th 2023), ctransformers has not been updated for some time and is not compatible with some recent models. Therefore I recommend you use llama-cpp-python.
136
+
137
+ ### How to load this model in Python code, using llama-cpp-python
138
+
139
+ For full documentation, please see: [llama-cpp-python docs](https://abetlen.github.io/llama-cpp-python/).
140
+
141
+ #### First install the package
142
+
143
+ Run one of the following commands, according to your system:
144
+
145
+ ```shell
146
+ # Base ctransformers with no GPU acceleration
147
+ pip install llama-cpp-python
148
+ # With NVidia CUDA acceleration
149
+ CMAKE_ARGS="-DLLAMA_CUBLAS=on" pip install llama-cpp-python
150
+ # Or with OpenBLAS acceleration
151
+ CMAKE_ARGS="-DLLAMA_BLAS=ON -DLLAMA_BLAS_VENDOR=OpenBLAS" pip install llama-cpp-python
152
+ # Or with CLBLast acceleration
153
+ CMAKE_ARGS="-DLLAMA_CLBLAST=on" pip install llama-cpp-python
154
+ # Or with AMD ROCm GPU acceleration (Linux only)
155
+ CMAKE_ARGS="-DLLAMA_HIPBLAS=on" pip install llama-cpp-python
156
+ # Or with Metal GPU acceleration for macOS systems only
157
+ CMAKE_ARGS="-DLLAMA_METAL=on" pip install llama-cpp-python
158
+ # In windows, to set the variables CMAKE_ARGS in PowerShell, follow this format; eg for NVidia CUDA:
159
+ $env:CMAKE_ARGS = "-DLLAMA_OPENBLAS=on"
160
+ pip install llama-cpp-python
161
+ ```
162
+
163
+ #### Simple llama-cpp-python example code
164
+
165
+ ```python
166
+ from llama_cpp import Llama
167
+ # Set gpu_layers to the number of layers to offload to GPU. Set to 0 if no GPU acceleration is available on your system.
168
+ llm = Llama(
169
+ model_path="./Q4_0/Q4_0-00001-of-00009.gguf", # Download the model file first
170
+ n_ctx=32768, # The max sequence length to use - note that longer sequence lengths require much more resources
171
+ n_threads=8, # The number of CPU threads to use, tailor to your system and the resulting performance
172
+ n_gpu_layers=35 # The number of layers to offload to GPU, if you have GPU acceleration available
173
+ )
174
+ # Simple inference example
175
+ output = llm(
176
+ "<PROMPT>", # Prompt
177
+ max_tokens=512, # Generate up to 512 tokens
178
+ stop=["</s>"], # Example stop token - not necessarily correct for this specific model! Please check before using.
179
+ echo=True # Whether to echo the prompt
180
+ )
181
+ # Chat Completion API
182
+ llm = Llama(model_path="./Q4_0/Q4_0-00001-of-00009.gguf", chat_format="llama-2") # Set chat_format according to the model you are using
183
+ llm.create_chat_completion(
184
+ messages = [
185
+ {"role": "system", "content": "You are a story writing assistant."},
186
+ {
187
+ "role": "user",
188
+ "content": "Write a story about llamas."
189
+ }
190
+ ]
191
+ )
192
+ ```
193
+
194
+ ## How to use with LangChain
195
+
196
+ Here are guides on using llama-cpp-python and ctransformers with LangChain:
197
+
198
+ * [LangChain + llama-cpp-python](https://python.langchain.com/docs/integrations/llms/llamacpp)
199
+ * [LangChain + ctransformers](https://python.langchain.com/docs/integrations/providers/ctransformers)
200
+
201
+ <!-- README_GGUF.md-how-to-run end -->
202
+
203
+ <!-- footer end -->
204
+
205
+ <!-- original-model-card start -->
206
+ # Original model card: Le_Triomphant-ECE-TW3
207
+
208
+
209
+ # Le_Triomphant-ECE-TW3
210
+
211
+ ## This model has been produced by :
212
+
213
+ - [Louis Garcia](https://www.linkedin.com/in/louis-garcia-profil/), engineering student at [French Engineering School ECE](https://www.ece.fr/en/)
214
+ - [Matthieu Jollard](https://www.linkedin.com/in/matthieu-jollard/), engineering student at [French Engineering School ECE](https://www.ece.fr/en/)
215
+
216
+ ## Under the supervision of :
217
+
218
+ - [Andre-Louis Rochet](https://www.linkedin.com/in/andrelouisrochet/), Lecturer at ECE & Co-Founder of [TW3 Partners](https://tw3partners.fr/)
219
+ - [Paul Lemaistre](https://www.linkedin.com/in/paul-lemaistre/), CTO of [TW3 Partners](https://tw3partners.fr/)
220
+
221
+ ## With the contribution of :
222
+
223
+ - ECE engineering school as sponsor and financial contributor
224
+ - RunPod as financial contributor
225
+
226
+ ## About ECE
227
+ > _**ECE**, a multi-program, multi-campus, and multi-sector engineering school specializing in digital engineering,
228
+ > trains engineers and technology experts for the 21st century, capable of meeting the challenges of the dual digital and sustainable development revolutions.
229
+ > [French Engineering School ECE](https://www.ece.fr/en/)_
230
+
231
+
232
+
233
+ # Le_Triomphant-ECE-TW3
234
+
235
+ Le_Triomphant-ECE-TW3 is a merge of the following models using [mergekit](https://github.com/cg123/mergekit):
236
+ * [abacusai/Smaug-72B-v0.1](https://huggingface.co/abacusai/Smaug-72B-v0.1)
237
+ * [MTSAIR/MultiVerse_70B](https://huggingface.co/MTSAIR/MultiVerse_70B)
238
+
239
+ ## 🧩 Configuration
240
+
241
+ <!-- original-model-card end -->