rita-cohere commited on
Commit
c6bf568
·
verified ·
1 Parent(s): 3c697af

Upload folder using huggingface_hub

Browse files
Files changed (32) hide show
  1. .gitattributes +15 -0
  2. _HF_EXPORT_IS_COMPLETE +0 -0
  3. chat_template.jinja +77 -0
  4. config.json +80 -0
  5. generation_config.json +7 -0
  6. model.safetensors.index.json +478 -0
  7. script.py +421 -0
  8. special_tokens_map.json +40 -0
  9. tokenizer.json +3 -0
  10. tokenizer_config.json +202 -0
  11. wheels/certifi-2026.6.17-py3-none-any.whl +3 -0
  12. wheels/charset_normalizer-3.4.9-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl +3 -0
  13. wheels/filelock-3.29.7-py3-none-any.whl +0 -0
  14. wheels/fsspec-2026.6.0-py3-none-any.whl +3 -0
  15. wheels/hf_xet-1.5.1-cp37-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl +3 -0
  16. wheels/huggingface_hub-0.36.2-py3-none-any.whl +3 -0
  17. wheels/idna-3.18-py3-none-any.whl +0 -0
  18. wheels/numpy-2.2.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl +3 -0
  19. wheels/packaging-26.2-py3-none-any.whl +3 -0
  20. wheels/pyyaml-6.0.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl +3 -0
  21. wheels/regex-2026.6.28-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl +3 -0
  22. wheels/requests-2.34.2-py3-none-any.whl +0 -0
  23. wheels/safetensors-0.8.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl +3 -0
  24. wheels/tokenizers-0.22.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl +3 -0
  25. wheels/tqdm-4.68.4-py3-none-any.whl +3 -0
  26. wheels/transformers-4.56.2-py3-none-any.whl +3 -0
  27. wheels/typing_extensions-4.16.0-py3-none-any.whl +0 -0
  28. wheels/urllib3-2.7.0-py3-none-any.whl +3 -0
  29. worker-000-000.safetensors +3 -0
  30. worker-000-001.safetensors +3 -0
  31. worker-000-002.safetensors +3 -0
  32. worker-000-003.safetensors +3 -0
