Kingaimaster commited on
Commit
8e995e0
·
verified ·
1 Parent(s): 6ccacbf

Upload folder using huggingface_hub

Browse files
.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
chat_template.jinja ADDED
@@ -0,0 +1,99 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {%- set think_start = '<think>' -%}
2
+ {%- set think_end = '</think>' -%}
3
+
4
+ {%- macro render_content(msg) -%}
5
+ {%- set c = msg.get('content') -%}
6
+ {%- if c is string -%}
7
+ {{ c | replace(think_start, '*') | replace(think_end, '*') }}
8
+ {%- endif -%}
9
+ {%- endmacro -%}
10
+
11
+ {% macro set_roles(message) -%}
12
+ {%- set role_name = message.get('name') or message['role'] -%}
13
+ {%- if message['role'] == 'user' -%}
14
+ <|im_user|>{{role_name}}<|im_middle|>
15
+ {%- elif message['role'] == 'assistant' -%}
16
+ <|im_assistant|>{{role_name}}<|im_middle|>
17
+ {%- else -%}
18
+ <|im_system|>{{role_name}}<|im_middle|>
19
+ {%- endif -%}
20
+ {%- endmacro -%}
21
+
22
+ {%- macro render_toolcalls(message) -%}
23
+ <|tool_calls_section_begin|>
24
+ {%- for tool_call in message['tool_calls'] -%}
25
+ {%- set formatted_id = tool_call['id'] -%}
26
+ <|tool_call_begin|>{{ formatted_id }}<|tool_call_argument_begin|>{% if tool_call['function']['arguments'] is string %}{{ tool_call['function']['arguments'] }}{% else %}{{ tool_call['function']['arguments'] | tojson }}{% endif %}<|tool_call_end|>
27
+ {%- endfor -%}
28
+ <|tool_calls_section_end|>
29
+ {%- endmacro -%}
30
+
31
+ {# Find last non-tool-call assisitant message #}
32
+ {%- set ns = namespace(last_non_tool_call_assistant_msg=-1) -%}
33
+ {%- for idx in range(messages|length-1, -1, -1) -%}
34
+ {%- if messages[idx]['role'] == 'assistant' and not messages[idx].get('tool_calls') -%}
35
+ {%- set ns.last_non_tool_call_assistant_msg = idx -%}
36
+ {%- break -%}
37
+ {%- endif -%}
38
+ {%- endfor -%}
39
+
40
+ {# split all messages into history & suffix, reasoning_content in suffix should be reserved.#}
41
+ {%- set hist_msgs = messages[:ns.last_non_tool_call_assistant_msg+1] -%}
42
+ {%- set suffix_msgs = messages[ns.last_non_tool_call_assistant_msg+1:] -%}
43
+
44
+ {%- if tools -%}
45
+ {%- if tools_ts_str -%}
46
+ <|im_system|>tool_declare<|im_middle|>{{ tools_ts_str }}<|im_end|>
47
+ {%- else -%}
48
+ <|im_system|>tool_declare<|im_middle|>{{ tools | tojson(separators=(',', ':')) }}<|im_end|>
49
+ {%- endif -%}
50
+ {%- endif -%}
51
+
52
+ {%- for message in hist_msgs -%}
53
+ {{set_roles(message)}}
54
+ {%- if message['role'] == 'assistant' -%}
55
+ <think></think>{{render_content(message)}}
56
+ {%- if message.get('tool_calls') -%}
57
+ {{render_toolcalls(message)}}
58
+ {%- endif -%}
59
+ {%- elif message['role'] == 'tool' -%}
60
+ {%- set tool_call_id = message.tool_call_id -%}
61
+ ## Return of {{ tool_call_id }}
62
+ {{render_content(message)}}
63
+ {%- elif message['content'] is not none -%}
64
+ {{render_content(message)}}
65
+ {%- endif -%}
66
+ <|im_end|>
67
+ {%- endfor -%}
68
+
69
+ {%- for message in suffix_msgs -%}
70
+ {{set_roles(message)}}
71
+ {%- if message['role'] == 'assistant' -%}
72
+ {%- if thinking is defined and thinking is false -%}
73
+ <think></think>{{render_content(message)}}
74
+ {%- else -%}
75
+ {%- set rc = message.get('reasoning_content', '') -%}
76
+ <think>{{rc}}</think>{{render_content(message)}}
77
+ {%- endif -%}
78
+ {%- if message.get('tool_calls') -%}
79
+ {{render_toolcalls(message)}}
80
+ {%- endif -%}
81
+ {%- elif message['role'] == 'tool' -%}
82
+ {%- set tool_call_id = message.tool_call_id -%}
83
+ ## Return of {{ tool_call_id }}
84
+ {{render_content(message)}}
85
+ {%- elif message['content'] is not none -%}
86
+ {{render_content(message)}}
87
+ {%- endif -%}
88
+ <|im_end|>
89
+ {%- endfor -%}
90
+
91
+
92
+ {%- if add_generation_prompt -%}
93
+ <|im_assistant|>assistant<|im_middle|>
94
+ {%- if thinking is defined and thinking is false -%}
95
+ <think></think>
96
+ {%- else -%}
97
+ <think>
98
+ {%- endif -%}
99
+ {%- endif -%}
config.json ADDED
@@ -0,0 +1,78 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": ["DeepseekV3ForCausalLM"],
3
+ "bos_token_id": 163584,
4
+ "dtype": "bfloat16",
5
+ "eos_token_id": 163585,
6
+ "hidden_act": "silu",
7
+ "hidden_size": 7168,
8
+ "initializer_range": 0.02,
9
+ "intermediate_size": 18432,
10
+ "max_position_embeddings": 262144,
11
+ "model_type": "deepseek_v3",
12
+ "moe_intermediate_size": 2048,
13
+ "num_attention_heads": 64,
14
+ "num_hidden_layers": 61,
15
+ "num_key_value_heads": 64,
16
+ "pad_token_id": 163839,
17
+ "rms_norm_eps": 1e-5,
18
+ "rope_theta": 50000,
19
+ "rope_scaling": {
20
+ "beta_fast": 32,
21
+ "beta_slow": 1,
22
+ "factor": 64,
23
+ "mscale": 1,
24
+ "mscale_all_dim": 1,
25
+ "original_max_position_embeddings": 4096,
26
+ "type": "yarn"
27
+ },
28
+ "routed_scaling_factor": 2.827,
29
+ "tie_word_embeddings": false,
30
+ "use_cache": true,
31
+ "vocab_size": 163840,
32
+ "aux_loss_alpha": 0.001,
33
+ "attention_bias": false,
34
+ "attention_dropout": 0,
35
+ "ep_size": 1,
36
+ "first_k_dense_replace": 1,
37
+ "kv_lora_rank": 512,
38
+ "n_group": 1,
39
+ "n_routed_experts": 384,
40
+ "n_shared_experts": 1,
41
+ "norm_topk_prob": true,
42
+ "num_experts_per_tok": 8,
43
+ "moe_layer_freq": 1,
44
+ "num_nextn_predict_layers": 0,
45
+ "q_lora_rank": 1536,
46
+ "qk_nope_head_dim": 128,
47
+ "qk_rope_head_dim": 64,
48
+ "scoring_func": "sigmoid",
49
+ "seq_aux": true,
50
+ "topk_group": 1,
51
+ "topk_method": "noaux_tc",
52
+ "v_head_dim": 128,
53
+ "quantization_config": {
54
+ "config_groups": {
55
+ "group_0": {
56
+ "input_activations": null,
57
+ "output_activations": null,
58
+ "targets": ["Linear"],
59
+ "weights": {
60
+ "actorder": null,
61
+ "block_structure": null,
62
+ "dynamic": false,
63
+ "group_size": 32,
64
+ "num_bits": 4,
65
+ "observer": "minmax",
66
+ "observer_kwargs": {},
67
+ "strategy": "group",
68
+ "symmetric": true,
69
+ "type": "int"
70
+ }
71
+ }
72
+ },
73
+ "format": "pack-quantized",
74
+ "ignore": ["lm_head", "re:.*self_attn.*", "re:.*shared_experts.*", "re:.*mlp\\.(gate|up|gate_up|down)_proj.*"],
75
+ "quant_method": "compressed-tensors",
76
+ "quantization_status": "compressed"
77
+ }
78
+ }
generation_config.json ADDED
@@ -0,0 +1 @@
 
 
1
+ {"max_length": 262144, "eos_token_id": 163586}
model-00001-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:997e10f3d8d9774e6d096a4d348c95d363757e9e176c2bb0fac700e747078cc9
3
+ size 32207566064
model-00002-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:18620ed9781ce126fc865431760d1887874cfdc0916e69588d9da88cbdc74e04
3
+ size 32209010008
model-00003-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c20f5675d602381daa651ecbb9d14ccdbf330d5921dee82eae8c9416ba2533f8
3
+ size 32209011024
model-00004-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8c285aa6b6ca2e20e62d46e3ab3cd6bfd151ba7525f1454c1b83984b66db7dd4
3
+ size 32207597368
model-00005-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4d2b68038154f6841d4a9e3fd9101a29906b12e9c9e155e552c731a9e860966a
3
+ size 32209019784
model-00006-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:dd1b5e83ea93edc9969140613c735d480debe17f2b28331a14aeb30a2312e77e
3
+ size 32209021432
model-00007-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a89e53f11762b0da426d5e31160d28e91a842bbe45840caee43c614374632dc6
3
+ size 32209019520
model-00008-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:26c3dc9ea05188457597456b3045fb9cc21e65b27390a6d9b5b821bb7060bf2f
3
+ size 32207597648
model-00009-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ab821190ee99e130dab829a540249be9919d25691b9ff1f35a846d04409e0d80
3
+ size 32209021432
model-00010-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:28c72a4c2c8d6bb74438185a9ce5d2a8a75db1d43d302bdb8f026454325d647b
3
+ size 32208102144
model-00011-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c080b5575edeb4087642a6abff4c38698f05fe437ef72a59e9624158e48617d6
3
+ size 32209288472
model-00012-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e7ac7c466570827801f6dc367124a8e4878c1f2523986da48e92fba37fafdd1d
3
+ size 32212833712
model-00013-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:874da2c6179347bb8ea5c662eebeda893a58e49a538a6ee196d364ed23ebcda6
3
+ size 32209021424
model-00014-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:74283d767f168be0db8ce79a896bc4e617332aa41b5c0b186dab9d3c7bb5f6ca
3
+ size 32209019568
model-00015-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0918c6e70159234183eb9e4739cbbc182edd3d2b988c2a2e2934d6b7a11e22ba
3
+ size 32207597592
model-00016-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b150d7b06817ca7f5f1f7f6f5b3e3613ab7b1c532bad7ebff28c7c913f5448bb
3
+ size 32209019784
model-00017-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:82743be5ef520e412f54fdbd1ca593685fdacd705c6427dc5e03c3f253017a4f
3
+ size 32209021432
model-00018-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6e4868844626652f8a8953d2737ca282ac7fc956fc0e65c181869819c7a4a0e1
3
+ size 32208099920
model-00019-of-00019.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7a902ebfd7cceebc8d051d7926534de7b53b625c6bc79a1044603230f805f523
3
+ size 14474008600
model.safetensors.index.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1341ea6020a68cdb9dd8c9f551ebcca6ff9121253ee1572755b03d8e321eaf94
3
+ size 20237088
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "163584": {"content": "[BOS]", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
4
+ "163585": {"content": "[EOS]", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
5
+ "163586": {"content": "<|im_end|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
6
+ "163587": {"content": "<|im_user|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
7
+ "163588": {"content": "<|im_assistant|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
8
+ "163590": {"content": "<|start_header_id|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
9
+ "163591": {"content": "<|end_header_id|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
10
+ "163593": {"content": "[EOT]", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
11
+ "163594": {"content": "<|im_system|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
12
+ "163595": {"content": "<|tool_calls_section_begin|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
13
+ "163596": {"content": "<|tool_calls_section_end|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
14
+ "163597": {"content": "<|tool_call_begin|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
15
+ "163598": {"content": "<|tool_call_argument_begin|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
16
+ "163599": {"content": "<|tool_call_end|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
17
+ "163601": {"content": "<|im_middle|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
18
+ "163606": {"content": "<think>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
19
+ "163607": {"content": "</think>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": false},
20
+ "163838": {"content": "[UNK]", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true},
21
+ "163839": {"content": "[PAD]", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true}
22
+ },
23
+ "additional_special_tokens": ["<|im_end|>", "<|im_user|>", "<|im_assistant|>", "<|start_header_id|>", "<|end_header_id|>", "[EOT]", "<|im_system|>", "<|im_middle|>"],
24
+ "bos_token": "[BOS]",
25
+ "clean_up_tokenization_spaces": false,
26
+ "eos_token": "[EOS]",
27
+ "model_max_length": 262144,
28
+ "pad_token": "[PAD]",
29
+ "tokenizer_class": "PreTrainedTokenizerFast",
30
+ "unk_token": "[UNK]"
31
+ }