SlyEcho commited on
Commit
27f69e4
·
verified ·
1 Parent(s): 02da027
.gitattributes CHANGED
@@ -4,6 +4,7 @@
4
  *.bz2 filter=lfs diff=lfs merge=lfs -text
5
  *.ckpt filter=lfs diff=lfs merge=lfs -text
6
  *.ftz filter=lfs diff=lfs merge=lfs -text
 
7
  *.gz filter=lfs diff=lfs merge=lfs -text
8
  *.h5 filter=lfs diff=lfs merge=lfs -text
9
  *.joblib filter=lfs diff=lfs merge=lfs -text
 
4
  *.bz2 filter=lfs diff=lfs merge=lfs -text
5
  *.ckpt filter=lfs diff=lfs merge=lfs -text
6
  *.ftz filter=lfs diff=lfs merge=lfs -text
7
+ *.gguf filter=lfs diff=lfs merge=lfs -text
8
  *.gz filter=lfs diff=lfs merge=lfs -text
9
  *.h5 filter=lfs diff=lfs merge=lfs -text
10
  *.joblib filter=lfs diff=lfs merge=lfs -text
.gitignore ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ llama.cpp*/
2
+ venv/
3
+ pytorch_model.bin
4
+ *.sha
5
+ *.tar.gz
6
+ tokenizer.model
7
+ config.json
8
+ tokenizer_config.json
Makefile ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ MODEL_NAME= open-llama-3b-v2
2
+ PYTHON?= python
3
+ LLAMA_BUILD= 1132
4
+ LLAMA_TAR= b$(LLAMA_BUILD).tar.gz
5
+ LLAMA_DIR= llama.cpp-b$(LLAMA_BUILD)
6
+ LLAMA_FLAGS= LLAMA_NO_K_QUANTS=1
7
+ HF_REPO= openlm-research/open_llama_3b_v2
8
+ HF_REF= main
9
+ HF_FILES= pytorch_model.bin \
10
+ tokenizer.model \
11
+ config.json \
12
+ tokenizer_config.json
13
+ $(HF_FILES): SITE= https://huggingface.co/$(HF_REPO)/resolve/$(HF_REF)
14
+ $(LLAMA_TAR): SITE= https://github.com/ggerganov/llama.cpp/archive/refs/tags
15
+
16
+ QUANTS= f16 q4_0 q4_1 q5_0 q5_1 q8_0
17
+
18
+ FILES= $(HF_FILES) $(LLAMA_TAR)
19
+ MODEL_FILES= $(foreach q,$(QUANTS),$(MODEL_NAME)-$(q).gguf)
20
+
21
+ .PHONY: all
22
+ all: $(MODEL_FILES) SHA256SUMS
23
+
24
+ $(FILES):
25
+ curl -L -o $@ --url $(SITE)/$@
26
+
27
+ $(LLAMA_DIR): | $(LLAMA_TAR)
28
+ tar -xf $(LLAMA_TAR)
29
+
30
+ $(LLAMA_DIR)/quantize: | $(LLAMA_DIR)
31
+ $(MAKE) -C $(LLAMA_DIR) $(LLAMA_FLAGS) quantize
32
+
33
+ venv:
34
+ $(PYTHON) -m venv venv
35
+ venv/bin/pip install -e $(LLAMA_DIR)/gguf-py
36
+ venv/bin/pip install -r $(LLAMA_DIR)/requirements.txt
37
+
38
+ $(MODEL_NAME)-f16.gguf: $(HF_FILES) | $(LLAMA_DIR) venv
39
+ venv/bin/python $(LLAMA_DIR)/convert.py --outtype f16 --outfile $@ .
40
+
41
+ $(MODEL_NAME)-q%.gguf: $(MODEL_NAME)-f16.gguf $(LLAMA_DIR)/quantize
42
+ $(LLAMA_DIR)/quantize $< $@ q$*
43
+
44
+ %.sha: %
45
+ sha256sum $< > $@
46
+
47
+ SHA256SUMS: $(addsuffix .sha,$(MODEL_FILES))
48
+ cat $^ > $@
README.md CHANGED
@@ -1,3 +1,22 @@
1
  ---
2
  license: apache-2.0
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: apache-2.0
3
  ---
4
+
5
+ # ggml versions of OpenLLaMa 3B v2
6
+
7
+ - Version: version 2 final
8
+ - Project: [OpenLLaMA: An Open Reproduction of LLaMA](https://github.com/openlm-research/open_llama)
9
+ - Model: [openlm-research/open_llama_3b_v2](https://huggingface.co/openlm-research/open_llama_3b_v2)
10
+ - [llama.cpp](https://github.com/ggerganov/llama.cpp): build 1012 (6381d4e) or later
11
+ - [ggml version](https://huggingface.co/SlyEcho/open_llama_3b_v2_ggml)
12
+
13
+ ## Newer quantizations
14
+
15
+ There are now more quantization types in llama.cpp, some lower than 4 bits.
16
+ Currently these are not well supported because of technical reasons.
17
+ If you want to use them, you have to build llama.cpp (from build 829 (ff5d58f)) with the `LLAMA_QKK_64` Make or CMake variable enabled (see PR [#2001](https://github.com/ggerganov/llama.cpp/pull/2001)).
18
+ Then you can quantize the F16 or maybe Q8_0 version to what you want.
19
+
20
+ ## Perplexity on wiki.test.406
21
+
22
+ Coming soon...
SHA256SUMS ADDED
@@ -0,0 +1,6 @@
 
 
 
 
 
 
 
1
+ 46978f4b19536f0d443ae75d2627fc4c15a8e1e85285f87b67710f8449633d63 open-llama-3b-v2-f16.gguf
2
+ 5d49a8182262ba3174b3882a65f60bc6472845b420a92f58445dbbaee573dd31 open-llama-3b-v2-q4_0.gguf
3
+ 9f11a025e5dc73442e8e943af7a4d4f0137216119235090f6c4c4c3f5c933697 open-llama-3b-v2-q4_1.gguf
4
+ 93bc066868b8efe0da4c8f5925834a6b30afaf7d48125f4025f288bf6b2e39d2 open-llama-3b-v2-q5_0.gguf
5
+ 5e12b1164ede981451d584943954f51362f60be429aa80d6488a523a4d13afa9 open-llama-3b-v2-q5_1.gguf
6
+ e85176fb15435c0222bf6edcfe740100996948a06a8ee27919de5500b1379865 open-llama-3b-v2-q8_0.gguf
open-llama-3b-v2-f16.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:46978f4b19536f0d443ae75d2627fc4c15a8e1e85285f87b67710f8449633d63
3
+ size 6854036032
open-llama-3b-v2-q4_0.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5d49a8182262ba3174b3882a65f60bc6472845b420a92f58445dbbaee573dd31
3
+ size 1928724096
open-llama-3b-v2-q4_1.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9f11a025e5dc73442e8e943af7a4d4f0137216119235090f6c4c4c3f5c933697
3
+ size 2142868096
open-llama-3b-v2-q5_0.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:93bc066868b8efe0da4c8f5925834a6b30afaf7d48125f4025f288bf6b2e39d2
3
+ size 2357012096
open-llama-3b-v2-q5_1.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5e12b1164ede981451d584943954f51362f60be429aa80d6488a523a4d13afa9
3
+ size 2571156096
open-llama-3b-v2-q8_0.gguf ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e85176fb15435c0222bf6edcfe740100996948a06a8ee27919de5500b1379865
3
+ size 3641876096