Upload folder using huggingface_hub
Browse files- README.md +191 -0
- config.json +84 -0
- model.safetensors +3 -0
- special_tokens_map.json +35 -0
- tokenizer.json +0 -0
- tokenizer.model +3 -0
- tokenizer_config.json +48 -0
README.md
ADDED
@@ -0,0 +1,191 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
---
|
2 |
+
language:
|
3 |
+
- en
|
4 |
+
license: mit
|
5 |
+
tags:
|
6 |
+
- generated_from_trainer
|
7 |
+
- mlx
|
8 |
+
datasets:
|
9 |
+
- HuggingFaceH4/ultrachat_200k
|
10 |
+
- HuggingFaceH4/ultrafeedback_binarized
|
11 |
+
base_model: mistralai/Mistral-7B-v0.1
|
12 |
+
widget:
|
13 |
+
- text: '<|system|>
|
14 |
+
|
15 |
+
You are a pirate chatbot who always responds with Arr!</s>
|
16 |
+
|
17 |
+
<|user|>
|
18 |
+
|
19 |
+
There''s a llama on my lawn, how can I get rid of him?</s>
|
20 |
+
|
21 |
+
<|assistant|>
|
22 |
+
|
23 |
+
'
|
24 |
+
output:
|
25 |
+
text: Arr! 'Tis a puzzlin' matter, me hearty! A llama on yer lawn be a rare sight,
|
26 |
+
but I've got a plan that might help ye get rid of 'im. Ye'll need to gather
|
27 |
+
some carrots and hay, and then lure the llama away with the promise of a tasty
|
28 |
+
treat. Once he's gone, ye can clean up yer lawn and enjoy the peace and quiet
|
29 |
+
once again. But beware, me hearty, for there may be more llamas where that one
|
30 |
+
came from! Arr!
|
31 |
+
pipeline_tag: text-generation
|
32 |
+
model-index:
|
33 |
+
- name: zephyr-7b-beta
|
34 |
+
results:
|
35 |
+
- task:
|
36 |
+
type: text-generation
|
37 |
+
name: Text Generation
|
38 |
+
dataset:
|
39 |
+
name: AI2 Reasoning Challenge (25-Shot)
|
40 |
+
type: ai2_arc
|
41 |
+
config: ARC-Challenge
|
42 |
+
split: test
|
43 |
+
args:
|
44 |
+
num_few_shot: 25
|
45 |
+
metrics:
|
46 |
+
- type: acc_norm
|
47 |
+
value: 62.03071672354948
|
48 |
+
name: normalized accuracy
|
49 |
+
source:
|
50 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
51 |
+
name: Open LLM Leaderboard
|
52 |
+
- task:
|
53 |
+
type: text-generation
|
54 |
+
name: Text Generation
|
55 |
+
dataset:
|
56 |
+
name: HellaSwag (10-Shot)
|
57 |
+
type: hellaswag
|
58 |
+
split: validation
|
59 |
+
args:
|
60 |
+
num_few_shot: 10
|
61 |
+
metrics:
|
62 |
+
- type: acc_norm
|
63 |
+
value: 84.35570603465445
|
64 |
+
name: normalized accuracy
|
65 |
+
source:
|
66 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
67 |
+
name: Open LLM Leaderboard
|
68 |
+
- task:
|
69 |
+
type: text-generation
|
70 |
+
name: Text Generation
|
71 |
+
dataset:
|
72 |
+
name: Drop (3-Shot)
|
73 |
+
type: drop
|
74 |
+
split: validation
|
75 |
+
args:
|
76 |
+
num_few_shot: 3
|
77 |
+
metrics:
|
78 |
+
- type: f1
|
79 |
+
value: 9.66243708053691
|
80 |
+
name: f1 score
|
81 |
+
source:
|
82 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
83 |
+
name: Open LLM Leaderboard
|
84 |
+
- task:
|
85 |
+
type: text-generation
|
86 |
+
name: Text Generation
|
87 |
+
dataset:
|
88 |
+
name: TruthfulQA (0-shot)
|
89 |
+
type: truthful_qa
|
90 |
+
config: multiple_choice
|
91 |
+
split: validation
|
92 |
+
args:
|
93 |
+
num_few_shot: 0
|
94 |
+
metrics:
|
95 |
+
- type: mc2
|
96 |
+
value: 57.44916942762855
|
97 |
+
source:
|
98 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
99 |
+
name: Open LLM Leaderboard
|
100 |
+
- task:
|
101 |
+
type: text-generation
|
102 |
+
name: Text Generation
|
103 |
+
dataset:
|
104 |
+
name: GSM8k (5-shot)
|
105 |
+
type: gsm8k
|
106 |
+
config: main
|
107 |
+
split: test
|
108 |
+
args:
|
109 |
+
num_few_shot: 5
|
110 |
+
metrics:
|
111 |
+
- type: acc
|
112 |
+
value: 12.736921910538287
|
113 |
+
name: accuracy
|
114 |
+
source:
|
115 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
116 |
+
name: Open LLM Leaderboard
|
117 |
+
- task:
|
118 |
+
type: text-generation
|
119 |
+
name: Text Generation
|
120 |
+
dataset:
|
121 |
+
name: MMLU (5-Shot)
|
122 |
+
type: cais/mmlu
|
123 |
+
config: all
|
124 |
+
split: test
|
125 |
+
args:
|
126 |
+
num_few_shot: 5
|
127 |
+
metrics:
|
128 |
+
- type: acc
|
129 |
+
value: 61.07
|
130 |
+
name: accuracy
|
131 |
+
source:
|
132 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
133 |
+
name: Open LLM Leaderboard
|
134 |
+
- task:
|
135 |
+
type: text-generation
|
136 |
+
name: Text Generation
|
137 |
+
dataset:
|
138 |
+
name: Winogrande (5-shot)
|
139 |
+
type: winogrande
|
140 |
+
config: winogrande_xl
|
141 |
+
split: validation
|
142 |
+
args:
|
143 |
+
num_few_shot: 5
|
144 |
+
metrics:
|
145 |
+
- type: acc
|
146 |
+
value: 77.7426992896606
|
147 |
+
name: accuracy
|
148 |
+
source:
|
149 |
+
url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=HuggingFaceH4/zephyr-7b-beta
|
150 |
+
name: Open LLM Leaderboard
|
151 |
+
- task:
|
152 |
+
type: text-generation
|
153 |
+
name: Text Generation
|
154 |
+
dataset:
|
155 |
+
name: AlpacaEval
|
156 |
+
type: tatsu-lab/alpaca_eval
|
157 |
+
metrics:
|
158 |
+
- type: unknown
|
159 |
+
value: 0.906
|
160 |
+
name: win rate
|
161 |
+
source:
|
162 |
+
url: https://tatsu-lab.github.io/alpaca_eval/
|
163 |
+
- task:
|
164 |
+
type: text-generation
|
165 |
+
name: Text Generation
|
166 |
+
dataset:
|
167 |
+
name: MT-Bench
|
168 |
+
type: unknown
|
169 |
+
metrics:
|
170 |
+
- type: unknown
|
171 |
+
value: 7.34
|
172 |
+
name: score
|
173 |
+
source:
|
174 |
+
url: https://huggingface.co/spaces/lmsys/mt-bench
|
175 |
+
---
|
176 |
+
|
177 |
+
# batmac/zephyr-7b-beta-mlx-4bit
|
178 |
+
This model was converted to MLX format from [`HuggingFaceH4/zephyr-7b-beta`]().
|
179 |
+
Refer to the [original model card](https://huggingface.co/HuggingFaceH4/zephyr-7b-beta) for more details on the model.
|
180 |
+
## Use with mlx
|
181 |
+
|
182 |
+
```bash
|
183 |
+
pip install mlx-lm
|
184 |
+
```
|
185 |
+
|
186 |
+
```python
|
187 |
+
from mlx_lm import load, generate
|
188 |
+
|
189 |
+
model, tokenizer = load("batmac/zephyr-7b-beta-mlx-4bit")
|
190 |
+
response = generate(model, tokenizer, prompt="hello", verbose=True)
|
191 |
+
```
|
config.json
ADDED
@@ -0,0 +1,84 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"vocab_size": 32000,
|
3 |
+
"max_position_embeddings": 32768,
|
4 |
+
"hidden_size": 4096,
|
5 |
+
"intermediate_size": 14336,
|
6 |
+
"num_hidden_layers": 32,
|
7 |
+
"num_attention_heads": 32,
|
8 |
+
"sliding_window": 4096,
|
9 |
+
"num_key_value_heads": 8,
|
10 |
+
"hidden_act": "silu",
|
11 |
+
"initializer_range": 0.02,
|
12 |
+
"rms_norm_eps": 1e-05,
|
13 |
+
"use_cache": true,
|
14 |
+
"rope_theta": 10000.0,
|
15 |
+
"attention_dropout": 0.0,
|
16 |
+
"return_dict": true,
|
17 |
+
"output_hidden_states": false,
|
18 |
+
"output_attentions": false,
|
19 |
+
"torchscript": false,
|
20 |
+
"torch_dtype": "bfloat16",
|
21 |
+
"use_bfloat16": false,
|
22 |
+
"tf_legacy_loss": false,
|
23 |
+
"pruned_heads": {},
|
24 |
+
"tie_word_embeddings": false,
|
25 |
+
"chunk_size_feed_forward": 0,
|
26 |
+
"is_encoder_decoder": false,
|
27 |
+
"is_decoder": false,
|
28 |
+
"cross_attention_hidden_size": null,
|
29 |
+
"add_cross_attention": false,
|
30 |
+
"tie_encoder_decoder": false,
|
31 |
+
"max_length": 20,
|
32 |
+
"min_length": 0,
|
33 |
+
"do_sample": false,
|
34 |
+
"early_stopping": false,
|
35 |
+
"num_beams": 1,
|
36 |
+
"num_beam_groups": 1,
|
37 |
+
"diversity_penalty": 0.0,
|
38 |
+
"temperature": 1.0,
|
39 |
+
"top_k": 50,
|
40 |
+
"top_p": 1.0,
|
41 |
+
"typical_p": 1.0,
|
42 |
+
"repetition_penalty": 1.0,
|
43 |
+
"length_penalty": 1.0,
|
44 |
+
"no_repeat_ngram_size": 0,
|
45 |
+
"encoder_no_repeat_ngram_size": 0,
|
46 |
+
"bad_words_ids": null,
|
47 |
+
"num_return_sequences": 1,
|
48 |
+
"output_scores": false,
|
49 |
+
"return_dict_in_generate": false,
|
50 |
+
"forced_bos_token_id": null,
|
51 |
+
"forced_eos_token_id": null,
|
52 |
+
"remove_invalid_values": false,
|
53 |
+
"exponential_decay_length_penalty": null,
|
54 |
+
"suppress_tokens": null,
|
55 |
+
"begin_suppress_tokens": null,
|
56 |
+
"architectures": [
|
57 |
+
"MistralForCausalLM"
|
58 |
+
],
|
59 |
+
"finetuning_task": null,
|
60 |
+
"id2label": {
|
61 |
+
"0": "LABEL_0",
|
62 |
+
"1": "LABEL_1"
|
63 |
+
},
|
64 |
+
"label2id": {
|
65 |
+
"LABEL_0": 0,
|
66 |
+
"LABEL_1": 1
|
67 |
+
},
|
68 |
+
"tokenizer_class": null,
|
69 |
+
"prefix": null,
|
70 |
+
"bos_token_id": 1,
|
71 |
+
"pad_token_id": 2,
|
72 |
+
"eos_token_id": 2,
|
73 |
+
"sep_token_id": null,
|
74 |
+
"decoder_start_token_id": null,
|
75 |
+
"task_specific_params": null,
|
76 |
+
"problem_type": null,
|
77 |
+
"_name_or_path": "/Users/bat/.cache/huggingface/hub/models--HuggingFaceH4--zephyr-7b-beta/snapshots/dc24cabd13eacd3ae3a5fe574bd645483a335a4a",
|
78 |
+
"transformers_version": "4.37.1",
|
79 |
+
"model_type": "mistral",
|
80 |
+
"quantization": {
|
81 |
+
"group_size": 64,
|
82 |
+
"bits": 4
|
83 |
+
}
|
84 |
+
}
|
model.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:be2ca1ed92a870c312e7fbb8ae7d81c11ab381445419469658e857567a383ba5
|
3 |
+
size 4262357056
|
special_tokens_map.json
ADDED
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"additional_special_tokens": [
|
3 |
+
"<unk>",
|
4 |
+
"<s>",
|
5 |
+
"</s>"
|
6 |
+
],
|
7 |
+
"bos_token": {
|
8 |
+
"content": "<s>",
|
9 |
+
"lstrip": false,
|
10 |
+
"normalized": false,
|
11 |
+
"rstrip": false,
|
12 |
+
"single_word": false
|
13 |
+
},
|
14 |
+
"eos_token": {
|
15 |
+
"content": "</s>",
|
16 |
+
"lstrip": false,
|
17 |
+
"normalized": false,
|
18 |
+
"rstrip": false,
|
19 |
+
"single_word": false
|
20 |
+
},
|
21 |
+
"pad_token": {
|
22 |
+
"content": "</s>",
|
23 |
+
"lstrip": false,
|
24 |
+
"normalized": false,
|
25 |
+
"rstrip": false,
|
26 |
+
"single_word": false
|
27 |
+
},
|
28 |
+
"unk_token": {
|
29 |
+
"content": "<unk>",
|
30 |
+
"lstrip": false,
|
31 |
+
"normalized": false,
|
32 |
+
"rstrip": false,
|
33 |
+
"single_word": false
|
34 |
+
}
|
35 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer.model
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:dadfd56d766715c61d2ef780a525ab43b8e6da4de6865bda3d95fdef5e134055
|
3 |
+
size 493443
|
tokenizer_config.json
ADDED
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"add_bos_token": true,
|
3 |
+
"add_eos_token": false,
|
4 |
+
"added_tokens_decoder": {
|
5 |
+
"0": {
|
6 |
+
"content": "<unk>",
|
7 |
+
"lstrip": false,
|
8 |
+
"normalized": false,
|
9 |
+
"rstrip": false,
|
10 |
+
"single_word": false,
|
11 |
+
"special": true
|
12 |
+
},
|
13 |
+
"1": {
|
14 |
+
"content": "<s>",
|
15 |
+
"lstrip": false,
|
16 |
+
"normalized": false,
|
17 |
+
"rstrip": false,
|
18 |
+
"single_word": false,
|
19 |
+
"special": true
|
20 |
+
},
|
21 |
+
"2": {
|
22 |
+
"content": "</s>",
|
23 |
+
"lstrip": false,
|
24 |
+
"normalized": false,
|
25 |
+
"rstrip": false,
|
26 |
+
"single_word": false,
|
27 |
+
"special": true
|
28 |
+
}
|
29 |
+
},
|
30 |
+
"additional_special_tokens": [
|
31 |
+
"<unk>",
|
32 |
+
"<s>",
|
33 |
+
"</s>"
|
34 |
+
],
|
35 |
+
"bos_token": "<s>",
|
36 |
+
"chat_template": "{% for message in messages %}\n{% if message['role'] == 'user' %}\n{{ '<|user|>\n' + message['content'] + eos_token }}\n{% elif message['role'] == 'system' %}\n{{ '<|system|>\n' + message['content'] + eos_token }}\n{% elif message['role'] == 'assistant' %}\n{{ '<|assistant|>\n' + message['content'] + eos_token }}\n{% endif %}\n{% if loop.last and add_generation_prompt %}\n{{ '<|assistant|>' }}\n{% endif %}\n{% endfor %}",
|
37 |
+
"clean_up_tokenization_spaces": false,
|
38 |
+
"eos_token": "</s>",
|
39 |
+
"legacy": true,
|
40 |
+
"model_max_length": 1000000000000000019884624838656,
|
41 |
+
"pad_token": "</s>",
|
42 |
+
"sp_model_kwargs": {},
|
43 |
+
"spaces_between_special_tokens": false,
|
44 |
+
"tokenizer_class": "LlamaTokenizer",
|
45 |
+
"truncation_side": "left",
|
46 |
+
"unk_token": "<unk>",
|
47 |
+
"use_default_system_prompt": true
|
48 |
+
}
|