Pinkstack commited on
Commit
1ae081c
·
verified ·
1 Parent(s): 970df75

Upload 6 files

Browse files
chat_template.jinja ADDED
@@ -0,0 +1,147 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {{- '<|reasoning_effort>low<reasoning_effort|>\n' }}
2
+ {%- if tools %}
3
+ {{- '<|im_start|>system\n' }}
4
+ {%- if messages[0].role == 'system' %}
5
+ {{- messages[0].content + '\n\n' }}
6
+ {%- endif %}
7
+ {{- "# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>" }}
8
+ {%- for tool in tools %}
9
+ {{- "\n" }}
10
+ {{- tool | tojson }}
11
+ {%- endfor %}
12
+ {{- "\n</tools>\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{\"name\": <function-name>, \"arguments\": <args-json-object>}\n</tool_call><|im_end|>\n" }}
13
+ {%- else %}
14
+ {%- if messages[0].role == 'system' %}
15
+ {{- '<|im_start|>system\n' + messages[0].content + '<|im_end|>\n' }}
16
+ {%- endif %}
17
+ {%- endif %}
18
+ {%- for message in messages %}
19
+ {%- if message.content is string %}
20
+ {%- set content = message.content %}
21
+ {%- else %}
22
+ {%- set content = '' %}
23
+ {%- endif %}
24
+ {%- if (message.role == "user") or (message.role == "system" and not loop.first) %}
25
+ {{- '<|im_start|>' + message.role + '\n' + content + '<|im_end|>' + '\n' }}
26
+ {%- elif message.role == "assistant" %}
27
+ {{- '<|im_start|>' + message.role + '\n' + content }}
28
+ {%- if message.tool_calls %}
29
+ {%- for tool_call in message.tool_calls %}
30
+ {%- if (loop.first and content) or (not loop.first) %}
31
+ {{- '\n' }}
32
+ {%- endif %}
33
+ {%- if tool_call.function %}
34
+ {%- set tool_call = tool_call.function %}
35
+ {%- endif %}
36
+ {{- '<tool_call>\n{"name": "' }}
37
+ {{- tool_call.name }}
38
+ {{- '", "arguments": ' }}
39
+ {%- if tool_call.arguments is string %}
40
+ {{- tool_call.arguments }}
41
+ {%- else %}
42
+ {{- tool_call.arguments | tojson }}
43
+ {%- endif %}
44
+ {{- '}\n</tool_call>' }}
45
+ {%- endfor %}
46
+ {%- endif %}
47
+ {{- '<|im_end|>\n' }}
48
+ {%- elif message.role == "tool" %}
49
+ {%- if loop.first or (messages[loop.index0 - 1].role != "tool") %}
50
+ {{- '<|im_start|>user' }}
51
+ {%- endif %}
52
+ {{- '\n<tool_response>\n' }}
53
+ {{- content }}
54
+ {{- '\n</tool_response>' }}
55
+ {%- if loop.last or (messages[loop.index0 + 1].role != "tool") %}
56
+ {{- '<|im_end|>\n' }}
57
+ {%- endif %}
58
+ {%- endif %}
59
+ {%- endfor %}
60
+ {%- if add_generation_prompt %}
61
+ {{- '<|im_start|>assistant\n' }}
62
+ {%- endif %}{%- if tools %}
63
+ {{- '<|im_start|>system\n' }}
64
+ {%- if messages[0].role == 'system' %}
65
+ {{- messages[0].content + '\n\n' }}
66
+ {%- endif %}
67
+ {{- "# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>" }}
68
+ {%- for tool in tools %}
69
+ {{- "\n" }}
70
+ {{- tool | tojson }}
71
+ {%- endfor %}
72
+ {{- "\n</tools>\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{\"name\": <function-name>, \"arguments\": <args-json-object>}\n</tool_call><|im_end|>\n" }}
73
+ {%- else %}
74
+ {%- if messages[0].role == 'system' %}
75
+ {{- '<|im_start|>system\n' + messages[0].content + '<|im_end|>\n' }}
76
+ {%- endif %}
77
+ {%- endif %}
78
+ {%- set ns = namespace(multi_step_tool=true, last_query_index=messages|length - 1) %}
79
+ {%- for message in messages[::-1] %}
80
+ {%- set index = (messages|length - 1) - loop.index0 %}
81
+ {%- if ns.multi_step_tool and message.role == "user" and message.content is string and not(message.content.startswith('<tool_response>') and message.content.endswith('</tool_response>')) %}
82
+ {%- set ns.multi_step_tool = false %}
83
+ {%- set ns.last_query_index = index %}
84
+ {%- endif %}
85
+ {%- endfor %}
86
+ {%- for message in messages %}
87
+ {%- if message.content is string %}
88
+ {%- set content = message.content %}
89
+ {%- else %}
90
+ {%- set content = '' %}
91
+ {%- endif %}
92
+ {%- if (message.role == "user") or (message.role == "system" and not loop.first) %}
93
+ {{- '<|im_start|>' + message.role + '\n' + content + '<|im_end|>' + '\n' }}
94
+ {%- elif message.role == "assistant" %}
95
+ {%- set reasoning_content = '' %}
96
+ {%- if message.reasoning_content is string %}
97
+ {%- set reasoning_content = message.reasoning_content %}
98
+ {%- else %}
99
+ {%- if '<pinkthink|>' in content %}
100
+ {%- set reasoning_content = content.split('<pinkthink|>')[0].rstrip('\n').split('<|pinkthink>')[-1].lstrip('\n') %}
101
+ {%- set content = content.split('<pinkthink|>')[-1].lstrip('\n') %}
102
+ {%- endif %}
103
+ {%- endif %}
104
+ {%- if loop.index0 > ns.last_query_index %}
105
+ {%- if loop.last or (not loop.last and reasoning_content) %}
106
+ {{- '<|im_start|>' + message.role + '\n<|pinkthink>\n' + reasoning_content.strip('\n') + '\n<pinkthink|>\n\n' + content.lstrip('\n') }}
107
+ {%- else %}
108
+ {{- '<|im_start|>' + message.role + '\n' + content }}
109
+ {%- endif %}
110
+ {%- else %}
111
+ {{- '<|im_start|>' + message.role + '\n' + content }}
112
+ {%- endif %}
113
+ {%- if message.tool_calls %}
114
+ {%- for tool_call in message.tool_calls %}
115
+ {%- if (loop.first and content) or (not loop.first) %}
116
+ {{- '\n' }}
117
+ {%- endif %}
118
+ {%- if tool_call.function %}
119
+ {%- set tool_call = tool_call.function %}
120
+ {%- endif %}
121
+ {{- '<tool_call>\n{"name": "' }}
122
+ {{- tool_call.name }}
123
+ {{- '", "arguments": ' }}
124
+ {%- if tool_call.arguments is string %}
125
+ {{- tool_call.arguments }}
126
+ {%- else %}
127
+ {{- tool_call.arguments | tojson }}
128
+ {%- endif %}
129
+ {{- '}\n</tool_call>' }}
130
+ {%- endfor %}
131
+ {%- endif %}
132
+ {{- '<|im_end|>\n' }}
133
+ {%- elif message.role == "tool" %}
134
+ {%- if loop.first or (messages[loop.index0 - 1].role != "tool") %}
135
+ {{- '<|im_start|>user' }}
136
+ {%- endif %}
137
+ {{- '\n<tool_response>\n' }}
138
+ {{- content }}
139
+ {{- '\n</tool_response>' }}
140
+ {%- if loop.last or (messages[loop.index0 + 1].role != "tool") %}
141
+ {{- '<|im_end|>\n' }}
142
+ {%- endif %}
143
+ {%- endif %}
144
+ {%- endfor %}
145
+ {%- if add_generation_prompt %}
146
+ {{- '<|im_start|>assistant\n' }}
147
+ {%- endif %}
config.json ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Qwen3ForCausalLM"
4
+ ],
5
+ "attention_bias": false,
6
+ "attention_dropout": 0.0,
7
+ "bos_token_id": 1,
8
+ "dtype": "bfloat16",
9
+ "eos_token_id": 0,
10
+ "head_dim": 64,
11
+ "hidden_act": "silu",
12
+ "hidden_size": 640,
13
+ "initializer_range": 0.02,
14
+ "intermediate_size": 1920,
15
+ "layer_types": [
16
+ "full_attention",
17
+ "full_attention",
18
+ "full_attention",
19
+ "full_attention",
20
+ "full_attention",
21
+ "full_attention",
22
+ "full_attention",
23
+ "full_attention",
24
+ "full_attention",
25
+ "full_attention",
26
+ "full_attention",
27
+ "full_attention",
28
+ "full_attention",
29
+ "full_attention",
30
+ "full_attention",
31
+ "full_attention",
32
+ "full_attention",
33
+ "full_attention",
34
+ "full_attention",
35
+ "full_attention",
36
+ "full_attention",
37
+ "full_attention",
38
+ "full_attention",
39
+ "full_attention",
40
+ "full_attention"
41
+ ],
42
+ "max_position_embeddings": 32768,
43
+ "max_window_layers": 25,
44
+ "model_name": "./outputs-luaudev-micro-177m/checkpoint-7000",
45
+ "model_type": "qwen3",
46
+ "num_attention_heads": 14,
47
+ "num_hidden_layers": 25,
48
+ "num_key_value_heads": 7,
49
+ "pad_token_id": 13,
50
+ "rms_norm_eps": 1e-05,
51
+ "rope_parameters": {
52
+ "rope_theta": 1000000.0,
53
+ "rope_type": "default"
54
+ },
55
+ "sliding_window": null,
56
+ "tie_word_embeddings": true,
57
+ "transformers_version": "5.17.0",
58
+ "unsloth_version": "2026.8.22",
59
+ "use_cache": false,
60
+ "use_sliding_window": false,
61
+ "vocab_size": 65536
62
+ }
generation_config.json ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token_id": 1,
3
+ "do_sample": false,
4
+ "eos_token_id": [
5
+ 0,
6
+ 2
7
+ ],
8
+ "max_length": 32768,
9
+ "max_new_tokens": 4096,
10
+ "pad_token_id": 13,
11
+ "temperature": 1.0,
12
+ "top_p": 1.0,
13
+ "transformers_version": "5.17.0"
14
+ }
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:75a6913915e40e09f36fb56a4f3c0437ccf2db7513caee8025bac9c2e327b10d
3
+ size 354395552
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,148 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "backend": "tokenizers",
3
+ "bos_token": "<|im_start|>",
4
+ "eos_token": "<|endoftext|>",
5
+ "extra_special_tokens": [
6
+ "<|im_start|>",
7
+ "<|im_end|>",
8
+ "<|pinkthink>",
9
+ "<pinkthink|>",
10
+ "<|reasoning_effort>",
11
+ "<reasoning_effort|>",
12
+ "<tool_call>",
13
+ "</tool_call>",
14
+ "<tool_response>",
15
+ "</tool_response>",
16
+ "<tools>",
17
+ "</tools>"
18
+ ],
19
+ "is_local": true,
20
+ "local_files_only": false,
21
+ "model_max_length": 1000000000000000019884624838656,
22
+ "pad_token": "<|textpad|>",
23
+ "padding_side": "right",
24
+ "tokenizer_class": "TokenizersBackend",
25
+ "unk_token": "<|unk|>",
26
+ "added_tokens_decoder": {
27
+ "0": {
28
+ "content": "<|endoftext|>",
29
+ "single_word": false,
30
+ "lstrip": false,
31
+ "rstrip": false,
32
+ "normalized": false,
33
+ "special": true
34
+ },
35
+ "1": {
36
+ "content": "<|im_start|>",
37
+ "single_word": false,
38
+ "lstrip": false,
39
+ "rstrip": false,
40
+ "normalized": false,
41
+ "special": true
42
+ },
43
+ "2": {
44
+ "content": "<|im_end|>",
45
+ "single_word": false,
46
+ "lstrip": false,
47
+ "rstrip": false,
48
+ "normalized": false,
49
+ "special": true
50
+ },
51
+ "3": {
52
+ "content": "<|pinkthink>",
53
+ "single_word": false,
54
+ "lstrip": false,
55
+ "rstrip": false,
56
+ "normalized": false,
57
+ "special": true
58
+ },
59
+ "4": {
60
+ "content": "<pinkthink|>",
61
+ "single_word": false,
62
+ "lstrip": false,
63
+ "rstrip": false,
64
+ "normalized": false,
65
+ "special": true
66
+ },
67
+ "5": {
68
+ "content": "<|reasoning_effort>",
69
+ "single_word": false,
70
+ "lstrip": false,
71
+ "rstrip": false,
72
+ "normalized": false,
73
+ "special": true
74
+ },
75
+ "6": {
76
+ "content": "<reasoning_effort|>",
77
+ "single_word": false,
78
+ "lstrip": false,
79
+ "rstrip": false,
80
+ "normalized": false,
81
+ "special": true
82
+ },
83
+ "7": {
84
+ "content": "<tool_call>",
85
+ "single_word": false,
86
+ "lstrip": false,
87
+ "rstrip": false,
88
+ "normalized": false,
89
+ "special": true
90
+ },
91
+ "8": {
92
+ "content": "</tool_call>",
93
+ "single_word": false,
94
+ "lstrip": false,
95
+ "rstrip": false,
96
+ "normalized": false,
97
+ "special": true
98
+ },
99
+ "9": {
100
+ "content": "<tool_response>",
101
+ "single_word": false,
102
+ "lstrip": false,
103
+ "rstrip": false,
104
+ "normalized": false,
105
+ "special": true
106
+ },
107
+ "10": {
108
+ "content": "</tool_response>",
109
+ "single_word": false,
110
+ "lstrip": false,
111
+ "rstrip": false,
112
+ "normalized": false,
113
+ "special": true
114
+ },
115
+ "11": {
116
+ "content": "<tools>",
117
+ "single_word": false,
118
+ "lstrip": false,
119
+ "rstrip": false,
120
+ "normalized": false,
121
+ "special": true
122
+ },
123
+ "12": {
124
+ "content": "</tools>",
125
+ "single_word": false,
126
+ "lstrip": false,
127
+ "rstrip": false,
128
+ "normalized": false,
129
+ "special": true
130
+ },
131
+ "13": {
132
+ "content": "<|textpad|>",
133
+ "single_word": false,
134
+ "lstrip": false,
135
+ "rstrip": false,
136
+ "normalized": false,
137
+ "special": true
138
+ },
139
+ "14": {
140
+ "content": "<|unk|>",
141
+ "single_word": false,
142
+ "lstrip": false,
143
+ "rstrip": false,
144
+ "normalized": false,
145
+ "special": true
146
+ }
147
+ }
148
+ }