andrijdavid commited on
Commit
7e766b9
1 Parent(s): 174f0af

Upload folder using huggingface_hub

Browse files
Files changed (3) hide show
  1. .gitattributes +1 -0
  2. Mistral-7B-Instruct-v0.3-f16.gguf +3 -0
  3. README.md +0 -198
.gitattributes CHANGED
@@ -33,3 +33,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
 
 
33
  *.zip filter=lfs diff=lfs merge=lfs -text
34
  *.zst filter=lfs diff=lfs merge=lfs -text
35
  *tfevents* filter=lfs diff=lfs merge=lfs -text
36
+ Mistral-7B-Instruct-v0.3-f16.gguf filter=lfs diff=lfs merge=lfs -text
Mistral-7B-Instruct-v0.3-f16.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4fa09db3fc2eaa9a8b6cbeed1504ed01b12568ea475d1a03837c128c3277927f
3
+ size 4564504512
README.md CHANGED
@@ -201,202 +201,6 @@ Here are guides on using llama-cpp-python and ctransformers with LangChain:
201
  # Original model card: Mistral-7B-Instruct-v0.3
202
 
203
 
204
-
205
- # Mistral-7B-Instruct-v0.3-GGUF
206
- - Original model: [Mistral-7B-Instruct-v0.3](https://huggingface.co/mistralai/Mistral-7B-Instruct-v0.3)
207
-
208
- <!-- description start -->
209
- ## Description
210
-
211
- This repo contains GGUF format model files for [Mistral-7B-Instruct-v0.3](https://huggingface.co/mistralai/Mistral-7B-Instruct-v0.3).
212
-
213
- <!-- description end -->
214
- <!-- README_GGUF.md-about-gguf start -->
215
- ### About GGUF
216
- 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.
217
- Here is an incomplete list of clients and libraries that are known to support GGUF:
218
- * [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.
219
- * [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.
220
- * [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​
221
- * [KoboldCpp](https://github.com/LostRuins/koboldcpp), A comprehensive web UI offering GPU acceleration across all platforms and architectures, particularly renowned for storytelling.
222
- * [GPT4All](https://gpt4all.io), This is a free and open source GUI that runs locally, supporting Windows, Linux, and macOS with full GPU acceleration.
223
- * [LM Studio](https://lmstudio.ai/) An intuitive and powerful local GUI for Windows and macOS (Silicon), featuring GPU acceleration.
224
- * [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.
225
- * [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.
226
- * [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.
227
- * [candle](https://github.com/huggingface/candle), A Rust-based ML framework focusing on performance, including GPU support, and designed for ease of use.
228
- * [ctransformers](https://github.com/marella/ctransformers), A Python library featuring GPU acceleration, LangChain support, and an OpenAI-compatible AI server.
229
- * [localGPT](https://github.com/PromtEngineer/localGPT) An open-source initiative enabling private conversations with documents.
230
- <!-- README_GGUF.md-about-gguf end -->
231
-
232
- <!-- compatibility_gguf start -->
233
- ## Explanation of quantisation methods
234
- <details>
235
- <summary>Click to see details</summary>
236
- The new methods available are:
237
-
238
- * 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)
239
- * 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.
240
- * 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.
241
- * GGML_TYPE_Q5_K - "type-1" 5-bit quantization. Same super-block structure as GGML_TYPE_Q4_K resulting in 5.5 bpw
242
- * 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.
243
- </details>
244
- <!-- compatibility_gguf end -->
245
-
246
- <!-- README_GGUF.md-how-to-download start -->
247
- ## How to download GGUF files
248
-
249
- **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.
250
-
251
- The following clients/libraries will automatically download models for you, providing a list of available models to choose from:
252
-
253
- * LM Studio
254
- * LoLLMS Web UI
255
- * Faraday.dev
256
-
257
- ### In `text-generation-webui`
258
-
259
- Under Download Model, you can enter the model repo: LiteLLMs/Mistral-7B-Instruct-v0.3-GGUF and below it, a specific filename to download, such as: Q4_0/Q4_0-00001-of-00009.gguf.
260
-
261
- Then click Download.
262
-
263
- ### On the command line, including multiple files at once
264
-
265
- I recommend using the `huggingface-hub` Python library:
266
-
267
- ```shell
268
- pip3 install huggingface-hub
269
- ```
270
-
271
- Then you can download any individual model file to the current directory, at high speed, with a command like this:
272
-
273
- ```shell
274
- huggingface-cli download LiteLLMs/Mistral-7B-Instruct-v0.3-GGUF Q4_0/Q4_0-00001-of-00009.gguf --local-dir . --local-dir-use-symlinks False
275
- ```
276
-
277
- <details>
278
- <summary>More advanced huggingface-cli download usage (click to read)</summary>
279
-
280
- You can also download multiple files at once with a pattern:
281
-
282
- ```shell
283
- huggingface-cli download LiteLLMs/Mistral-7B-Instruct-v0.3-GGUF --local-dir . --local-dir-use-symlinks False --include='*Q4_K*gguf'
284
- ```
285
-
286
- 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).
287
-
288
- To accelerate downloads on fast connections (1Gbit/s or higher), install `hf_transfer`:
289
-
290
- ```shell
291
- pip3 install huggingface_hub[hf_transfer]
292
- ```
293
-
294
- And set environment variable `HF_HUB_ENABLE_HF_TRANSFER` to `1`:
295
-
296
- ```shell
297
- HF_HUB_ENABLE_HF_TRANSFER=1 huggingface-cli download LiteLLMs/Mistral-7B-Instruct-v0.3-GGUF Q4_0/Q4_0-00001-of-00009.gguf --local-dir . --local-dir-use-symlinks False
298
- ```
299
-
300
- Windows Command Line users: You can set the environment variable by running `set HF_HUB_ENABLE_HF_TRANSFER=1` before the download command.
301
- </details>
302
- <!-- README_GGUF.md-how-to-download end -->
303
- <!-- README_GGUF.md-how-to-run start -->
304
- ## Example `llama.cpp` command
305
-
306
- Make sure you are using `llama.cpp` from commit [d0cee0d](https://github.com/ggerganov/llama.cpp/commit/d0cee0d36d5be95a0d9088b674dbb27354107221) or later.
307
-
308
- ```shell
309
- ./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>"
310
- ```
311
-
312
- Change `-ngl 32` to the number of layers to offload to GPU. Remove it if you don't have GPU acceleration.
313
-
314
- 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.
315
-
316
- If you want to have a chat-style conversation, replace the `-p <PROMPT>` argument with `-i -ins`
317
-
318
- 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)
319
-
320
- ## How to run in `text-generation-webui`
321
-
322
- 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).
323
-
324
- ## How to run from Python code
325
-
326
- 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.
327
-
328
- ### How to load this model in Python code, using llama-cpp-python
329
-
330
- For full documentation, please see: [llama-cpp-python docs](https://abetlen.github.io/llama-cpp-python/).
331
-
332
- #### First install the package
333
-
334
- Run one of the following commands, according to your system:
335
-
336
- ```shell
337
- # Base ctransformers with no GPU acceleration
338
- pip install llama-cpp-python
339
- # With NVidia CUDA acceleration
340
- CMAKE_ARGS="-DLLAMA_CUBLAS=on" pip install llama-cpp-python
341
- # Or with OpenBLAS acceleration
342
- CMAKE_ARGS="-DLLAMA_BLAS=ON -DLLAMA_BLAS_VENDOR=OpenBLAS" pip install llama-cpp-python
343
- # Or with CLBLast acceleration
344
- CMAKE_ARGS="-DLLAMA_CLBLAST=on" pip install llama-cpp-python
345
- # Or with AMD ROCm GPU acceleration (Linux only)
346
- CMAKE_ARGS="-DLLAMA_HIPBLAS=on" pip install llama-cpp-python
347
- # Or with Metal GPU acceleration for macOS systems only
348
- CMAKE_ARGS="-DLLAMA_METAL=on" pip install llama-cpp-python
349
- # In windows, to set the variables CMAKE_ARGS in PowerShell, follow this format; eg for NVidia CUDA:
350
- $env:CMAKE_ARGS = "-DLLAMA_OPENBLAS=on"
351
- pip install llama-cpp-python
352
- ```
353
-
354
- #### Simple llama-cpp-python example code
355
-
356
- ```python
357
- from llama_cpp import Llama
358
- # Set gpu_layers to the number of layers to offload to GPU. Set to 0 if no GPU acceleration is available on your system.
359
- llm = Llama(
360
- model_path="./Q4_0/Q4_0-00001-of-00009.gguf", # Download the model file first
361
- n_ctx=32768, # The max sequence length to use - note that longer sequence lengths require much more resources
362
- n_threads=8, # The number of CPU threads to use, tailor to your system and the resulting performance
363
- n_gpu_layers=35 # The number of layers to offload to GPU, if you have GPU acceleration available
364
- )
365
- # Simple inference example
366
- output = llm(
367
- "<PROMPT>", # Prompt
368
- max_tokens=512, # Generate up to 512 tokens
369
- stop=["</s>"], # Example stop token - not necessarily correct for this specific model! Please check before using.
370
- echo=True # Whether to echo the prompt
371
- )
372
- # Chat Completion API
373
- 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
374
- llm.create_chat_completion(
375
- messages = [
376
- {"role": "system", "content": "You are a story writing assistant."},
377
- {
378
- "role": "user",
379
- "content": "Write a story about llamas."
380
- }
381
- ]
382
- )
383
- ```
384
-
385
- ## How to use with LangChain
386
-
387
- Here are guides on using llama-cpp-python and ctransformers with LangChain:
388
-
389
- * [LangChain + llama-cpp-python](https://python.langchain.com/docs/integrations/llms/llamacpp)
390
- * [LangChain + ctransformers](https://python.langchain.com/docs/integrations/providers/ctransformers)
391
-
392
- <!-- README_GGUF.md-how-to-run end -->
393
-
394
- <!-- footer end -->
395
-
396
- <!-- original-model-card start -->
397
- # Original model card: Mistral-7B-Instruct-v0.3
398
-
399
-
400
  # Model Card for Mistral-7B-Instruct-v0.3
401
 
402
  The Mistral-7B-Instruct-v0.3 Large Language Model (LLM) is an instruct fine-tuned version of the Mistral-7B-v0.3.
@@ -536,5 +340,3 @@ make the model finely respect guardrails, allowing for deployment in environment
536
  Albert Jiang, Alexandre Sablayrolles, Alexis Tacnet, Antoine Roux, Arthur Mensch, Audrey Herblin-Stoop, Baptiste Bout, Baudouin de Monicault, Blanche Savary, Bam4d, Caroline Feldman, Devendra Singh Chaplot, Diego de las Casas, Eleonore Arcelin, Emma Bou Hanna, Etienne Metzger, Gianna Lengyel, Guillaume Bour, Guillaume Lample, Harizo Rajaona, Jean-Malo Delignon, Jia Li, Justus Murke, Louis Martin, Louis Ternon, Lucile Saulnier, Lélio Renard Lavaud, Margaret Jennings, Marie Pellat, Marie Torelli, Marie-Anne Lachaux, Nicolas Schuhl, Patrick von Platen, Pierre Stock, Sandeep Subramanian, Sophia Yang, Szymon Antoniak, Teven Le Scao, Thibaut Lavril, Timothée Lacroix, Théophile Gervet, Thomas Wang, Valera Nemychnikova, William El Sayed, William Marshall
537
 
538
  <!-- original-model-card end -->
539
-
540
- <!-- original-model-card end -->
 
201
  # Original model card: Mistral-7B-Instruct-v0.3
202
 
203
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
204
  # Model Card for Mistral-7B-Instruct-v0.3
205
 
206
  The Mistral-7B-Instruct-v0.3 Large Language Model (LLM) is an instruct fine-tuned version of the Mistral-7B-v0.3.
 
340
  Albert Jiang, Alexandre Sablayrolles, Alexis Tacnet, Antoine Roux, Arthur Mensch, Audrey Herblin-Stoop, Baptiste Bout, Baudouin de Monicault, Blanche Savary, Bam4d, Caroline Feldman, Devendra Singh Chaplot, Diego de las Casas, Eleonore Arcelin, Emma Bou Hanna, Etienne Metzger, Gianna Lengyel, Guillaume Bour, Guillaume Lample, Harizo Rajaona, Jean-Malo Delignon, Jia Li, Justus Murke, Louis Martin, Louis Ternon, Lucile Saulnier, Lélio Renard Lavaud, Margaret Jennings, Marie Pellat, Marie Torelli, Marie-Anne Lachaux, Nicolas Schuhl, Patrick von Platen, Pierre Stock, Sandeep Subramanian, Sophia Yang, Szymon Antoniak, Teven Le Scao, Thibaut Lavril, Timothée Lacroix, Théophile Gervet, Thomas Wang, Valera Nemychnikova, William El Sayed, William Marshall
341
 
342
  <!-- original-model-card end -->