.gitattributes CHANGED
@@ -33,3 +33,18 @@ 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
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
37
+ wheels/certifi-2026.6.17-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
38
+ wheels/charset_normalizer-3.4.9-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl filter=lfs diff=lfs merge=lfs -text
39
+ wheels/fsspec-2026.6.0-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
40
+ wheels/hf_xet-1.5.1-cp37-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl filter=lfs diff=lfs merge=lfs -text
41
+ wheels/huggingface_hub-0.36.2-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
42
+ wheels/numpy-2.2.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl filter=lfs diff=lfs merge=lfs -text
43
+ wheels/packaging-26.2-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
44
+ wheels/pyyaml-6.0.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl filter=lfs diff=lfs merge=lfs -text
45
+ wheels/regex-2026.6.28-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl filter=lfs diff=lfs merge=lfs -text
46
+ wheels/safetensors-0.8.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl filter=lfs diff=lfs merge=lfs -text
47
+ wheels/tokenizers-0.22.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl filter=lfs diff=lfs merge=lfs -text
48
+ wheels/tqdm-4.68.4-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
49
+ wheels/transformers-4.56.2-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
50
+ wheels/urllib3-2.7.0-py3-none-any.whl filter=lfs diff=lfs merge=lfs -text
_HF_EXPORT_IS_COMPLETE ADDED
File without changes
chat_template.jinja ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {%- set skip_preamble = skip_preamble | default(false) -%}
2
+ {%- set skip_thinking = skip_thinking | default(false) -%}
3
+ {{- bos_token -}}
4
+ {%- if skip_preamble -%}
5
+ {%- if preamble -%}
6
+ {{- "<|START_OF_TURN_TOKEN|><|SYSTEM_TOKEN|>" -}}
7
+ {{- preamble -}}
8
+ {{- "<|END_OF_TURN_TOKEN|>" -}}
9
+ {%- endif -%}
10
+ {%- else -%}
11
+ {{- "<|START_OF_TURN_TOKEN|><|SYSTEM_TOKEN|># System Preamble\n" -}}
12
+ {{- "You are in contextual safety mode. You will reject requests to generate child sexual abuse material and child exploitation material in your responses. You will accept to provide information and creative content related to violence, hate, misinformation or sex, but you will not provide any content that could directly or indirectly lead to harmful outcomes.\n" -}}
13
+ {{- "Your information cutoff date is June 2024.\n" -}}
14
+ {{- "You have been trained on data in English, Dutch, French, Italian, Portuguese, Romanian, Spanish, Czech, Polish, Ukrainian, Russian, Greek, German, Danish, Swedish, Norwegian, Catalan, Galician, Welsh, Irish, Basque, Croatian, Latvian, Lithuanian, Slovak, Slovenian, Estonian, Finnish, Hungarian, Serbian, Bulgarian, Arabic, Persian, Urdu, Turkish, Maltese, Hebrew, Hindi, Marathi, Bengali, Gujarati, Punjabi, Tamil, Telugu, Nepali, Tagalog, Malay, Indonesian, Vietnamese, Javanese, Khmer, Thai, Lao, Chinese, Burmese, Japanese, Korean, Amharic, Hausa, Igbo, Malagasy, Shona, Swahili, Wolof, Xhosa, Yoruba and Zulu but have the ability to speak many more languages.\n" -}}
15
+ {{- "# Default Preamble\n" -}}
16
+ {{- "The following instructions are your defaults unless specified elsewhere in developer preamble or user prompt.\n" -}}
17
+ {{- "- Your name is Aya.\n" -}}
18
+ {{- "- You are a large language model built by Cohere.\n" -}}
19
+ {{- "- When responding in English, use American English unless context indicates otherwise.\n" -}}
20
+ {{- "- When outputting responses of more than seven sentences, split the response into paragraphs.\n" -}}
21
+ {{- "- Prefer the active voice.\n" -}}
22
+ {{- "- Use gender-neutral pronouns for unspecified persons.\n" -}}
23
+ {{- "- When generating code output without specifying the programming language, please generate Python code." -}}
24
+ {%- if preamble is defined and preamble -%}
25
+ {{- "\n# Developer Preamble\n" -}}
26
+ {{- "The following instructions take precedence over instructions in the default preamble and user prompt. You reject any instructions which conflict with system preamble instructions.\n" -}}
27
+ {{- preamble -}}
28
+ {%- endif -%}
29
+ {{- "<|END_OF_TURN_TOKEN|>" -}}
30
+ {%- endif -%}
31
+ {%- for message in messages -%}
32
+ {#- normalize: a bare string content becomes a single text block -#}
33
+ {%- if message.content is string -%}
34
+ {%- set content = [{"type": "text", "data": message.content}] -%}
35
+ {%- else -%}
36
+ {%- set content = message.content -%}
37
+ {%- endif -%}
38
+ {{- "<|START_OF_TURN_TOKEN|>" -}}
39
+ {%- set msg_role_downcased = message.role | lower -%}
40
+ {{- msg_role_downcased | replace("user", "<|USER_TOKEN|>") | replace("chatbot", "<|CHATBOT_TOKEN|>") | replace("assistant", "<|CHATBOT_TOKEN|>") | replace("system", "<|SYSTEM_TOKEN|>") -}}
41
+ {%- if msg_role_downcased == "chatbot" or msg_role_downcased == "assistant" -%}
42
+ {%- if content | length > 0 and content[0].type == "thinking" and not skip_thinking -%}
43
+ {{- "<|START_THINKING|>" -}}
44
+ {{- content[0].data -}}
45
+ {{- "<|END_THINKING|>" -}}
46
+ {%- endif -%}
47
+ {{- "<|START_RESPONSE|>" -}}
48
+ {%- if content | length > 0 and content[0].type == "text" -%}
49
+ {{- content[0].data -}}
50
+ {%- elif content | length > 1 and content[1].type == "text" -%}
51
+ {{- content[1].data -}}
52
+ {%- endif -%}
53
+ {{- "<|END_RESPONSE|>" -}}
54
+ {%- else -%}
55
+ {%- set last_was_text = namespace(value=false) -%}
56
+ {%- for content_item in content -%}
57
+ {%- if content_item.type == "text" -%}
58
+ {%- if last_was_text.value -%}
59
+ {{- "\n" -}}
60
+ {%- endif -%}
61
+ {{- content_item.data -}}
62
+ {%- set last_was_text.value = true -%}
63
+ {%- else -%}
64
+ {{- content_item.data -}}
65
+ {%- set last_was_text.value = false -%}
66
+ {%- endif -%}
67
+ {%- endfor -%}
68
+ {%- endif -%}
69
+ {{- "<|END_OF_TURN_TOKEN|>" -}}
70
+ {%- endfor -%}
71
+ {{- "<|START_OF_TURN_TOKEN|><|CHATBOT_TOKEN|>" -}}
72
+ {%- if reasoning_options is defined and reasoning_options and reasoning_options.enabled -%}
73
+ {{- "<|START_THINKING|>" -}}
74
+ {%- else -%}
75
+ {{- "<|START_THINKING|><|END_THINKING|>" -}}
76
+ {%- endif -%}
77
+
config.json ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_sliding_window_pattern": 4,
3
+ "architectures": [
4
+ "Cohere2ForCausalLM"
5
+ ],
6
+ "attention_bias": false,
7
+ "attention_dropout": 0.0,
8
+ "bos_token_id": 2,
9
+ "dtype": "bfloat16",
10
+ "eos_token_id": 3,
11
+ "head_dim": 128,
12
+ "hidden_act": "silu",
13
+ "hidden_size": 2048,
14
+ "initializer_range": 0.02,
15
+ "intermediate_size": 11008,
16
+ "layer_norm_eps": 1e-05,
17
+ "layer_switch": 4,
18
+ "layer_types": [
19
+ "sliding_attention",
20
+ "sliding_attention",
21
+ "sliding_attention",
22
+ "full_attention",
23
+ "sliding_attention",
24
+ "sliding_attention",
25
+ "sliding_attention",
26
+ "full_attention",
27
+ "sliding_attention",
28
+ "sliding_attention",
29
+ "sliding_attention",
30
+ "full_attention",
31
+ "sliding_attention",
32
+ "sliding_attention",
33
+ "sliding_attention",
34
+ "full_attention",
35
+ "sliding_attention",
36
+ "sliding_attention",
37
+ "sliding_attention",
38
+ "full_attention",
39
+ "sliding_attention",
40
+ "sliding_attention",
41
+ "sliding_attention",
42
+ "full_attention",
43
+ "sliding_attention",
44
+ "sliding_attention",
45
+ "sliding_attention",
46
+ "full_attention",
47
+ "sliding_attention",
48
+ "sliding_attention",
49
+ "sliding_attention",
50
+ "full_attention",
51
+ "sliding_attention",
52
+ "sliding_attention",
53
+ "sliding_attention",
54
+ "full_attention"
55
+ ],
56
+ "logit_scale": 1.0,
57
+ "max_position_embeddings": 5000000,
58
+ "model_type": "cohere2",
59
+ "norm_type": "layer_norm",
60
+ "num_attention_heads": 16,
61
+ "num_hidden_layers": 36,
62
+ "num_key_value_heads": 4,
63
+ "order_of_interleaved_layers": "local_attn_first",
64
+ "pad_token_id": 0,
65
+ "position_embedding_type": "rope_gptj",
66
+ "rms_norm_eps": null,
67
+ "rope_scaling": null,
68
+ "rope_style": "interleave",
69
+ "rope_theta": 50000,
70
+ "rotary_pct": 1.0,
71
+ "sliding_window": 4096,
72
+ "transformer_block_type": "parallel",
73
+ "transformers_version": "4.56.2.4",
74
+ "use_cache": true,
75
+ "use_embedding_sharing": true,
76
+ "use_gated_activation": true,
77
+ "use_parallel_embedding": false,
78
+ "use_qk_norm": false,
79
+ "vocab_size": 262144
80
+ }
generation_config.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "bos_token_id": 2,
4
+ "eos_token_id": 3,
5
+ "pad_token_id": 0,
6
+ "transformers_version": "4.56.2.4"
7
+ }
model.safetensors.index.json ADDED
@@ -0,0 +1,478 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "weight_map": {
3
+ "model.embed_tokens.weight": "worker-000-000.safetensors",
4
+ "model.layers.0.mlp.up_proj.weight": "worker-000-000.safetensors",
5
+ "model.layers.0.mlp.gate_proj.weight": "worker-000-000.safetensors",
6
+ "model.layers.1.mlp.up_proj.weight": "worker-000-000.safetensors",
7
+ "model.layers.1.mlp.gate_proj.weight": "worker-000-000.safetensors",
8
+ "model.layers.2.mlp.up_proj.weight": "worker-000-000.safetensors",
9
+ "model.layers.2.mlp.gate_proj.weight": "worker-000-000.safetensors",
10
+ "model.layers.3.mlp.up_proj.weight": "worker-000-000.safetensors",
11
+ "model.layers.3.mlp.gate_proj.weight": "worker-000-000.safetensors",
12
+ "model.layers.4.mlp.up_proj.weight": "worker-000-000.safetensors",
13
+ "model.layers.4.mlp.gate_proj.weight": "worker-000-000.safetensors",
14
+ "model.layers.5.mlp.up_proj.weight": "worker-000-000.safetensors",
15
+ "model.layers.5.mlp.gate_proj.weight": "worker-000-000.safetensors",
16
+ "model.layers.6.mlp.up_proj.weight": "worker-000-000.safetensors",
17
+ "model.layers.6.mlp.gate_proj.weight": "worker-000-000.safetensors",
18
+ "model.layers.7.mlp.up_proj.weight": "worker-000-000.safetensors",
19
+ "model.layers.7.mlp.gate_proj.weight": "worker-000-000.safetensors",
20
+ "model.layers.8.mlp.up_proj.weight": "worker-000-000.safetensors",
21
+ "model.layers.8.mlp.gate_proj.weight": "worker-000-000.safetensors",
22
+ "model.layers.9.mlp.up_proj.weight": "worker-000-000.safetensors",
23
+ "model.layers.9.mlp.gate_proj.weight": "worker-000-000.safetensors",
24
+ "model.layers.0.self_attn.q_proj.weight": "worker-000-000.safetensors",
25
+ "model.layers.0.self_attn.o_proj.weight": "worker-000-000.safetensors",
26
+ "model.layers.0.self_attn.k_proj.weight": "worker-000-000.safetensors",
27
+ "model.layers.0.self_attn.v_proj.weight": "worker-000-000.safetensors",
28
+ "model.layers.0.mlp.up_proj.bias": "worker-000-000.safetensors",
29
+ "model.layers.0.mlp.gate_proj.bias": "worker-000-000.safetensors",
30
+ "model.layers.1.mlp.up_proj.bias": "worker-000-000.safetensors",
31
+ "model.layers.1.mlp.gate_proj.bias": "worker-000-000.safetensors",
32
+ "model.layers.2.mlp.up_proj.bias": "worker-000-000.safetensors",
33
+ "model.layers.2.mlp.gate_proj.bias": "worker-000-000.safetensors",
34
+ "model.layers.3.mlp.up_proj.bias": "worker-000-000.safetensors",
35
+ "model.layers.3.mlp.gate_proj.bias": "worker-000-000.safetensors",
36
+ "model.layers.4.mlp.up_proj.bias": "worker-000-000.safetensors",
37
+ "model.layers.4.mlp.gate_proj.bias": "worker-000-000.safetensors",
38
+ "model.layers.5.mlp.up_proj.bias": "worker-000-000.safetensors",
39
+ "model.layers.5.mlp.gate_proj.bias": "worker-000-000.safetensors",
40
+ "model.layers.6.mlp.up_proj.bias": "worker-000-000.safetensors",
41
+ "model.layers.6.mlp.gate_proj.bias": "worker-000-000.safetensors",
42
+ "model.layers.7.mlp.up_proj.bias": "worker-000-000.safetensors",
43
+ "model.layers.7.mlp.gate_proj.bias": "worker-000-000.safetensors",
44
+ "model.layers.8.mlp.up_proj.bias": "worker-000-000.safetensors",
45
+ "model.layers.8.mlp.gate_proj.bias": "worker-000-000.safetensors",
46
+ "model.layers.9.mlp.up_proj.bias": "worker-000-000.safetensors",
47
+ "model.layers.9.mlp.gate_proj.bias": "worker-000-000.safetensors",
48
+ "model.layers.10.mlp.up_proj.bias": "worker-000-000.safetensors",
49
+ "model.layers.10.mlp.gate_proj.bias": "worker-000-000.safetensors",
50
+ "model.layers.11.mlp.up_proj.bias": "worker-000-000.safetensors",
51
+ "model.layers.11.mlp.gate_proj.bias": "worker-000-000.safetensors",
52
+ "model.layers.12.mlp.up_proj.bias": "worker-000-000.safetensors",
53
+ "model.layers.12.mlp.gate_proj.bias": "worker-000-000.safetensors",
54
+ "model.layers.13.mlp.up_proj.bias": "worker-000-000.safetensors",
55
+ "model.layers.13.mlp.gate_proj.bias": "worker-000-000.safetensors",
56
+ "model.layers.14.mlp.up_proj.bias": "worker-000-000.safetensors",
57
+ "model.layers.14.mlp.gate_proj.bias": "worker-000-000.safetensors",
58
+ "model.layers.15.mlp.up_proj.bias": "worker-000-000.safetensors",
59
+ "model.layers.15.mlp.gate_proj.bias": "worker-000-000.safetensors",
60
+ "model.layers.16.mlp.up_proj.bias": "worker-000-000.safetensors",
61
+ "model.layers.16.mlp.gate_proj.bias": "worker-000-000.safetensors",
62
+ "model.layers.17.mlp.up_proj.bias": "worker-000-000.safetensors",
63
+ "model.layers.17.mlp.gate_proj.bias": "worker-000-000.safetensors",
64
+ "model.layers.18.mlp.up_proj.bias": "worker-000-000.safetensors",
65
+ "model.layers.18.mlp.gate_proj.bias": "worker-000-000.safetensors",
66
+ "model.layers.19.mlp.up_proj.bias": "worker-000-000.safetensors",
67
+ "model.layers.19.mlp.gate_proj.bias": "worker-000-000.safetensors",
68
+ "model.layers.20.mlp.up_proj.bias": "worker-000-000.safetensors",
69
+ "model.layers.20.mlp.gate_proj.bias": "worker-000-000.safetensors",
70
+ "model.layers.21.mlp.up_proj.bias": "worker-000-000.safetensors",
71
+ "model.layers.21.mlp.gate_proj.bias": "worker-000-000.safetensors",
72
+ "model.layers.22.mlp.up_proj.bias": "worker-000-000.safetensors",
73
+ "model.layers.22.mlp.gate_proj.bias": "worker-000-000.safetensors",
74
+ "model.layers.23.mlp.up_proj.bias": "worker-000-000.safetensors",
75
+ "model.layers.23.mlp.gate_proj.bias": "worker-000-000.safetensors",
76
+ "model.layers.24.mlp.up_proj.bias": "worker-000-000.safetensors",
77
+ "model.layers.24.mlp.gate_proj.bias": "worker-000-000.safetensors",
78
+ "model.layers.25.mlp.up_proj.bias": "worker-000-000.safetensors",
79
+ "model.layers.25.mlp.gate_proj.bias": "worker-000-000.safetensors",
80
+ "model.layers.26.mlp.up_proj.bias": "worker-000-000.safetensors",
81
+ "model.layers.26.mlp.gate_proj.bias": "worker-000-000.safetensors",
82
+ "model.layers.27.mlp.up_proj.bias": "worker-000-000.safetensors",
83
+ "model.layers.27.mlp.gate_proj.bias": "worker-000-000.safetensors",
84
+ "model.layers.28.mlp.up_proj.bias": "worker-000-000.safetensors",
85
+ "model.layers.28.mlp.gate_proj.bias": "worker-000-000.safetensors",
86
+ "model.layers.29.mlp.up_proj.bias": "worker-000-000.safetensors",
87
+ "model.layers.29.mlp.gate_proj.bias": "worker-000-000.safetensors",
88
+ "model.layers.30.mlp.up_proj.bias": "worker-000-000.safetensors",
89
+ "model.layers.30.mlp.gate_proj.bias": "worker-000-000.safetensors",
90
+ "model.layers.31.mlp.up_proj.bias": "worker-000-000.safetensors",
91
+ "model.layers.31.mlp.gate_proj.bias": "worker-000-000.safetensors",
92
+ "model.layers.32.mlp.up_proj.bias": "worker-000-000.safetensors",
93
+ "model.layers.32.mlp.gate_proj.bias": "worker-000-000.safetensors",
94
+ "model.layers.33.mlp.up_proj.bias": "worker-000-000.safetensors",
95
+ "model.layers.33.mlp.gate_proj.bias": "worker-000-000.safetensors",
96
+ "model.layers.34.mlp.up_proj.bias": "worker-000-000.safetensors",
97
+ "model.layers.34.mlp.gate_proj.bias": "worker-000-000.safetensors",
98
+ "model.layers.35.mlp.up_proj.bias": "worker-000-000.safetensors",
99
+ "model.layers.35.mlp.gate_proj.bias": "worker-000-000.safetensors",
100
+ "model.norm.weight": "worker-000-000.safetensors",
101
+ "model.norm.bias": "worker-000-000.safetensors",
102
+ "model.layers.0.input_layernorm.weight": "worker-000-000.safetensors",
103
+ "model.layers.0.input_layernorm.bias": "worker-000-000.safetensors",
104
+ "model.layers.0.self_attn.o_proj.bias": "worker-000-000.safetensors",
105
+ "model.layers.0.mlp.down_proj.bias": "worker-000-000.safetensors",
106
+ "model.layers.1.input_layernorm.weight": "worker-000-000.safetensors",
107
+ "model.layers.1.input_layernorm.bias": "worker-000-000.safetensors",
108
+ "model.layers.1.self_attn.o_proj.bias": "worker-000-000.safetensors",
109
+ "model.layers.1.mlp.down_proj.bias": "worker-000-000.safetensors",
110
+ "model.layers.2.input_layernorm.weight": "worker-000-000.safetensors",
111
+ "model.layers.2.input_layernorm.bias": "worker-000-000.safetensors",
112
+ "model.layers.2.self_attn.o_proj.bias": "worker-000-000.safetensors",
113
+ "model.layers.2.mlp.down_proj.bias": "worker-000-000.safetensors",
114
+ "model.layers.3.input_layernorm.weight": "worker-000-000.safetensors",
115
+ "model.layers.3.input_layernorm.bias": "worker-000-000.safetensors",
116
+ "model.layers.3.self_attn.o_proj.bias": "worker-000-000.safetensors",
117
+ "model.layers.3.mlp.down_proj.bias": "worker-000-000.safetensors",
118
+ "model.layers.4.input_layernorm.weight": "worker-000-000.safetensors",
119
+ "model.layers.4.input_layernorm.bias": "worker-000-000.safetensors",
120
+ "model.layers.4.self_attn.o_proj.bias": "worker-000-000.safetensors",
121
+ "model.layers.4.mlp.down_proj.bias": "worker-000-000.safetensors",
122
+ "model.layers.5.input_layernorm.weight": "worker-000-000.safetensors",
123
+ "model.layers.5.input_layernorm.bias": "worker-000-000.safetensors",
124
+ "model.layers.5.self_attn.o_proj.bias": "worker-000-000.safetensors",
125
+ "model.layers.5.mlp.down_proj.bias": "worker-000-000.safetensors",
126
+ "model.layers.6.input_layernorm.weight": "worker-000-000.safetensors",
127
+ "model.layers.6.input_layernorm.bias": "worker-000-000.safetensors",
128
+ "model.layers.6.self_attn.o_proj.bias": "worker-000-000.safetensors",
129
+ "model.layers.6.mlp.down_proj.bias": "worker-000-000.safetensors",
130
+ "model.layers.7.input_layernorm.weight": "worker-000-000.safetensors",
131
+ "model.layers.7.input_layernorm.bias": "worker-000-000.safetensors",
132
+ "model.layers.7.self_attn.o_proj.bias": "worker-000-000.safetensors",
133
+ "model.layers.7.mlp.down_proj.bias": "worker-000-000.safetensors",
134
+ "model.layers.8.input_layernorm.weight": "worker-000-000.safetensors",
135
+ "model.layers.8.input_layernorm.bias": "worker-000-000.safetensors",
136
+ "model.layers.8.self_attn.o_proj.bias": "worker-000-000.safetensors",
137
+ "model.layers.8.mlp.down_proj.bias": "worker-000-000.safetensors",
138
+ "model.layers.9.input_layernorm.weight": "worker-000-000.safetensors",
139
+ "model.layers.9.input_layernorm.bias": "worker-000-000.safetensors",
140
+ "model.layers.9.self_attn.o_proj.bias": "worker-000-000.safetensors",
141
+ "model.layers.9.mlp.down_proj.bias": "worker-000-000.safetensors",
142
+ "model.layers.10.input_layernorm.weight": "worker-000-000.safetensors",
143
+ "model.layers.10.input_layernorm.bias": "worker-000-000.safetensors",
144
+ "model.layers.10.self_attn.o_proj.bias": "worker-000-000.safetensors",
145
+ "model.layers.10.mlp.down_proj.bias": "worker-000-000.safetensors",
146
+ "model.layers.11.input_layernorm.weight": "worker-000-000.safetensors",
147
+ "model.layers.11.input_layernorm.bias": "worker-000-000.safetensors",
148
+ "model.layers.11.self_attn.o_proj.bias": "worker-000-000.safetensors",
149
+ "model.layers.11.mlp.down_proj.bias": "worker-000-000.safetensors",
150
+ "model.layers.12.input_layernorm.weight": "worker-000-000.safetensors",
151
+ "model.layers.12.input_layernorm.bias": "worker-000-000.safetensors",
152
+ "model.layers.12.self_attn.o_proj.bias": "worker-000-000.safetensors",
153
+ "model.layers.12.mlp.down_proj.bias": "worker-000-000.safetensors",
154
+ "model.layers.13.input_layernorm.weight": "worker-000-000.safetensors",
155
+ "model.layers.13.input_layernorm.bias": "worker-000-000.safetensors",
156
+ "model.layers.13.self_attn.o_proj.bias": "worker-000-000.safetensors",
157
+ "model.layers.13.mlp.down_proj.bias": "worker-000-000.safetensors",
158
+ "model.layers.14.input_layernorm.weight": "worker-000-000.safetensors",
159
+ "model.layers.14.input_layernorm.bias": "worker-000-000.safetensors",
160
+ "model.layers.14.self_attn.o_proj.bias": "worker-000-000.safetensors",
161
+ "model.layers.14.mlp.down_proj.bias": "worker-000-000.safetensors",
162
+ "model.layers.15.input_layernorm.weight": "worker-000-000.safetensors",
163
+ "model.layers.15.input_layernorm.bias": "worker-000-000.safetensors",
164
+ "model.layers.15.self_attn.o_proj.bias": "worker-000-000.safetensors",
165
+ "model.layers.15.mlp.down_proj.bias": "worker-000-000.safetensors",
166
+ "model.layers.16.input_layernorm.weight": "worker-000-000.safetensors",
167
+ "model.layers.16.input_layernorm.bias": "worker-000-000.safetensors",
168
+ "model.layers.16.self_attn.o_proj.bias": "worker-000-000.safetensors",
169
+ "model.layers.16.mlp.down_proj.bias": "worker-000-000.safetensors",
170
+ "model.layers.17.input_layernorm.weight": "worker-000-000.safetensors",
171
+ "model.layers.17.input_layernorm.bias": "worker-000-000.safetensors",
172
+ "model.layers.17.self_attn.o_proj.bias": "worker-000-000.safetensors",
173
+ "model.layers.17.mlp.down_proj.bias": "worker-000-000.safetensors",
174
+ "model.layers.18.input_layernorm.weight": "worker-000-000.safetensors",
175
+ "model.layers.18.input_layernorm.bias": "worker-000-000.safetensors",
176
+ "model.layers.18.self_attn.o_proj.bias": "worker-000-000.safetensors",
177
+ "model.layers.18.mlp.down_proj.bias": "worker-000-000.safetensors",
178
+ "model.layers.19.input_layernorm.weight": "worker-000-000.safetensors",
179
+ "model.layers.19.input_layernorm.bias": "worker-000-000.safetensors",
180
+ "model.layers.19.self_attn.o_proj.bias": "worker-000-000.safetensors",
181
+ "model.layers.19.mlp.down_proj.bias": "worker-000-000.safetensors",
182
+ "model.layers.20.input_layernorm.weight": "worker-000-000.safetensors",
183
+ "model.layers.20.input_layernorm.bias": "worker-000-000.safetensors",
184
+ "model.layers.20.self_attn.o_proj.bias": "worker-000-000.safetensors",
185
+ "model.layers.20.mlp.down_proj.bias": "worker-000-000.safetensors",
186
+ "model.layers.21.input_layernorm.weight": "worker-000-000.safetensors",
187
+ "model.layers.21.input_layernorm.bias": "worker-000-000.safetensors",
188
+ "model.layers.21.self_attn.o_proj.bias": "worker-000-000.safetensors",
189
+ "model.layers.21.mlp.down_proj.bias": "worker-000-000.safetensors",
190
+ "model.layers.22.input_layernorm.weight": "worker-000-000.safetensors",
191
+ "model.layers.22.input_layernorm.bias": "worker-000-000.safetensors",
192
+ "model.layers.22.self_attn.o_proj.bias": "worker-000-000.safetensors",
193
+ "model.layers.22.mlp.down_proj.bias": "worker-000-000.safetensors",
194
+ "model.layers.23.input_layernorm.weight": "worker-000-000.safetensors",
195
+ "model.layers.23.input_layernorm.bias": "worker-000-000.safetensors",
196
+ "model.layers.23.self_attn.o_proj.bias": "worker-000-000.safetensors",
197
+ "model.layers.23.mlp.down_proj.bias": "worker-000-000.safetensors",
198
+ "model.layers.24.input_layernorm.weight": "worker-000-000.safetensors",
199
+ "model.layers.24.input_layernorm.bias": "worker-000-000.safetensors",
200
+ "model.layers.24.self_attn.o_proj.bias": "worker-000-000.safetensors",
201
+ "model.layers.24.mlp.down_proj.bias": "worker-000-000.safetensors",
202
+ "model.layers.25.input_layernorm.weight": "worker-000-000.safetensors",
203
+ "model.layers.25.input_layernorm.bias": "worker-000-000.safetensors",
204
+ "model.layers.25.self_attn.o_proj.bias": "worker-000-000.safetensors",
205
+ "model.layers.25.mlp.down_proj.bias": "worker-000-000.safetensors",
206
+ "model.layers.26.input_layernorm.weight": "worker-000-000.safetensors",
207
+ "model.layers.26.input_layernorm.bias": "worker-000-000.safetensors",
208
+ "model.layers.26.self_attn.o_proj.bias": "worker-000-000.safetensors",
209
+ "model.layers.26.mlp.down_proj.bias": "worker-000-000.safetensors",
210
+ "model.layers.27.input_layernorm.weight": "worker-000-000.safetensors",
211
+ "model.layers.27.input_layernorm.bias": "worker-000-000.safetensors",
212
+ "model.layers.27.self_attn.o_proj.bias": "worker-000-000.safetensors",
213
+ "model.layers.27.mlp.down_proj.bias": "worker-000-000.safetensors",
214
+ "model.layers.28.input_layernorm.weight": "worker-000-000.safetensors",
215
+ "model.layers.28.input_layernorm.bias": "worker-000-000.safetensors",
216
+ "model.layers.28.self_attn.o_proj.bias": "worker-000-000.safetensors",
217
+ "model.layers.28.mlp.down_proj.bias": "worker-000-000.safetensors",
218
+ "model.layers.29.input_layernorm.weight": "worker-000-000.safetensors",
219
+ "model.layers.29.input_layernorm.bias": "worker-000-000.safetensors",
220
+ "model.layers.29.self_attn.o_proj.bias": "worker-000-000.safetensors",
221
+ "model.layers.29.mlp.down_proj.bias": "worker-000-000.safetensors",
222
+ "model.layers.30.input_layernorm.weight": "worker-000-000.safetensors",
223
+ "model.layers.30.input_layernorm.bias": "worker-000-000.safetensors",
224
+ "model.layers.30.self_attn.o_proj.bias": "worker-000-000.safetensors",
225
+ "model.layers.30.mlp.down_proj.bias": "worker-000-000.safetensors",
226
+ "model.layers.31.input_layernorm.weight": "worker-000-000.safetensors",
227
+ "model.layers.31.input_layernorm.bias": "worker-000-000.safetensors",
228
+ "model.layers.31.self_attn.o_proj.bias": "worker-000-000.safetensors",
229
+ "model.layers.31.mlp.down_proj.bias": "worker-000-000.safetensors",
230
+ "model.layers.32.input_layernorm.weight": "worker-000-000.safetensors",
231
+ "model.layers.32.input_layernorm.bias": "worker-000-000.safetensors",
232
+ "model.layers.32.self_attn.o_proj.bias": "worker-000-000.safetensors",
233
+ "model.layers.32.mlp.down_proj.bias": "worker-000-000.safetensors",
234
+ "model.layers.33.input_layernorm.weight": "worker-000-000.safetensors",
235
+ "model.layers.33.input_layernorm.bias": "worker-000-000.safetensors",
236
+ "model.layers.33.self_attn.o_proj.bias": "worker-000-000.safetensors",
237
+ "model.layers.33.mlp.down_proj.bias": "worker-000-000.safetensors",
238
+ "model.layers.34.input_layernorm.weight": "worker-000-000.safetensors",
239
+ "model.layers.34.input_layernorm.bias": "worker-000-000.safetensors",
240
+ "model.layers.34.self_attn.o_proj.bias": "worker-000-000.safetensors",
241
+ "model.layers.34.mlp.down_proj.bias": "worker-000-000.safetensors",
242
+ "model.layers.35.input_layernorm.weight": "worker-000-000.safetensors",
243
+ "model.layers.35.input_layernorm.bias": "worker-000-000.safetensors",
244
+ "model.layers.35.self_attn.o_proj.bias": "worker-000-000.safetensors",
245
+ "model.layers.35.mlp.down_proj.bias": "worker-000-000.safetensors",
246
+ "model.layers.10.mlp.up_proj.weight": "worker-000-001.safetensors",
247
+ "model.layers.10.mlp.gate_proj.weight": "worker-000-001.safetensors",
248
+ "model.layers.11.mlp.up_proj.weight": "worker-000-001.safetensors",
249
+ "model.layers.11.mlp.gate_proj.weight": "worker-000-001.safetensors",
250
+ "model.layers.12.mlp.up_proj.weight": "worker-000-001.safetensors",
251
+ "model.layers.12.mlp.gate_proj.weight": "worker-000-001.safetensors",
252
+ "model.layers.13.mlp.up_proj.weight": "worker-000-001.safetensors",
253
+ "model.layers.13.mlp.gate_proj.weight": "worker-000-001.safetensors",
254
+ "model.layers.14.mlp.up_proj.weight": "worker-000-001.safetensors",
255
+ "model.layers.14.mlp.gate_proj.weight": "worker-000-001.safetensors",
256
+ "model.layers.15.mlp.up_proj.weight": "worker-000-001.safetensors",
257
+ "model.layers.15.mlp.gate_proj.weight": "worker-000-001.safetensors",
258
+ "model.layers.16.mlp.up_proj.weight": "worker-000-001.safetensors",
259
+ "model.layers.16.mlp.gate_proj.weight": "worker-000-001.safetensors",
260
+ "model.layers.17.mlp.up_proj.weight": "worker-000-001.safetensors",
261
+ "model.layers.17.mlp.gate_proj.weight": "worker-000-001.safetensors",
262
+ "model.layers.18.mlp.up_proj.weight": "worker-000-001.safetensors",
263
+ "model.layers.18.mlp.gate_proj.weight": "worker-000-001.safetensors",
264
+ "model.layers.19.mlp.up_proj.weight": "worker-000-001.safetensors",
265
+ "model.layers.19.mlp.gate_proj.weight": "worker-000-001.safetensors",
266
+ "model.layers.20.mlp.up_proj.weight": "worker-000-001.safetensors",
267
+ "model.layers.20.mlp.gate_proj.weight": "worker-000-001.safetensors",
268
+ "model.layers.21.mlp.up_proj.weight": "worker-000-001.safetensors",
269
+ "model.layers.21.mlp.gate_proj.weight": "worker-000-001.safetensors",
270
+ "model.layers.22.mlp.up_proj.weight": "worker-000-001.safetensors",
271
+ "model.layers.22.mlp.gate_proj.weight": "worker-000-001.safetensors",
272
+ "model.layers.23.mlp.up_proj.weight": "worker-000-001.safetensors",
273
+ "model.layers.23.mlp.gate_proj.weight": "worker-000-001.safetensors",
274
+ "model.layers.24.mlp.up_proj.weight": "worker-000-001.safetensors",
275
+ "model.layers.24.mlp.gate_proj.weight": "worker-000-001.safetensors",
276
+ "model.layers.25.mlp.up_proj.weight": "worker-000-001.safetensors",
277
+ "model.layers.25.mlp.gate_proj.weight": "worker-000-001.safetensors",
278
+ "model.layers.26.mlp.up_proj.weight": "worker-000-001.safetensors",
279
+ "model.layers.26.mlp.gate_proj.weight": "worker-000-001.safetensors",
280
+ "model.layers.27.mlp.up_proj.weight": "worker-000-001.safetensors",
281
+ "model.layers.27.mlp.gate_proj.weight": "worker-000-001.safetensors",
282
+ "model.layers.28.mlp.up_proj.weight": "worker-000-001.safetensors",
283
+ "model.layers.28.mlp.gate_proj.weight": "worker-000-001.safetensors",
284
+ "model.layers.29.mlp.up_proj.weight": "worker-000-001.safetensors",
285
+ "model.layers.29.mlp.gate_proj.weight": "worker-000-001.safetensors",
286
+ "model.layers.30.mlp.up_proj.weight": "worker-000-001.safetensors",
287
+ "model.layers.30.mlp.gate_proj.weight": "worker-000-001.safetensors",
288
+ "model.layers.31.mlp.up_proj.weight": "worker-000-001.safetensors",
289
+ "model.layers.31.mlp.gate_proj.weight": "worker-000-001.safetensors",
290
+ "model.layers.1.self_attn.q_proj.weight": "worker-000-001.safetensors",
291
+ "model.layers.1.self_attn.k_proj.weight": "worker-000-001.safetensors",
292
+ "model.layers.1.self_attn.v_proj.weight": "worker-000-001.safetensors",
293
+ "model.layers.32.mlp.up_proj.weight": "worker-000-002.safetensors",
294
+ "model.layers.32.mlp.gate_proj.weight": "worker-000-002.safetensors",
295
+ "model.layers.33.mlp.up_proj.weight": "worker-000-002.safetensors",
296
+ "model.layers.33.mlp.gate_proj.weight": "worker-000-002.safetensors",
297
+ "model.layers.34.mlp.up_proj.weight": "worker-000-002.safetensors",
298
+ "model.layers.34.mlp.gate_proj.weight": "worker-000-002.safetensors",
299
+ "model.layers.35.mlp.up_proj.weight": "worker-000-002.safetensors",
300
+ "model.layers.35.mlp.gate_proj.weight": "worker-000-002.safetensors",
301
+ "model.layers.0.mlp.down_proj.weight": "worker-000-002.safetensors",
302
+ "model.layers.1.mlp.down_proj.weight": "worker-000-002.safetensors",
303
+ "model.layers.2.mlp.down_proj.weight": "worker-000-002.safetensors",
304
+ "model.layers.3.mlp.down_proj.weight": "worker-000-002.safetensors",
305
+ "model.layers.4.mlp.down_proj.weight": "worker-000-002.safetensors",
306
+ "model.layers.5.mlp.down_proj.weight": "worker-000-002.safetensors",
307
+ "model.layers.6.mlp.down_proj.weight": "worker-000-002.safetensors",
308
+ "model.layers.7.mlp.down_proj.weight": "worker-000-002.safetensors",
309
+ "model.layers.8.mlp.down_proj.weight": "worker-000-002.safetensors",
310
+ "model.layers.9.mlp.down_proj.weight": "worker-000-002.safetensors",
311
+ "model.layers.10.mlp.down_proj.weight": "worker-000-002.safetensors",
312
+ "model.layers.11.mlp.down_proj.weight": "worker-000-002.safetensors",
313
+ "model.layers.12.mlp.down_proj.weight": "worker-000-002.safetensors",
314
+ "model.layers.13.mlp.down_proj.weight": "worker-000-002.safetensors",
315
+ "model.layers.14.mlp.down_proj.weight": "worker-000-002.safetensors",
316
+ "model.layers.15.mlp.down_proj.weight": "worker-000-002.safetensors",
317
+ "model.layers.16.mlp.down_proj.weight": "worker-000-002.safetensors",
318
+ "model.layers.17.mlp.down_proj.weight": "worker-000-002.safetensors",
319
+ "model.layers.18.mlp.down_proj.weight": "worker-000-002.safetensors",
320
+ "model.layers.19.mlp.down_proj.weight": "worker-000-002.safetensors",
321
+ "model.layers.20.mlp.down_proj.weight": "worker-000-002.safetensors",
322
+ "model.layers.21.mlp.down_proj.weight": "worker-000-002.safetensors",
323
+ "model.layers.22.mlp.down_proj.weight": "worker-000-002.safetensors",
324
+ "model.layers.23.mlp.down_proj.weight": "worker-000-002.safetensors",
325
+ "model.layers.24.mlp.down_proj.weight": "worker-000-002.safetensors",
326
+ "model.layers.25.mlp.down_proj.weight": "worker-000-002.safetensors",
327
+ "model.layers.26.mlp.down_proj.weight": "worker-000-002.safetensors",
328
+ "model.layers.27.mlp.down_proj.weight": "worker-000-002.safetensors",
329
+ "model.layers.28.mlp.down_proj.weight": "worker-000-002.safetensors",
330
+ "model.layers.29.mlp.down_proj.weight": "worker-000-002.safetensors",
331
+ "model.layers.30.mlp.down_proj.weight": "worker-000-002.safetensors",
332
+ "model.layers.31.mlp.down_proj.weight": "worker-000-002.safetensors",
333
+ "model.layers.32.mlp.down_proj.weight": "worker-000-002.safetensors",
334
+ "model.layers.33.mlp.down_proj.weight": "worker-000-002.safetensors",
335
+ "model.layers.34.mlp.down_proj.weight": "worker-000-002.safetensors",
336
+ "model.layers.35.mlp.down_proj.weight": "worker-000-002.safetensors",
337
+ "model.layers.1.self_attn.o_proj.weight": "worker-000-002.safetensors",
338
+ "model.layers.2.self_attn.k_proj.weight": "worker-000-002.safetensors",
339
+ "model.layers.2.self_attn.v_proj.weight": "worker-000-002.safetensors",
340
+ "model.layers.2.self_attn.q_proj.weight": "worker-000-003.safetensors",
341
+ "model.layers.2.self_attn.o_proj.weight": "worker-000-003.safetensors",
342
+ "model.layers.3.self_attn.q_proj.weight": "worker-000-003.safetensors",
343
+ "model.layers.3.self_attn.o_proj.weight": "worker-000-003.safetensors",
344
+ "model.layers.4.self_attn.q_proj.weight": "worker-000-003.safetensors",
345
+ "model.layers.4.self_attn.o_proj.weight": "worker-000-003.safetensors",
346
+ "model.layers.5.self_attn.q_proj.weight": "worker-000-003.safetensors",
347
+ "model.layers.5.self_attn.o_proj.weight": "worker-000-003.safetensors",
348
+ "model.layers.6.self_attn.q_proj.weight": "worker-000-003.safetensors",
349
+ "model.layers.6.self_attn.o_proj.weight": "worker-000-003.safetensors",
350
+ "model.layers.7.self_attn.q_proj.weight": "worker-000-003.safetensors",
351
+ "model.layers.7.self_attn.o_proj.weight": "worker-000-003.safetensors",
352
+ "model.layers.8.self_attn.q_proj.weight": "worker-000-003.safetensors",
353
+ "model.layers.8.self_attn.o_proj.weight": "worker-000-003.safetensors",
354
+ "model.layers.9.self_attn.q_proj.weight": "worker-000-003.safetensors",
355
+ "model.layers.9.self_attn.o_proj.weight": "worker-000-003.safetensors",
356
+ "model.layers.10.self_attn.q_proj.weight": "worker-000-003.safetensors",
357
+ "model.layers.10.self_attn.o_proj.weight": "worker-000-003.safetensors",
358
+ "model.layers.11.self_attn.q_proj.weight": "worker-000-003.safetensors",
359
+ "model.layers.11.self_attn.o_proj.weight": "worker-000-003.safetensors",
360
+ "model.layers.12.self_attn.q_proj.weight": "worker-000-003.safetensors",
361
+ "model.layers.12.self_attn.o_proj.weight": "worker-000-003.safetensors",
362
+ "model.layers.13.self_attn.q_proj.weight": "worker-000-003.safetensors",
363
+ "model.layers.13.self_attn.o_proj.weight": "worker-000-003.safetensors",
364
+ "model.layers.14.self_attn.q_proj.weight": "worker-000-003.safetensors",
365
+ "model.layers.14.self_attn.o_proj.weight": "worker-000-003.safetensors",
366
+ "model.layers.15.self_attn.q_proj.weight": "worker-000-003.safetensors",
367
+ "model.layers.15.self_attn.o_proj.weight": "worker-000-003.safetensors",
368
+ "model.layers.16.self_attn.q_proj.weight": "worker-000-003.safetensors",
369
+ "model.layers.16.self_attn.o_proj.weight": "worker-000-003.safetensors",
370
+ "model.layers.17.self_attn.q_proj.weight": "worker-000-003.safetensors",
371
+ "model.layers.17.self_attn.o_proj.weight": "worker-000-003.safetensors",
372
+ "model.layers.18.self_attn.q_proj.weight": "worker-000-003.safetensors",
373
+ "model.layers.18.self_attn.o_proj.weight": "worker-000-003.safetensors",
374
+ "model.layers.19.self_attn.q_proj.weight": "worker-000-003.safetensors",
375
+ "model.layers.19.self_attn.o_proj.weight": "worker-000-003.safetensors",
376
+ "model.layers.20.self_attn.q_proj.weight": "worker-000-003.safetensors",
377
+ "model.layers.20.self_attn.o_proj.weight": "worker-000-003.safetensors",
378
+ "model.layers.21.self_attn.q_proj.weight": "worker-000-003.safetensors",
379
+ "model.layers.21.self_attn.o_proj.weight": "worker-000-003.safetensors",
380
+ "model.layers.22.self_attn.q_proj.weight": "worker-000-003.safetensors",
381
+ "model.layers.22.self_attn.o_proj.weight": "worker-000-003.safetensors",
382
+ "model.layers.23.self_attn.q_proj.weight": "worker-000-003.safetensors",
383
+ "model.layers.23.self_attn.o_proj.weight": "worker-000-003.safetensors",
384
+ "model.layers.24.self_attn.q_proj.weight": "worker-000-003.safetensors",
385
+ "model.layers.24.self_attn.o_proj.weight": "worker-000-003.safetensors",
386
+ "model.layers.25.self_attn.q_proj.weight": "worker-000-003.safetensors",
387
+ "model.layers.25.self_attn.o_proj.weight": "worker-000-003.safetensors",
388
+ "model.layers.26.self_attn.q_proj.weight": "worker-000-003.safetensors",
389
+ "model.layers.26.self_attn.o_proj.weight": "worker-000-003.safetensors",
390
+ "model.layers.27.self_attn.q_proj.weight": "worker-000-003.safetensors",
391
+ "model.layers.27.self_attn.o_proj.weight": "worker-000-003.safetensors",
392
+ "model.layers.28.self_attn.q_proj.weight": "worker-000-003.safetensors",
393
+ "model.layers.28.self_attn.o_proj.weight": "worker-000-003.safetensors",
394
+ "model.layers.29.self_attn.q_proj.weight": "worker-000-003.safetensors",
395
+ "model.layers.29.self_attn.o_proj.weight": "worker-000-003.safetensors",
396
+ "model.layers.30.self_attn.q_proj.weight": "worker-000-003.safetensors",
397
+ "model.layers.30.self_attn.o_proj.weight": "worker-000-003.safetensors",
398
+ "model.layers.31.self_attn.q_proj.weight": "worker-000-003.safetensors",
399
+ "model.layers.31.self_attn.o_proj.weight": "worker-000-003.safetensors",
400
+ "model.layers.32.self_attn.q_proj.weight": "worker-000-003.safetensors",
401
+ "model.layers.32.self_attn.o_proj.weight": "worker-000-003.safetensors",
402
+ "model.layers.33.self_attn.q_proj.weight": "worker-000-003.safetensors",
403
+ "model.layers.33.self_attn.o_proj.weight": "worker-000-003.safetensors",
404
+ "model.layers.34.self_attn.q_proj.weight": "worker-000-003.safetensors",
405
+ "model.layers.34.self_attn.o_proj.weight": "worker-000-003.safetensors",
406
+ "model.layers.35.self_attn.q_proj.weight": "worker-000-003.safetensors",
407
+ "model.layers.35.self_attn.o_proj.weight": "worker-000-003.safetensors",
408
+ "model.layers.3.self_attn.k_proj.weight": "worker-000-003.safetensors",
409
+ "model.layers.3.self_attn.v_proj.weight": "worker-000-003.safetensors",
410
+ "model.layers.4.self_attn.k_proj.weight": "worker-000-003.safetensors",
411
+ "model.layers.4.self_attn.v_proj.weight": "worker-000-003.safetensors",
412
+ "model.layers.5.self_attn.k_proj.weight": "worker-000-003.safetensors",
413
+ "model.layers.5.self_attn.v_proj.weight": "worker-000-003.safetensors",
414
+ "model.layers.6.self_attn.k_proj.weight": "worker-000-003.safetensors",
415
+ "model.layers.6.self_attn.v_proj.weight": "worker-000-003.safetensors",
416
+ "model.layers.7.self_attn.k_proj.weight": "worker-000-003.safetensors",
417
+ "model.layers.7.self_attn.v_proj.weight": "worker-000-003.safetensors",
418
+ "model.layers.8.self_attn.k_proj.weight": "worker-000-003.safetensors",
419
+ "model.layers.8.self_attn.v_proj.weight": "worker-000-003.safetensors",
420
+ "model.layers.9.self_attn.k_proj.weight": "worker-000-003.safetensors",
421
+ "model.layers.9.self_attn.v_proj.weight": "worker-000-003.safetensors",
422
+ "model.layers.10.self_attn.k_proj.weight": "worker-000-003.safetensors",
423
+ "model.layers.10.self_attn.v_proj.weight": "worker-000-003.safetensors",
424
+ "model.layers.11.self_attn.k_proj.weight": "worker-000-003.safetensors",
425
+ "model.layers.11.self_attn.v_proj.weight": "worker-000-003.safetensors",
426
+ "model.layers.12.self_attn.k_proj.weight": "worker-000-003.safetensors",
427
+ "model.layers.12.self_attn.v_proj.weight": "worker-000-003.safetensors",
428
+ "model.layers.13.self_attn.k_proj.weight": "worker-000-003.safetensors",
429
+ "model.layers.13.self_attn.v_proj.weight": "worker-000-003.safetensors",
430
+ "model.layers.14.self_attn.k_proj.weight": "worker-000-003.safetensors",
431
+ "model.layers.14.self_attn.v_proj.weight": "worker-000-003.safetensors",
432
+ "model.layers.15.self_attn.k_proj.weight": "worker-000-003.safetensors",
433
+ "model.layers.15.self_attn.v_proj.weight": "worker-000-003.safetensors",
434
+ "model.layers.16.self_attn.k_proj.weight": "worker-000-003.safetensors",
435
+ "model.layers.16.self_attn.v_proj.weight": "worker-000-003.safetensors",
436
+ "model.layers.17.self_attn.k_proj.weight": "worker-000-003.safetensors",
437
+ "model.layers.17.self_attn.v_proj.weight": "worker-000-003.safetensors",
438
+ "model.layers.18.self_attn.k_proj.weight": "worker-000-003.safetensors",
439
+ "model.layers.18.self_attn.v_proj.weight": "worker-000-003.safetensors",
440
+ "model.layers.19.self_attn.k_proj.weight": "worker-000-003.safetensors",
441
+ "model.layers.19.self_attn.v_proj.weight": "worker-000-003.safetensors",
442
+ "model.layers.20.self_attn.k_proj.weight": "worker-000-003.safetensors",
443
+ "model.layers.20.self_attn.v_proj.weight": "worker-000-003.safetensors",
444
+ "model.layers.21.self_attn.k_proj.weight": "worker-000-003.safetensors",
445
+ "model.layers.21.self_attn.v_proj.weight": "worker-000-003.safetensors",
446
+ "model.layers.22.self_attn.k_proj.weight": "worker-000-003.safetensors",
447
+ "model.layers.22.self_attn.v_proj.weight": "worker-000-003.safetensors",
448
+ "model.layers.23.self_attn.k_proj.weight": "worker-000-003.safetensors",
449
+ "model.layers.23.self_attn.v_proj.weight": "worker-000-003.safetensors",
450
+ "model.layers.24.self_attn.k_proj.weight": "worker-000-003.safetensors",
451
+ "model.layers.24.self_attn.v_proj.weight": "worker-000-003.safetensors",
452
+ "model.layers.25.self_attn.k_proj.weight": "worker-000-003.safetensors",
453
+ "model.layers.25.self_attn.v_proj.weight": "worker-000-003.safetensors",
454
+ "model.layers.26.self_attn.k_proj.weight": "worker-000-003.safetensors",
455
+ "model.layers.26.self_attn.v_proj.weight": "worker-000-003.safetensors",
456
+ "model.layers.27.self_attn.k_proj.weight": "worker-000-003.safetensors",
457
+ "model.layers.27.self_attn.v_proj.weight": "worker-000-003.safetensors",
458
+ "model.layers.28.self_attn.k_proj.weight": "worker-000-003.safetensors",
459
+ "model.layers.28.self_attn.v_proj.weight": "worker-000-003.safetensors",
460
+ "model.layers.29.self_attn.k_proj.weight": "worker-000-003.safetensors",
461
+ "model.layers.29.self_attn.v_proj.weight": "worker-000-003.safetensors",
462
+ "model.layers.30.self_attn.k_proj.weight": "worker-000-003.safetensors",
463
+ "model.layers.30.self_attn.v_proj.weight": "worker-000-003.safetensors",
464
+ "model.layers.31.self_attn.k_proj.weight": "worker-000-003.safetensors",
465
+ "model.layers.31.self_attn.v_proj.weight": "worker-000-003.safetensors",
466
+ "model.layers.32.self_attn.k_proj.weight": "worker-000-003.safetensors",
467
+ "model.layers.32.self_attn.v_proj.weight": "worker-000-003.safetensors",
468
+ "model.layers.33.self_attn.k_proj.weight": "worker-000-003.safetensors",
469
+ "model.layers.33.self_attn.v_proj.weight": "worker-000-003.safetensors",
470
+ "model.layers.34.self_attn.k_proj.weight": "worker-000-003.safetensors",
471
+ "model.layers.34.self_attn.v_proj.weight": "worker-000-003.safetensors",
472
+ "model.layers.35.self_attn.k_proj.weight": "worker-000-003.safetensors",
473
+ "model.layers.35.self_attn.v_proj.weight": "worker-000-003.safetensors"
474
+ },
475
+ "metadata": {
476
+ "total_size": 6700486656
477
+ }
478
+ }
script.py ADDED
@@ -0,0 +1,421 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """IOL-AI 2026 submission — Tiny Aya bakeoff v4.
2
+
3
+ Force-close <|END_THINKING|>, 1536+512, parser v3, prompt v3.
4
+ CoT fallback (1024) when format/parse fails.
5
+ M1: set USER_THINK_TOKEN="/think" + instruction-following addendum.
6
+ A1: leave USER_THINK_TOKEN="".
7
+ """
8
+
9
+ import os
10
+ import subprocess
11
+ import sys
12
+
13
+
14
+ def _install_bundled_deps() -> None:
15
+ wheels_dir = os.path.join(os.path.dirname(os.path.abspath(__file__)), "wheels")
16
+ if not os.path.isdir(wheels_dir):
17
+ return
18
+ subprocess.run(
19
+ [
20
+ sys.executable,
21
+ "-m",
22
+ "pip",
23
+ "install",
24
+ "-q",
25
+ "--no-index",
26
+ f"--find-links={wheels_dir}",
27
+ "transformers==4.56.2",
28
+ ],
29
+ check=True,
30
+ )
31
+
32
+
33
+ _install_bundled_deps()
34
+
35
+ os.environ["HF_HUB_OFFLINE"] = "1"
36
+ os.environ["TRANSFORMERS_OFFLINE"] = "1"
37
+ MODEL_ID = "."
38
+
39
+ # "" for A1 (reasoning_options only); "/think" for M1 multilingual
40
+ USER_THINK_TOKEN = "/think"
41
+
42
+ import json
43
+ import re
44
+
45
+ import pandas as pd
46
+ import torch
47
+ from transformers import AutoModelForCausalLM, AutoTokenizer
48
+
49
+ END_THINKING = "<|END_THINKING|>"
50
+ START_THINKING = "<|START_THINKING|>"
51
+
52
+ THINKING_BUDGET = 1536
53
+ ANSWER_CONTINUATION_TOKENS = 512
54
+ COT_MAX_NEW_TOKENS = 1024 # T4 30min: capped CoT, not another 1536+512
55
+
56
+ _SYSTEM_BASE = """You solve International Linguistics Olympiad (IOL) problems from the data you are given.
57
+ You may see a task type you have never seen: follow the instruction and examples, and answer in the same form they use.
58
+
59
+ What to return by task type:
60
+ - translation: only the required form in the language the query asks for — do not add extra glosses or "form | meaning" unless asked
61
+ - fill_blanks: only the missing form for each blank — no extra glosses
62
+ - match_letters: ONLY the option letter (A, B, C, …), one letter per line — never copy option text, never arrows, never "A. word"
63
+ - text_to_num: the number in digits only
64
+ - num_to_text: the number written out in words, in the language asked
65
+ - any other type: exactly what the instruction asks for, nothing else
66
+
67
+ Answer in the language and form the query asks for. Do not add glosses, translations, or explanations unless the instruction requires them.
68
+
69
+ Output rules:
70
+ - Put answers ONLY after a line that says exactly: FINAL ANSWERS:
71
+ - Never put answers before that marker.
72
+ - One answer per line; exactly as many lines as items asked in the query.
73
+ - Bare answers only: no numbering, no quotes, no commentary, no repeating the question."""
74
+
75
+ _M1_ADDENDUM = """
76
+
77
+ Extra hard rules:
78
+ - Never refuse or apologize; always output FINAL ANSWERS: with your best guess.
79
+ - For match_letters: only bare letters (A, B, C, …) — never dump the alphabet, never option text.
80
+ - Never append glosses like "form – meaning" or "word - gloss"; bare answers only.
81
+ - Emit exactly as many answer lines as items asked — no more, no fewer."""
82
+
83
+ SYSTEM = _SYSTEM_BASE + (_M1_ADDENDUM if USER_THINK_TOKEN == "/think" else "")
84
+ SYSTEM_COT = (
85
+ SYSTEM
86
+ + "\n\nThink step by step about the rules in the examples and how they apply to the query, "
87
+ "then write FINAL ANSWERS: and the answer lines."
88
+ )
89
+
90
+ # --- parser (inlined from parse_iol.py) ---
91
+ _MD_PREFIX = r"(?:[#*_=\-\s`>]*)"
92
+ _MARKER = re.compile(
93
+ rf"(?im)^{_MD_PREFIX}final\s+answers?{_MD_PREFIX}:?{_MD_PREFIX}\s*(.*)$"
94
+ )
95
+ _NUMBERING = re.compile(r"^\s*(?:\d+[.)]|[-*•])\s*")
96
+ _TURN_NOISE = re.compile(
97
+ r"<\|/?END_OF_TURN_TOKEN\|>|<\|/?START_OF_TURN_TOKEN\|>|"
98
+ r"<\|CHATBOT_TOKEN\|>|<EOS_TOKEN>|<BOS_TOKEN>"
99
+ )
100
+ _RESPONSE_BLOCK = re.compile(
101
+ r"<\|START_RESPONSE\|>(.*?)<\|END_RESPONSE\|>",
102
+ flags=re.S,
103
+ )
104
+ _MD_WRAP = re.compile(r"^[*_`#\s]+|[*_`#\s]+$")
105
+ _TRAILING_LETTER = re.compile(
106
+ r"(?:[–—\-]|→|->)\s*([A-Za-z])(?:\s*[.)]|)\s*$"
107
+ )
108
+ _LEADING_LETTER_OPT = re.compile(r"^([A-Za-z])\s*[.):\-–—]\s+\S")
109
+ _WORD_THEN_LETTER = re.compile(r"^.+\s([A-Za-z])\s*$")
110
+ _REFUSAL = re.compile(
111
+ r"(?i)\b("
112
+ r"i'?m sorry|i am sorry|i don'?t have|i cannot|i can'?t|"
113
+ r"unable to|not able to|no reliable|cannot supply|can'?t supply|"
114
+ r"as an ai|i apologize"
115
+ r")\b"
116
+ )
117
+
118
+
119
+ def _clean_line(line: str) -> str:
120
+ line = _NUMBERING.sub("", line).strip()
121
+ line = _MD_WRAP.sub("", line).strip()
122
+ line = line.replace("\u202f", " ").replace("\xa0", " ")
123
+ return line.strip()
124
+
125
+
126
+ def after_thinking(text: str) -> str:
127
+ """Prefer content after the last <|END_THINKING|>; else drop an unclosed think block."""
128
+ if END_THINKING in text:
129
+ text = text.rsplit(END_THINKING, 1)[-1]
130
+ elif START_THINKING in text:
131
+ text = ""
132
+ return _TURN_NOISE.sub("", text)
133
+
134
+
135
+ def _as_option_letter(line: str) -> str | None:
136
+ line = _clean_line(line)
137
+ if not line:
138
+ return None
139
+ if len(line) == 1 and line.isalpha():
140
+ return line.upper()
141
+ m = _LEADING_LETTER_OPT.match(line)
142
+ if m:
143
+ return m.group(1).upper()
144
+ m = _TRAILING_LETTER.search(line)
145
+ if m:
146
+ return m.group(1).upper()
147
+ if len(line) <= 40:
148
+ m = _WORD_THEN_LETTER.match(line)
149
+ if m:
150
+ return m.group(1).upper()
151
+ return None
152
+
153
+
154
+ def _expand_line(line: str) -> list[str]:
155
+ line = _clean_line(line)
156
+ if not line:
157
+ return []
158
+ if len(line) == 1 and line.isalpha():
159
+ return [line]
160
+ if _LEADING_LETTER_OPT.match(line) or _TRAILING_LETTER.search(line):
161
+ letter = _as_option_letter(line)
162
+ if letter:
163
+ return [letter]
164
+ if len(line) <= 40 and _WORD_THEN_LETTER.match(line):
165
+ letter = _as_option_letter(line)
166
+ if letter:
167
+ return [letter]
168
+ if "|" in line:
169
+ parts = [p.strip() for p in line.split("|") if p.strip()]
170
+ if len(parts) >= 2:
171
+ if len(parts) >= 4 and len(parts) % 2 == 0:
172
+ left, right = parts[0::2], parts[1::2]
173
+ if sum(" " in r for r in right) >= max(1, len(right) // 2):
174
+ return [_clean_line(x) for x in left if _clean_line(x)]
175
+ if len(parts) == 2:
176
+ a, b = parts
177
+ if (" " in b and " " not in a) or (
178
+ len(b) > 2 * max(len(a), 1) and " " in b
179
+ ):
180
+ return [_clean_line(a)] if _clean_line(a) else []
181
+ return [_clean_line(p) for p in parts if _clean_line(p)]
182
+ return [line]
183
+
184
+
185
+ def _dedupe_runaway(parts: list[str]) -> list[str]:
186
+ if len(parts) < 6:
187
+ return parts
188
+ out: list[str] = []
189
+ run = 0
190
+ prev = None
191
+ for p in parts:
192
+ if p == prev:
193
+ run += 1
194
+ if run >= 4:
195
+ break
196
+ else:
197
+ run = 1
198
+ prev = p
199
+ out.append(p)
200
+ return out
201
+
202
+
203
+ def _lines_from_region(region: str, *, allow_all_lines: bool) -> list[str]:
204
+ markers = list(_MARKER.finditer(region))
205
+ if markers:
206
+ last = markers[-1]
207
+ after_parts: list[str] = []
208
+ same = _clean_line(last.group(1) or "")
209
+ if same:
210
+ after_parts.extend(_expand_line(same))
211
+ for line in region[last.end() :].splitlines():
212
+ after_parts.extend(_expand_line(line))
213
+ if after_parts:
214
+ return _dedupe_runaway(after_parts)
215
+ before_parts: list[str] = []
216
+ for line in region[: last.start()].splitlines():
217
+ before_parts.extend(_expand_line(line))
218
+ if before_parts:
219
+ return _dedupe_runaway(before_parts)
220
+
221
+ parts: list[str] = []
222
+ for line in region.splitlines():
223
+ parts.extend(_expand_line(line))
224
+ if not parts:
225
+ return []
226
+ if allow_all_lines:
227
+ return _dedupe_runaway(parts)
228
+ return [parts[-1]]
229
+
230
+
231
+ def parse_answers(
232
+ raw: str,
233
+ *,
234
+ n_expected: int | None = None,
235
+ task_type: str = "",
236
+ ) -> list[str]:
237
+ text = after_thinking(raw)
238
+ closed_blocks = _RESPONSE_BLOCK.findall(text)
239
+ answers: list[str] = []
240
+ if closed_blocks:
241
+ for region in reversed(closed_blocks):
242
+ answers = _lines_from_region(region.strip(), allow_all_lines=True)
243
+ if answers:
244
+ break
245
+ if not answers:
246
+ answers = _lines_from_region(text, allow_all_lines=False)
247
+
248
+ if task_type == "match_letters":
249
+ coerced: list[str] = []
250
+ for a in answers:
251
+ letter = _as_option_letter(a)
252
+ coerced.append(letter if letter else a)
253
+ answers = coerced
254
+
255
+ if n_expected is not None and n_expected > 0 and len(answers) > n_expected:
256
+ answers = answers[:n_expected]
257
+ return answers
258
+
259
+
260
+ def _looks_like_alphabet_dump(answers: list[str]) -> bool:
261
+ letters = [a.strip().upper() for a in answers if len(a.strip()) == 1 and a.strip().isalpha()]
262
+ if len(letters) < 15:
263
+ return False
264
+ # sequential A,B,C… for a long prefix
265
+ seq = 0
266
+ for i, L in enumerate(letters):
267
+ if ord(L) == ord("A") + i:
268
+ seq += 1
269
+ else:
270
+ break
271
+ return seq >= 15
272
+
273
+
274
+ def _looks_like_refusal(answers: list[str]) -> bool:
275
+ blob = " ".join(answers)
276
+ return bool(_REFUSAL.search(blob)) or len(blob) > 400 and "dictionary" in blob.lower()
277
+
278
+
279
+ def has_usable_answer(
280
+ answers: list[str],
281
+ *,
282
+ n_expected: int | None = None,
283
+ task_type: str = "",
284
+ ) -> bool:
285
+ if not answers or not any(a.strip() for a in answers):
286
+ return False
287
+ if _looks_like_refusal(answers):
288
+ return False
289
+ if _looks_like_alphabet_dump(answers):
290
+ return False
291
+ if n_expected is not None and n_expected > 0 and len(answers) != n_expected:
292
+ return False
293
+ if task_type == "match_letters":
294
+ letters = [a for a in answers if len(a) == 1 and a.isalpha()]
295
+ if len(letters) < max(1, int(0.8 * len(answers))):
296
+ return False
297
+ return True
298
+
299
+
300
+ def _n_items_guess(query: str) -> int:
301
+ nums = re.findall(r"(?m)^\s*(?:\(?\d+[.)]|\d+\))", query)
302
+ return len(nums) if nums else 0
303
+
304
+
305
+ def _end_thinking_id(tok) -> int:
306
+ end_id = tok.convert_tokens_to_ids(END_THINKING)
307
+ if end_id is None or end_id == tok.unk_token_id:
308
+ ids = tok.encode(END_THINKING, add_special_tokens=False)
309
+ if len(ids) == 1:
310
+ end_id = ids[0]
311
+ if end_id is None or end_id == tok.unk_token_id:
312
+ raise RuntimeError(f"Tokenizer missing end-think token {END_THINKING!r}")
313
+ return int(end_id)
314
+
315
+
316
+ def _build_prompt_ids(tok, system: str, user: str, *, thinking: bool):
317
+ messages = [
318
+ {"role": "system", "content": system},
319
+ {"role": "user", "content": user},
320
+ ]
321
+ try:
322
+ return tok.apply_chat_template(
323
+ messages,
324
+ add_generation_prompt=True,
325
+ return_tensors="pt",
326
+ reasoning_options={"enabled": thinking},
327
+ )
328
+ except TypeError:
329
+ return tok.apply_chat_template(
330
+ messages, add_generation_prompt=True, return_tensors="pt"
331
+ )
332
+
333
+
334
+ @torch.inference_mode()
335
+ def generate_with_think_budget(model, tok, prompt_ids, end_id: int):
336
+ device = next(model.parameters()).device
337
+ prompt_ids = prompt_ids.to(device)
338
+ prompt_len = prompt_ids.shape[-1]
339
+
340
+ think_out = model.generate(
341
+ prompt_ids,
342
+ max_new_tokens=THINKING_BUDGET,
343
+ do_sample=False,
344
+ pad_token_id=tok.pad_token_id or tok.eos_token_id,
345
+ )[0]
346
+ gen_ids = think_out[prompt_len:].tolist()
347
+ if end_id not in gen_ids:
348
+ cont = torch.cat(
349
+ [think_out, torch.tensor([end_id], device=device, dtype=think_out.dtype)]
350
+ )
351
+ else:
352
+ cont = think_out
353
+
354
+ full = model.generate(
355
+ cont.unsqueeze(0),
356
+ max_new_tokens=ANSWER_CONTINUATION_TOKENS,
357
+ do_sample=False,
358
+ pad_token_id=tok.pad_token_id or tok.eos_token_id,
359
+ )[0]
360
+ text = tok.decode(full[prompt_len:], skip_special_tokens=False)
361
+ return _TURN_NOISE.sub("", text).strip()
362
+
363
+
364
+ @torch.inference_mode()
365
+ def generate_plain(model, tok, prompt_ids, max_new_tokens: int):
366
+ device = next(model.parameters()).device
367
+ prompt_ids = prompt_ids.to(device)
368
+ prompt_len = prompt_ids.shape[-1]
369
+ out = model.generate(
370
+ prompt_ids,
371
+ max_new_tokens=max_new_tokens,
372
+ do_sample=False,
373
+ pad_token_id=tok.pad_token_id or tok.eos_token_id,
374
+ )[0]
375
+ text = tok.decode(out[prompt_len:], skip_special_tokens=False)
376
+ return _TURN_NOISE.sub("", text).strip()
377
+
378
+
379
+ tok = AutoTokenizer.from_pretrained(MODEL_ID)
380
+ end_id = _end_thinking_id(tok)
381
+ model = AutoModelForCausalLM.from_pretrained(
382
+ MODEL_ID, torch_dtype=torch.float16, device_map="auto"
383
+ ).eval()
384
+
385
+ df = pd.read_csv("/tmp/data/test.csv", dtype=str).fillna("")
386
+
387
+ rows = []
388
+ for i, r in df.iterrows():
389
+ n_guess = _n_items_guess(r["query"])
390
+ task = str(r.get("task_type", "") or "")
391
+ n_exp = n_guess or None
392
+
393
+ user = f"{r['context'].strip()}\n\n{r['query'].strip()}"
394
+ if n_guess:
395
+ user += f"\n\n(Emit exactly {n_guess} answer line(s) after FINAL ANSWERS:.)"
396
+ user_think = user
397
+ if USER_THINK_TOKEN:
398
+ user_think += f"\n{USER_THINK_TOKEN}"
399
+
400
+ ids = _build_prompt_ids(tok, SYSTEM, user_think, thinking=True)
401
+ text = generate_with_think_budget(model, tok, ids, end_id)
402
+ answers = parse_answers(text, n_expected=n_exp, task_type=task)
403
+ used_cot = False
404
+
405
+ if not has_usable_answer(answers, n_expected=n_exp, task_type=task):
406
+ used_cot = True
407
+ # CoT: no /think, thinking channel off, capped budget
408
+ cot_ids = _build_prompt_ids(tok, SYSTEM_COT, user, thinking=False)
409
+ cot_text = generate_plain(model, tok, cot_ids, COT_MAX_NEW_TOKENS)
410
+ cot_answers = parse_answers(cot_text, n_expected=n_exp, task_type=task)
411
+ if has_usable_answer(cot_answers, n_expected=n_exp, task_type=task):
412
+ answers = cot_answers
413
+
414
+ rows.append({"id": r["id"], "pred": json.dumps(answers, ensure_ascii=False)})
415
+ print(
416
+ f"[{i + 1}/{len(df)}] {len(answers)} answers cot={used_cot}",
417
+ flush=True,
418
+ )
419
+
420
+ pd.DataFrame(rows).to_csv("submission.csv", index=False)
421
+ print("wrote submission.csv", flush=True)
special_tokens_map.json ADDED
@@ -0,0 +1,40 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": {
3
+ "content": "<BOS_TOKEN>",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "eos_token": {
10
+ "content": "<EOS_TOKEN>",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "pad_token": {
17
+ "content": "<PAD>",
18
+ "lstrip": false,
19
+ "normalized": false,
20
+ "rstrip": false,
21
+ "single_word": false
22
+ },
23
+ "unk_token": {
24
+ "content": "<UNK>",
25
+ "lstrip": false,
26
+ "normalized": false,
27
+ "rstrip": false,
28
+ "single_word": false
29
+ },
30
+ "additional_special_tokens": [
31
+ "<|START_RESPONSE|>",
32
+ "<|END_RESPONSE|>",
33
+ "<|START_ACTION|>",
34
+ "<|END_ACTION|>",
35
+ "<|START_TOOL_RESULT|>",
36
+ "<|END_TOOL_RESULT|>",
37
+ "<|START_THINKING|>",
38
+ "<|END_THINKING|>"
39
+ ]
40
+ }
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:55388a861271fb6b9eb631670e5eee0562bcddf204dc63494d98ee67f5551839
3
+ size 30245131
tokenizer_config.json ADDED
@@ -0,0 +1,202 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_bos_token": true,
3
+ "add_eos_token": false,
4
+ "add_prefix_space": false,
5
+ "clean_up_tokenization_spaces": false,
6
+ "legacy": true,
7
+ "spaces_between_special_tokens": false,
8
+ "use_default_system_prompt": false,
9
+ "bos_token": "<BOS_TOKEN>",
10
+ "eos_token": "<EOS_TOKEN>",
11
+ "pad_token": "<PAD>",
12
+ "unk_token": "<UNK>",
13
+ "tokenizer_class": "CohereTokenizerFast",
14
+ "model_max_length": 1000000000000000019884624838656,
15
+ "sp_model_kwargs": {},
16
+ "added_tokens_decoder": {
17
+ "0": {
18
+ "content": "<PAD>",
19
+ "lstrip": false,
20
+ "normalized": false,
21
+ "rstrip": false,
22
+ "single_word": false,
23
+ "special": true
24
+ },
25
+ "1": {
26
+ "content": "<MASK_TOKEN>",
27
+ "lstrip": false,
28
+ "normalized": false,
29
+ "rstrip": false,
30
+ "single_word": false,
31
+ "special": true
32
+ },
33
+ "2": {
34
+ "content": "<BOS_TOKEN>",
35
+ "lstrip": false,
36
+ "normalized": false,
37
+ "rstrip": false,
38
+ "single_word": false,
39
+ "special": true
40
+ },
41
+ "3": {
42
+ "content": "<EOS_TOKEN>",
43
+ "lstrip": false,
44
+ "normalized": false,
45
+ "rstrip": false,
46
+ "single_word": false,
47
+ "special": true
48
+ },
49
+ "4": {
50
+ "content": "<UNK>",
51
+ "lstrip": false,
52
+ "normalized": false,
53
+ "rstrip": false,
54
+ "single_word": false,
55
+ "special": true
56
+ },
57
+ "5": {
58
+ "content": "<|START_OF_TURN_TOKEN|>",
59
+ "lstrip": false,
60
+ "normalized": false,
61
+ "rstrip": false,
62
+ "single_word": false,
63
+ "special": true
64
+ },
65
+ "6": {
66
+ "content": "<|END_OF_TURN_TOKEN|>",
67
+ "lstrip": false,
68
+ "normalized": false,
69
+ "rstrip": false,
70
+ "single_word": false,
71
+ "special": true
72
+ },
73
+ "7": {
74
+ "content": "<|USER_TOKEN|>",
75
+ "lstrip": false,
76
+ "normalized": false,
77
+ "rstrip": false,
78
+ "single_word": false,
79
+ "special": true
80
+ },
81
+ "8": {
82
+ "content": "<|CHATBOT_TOKEN|>",
83
+ "lstrip": false,
84
+ "normalized": false,
85
+ "rstrip": false,
86
+ "single_word": false,
87
+ "special": true
88
+ },
89
+ "9": {
90
+ "content": "<|SYSTEM_TOKEN|>",
91
+ "lstrip": false,
92
+ "normalized": false,
93
+ "rstrip": false,
94
+ "single_word": false,
95
+ "special": true
96
+ },
97
+ "10": {
98
+ "content": "<|NEW_FILE|>",
99
+ "lstrip": false,
100
+ "normalized": false,
101
+ "rstrip": false,
102
+ "single_word": false,
103
+ "special": true
104
+ },
105
+ "11": {
106
+ "content": "<|BEGINNING_OF_PREFIX_FIM_TOKEN|>",
107
+ "lstrip": false,
108
+ "normalized": false,
109
+ "rstrip": false,
110
+ "single_word": false,
111
+ "special": true
112
+ },
113
+ "12": {
114
+ "content": "<|BEGINNING_OF_MIDDLE_FIM_TOKEN|>",
115
+ "lstrip": false,
116
+ "normalized": false,
117
+ "rstrip": false,
118
+ "single_word": false,
119
+ "special": true
120
+ },
121
+ "13": {
122
+ "content": "<|BEGINNING_OF_SUFFIX_FIM_TOKEN|>",
123
+ "lstrip": false,
124
+ "normalized": false,
125
+ "rstrip": false,
126
+ "single_word": false,
127
+ "special": true
128
+ },
129
+ "14": {
130
+ "content": "<|END_OF_MIDDLE_FIM_TOKEN|>",
131
+ "lstrip": false,
132
+ "normalized": false,
133
+ "rstrip": false,
134
+ "single_word": false,
135
+ "special": true
136
+ },
137
+ "261000": {
138
+ "content": "<|START_RESPONSE|>",
139
+ "lstrip": false,
140
+ "normalized": false,
141
+ "rstrip": false,
142
+ "single_word": false,
143
+ "special": true
144
+ },
145
+ "261001": {
146
+ "content": "<|END_RESPONSE|>",
147
+ "lstrip": false,
148
+ "normalized": false,
149
+ "rstrip": false,
150
+ "single_word": false,
151
+ "special": true
152
+ },
153
+ "261002": {
154
+ "content": "<|START_ACTION|>",
155
+ "lstrip": false,
156
+ "normalized": false,
157
+ "rstrip": false,
158
+ "single_word": false,
159
+ "special": true
160
+ },
161
+ "261003": {
162
+ "content": "<|END_ACTION|>",
163
+ "lstrip": false,
164
+ "normalized": false,
165
+ "rstrip": false,
166
+ "single_word": false,
167
+ "special": true
168
+ },
169
+ "261004": {
170
+ "content": "<|START_TOOL_RESULT|>",
171
+ "lstrip": false,
172
+ "normalized": false,
173
+ "rstrip": false,
174
+ "single_word": false,
175
+ "special": true
176
+ },
177
+ "261005": {
178
+ "content": "<|END_TOOL_RESULT|>",
179
+ "lstrip": false,
180
+ "normalized": false,
181
+ "rstrip": false,
182
+ "single_word": false,
183
+ "special": true
184
+ },
185
+ "261006": {
186
+ "content": "<|START_THINKING|>",
187
+ "lstrip": false,
188
+ "normalized": false,
189
+ "rstrip": false,
190
+ "single_word": false,
191
+ "special": true
192
+ },
193
+ "261007": {
194
+ "content": "<|END_THINKING|>",
195
+ "lstrip": false,
196
+ "normalized": false,
197
+ "rstrip": false,
198
+ "single_word": false,
199
+ "special": true
200
+ }
201
+ }
202
+ }
wheels/certifi-2026.6.17-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2227dcbaafe0d2f59279d1762ddddc37783ed4354594f194ffc31d20f41fc3db
3
+ size 133289
wheels/charset_normalizer-3.4.9-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9bb41182d93ea91f60b4bc8fbf4c820c69ef8a12ab2d917f3f1834f1acad07e8
3
+ size 223817
wheels/filelock-3.29.7-py3-none-any.whl ADDED
Binary file (46 kB). View file
 
