RichardErkhov commited on
Commit
2bf06bc
Β·
verified Β·
1 Parent(s): 8675bcc

uploaded readme

Browse files
Files changed (1) hide show
  1. README.md +123 -0
README.md ADDED
@@ -0,0 +1,123 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Quantization made by Richard Erkhov.
2
+
3
+ [Github](https://github.com/RichardErkhov)
4
+
5
+ [Discord](https://discord.gg/pvy7H8DZMG)
6
+
7
+ [Request more models](https://github.com/RichardErkhov/quant_request)
8
+
9
+
10
+ MiniMA-3B - GGUF
11
+ - Model creator: https://huggingface.co/GeneZC/
12
+ - Original model: https://huggingface.co/GeneZC/MiniMA-3B/
13
+
14
+
15
+ | Name | Quant method | Size |
16
+ | ---- | ---- | ---- |
17
+ | [MiniMA-3B.Q2_K.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q2_K.gguf) | Q2_K | 1.09GB |
18
+ | [MiniMA-3B.IQ3_XS.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.IQ3_XS.gguf) | IQ3_XS | 1.21GB |
19
+ | [MiniMA-3B.IQ3_S.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.IQ3_S.gguf) | IQ3_S | 1.27GB |
20
+ | [MiniMA-3B.Q3_K_S.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q3_K_S.gguf) | Q3_K_S | 1.27GB |
21
+ | [MiniMA-3B.IQ3_M.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.IQ3_M.gguf) | IQ3_M | 1.33GB |
22
+ | [MiniMA-3B.Q3_K.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q3_K.gguf) | Q3_K | 1.4GB |
23
+ | [MiniMA-3B.Q3_K_M.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q3_K_M.gguf) | Q3_K_M | 1.4GB |
24
+ | [MiniMA-3B.Q3_K_L.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q3_K_L.gguf) | Q3_K_L | 1.52GB |
25
+ | [MiniMA-3B.IQ4_XS.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.IQ4_XS.gguf) | IQ4_XS | 1.55GB |
26
+ | [MiniMA-3B.Q4_0.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q4_0.gguf) | Q4_0 | 1.62GB |
27
+ | [MiniMA-3B.IQ4_NL.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.IQ4_NL.gguf) | IQ4_NL | 1.63GB |
28
+ | [MiniMA-3B.Q4_K_S.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q4_K_S.gguf) | Q4_K_S | 1.63GB |
29
+ | [MiniMA-3B.Q4_K.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q4_K.gguf) | Q4_K | 1.72GB |
30
+ | [MiniMA-3B.Q4_K_M.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q4_K_M.gguf) | Q4_K_M | 1.72GB |
31
+ | [MiniMA-3B.Q4_1.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q4_1.gguf) | Q4_1 | 1.79GB |
32
+ | [MiniMA-3B.Q5_0.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q5_0.gguf) | Q5_0 | 1.95GB |
33
+ | [MiniMA-3B.Q5_K_S.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q5_K_S.gguf) | Q5_K_S | 1.95GB |
34
+ | [MiniMA-3B.Q5_K.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q5_K.gguf) | Q5_K | 2.01GB |
35
+ | [MiniMA-3B.Q5_K_M.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q5_K_M.gguf) | Q5_K_M | 2.01GB |
36
+ | [MiniMA-3B.Q5_1.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q5_1.gguf) | Q5_1 | 2.12GB |
37
+ | [MiniMA-3B.Q6_K.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q6_K.gguf) | Q6_K | 2.31GB |
38
+ | [MiniMA-3B.Q8_0.gguf](https://huggingface.co/RichardErkhov/GeneZC_-_MiniMA-3B-gguf/blob/main/MiniMA-3B.Q8_0.gguf) | Q8_0 | 2.99GB |
39
+
40
+
41
+
42
+
43
+ Original model description:
44
+ ---
45
+ license: apache-2.0
46
+ datasets:
47
+ - EleutherAI/pile
48
+ - togethercomputer/RedPajama-Data-1T
49
+ - p208p2002/wudao
50
+ language:
51
+ - en
52
+ - zh
53
+ library_name: transformers
54
+ widget:
55
+ - text: "<s> 4 + 3 ="
56
+ ---
57
+
58
+ ## MiniMA-3B
59
+
60
+ πŸ“‘ [arXiv](https://arxiv.org/abs/2311.07052) | πŸ‘» [GitHub](https://github.com/GeneZC/MiniMA) | πŸ€— [HuggingFace-MiniMA](https://huggingface.co/GeneZC/MiniMA-3B) | πŸ€— [HuggingFace-MiniChat](https://huggingface.co/GeneZC/MiniChat-3B) | πŸ€— [HuggingFace-MiniChat-1.5](https://huggingface.co/GeneZC/MiniChat-1.5-3B) | πŸ€– [ModelScope-MiniMA](https://modelscope.cn/models/GeneZC/MiniMA-3B) | πŸ€– [ModelScope-MiniChat](https://modelscope.cn/models/GeneZC/MiniChat-3B)
61
+
62
+ πŸ†• **Updates: MiniChat-1.5-3B**
63
+
64
+ ❗ Must comply with LICENSE of LLaMA2 since it is derived from LLaMA2.
65
+
66
+ A language model distilled from an adapted version of LLaMA2-7B following "Towards the Law of Capacity Gap in Distilling Language Models".
67
+
68
+ Establishing a new compute-performance pareto frontier.
69
+
70
+ <img src="./teaser_a.jpg" alt="teaser_a" width="700" />
71
+
72
+ The following is an example code snippet to use MiniMA-3B:
73
+
74
+ ```python
75
+ import torch
76
+
77
+ from transformers import AutoModelForCausalLM, AutoTokenizer
78
+
79
+ # MiniMA
80
+ tokenizer = AutoTokenizer.from_pretrained("GeneZC/MiniMA-3B", use_fast=False)
81
+ # GPU.
82
+ model = AutoModelForCausalLM.from_pretrained("GeneZC/MiniMA-3B", use_cache=True, device_map="auto", torch_dtype=torch.float16).eval()
83
+ # CPU.
84
+ # model = AutoModelForCausalLM.from_pretrained("GeneZC/MiniMA-3B", use_cache=True, device_map="cpu", torch_dtype=torch.float16).eval()
85
+
86
+ prompt = "Question: Sherrie tells the truth. Vernell says Sherrie tells the truth. Alexis says Vernell lies. Michaela says Alexis tells the truth. Elanor says Michaela tells the truth. Does Elanor tell the truth?\nAnswer: No\n\nQuestion: Kristian lies. Sherrie says Kristian lies. Delbert says Sherrie lies. Jerry says Delbert tells the truth. Shalonda says Jerry tells the truth. Does Shalonda tell the truth?\nAnswer: No\n\nQuestion: Vina tells the truth. Helene says Vina lies. Kandi says Helene tells the truth. Jamey says Kandi lies. Ka says Jamey lies. Does Ka tell the truth?\nAnswer: No\n\nQuestion: Christie tells the truth. Ka says Christie tells the truth. Delbert says Ka lies. Leda says Delbert tells the truth. Lorine says Leda tells the truth. Does Lorine tell the truth?\nAnswer:"
87
+ input_ids = tokenizer([prompt]).input_ids
88
+ output_ids = model.generate(
89
+ torch.as_tensor(input_ids).cuda(),
90
+ do_sample=True,
91
+ temperature=0.7,
92
+ max_new_tokens=1024,
93
+ )
94
+ output_ids = output_ids[0][len(input_ids[0]):]
95
+ output = tokenizer.decode(output_ids, skip_special_tokens=True).strip()
96
+ # output: "No"
97
+ ```
98
+
99
+ ## Bibtex
100
+
101
+ ```bibtex
102
+ @article{zhang2023law,
103
+ title={Towards the Law of Capacity Gap in Distilling Language Models},
104
+ author={Zhang, Chen and Song, Dawei and Ye, Zheyu and Gao, Yan},
105
+ year={2023},
106
+ url={https://arxiv.org/abs/2311.07052}
107
+ }
108
+ ```
109
+ # [Open LLM Leaderboard Evaluation Results](https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard)
110
+ Detailed results can be found [here](https://huggingface.co/datasets/open-llm-leaderboard/details_GeneZC__MiniMA-3B)
111
+
112
+ | Metric | Value |
113
+ |-----------------------|---------------------------|
114
+ | Avg. | 36.2 |
115
+ | ARC (25-shot) | 43.43 |
116
+ | HellaSwag (10-shot) | 68.06 |
117
+ | MMLU (5-shot) | 28.69 |
118
+ | TruthfulQA (0-shot) | 39.76 |
119
+ | Winogrande (5-shot) | 65.98 |
120
+ | GSM8K (5-shot) | 2.73 |
121
+ | DROP (3-shot) | 4.72 |
122
+
123
+