Converted deepseek-ai/DeepSeek-V2.5 to BNB with nf4 and bf16
Browse files- .gitattributes +1 -0
- config.json +76 -0
- generation_config.json +9 -0
- model-00001-of-00025.safetensors +3 -0
- model-00002-of-00025.safetensors +3 -0
- model-00003-of-00025.safetensors +3 -0
- model-00004-of-00025.safetensors +3 -0
- model-00005-of-00025.safetensors +3 -0
- model-00006-of-00025.safetensors +3 -0
- model-00007-of-00025.safetensors +3 -0
- model-00008-of-00025.safetensors +3 -0
- model-00009-of-00025.safetensors +3 -0
- model-00010-of-00025.safetensors +3 -0
- model-00011-of-00025.safetensors +3 -0
- model-00012-of-00025.safetensors +3 -0
- model-00013-of-00025.safetensors +3 -0
- model-00014-of-00025.safetensors +3 -0
- model-00015-of-00025.safetensors +3 -0
- model-00016-of-00025.safetensors +3 -0
- model-00017-of-00025.safetensors +3 -0
- model-00018-of-00025.safetensors +3 -0
- model-00019-of-00025.safetensors +3 -0
- model-00020-of-00025.safetensors +3 -0
- model-00021-of-00025.safetensors +3 -0
- model-00022-of-00025.safetensors +3 -0
- model-00023-of-00025.safetensors +3 -0
- model-00024-of-00025.safetensors +3 -0
- model-00025-of-00025.safetensors +3 -0
- model.safetensors.index.json +3 -0
- special_tokens_map.json +23 -0
- tokenizer.json +0 -0
- tokenizer_config.json +162 -0
.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 |
+
model.safetensors.index.json filter=lfs diff=lfs merge=lfs -text
|
config.json
ADDED
@@ -0,0 +1,76 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_name_or_path": "deepseek-ai/DeepSeek-V2.5",
|
3 |
+
"architectures": [
|
4 |
+
"DeepseekV2ForCausalLM"
|
5 |
+
],
|
6 |
+
"attention_bias": false,
|
7 |
+
"attention_dropout": 0.0,
|
8 |
+
"auto_map": {
|
9 |
+
"AutoConfig": "deepseek-ai/DeepSeek-V2.5--configuration_deepseek.DeepseekV2Config",
|
10 |
+
"AutoModel": "deepseek-ai/DeepSeek-V2.5--modeling_deepseek.DeepseekV2Model",
|
11 |
+
"AutoModelForCausalLM": "deepseek-ai/DeepSeek-V2.5--modeling_deepseek.DeepseekV2ForCausalLM"
|
12 |
+
},
|
13 |
+
"aux_loss_alpha": 0.001,
|
14 |
+
"bos_token_id": 100000,
|
15 |
+
"eos_token_id": 100001,
|
16 |
+
"ep_size": 1,
|
17 |
+
"first_k_dense_replace": 1,
|
18 |
+
"hidden_act": "silu",
|
19 |
+
"hidden_size": 5120,
|
20 |
+
"initializer_range": 0.02,
|
21 |
+
"intermediate_size": 12288,
|
22 |
+
"kv_lora_rank": 512,
|
23 |
+
"max_position_embeddings": 163840,
|
24 |
+
"model_type": "deepseek_v2",
|
25 |
+
"moe_intermediate_size": 1536,
|
26 |
+
"moe_layer_freq": 1,
|
27 |
+
"n_group": 8,
|
28 |
+
"n_routed_experts": 160,
|
29 |
+
"n_shared_experts": 2,
|
30 |
+
"norm_topk_prob": false,
|
31 |
+
"num_attention_heads": 128,
|
32 |
+
"num_experts_per_tok": 6,
|
33 |
+
"num_hidden_layers": 60,
|
34 |
+
"num_key_value_heads": 128,
|
35 |
+
"pretraining_tp": 1,
|
36 |
+
"q_lora_rank": 1536,
|
37 |
+
"qk_nope_head_dim": 128,
|
38 |
+
"qk_rope_head_dim": 64,
|
39 |
+
"quantization_config": {
|
40 |
+
"_load_in_4bit": true,
|
41 |
+
"_load_in_8bit": false,
|
42 |
+
"bnb_4bit_compute_dtype": "bfloat16",
|
43 |
+
"bnb_4bit_quant_storage": "bfloat16",
|
44 |
+
"bnb_4bit_quant_type": "nf4",
|
45 |
+
"bnb_4bit_use_double_quant": true,
|
46 |
+
"llm_int8_enable_fp32_cpu_offload": false,
|
47 |
+
"llm_int8_has_fp16_weight": false,
|
48 |
+
"llm_int8_skip_modules": null,
|
49 |
+
"llm_int8_threshold": 6.0,
|
50 |
+
"load_in_4bit": true,
|
51 |
+
"load_in_8bit": false,
|
52 |
+
"quant_method": "bitsandbytes"
|
53 |
+
},
|
54 |
+
"rms_norm_eps": 1e-06,
|
55 |
+
"rope_scaling": {
|
56 |
+
"beta_fast": 32,
|
57 |
+
"beta_slow": 1,
|
58 |
+
"factor": 40,
|
59 |
+
"mscale": 1.0,
|
60 |
+
"mscale_all_dim": 1.0,
|
61 |
+
"original_max_position_embeddings": 4096,
|
62 |
+
"type": "yarn"
|
63 |
+
},
|
64 |
+
"rope_theta": 10000,
|
65 |
+
"routed_scaling_factor": 16.0,
|
66 |
+
"scoring_func": "softmax",
|
67 |
+
"seq_aux": true,
|
68 |
+
"tie_word_embeddings": false,
|
69 |
+
"topk_group": 3,
|
70 |
+
"topk_method": "group_limited_greedy",
|
71 |
+
"torch_dtype": "bfloat16",
|
72 |
+
"transformers_version": "4.44.2",
|
73 |
+
"use_cache": false,
|
74 |
+
"v_head_dim": 128,
|
75 |
+
"vocab_size": 102400
|
76 |
+
}
|
generation_config.json
ADDED
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"_from_model_config": true,
|
3 |
+
"bos_token_id": 100000,
|
4 |
+
"do_sample": true,
|
5 |
+
"eos_token_id": 100001,
|
6 |
+
"temperature": 0.3,
|
7 |
+
"top_p": 0.95,
|
8 |
+
"transformers_version": "4.44.2"
|
9 |
+
}
|
model-00001-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:75337c50c026b34596da55a2091a8100a4636e428fa903fd76b1cb2c82335c7a
|
3 |
+
size 4999229224
|
model-00002-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:6cf4f6bf7f8ededd5b58112c85ccf3d01c17514b256dd2b6a948759b01055a3a
|
3 |
+
size 4997141922
|
model-00003-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:6bf315359fa6f07002de025b6b52dfa8a369b22a6c2afacbf280691a0aaad910
|
3 |
+
size 4999673056
|
model-00004-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:217ecbffc8c857fe74ff2ad8375944f31541a5271e614b6360ea6bd0e8feec2b
|
3 |
+
size 4997142442
|
model-00005-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5f99bdfeead9fab1e48d24cd4c3d5be36474326e8d79d8208d872affcb3439df
|
3 |
+
size 4999679847
|
model-00006-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:139e8991a56ceeb2934d4bb7d1399068a3b2b9c46863d2180d1fe6c2e0d9e2e2
|
3 |
+
size 4982286120
|
model-00007-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:94d5a9d2fc5bf03f1fb1e8b0b821903d3a04c9e373afe1a7801ba601d0a80acc
|
3 |
+
size 4998306813
|
model-00008-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:254356845729699d5337ef158186ea0952a1ff4c8d53f92b016b9ca401c5609b
|
3 |
+
size 4999680465
|
model-00009-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a2b2abd7a489d7fcea9a087ed365e7d39046ad3cfc526dd52dc410f9427243f7
|
3 |
+
size 4997148237
|
model-00010-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:717bbe1bae75105f4a57e6b325471d29fecfaf2be8b7b436e9008fe1eda6c1ac
|
3 |
+
size 4999680036
|
model-00011-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:9114102c93aab26f166668a711a957b556cc2510939281792d0b33a237590c9c
|
3 |
+
size 4997148597
|
model-00012-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:add6f9a6e8ab8cc9e078f951d8b0a109dc901b0fc875dfe1d76a3153da20003e
|
3 |
+
size 4999679619
|
model-00013-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:d6b59849bc252f9168f9dd89ecb9bea2f42dd82a11d208abcf55e26a352954fc
|
3 |
+
size 4997149015
|
model-00014-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a1e63efd57b0b626a7ff37e5c169af1fcdcfbe6939361ea5b04f3c4713acfc8b
|
3 |
+
size 4999679522
|
model-00015-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:21fd7188d7f8eb80c9dad098d25aa39aa508bbbb1ba02d78388b4d421609b9ac
|
3 |
+
size 4999680573
|
model-00016-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:de513dbb3cd5ecc8a83ea818c16c0fb9e25c6d677f3351ee086ef893a0698c71
|
3 |
+
size 4997148034
|
model-00017-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:f06dcdb605cf71d9be8a6d737bb6e1167426a8f1dc426c33e6be2d0b4c50c399
|
3 |
+
size 4999680184
|
model-00018-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:0884a174fd8a455b352dddd1e198a7a7fd951ba857392171537c2afbfe738da4
|
3 |
+
size 4997148370
|
model-00019-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:af2193ceafd3c051e7918fa7a3ce78c95dd2356e1068a52f8e706e7cd4a8d599
|
3 |
+
size 4999679757
|
model-00020-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b885345c5bac6e5df44a10f9d7d4cb6829a335bd1892d30e1ed4268202a51473
|
3 |
+
size 4997148804
|
model-00021-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a765aabad07366b323605aa3246f2106d83f1c6146b67b67c14fabe65ac90c28
|
3 |
+
size 4999679582
|
model-00022-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:75aa46e66010560ab27fb573ac5c0e63de41064af04d807d81fbff8080bb356a
|
3 |
+
size 4993218989
|
model-00023-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:2ff88eb5543885fa582454308d0ad75595f63a3342f89241775f0db8422b6aa1
|
3 |
+
size 4999550541
|
model-00024-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:aa1c9d3ebd01d540fb42d66cf6e127b095d9a69ae921b8456f7f06d1a1ddef5c
|
3 |
+
size 4999680347
|
model-00025-of-00025.safetensors
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a4d2b44282d4a61cb9751544195a7900a5c30ff50ca8eae3da720fd182759f56
|
3 |
+
size 3353217600
|
model.safetensors.index.json
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5c17e2b107c08c378935d52e3e0efe051544cffec65d61b3ae1182d326f8da74
|
3 |
+
size 17906271
|
special_tokens_map.json
ADDED
@@ -0,0 +1,23 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"bos_token": {
|
3 |
+
"content": "<|begin▁of▁sentence|>",
|
4 |
+
"lstrip": false,
|
5 |
+
"normalized": true,
|
6 |
+
"rstrip": false,
|
7 |
+
"single_word": false
|
8 |
+
},
|
9 |
+
"eos_token": {
|
10 |
+
"content": "<|end▁of▁sentence|>",
|
11 |
+
"lstrip": false,
|
12 |
+
"normalized": true,
|
13 |
+
"rstrip": false,
|
14 |
+
"single_word": false
|
15 |
+
},
|
16 |
+
"pad_token": {
|
17 |
+
"content": "<|end▁of▁sentence|>",
|
18 |
+
"lstrip": false,
|
19 |
+
"normalized": true,
|
20 |
+
"rstrip": false,
|
21 |
+
"single_word": false
|
22 |
+
}
|
23 |
+
}
|
tokenizer.json
ADDED
The diff for this file is too large to render.
See raw diff
|
|
tokenizer_config.json
ADDED
@@ -0,0 +1,162 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
{
|
2 |
+
"add_bos_token": true,
|
3 |
+
"add_eos_token": false,
|
4 |
+
"add_prefix_space": null,
|
5 |
+
"added_tokens_decoder": {
|
6 |
+
"100000": {
|
7 |
+
"content": "<|begin▁of▁sentence|>",
|
8 |
+
"lstrip": false,
|
9 |
+
"normalized": true,
|
10 |
+
"rstrip": false,
|
11 |
+
"single_word": false,
|
12 |
+
"special": true
|
13 |
+
},
|
14 |
+
"100001": {
|
15 |
+
"content": "<|end▁of▁sentence|>",
|
16 |
+
"lstrip": false,
|
17 |
+
"normalized": true,
|
18 |
+
"rstrip": false,
|
19 |
+
"single_word": false,
|
20 |
+
"special": true
|
21 |
+
},
|
22 |
+
"100002": {
|
23 |
+
"content": "<|fim▁hole|>",
|
24 |
+
"lstrip": false,
|
25 |
+
"normalized": true,
|
26 |
+
"rstrip": false,
|
27 |
+
"single_word": false,
|
28 |
+
"special": false
|
29 |
+
},
|
30 |
+
"100003": {
|
31 |
+
"content": "<|fim▁begin|>",
|
32 |
+
"lstrip": false,
|
33 |
+
"normalized": true,
|
34 |
+
"rstrip": false,
|
35 |
+
"single_word": false,
|
36 |
+
"special": false
|
37 |
+
},
|
38 |
+
"100004": {
|
39 |
+
"content": "<|fim▁end|>",
|
40 |
+
"lstrip": false,
|
41 |
+
"normalized": true,
|
42 |
+
"rstrip": false,
|
43 |
+
"single_word": false,
|
44 |
+
"special": false
|
45 |
+
},
|
46 |
+
"100005": {
|
47 |
+
"content": "<|completion|>",
|
48 |
+
"lstrip": false,
|
49 |
+
"normalized": true,
|
50 |
+
"rstrip": false,
|
51 |
+
"single_word": false,
|
52 |
+
"special": false
|
53 |
+
},
|
54 |
+
"100006": {
|
55 |
+
"content": "<|User|>",
|
56 |
+
"lstrip": false,
|
57 |
+
"normalized": true,
|
58 |
+
"rstrip": false,
|
59 |
+
"single_word": false,
|
60 |
+
"special": false
|
61 |
+
},
|
62 |
+
"100007": {
|
63 |
+
"content": "<|Assistant|>",
|
64 |
+
"lstrip": false,
|
65 |
+
"normalized": true,
|
66 |
+
"rstrip": false,
|
67 |
+
"single_word": false,
|
68 |
+
"special": false
|
69 |
+
},
|
70 |
+
"100008": {
|
71 |
+
"content": "<|EOT|>",
|
72 |
+
"lstrip": false,
|
73 |
+
"normalized": true,
|
74 |
+
"rstrip": false,
|
75 |
+
"single_word": false,
|
76 |
+
"special": true
|
77 |
+
},
|
78 |
+
"100009": {
|
79 |
+
"content": "<|tool▁calls▁begin|>",
|
80 |
+
"lstrip": false,
|
81 |
+
"normalized": true,
|
82 |
+
"rstrip": false,
|
83 |
+
"single_word": false,
|
84 |
+
"special": false
|
85 |
+
},
|
86 |
+
"100010": {
|
87 |
+
"content": "<|tool▁calls▁end|>",
|
88 |
+
"lstrip": false,
|
89 |
+
"normalized": true,
|
90 |
+
"rstrip": false,
|
91 |
+
"single_word": false,
|
92 |
+
"special": false
|
93 |
+
},
|
94 |
+
"100011": {
|
95 |
+
"content": "<|tool▁call▁begin|>",
|
96 |
+
"lstrip": false,
|
97 |
+
"normalized": true,
|
98 |
+
"rstrip": false,
|
99 |
+
"single_word": false,
|
100 |
+
"special": false
|
101 |
+
},
|
102 |
+
"100012": {
|
103 |
+
"content": "<|tool▁call▁end|>",
|
104 |
+
"lstrip": false,
|
105 |
+
"normalized": true,
|
106 |
+
"rstrip": false,
|
107 |
+
"single_word": false,
|
108 |
+
"special": false
|
109 |
+
},
|
110 |
+
"100013": {
|
111 |
+
"content": "<|tool▁outputs▁begin|>",
|
112 |
+
"lstrip": false,
|
113 |
+
"normalized": true,
|
114 |
+
"rstrip": false,
|
115 |
+
"single_word": false,
|
116 |
+
"special": false
|
117 |
+
},
|
118 |
+
"100014": {
|
119 |
+
"content": "<|tool▁outputs▁end|>",
|
120 |
+
"lstrip": false,
|
121 |
+
"normalized": true,
|
122 |
+
"rstrip": false,
|
123 |
+
"single_word": false,
|
124 |
+
"special": false
|
125 |
+
},
|
126 |
+
"100015": {
|
127 |
+
"content": "<|tool▁output▁begin|>",
|
128 |
+
"lstrip": false,
|
129 |
+
"normalized": true,
|
130 |
+
"rstrip": false,
|
131 |
+
"single_word": false,
|
132 |
+
"special": false
|
133 |
+
},
|
134 |
+
"100016": {
|
135 |
+
"content": "<|tool▁output▁end|>",
|
136 |
+
"lstrip": false,
|
137 |
+
"normalized": true,
|
138 |
+
"rstrip": false,
|
139 |
+
"single_word": false,
|
140 |
+
"special": false
|
141 |
+
},
|
142 |
+
"100017": {
|
143 |
+
"content": "<|tool▁sep|>",
|
144 |
+
"lstrip": false,
|
145 |
+
"normalized": true,
|
146 |
+
"rstrip": false,
|
147 |
+
"single_word": false,
|
148 |
+
"special": false
|
149 |
+
}
|
150 |
+
},
|
151 |
+
"bos_token": "<|begin▁of▁sentence|>",
|
152 |
+
"chat_template": "{% if not add_generation_prompt is defined %}{% set add_generation_prompt = false %}{% endif %}{% set ns = namespace(is_first=false, is_tool=false, is_output_first=true, system_prompt='') %}{%- for message in messages %} {%- if message['role'] == 'system' %} {% set ns.system_prompt = message['content'] %} {%- endif %}{%- endfor %}{{bos_token}}{{ns.system_prompt}}{%- for message in messages %} {%- if message['role'] == 'user' %} {%- set ns.is_tool = false -%}{{'<|User|>' + message['content']}} {%- endif %} {%- if message['role'] == 'assistant' and message['content'] is none %} {%- set ns.is_tool = false -%} {%- for tool in message['tool_calls']%} {%- if not ns.is_first %}{{'<|Assistant|><|tool▁calls▁begin|><|tool▁call▁begin|>' + tool['type'] + '<|tool▁sep|>' + tool['function']['name'] + '\\n' + '```json' + '\\n' + tool['function']['arguments'] + '\\n' + '```' + '<|tool▁call▁end|>'}} {%- set ns.is_first = true -%} {%- else %}{{'\\n' + '<|tool▁call▁begin|>' + tool['type'] + '<|tool▁sep|>' + tool['function']['name'] + '\\n' + '```json' + '\\n' + tool['function']['arguments'] + '\\n' + '```' + '<|tool▁call▁end|>'}}{{'<|tool▁calls▁end|><|end▁of▁sentence|>'}} {%- endif %} {%- endfor %} {%- endif %} {%- if message['role'] == 'assistant' and message['content'] is not none %} {%- if ns.is_tool %}{{'<|tool▁outputs▁end|>' + message['content'] + '<|end▁of▁sentence|>'}} {%- set ns.is_tool = false -%} {%- else %}{{'<|Assistant|>' + message['content'] + '<|end▁of▁sentence|>'}} {%- endif %} {%- endif %} {%- if message['role'] == 'tool' %} {%- set ns.is_tool = true -%} {%- if ns.is_output_first %}{{'<|tool▁outputs▁begin|><|tool▁output▁begin|>' + message['content'] + '<|tool▁output▁end|>'}} {%- set ns.is_output_first = false %} {%- else %}{{'\\n<|tool▁output▁begin|>' + message['content'] + '<|tool▁output▁end|>'}} {%- endif %} {%- endif %}{%- endfor -%}{% if ns.is_tool %}{{'<|tool▁outputs▁end|>'}}{% endif %}{% if add_generation_prompt and not ns.is_tool %}{{'<|Assistant|>'}}{% endif %}",
|
153 |
+
"clean_up_tokenization_spaces": false,
|
154 |
+
"eos_token": "<|end▁of▁sentence|>",
|
155 |
+
"legacy": true,
|
156 |
+
"model_max_length": 16384,
|
157 |
+
"pad_token": "<|end▁of▁sentence|>",
|
158 |
+
"sp_model_kwargs": {},
|
159 |
+
"tokenizer_class": "LlamaTokenizer",
|
160 |
+
"unk_token": null,
|
161 |
+
"use_default_system_prompt": false
|
162 |
+
}
|