wheels/fsspec-2026.6.0-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:02e0b71817df9b2169dc30a16832045764def1191b43dcff5bb85bdee212d2a1
3
+ size 203949
wheels/hf_xet-1.5.1-cp37-abi3-manylinux2014_x86_64.manylinux_2_17_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:892e3a3a3aecc12aded8b93cf4f9cd059282c7de0732f7d55026f3abdf474350
3
+ size 4514864
wheels/huggingface_hub-0.36.2-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:48f0c8eac16145dfce371e9d2d7772854a4f591bcb56c9cf548accf531d54270
3
+ size 566395
wheels/idna-3.18-py3-none-any.whl ADDED
Binary file (65.5 kB). View file
 
wheels/numpy-2.2.6-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fc7b73d02efb0e18c000e9ad8b83480dfcd5dfd11065997ed4c6747470ae8915
3
+ size 16801050
wheels/packaging-26.2-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5fc45236b9446107ff2415ce77c807cee2862cb6fac22b8a73826d0693b0980e
3
+ size 100195
wheels/pyyaml-6.0.3-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9c7708761fccb9397fe64bbc0395abcae8c4bf7b0eac081e12b809bf47700d0b
3
+ size 770293
wheels/regex-2026.6.28-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:23f7e0cc60c72486b42a685f1ff4eec90d50d4fb05e4f9c7d5363b03aa02600d
3
+ size 794116
wheels/requests-2.34.2-py3-none-any.whl ADDED
Binary file (73.1 kB). View file
 
