initial commit.
Browse files- .gitignore +7 -0
- Makefile +42 -0
- README.md +20 -0
- SHA256SUMS +6 -0
- flan-open-llama-3b-f16.bin +3 -0
- flan-open-llama-3b-q4_0.bin +3 -0
- flan-open-llama-3b-q4_1.bin +3 -0
- flan-open-llama-3b-q5_0.bin +3 -0
- flan-open-llama-3b-q5_1.bin +3 -0
- flan-open-llama-3b-q8_0.bin +3 -0
.gitignore
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
convert.py
|
2 |
+
llama.cpp*/
|
3 |
+
pytorch_model.bin
|
4 |
+
*.sha
|
5 |
+
*.tar.gz
|
6 |
+
tokenizer.model
|
7 |
+
config.json
|
Makefile
ADDED
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
MODEL_NAME= flan-open-llama-3b
|
2 |
+
PYTHON?= python
|
3 |
+
LLAMA_TAG= 7487137
|
4 |
+
LLAMA_TAR= master-$(LLAMA_TAG).tar.gz
|
5 |
+
LLAMA_DIR= llama.cpp-master-$(LLAMA_TAG)
|
6 |
+
LLAMA_FLAGS= LLAMA_NO_K_QUANTS=1
|
7 |
+
HF_REPO= conceptofmind/Flan-Open-Llama-3b
|
8 |
+
HF_REF= main
|
9 |
+
HF_FILES= pytorch_model.bin \
|
10 |
+
tokenizer.model \
|
11 |
+
config.json
|
12 |
+
$(HF_FILES): SITE= https://huggingface.co/$(HF_REPO)/resolve/$(HF_REF)
|
13 |
+
$(LLAMA_TAR): SITE= https://github.com/ggerganov/llama.cpp/archive/refs/tags
|
14 |
+
|
15 |
+
FILES= $(HF_FILES) $(LLAMA_TAR)
|
16 |
+
|
17 |
+
QUANTS= f16 q4_0 q4_1 q5_0 q5_1 q8_0
|
18 |
+
MODEL_FILES= $(foreach q,$(QUANTS),$(MODEL_NAME)-$(q).bin)
|
19 |
+
|
20 |
+
.PHONY: all
|
21 |
+
all: $(MODEL_FILES) SHA256SUMS
|
22 |
+
|
23 |
+
$(FILES):
|
24 |
+
curl -L -o $@ --url $(SITE)/$@
|
25 |
+
|
26 |
+
$(LLAMA_DIR): | $(LLAMA_TAR)
|
27 |
+
tar -xf $(LLAMA_TAR)
|
28 |
+
|
29 |
+
$(LLAMA_DIR)/quantize: | $(LLAMA_DIR)
|
30 |
+
$(MAKE) -C $(LLAMA_DIR) $(LLAMA_FLAGS) quantize
|
31 |
+
|
32 |
+
$(MODEL_NAME)-f16.bin: $(HF_FILES) | $(LLAMA_DIR)
|
33 |
+
$(PYTHON) $(LLAMA_DIR)/convert.py --outtype f16 --outfile $@ .
|
34 |
+
|
35 |
+
$(MODEL_NAME)-q%.bin: $(MODEL_NAME)-f16.bin $(LLAMA_DIR)/quantize
|
36 |
+
$(LLAMA_DIR)/quantize $< $@ q$*
|
37 |
+
|
38 |
+
%.sha: %
|
39 |
+
sha256sum $< > $@
|
40 |
+
|
41 |
+
SHA256SUMS: $(addsuffix .sha,$(MODEL_FILES))
|
42 |
+
cat $^ > $@
|
README.md
CHANGED
@@ -1,3 +1,23 @@
|
|
1 |
---
|
2 |
license: apache-2.0
|
3 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
license: apache-2.0
|
3 |
---
|
4 |
+
|
5 |
+
# ggml versions of Flan-Open-Llama-3b
|
6 |
+
|
7 |
+
- Announcement: [Tweet by @EnricoShippole](https://twitter.com/EnricoShippole/status/1661756166248996867) ("open-source")
|
8 |
+
- Model: [conceptofmind/Flan-Open-Llama-3b](https://huggingface.co/conceptofmind/Flan-Open-Llama-3b)
|
9 |
+
- Base Model: [openlm-research/open_llama_3b](https://huggingface.co/openlm-research/open_llama_3b) [OpenLLaMA: An Open Reproduction of LLaMA](https://github.com/openlm-research/open_llama) (Apache 2.0)
|
10 |
+
- Dataset: [FLAN](https://github.com/google-research/FLAN) (Apache 2.0)
|
11 |
+
- [llama.cpp](https://github.com/ggerganov/llama.cpp): build 607(ffb06a3) or later
|
12 |
+
- Type: instruct
|
13 |
+
|
14 |
+
## Use with llama.cpp
|
15 |
+
|
16 |
+
Support is now merged to master branch.
|
17 |
+
|
18 |
+
## K-quants
|
19 |
+
|
20 |
+
There are now more quantization types in llama.cpp, some lower than 4 bits.
|
21 |
+
Currently these are not well supported because of technical reasons.
|
22 |
+
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)).
|
23 |
+
Then you can quantize the F16 or maybe Q8_0 version to what you want.
|
SHA256SUMS
ADDED
@@ -0,0 +1,6 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
b3d6654431552b1600a5337d49f18230b525297e6f5dfcebb1e58aa53742f952 flan-open-llama-3b-f16.bin
|
2 |
+
78e32dd9f16e2ff835f3254bf6b5b51116e6c86c99a6ebaa2de18598704489fc flan-open-llama-3b-q4_0.bin
|
3 |
+
0aa777b9c0837ccb57aa7ed7a3f180b1b3cead44bfb0a8e7f02d7af84ab67459 flan-open-llama-3b-q4_1.bin
|
4 |
+
6d76ccd0a016435984650e241a5168d271dace34333b5d87fbd5760e60ed34d4 flan-open-llama-3b-q5_0.bin
|
5 |
+
808870854a43b9c3392f156f6975de30fd5189ce6ecdc244dabeb96777e85059 flan-open-llama-3b-q5_1.bin
|
6 |
+
3b9cc39620e8b52343b29a41f58ddf34fd7dbd601d748134e839f8b595e6ed55 flan-open-llama-3b-q8_0.bin
|
flan-open-llama-3b-f16.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b3d6654431552b1600a5337d49f18230b525297e6f5dfcebb1e58aa53742f952
|
3 |
+
size 6853758208
|
flan-open-llama-3b-q4_0.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:78e32dd9f16e2ff835f3254bf6b5b51116e6c86c99a6ebaa2de18598704489fc
|
3 |
+
size 1928446208
|
flan-open-llama-3b-q4_1.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:0aa777b9c0837ccb57aa7ed7a3f180b1b3cead44bfb0a8e7f02d7af84ab67459
|
3 |
+
size 2142590208
|
flan-open-llama-3b-q5_0.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:6d76ccd0a016435984650e241a5168d271dace34333b5d87fbd5760e60ed34d4
|
3 |
+
size 2356734208
|
flan-open-llama-3b-q5_1.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:808870854a43b9c3392f156f6975de30fd5189ce6ecdc244dabeb96777e85059
|
3 |
+
size 2570878208
|
flan-open-llama-3b-q8_0.bin
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:3b9cc39620e8b52343b29a41f58ddf34fd7dbd601d748134e839f8b595e6ed55
|
3 |
+
size 3641598208
|