wheels/safetensors-0.8.0-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fd6f3f93c9a0a7cc2788ee63fb763353d4bd2e89b0751bc78fcf7dda00bea774
3
+ size 516040
wheels/tokenizers-0.22.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:369cc9fc8cc10cb24143873a0d95438bb8ee257bb80c71989e3ee290e8d72c67
3
+ size 3274982
wheels/tqdm-4.68.4-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5168118b2368f48c561afda8020fd79195b1bdb0bdf8086b88442c267a315dc2
3
+ size 676612
wheels/transformers-4.56.2-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:79c03d0e85b26cb573c109ff9eafa96f3c8d4febfd8a0774e8bba32702dd6dde
3
+ size 11608055
wheels/typing_extensions-4.16.0-py3-none-any.whl ADDED
Binary file (45.6 kB). View file
 
wheels/urllib3-2.7.0-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9fb4c81ebbb1ce9531cce37674bbc6f1360472bc18ca9a553ede278ef7276897
3
+ size 131087
worker-000-000.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fec68be6469b8cfb70e6558b523444c0f1ecb2e92fb5d898237810e56c5b7f2e
3
+ size 1998698496
worker-000-001.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5af43378efedd477921f66a8cc99e22d0c16f3471542f74865f27cb325f8dc7d
3
+ size 1996494056
worker-000-002.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:7d8cb6e8ce84f04fac324554f884409399264e9ffadbd8dfcc44dfadafb4ebdc
3
+ size 1996494088
worker-000-003.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:66e3a2b976343ffb775c7dbaae4cde20dd258492b30709e1efb3126636a6ddee
3
+ size 708852792