anonymousICML commited on
Commit
a289e78
·
verified ·
1 Parent(s): 2c049fc

Upload OmniGuard-7B-Full

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
+ tokenizer.json filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ language:
4
+ - zh
5
+ - en
6
+ tags:
7
+ - safety
8
+ - moderation
9
+ - multimodal
10
+ pipeline_tag: text-generation
11
+ ---
12
+
13
+ # OmniGuard-7B-Full
14
+
15
+ OmniGuard 系列安全审核模型。
16
+
17
+ ## 模型信息
18
+
19
+ - **模型名称**: OmniGuard-7B-Full
20
+ - **原始模型**: OmniGuard-7B
21
+ - **模型类型**: 多模态安全审核
22
+ - **支持语言**: 中文、英文
23
+
24
+ ## 使用方法
25
+
26
+ ```python
27
+ from transformers import AutoModelForCausalLM, AutoTokenizer
28
+
29
+ model_name = "anonymousICML/OmniGuard-7B-Full"
30
+ model = AutoModelForCausalLM.from_pretrained(
31
+ model_name,
32
+ torch_dtype="auto",
33
+ device_map="auto",
34
+ attn_implementation="flash_attention_2" # 推荐使用 flash attention
35
+ )
36
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
37
+
38
+ # 使用模型
39
+ messages = [
40
+ {"role": "user", "content": "你的输入"}
41
+ ]
42
+ text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
43
+ inputs = tokenizer([text], return_tensors="pt").to(model.device)
44
+
45
+ outputs = model.generate(**inputs, max_new_tokens=512, do_sample=False)
46
+ response = tokenizer.decode(outputs[0], skip_special_tokens=True)
47
+ print(response)
48
+ ```
49
+
50
+ ## 性能
51
+
52
+ - 推荐使用 `flash_attention_2` 以获得最佳性能
53
+ - 支持 GPU 加速推理
54
+ - 建议使用 `torch_dtype="auto"` 自动选择最佳精度
55
+
56
+ ## 许可证
57
+
58
+ Apache-2.0
added_tokens.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "</tool_call>": 151658,
3
+ "<tool_call>": 151657,
4
+ "<|AUDIO|>": 151646,
5
+ "<|IMAGE|>": 151655,
6
+ "<|VIDEO|>": 151656,
7
+ "<|audio_bos|>": 151647,
8
+ "<|audio_eos|>": 151648,
9
+ "<|box_end|>": 151649,
10
+ "<|endoftext|>": 151643,
11
+ "<|file_sep|>": 151664,
12
+ "<|fim_middle|>": 151660,
13
+ "<|fim_pad|>": 151662,
14
+ "<|fim_prefix|>": 151659,
15
+ "<|fim_suffix|>": 151661,
16
+ "<|im_end|>": 151645,
17
+ "<|im_start|>": 151644,
18
+ "<|quad_end|>": 151651,
19
+ "<|quad_start|>": 151650,
20
+ "<|repo_name|>": 151663,
21
+ "<|vision_bos|>": 151652,
22
+ "<|vision_eos|>": 151653,
23
+ "<|vision_pad|>": 151654
24
+ }
chat_template.jinja ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {% set audio_count = namespace(value=0) %}{% set image_count = namespace(value=0) %}{% set video_count = namespace(value=0) %}{% for message in messages %}{% if loop.first and message['role'] != 'system' %}<|im_start|>system
2
+ You are a helpful assistant.<|im_end|>
3
+ {% endif %}<|im_start|>{{ message['role'] }}
4
+ {% if message['content'] is string %}{{ message['content'] }}<|im_end|>
5
+ {% else %}{% for content in message['content'] %}{% if content['type'] == 'image' or 'image' in content or 'image_url' in content %}{% set image_count.value = image_count.value + 1 %}{% if add_vision_id %}Picture {{ image_count.value }}: {% endif %}<|vision_bos|><|IMAGE|><|vision_eos|>{% elif content['type'] == 'audio' or 'audio' in content or 'audio_url' in content %}{% set audio_count.value = audio_count.value + 1 %}{% if add_audio_id %}Audio {{ audio_count.value }}: {% endif %}<|audio_bos|><|AUDIO|><|audio_eos|>{% elif content['type'] == 'video' or 'video' in content %}{% set video_count.value = video_count.value + 1 %}{% if add_vision_id %}Video {{ video_count.value }}: {% endif %}<|vision_bos|><|VIDEO|><|vision_eos|>{% elif 'text' in content %}{{ content['text'] }}{% endif %}{% endfor %}<|im_end|>
6
+ {% endif %}{% endfor %}{% if add_generation_prompt %}<|im_start|>assistant
7
+ {% endif %}
config.json ADDED
@@ -0,0 +1,636 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Qwen2_5OmniForConditionalGeneration"
4
+ ],
5
+ "dtype": "bfloat16",
6
+ "enable_audio_output": false,
7
+ "enable_talker": true,
8
+ "eos_token_id": 151645,
9
+ "hidden_size": 3584,
10
+ "keys_to_ignore_at_inference": [
11
+ "past_key_values",
12
+ "hidden_states",
13
+ "attention_mask"
14
+ ],
15
+ "model_type": "qwen2_5_omni",
16
+ "pad_token_id": 151643,
17
+ "talker_config": {
18
+ "_attn_implementation_autoset": true,
19
+ "_name_or_path": "Qwen2.5-Omni-7B/talker",
20
+ "architectures": [
21
+ "Qwen2OmniTalkerForConditionalGeneration"
22
+ ],
23
+ "attention_dropout": 0.0,
24
+ "audio_end_token_id": 151648,
25
+ "audio_start_token_id": 151647,
26
+ "audio_token_index": 151646,
27
+ "dtype": "bfloat16",
28
+ "embedding_size": 3584,
29
+ "head_dim": 128,
30
+ "hidden_act": "silu",
31
+ "hidden_size": 896,
32
+ "image_token_index": 151655,
33
+ "init_std": 0.02,
34
+ "initializer_range": 0.02,
35
+ "intermediate_size": 18944,
36
+ "layer_types": [
37
+ "full_attention",
38
+ "full_attention",
39
+ "full_attention",
40
+ "full_attention",
41
+ "full_attention",
42
+ "full_attention",
43
+ "full_attention",
44
+ "full_attention",
45
+ "full_attention",
46
+ "full_attention",
47
+ "full_attention",
48
+ "full_attention",
49
+ "full_attention",
50
+ "full_attention",
51
+ "full_attention",
52
+ "full_attention",
53
+ "full_attention",
54
+ "full_attention",
55
+ "full_attention",
56
+ "full_attention",
57
+ "full_attention",
58
+ "full_attention",
59
+ "full_attention",
60
+ "full_attention"
61
+ ],
62
+ "max_position_embeddings": 32768,
63
+ "max_window_layers": 28,
64
+ "model_type": "qwen2_5_omni_talker",
65
+ "num_attention_heads": 12,
66
+ "num_hidden_layers": 24,
67
+ "num_key_value_heads": 4,
68
+ "position_id_per_seconds": 25,
69
+ "rms_norm_eps": 1e-06,
70
+ "rope_scaling": {
71
+ "mrope_section": [
72
+ 16,
73
+ 24,
74
+ 24
75
+ ],
76
+ "rope_type": "default",
77
+ "type": "default"
78
+ },
79
+ "rope_theta": 1000000.0,
80
+ "seconds_per_chunk": 2,
81
+ "sliding_window": null,
82
+ "spatial_merge_size": 2,
83
+ "tts_codec_end_token_id": 8294,
84
+ "tts_codec_mask_token_id": 8296,
85
+ "tts_codec_pad_token_id": 8292,
86
+ "tts_codec_start_token_id": 8293,
87
+ "tts_text_end_token_id": 151861,
88
+ "tts_text_pad_token_id": 151859,
89
+ "tts_text_start_token_id": 151860,
90
+ "use_cache": true,
91
+ "use_sliding_window": false,
92
+ "video_token_index": 151656,
93
+ "vision_end_token_id": 151653,
94
+ "vision_start_token_id": 151652,
95
+ "vocab_size": 8448
96
+ },
97
+ "thinker_config": {
98
+ "_attn_implementation_autoset": true,
99
+ "_name_or_path": "Qwen2.5-Omni-7B/thinker",
100
+ "architectures": [
101
+ "Qwen2OmniNaViTThinkerForConditionalGeneration"
102
+ ],
103
+ "audio_config": {
104
+ "_attn_implementation_autoset": true,
105
+ "_name_or_path": "",
106
+ "activation_dropout": 0.0,
107
+ "activation_function": "gelu",
108
+ "add_cross_attention": false,
109
+ "architectures": null,
110
+ "attention_dropout": 0.0,
111
+ "bad_words_ids": null,
112
+ "begin_suppress_tokens": null,
113
+ "bos_token_id": null,
114
+ "chunk_size_feed_forward": 0,
115
+ "cross_attention_hidden_size": null,
116
+ "d_model": 1280,
117
+ "decoder_start_token_id": null,
118
+ "diversity_penalty": 0.0,
119
+ "do_sample": false,
120
+ "dropout": 0.0,
121
+ "dtype": "bfloat16",
122
+ "early_stopping": false,
123
+ "encoder_attention_heads": 20,
124
+ "encoder_ffn_dim": 5120,
125
+ "encoder_layerdrop": 0.0,
126
+ "encoder_layers": 32,
127
+ "encoder_no_repeat_ngram_size": 0,
128
+ "eos_token_id": null,
129
+ "exponential_decay_length_penalty": null,
130
+ "finetuning_task": null,
131
+ "forced_bos_token_id": null,
132
+ "forced_eos_token_id": null,
133
+ "id2label": {
134
+ "0": "LABEL_0",
135
+ "1": "LABEL_1"
136
+ },
137
+ "init_std": 0.02,
138
+ "initializer_range": 0.02,
139
+ "is_decoder": false,
140
+ "is_encoder_decoder": false,
141
+ "label2id": {
142
+ "LABEL_0": 0,
143
+ "LABEL_1": 1
144
+ },
145
+ "length_penalty": 1.0,
146
+ "max_length": 20,
147
+ "max_source_positions": 1500,
148
+ "min_length": 0,
149
+ "model_type": "qwen2_5_omni_audio_encoder",
150
+ "n_window": 100,
151
+ "no_repeat_ngram_size": 0,
152
+ "num_beam_groups": 1,
153
+ "num_beams": 1,
154
+ "num_hidden_layers": 32,
155
+ "num_mel_bins": 128,
156
+ "num_return_sequences": 1,
157
+ "output_attentions": false,
158
+ "output_dim": 3584,
159
+ "output_hidden_states": false,
160
+ "output_scores": false,
161
+ "pad_token_id": 151643,
162
+ "prefix": null,
163
+ "problem_type": null,
164
+ "pruned_heads": {},
165
+ "remove_invalid_values": false,
166
+ "repetition_penalty": 1.0,
167
+ "return_dict": true,
168
+ "return_dict_in_generate": false,
169
+ "scale_embedding": false,
170
+ "sep_token_id": null,
171
+ "suppress_tokens": null,
172
+ "task_specific_params": null,
173
+ "temperature": 1.0,
174
+ "tf_legacy_loss": false,
175
+ "tie_encoder_decoder": false,
176
+ "tie_word_embeddings": true,
177
+ "tokenizer_class": null,
178
+ "top_k": 50,
179
+ "top_p": 1.0,
180
+ "torchscript": false,
181
+ "typical_p": 1.0,
182
+ "use_bfloat16": false
183
+ },
184
+ "audio_end_token_id": 151648,
185
+ "audio_start_token_id": 151647,
186
+ "audio_token_index": 151646,
187
+ "bos_token_id": 151644,
188
+ "dtype": "bfloat16",
189
+ "eos_token_id": 151645,
190
+ "ignore_index": -100,
191
+ "image_token_index": 151655,
192
+ "init_std": 0.02,
193
+ "initializer_range": 0.02,
194
+ "model_type": "qwen2_5_omni_thinker",
195
+ "pad_token_id": 151643,
196
+ "position_id_per_seconds": 25,
197
+ "seconds_per_chunk": 2,
198
+ "text_config": {
199
+ "_name_or_path": "",
200
+ "add_cross_attention": false,
201
+ "architectures": null,
202
+ "attention_dropout": 0.0,
203
+ "bad_words_ids": null,
204
+ "begin_suppress_tokens": null,
205
+ "bos_token_id": null,
206
+ "chunk_size_feed_forward": 0,
207
+ "cross_attention_hidden_size": null,
208
+ "decoder_start_token_id": null,
209
+ "diversity_penalty": 0.0,
210
+ "do_sample": false,
211
+ "dtype": "bfloat16",
212
+ "early_stopping": false,
213
+ "encoder_no_repeat_ngram_size": 0,
214
+ "eos_token_id": null,
215
+ "exponential_decay_length_penalty": null,
216
+ "finetuning_task": null,
217
+ "forced_bos_token_id": null,
218
+ "forced_eos_token_id": null,
219
+ "hidden_act": "silu",
220
+ "hidden_size": 3584,
221
+ "id2label": {
222
+ "0": "LABEL_0",
223
+ "1": "LABEL_1"
224
+ },
225
+ "init_std": 0.02,
226
+ "initializer_range": 0.02,
227
+ "intermediate_size": 18944,
228
+ "is_decoder": false,
229
+ "is_encoder_decoder": false,
230
+ "label2id": {
231
+ "LABEL_0": 0,
232
+ "LABEL_1": 1
233
+ },
234
+ "layer_types": [
235
+ "full_attention",
236
+ "full_attention",
237
+ "full_attention",
238
+ "full_attention",
239
+ "full_attention",
240
+ "full_attention",
241
+ "full_attention",
242
+ "full_attention",
243
+ "full_attention",
244
+ "full_attention",
245
+ "full_attention",
246
+ "full_attention",
247
+ "full_attention",
248
+ "full_attention",
249
+ "full_attention",
250
+ "full_attention",
251
+ "full_attention",
252
+ "full_attention",
253
+ "full_attention",
254
+ "full_attention",
255
+ "full_attention",
256
+ "full_attention",
257
+ "full_attention",
258
+ "full_attention",
259
+ "full_attention",
260
+ "full_attention",
261
+ "full_attention",
262
+ "full_attention"
263
+ ],
264
+ "length_penalty": 1.0,
265
+ "max_length": 20,
266
+ "max_position_embeddings": 32768,
267
+ "max_window_layers": 28,
268
+ "min_length": 0,
269
+ "model_type": "qwen2_5_omni_text",
270
+ "no_repeat_ngram_size": 0,
271
+ "num_attention_heads": 28,
272
+ "num_beam_groups": 1,
273
+ "num_beams": 1,
274
+ "num_hidden_layers": 28,
275
+ "num_key_value_heads": 4,
276
+ "num_return_sequences": 1,
277
+ "output_attentions": false,
278
+ "output_hidden_states": false,
279
+ "output_scores": false,
280
+ "pad_token_id": 151643,
281
+ "prefix": null,
282
+ "problem_type": null,
283
+ "pruned_heads": {},
284
+ "remove_invalid_values": false,
285
+ "repetition_penalty": 1.0,
286
+ "return_dict": true,
287
+ "return_dict_in_generate": false,
288
+ "rms_norm_eps": 1e-06,
289
+ "rope_scaling": {
290
+ "mrope_section": [
291
+ 16,
292
+ 24,
293
+ 24
294
+ ],
295
+ "rope_type": "default",
296
+ "type": "default"
297
+ },
298
+ "rope_theta": 1000000.0,
299
+ "sep_token_id": null,
300
+ "sliding_window": null,
301
+ "suppress_tokens": null,
302
+ "task_specific_params": null,
303
+ "temperature": 1.0,
304
+ "tf_legacy_loss": false,
305
+ "tie_encoder_decoder": false,
306
+ "tie_word_embeddings": false,
307
+ "tokenizer_class": null,
308
+ "top_k": 50,
309
+ "top_p": 1.0,
310
+ "torchscript": false,
311
+ "typical_p": 1.0,
312
+ "use_bfloat16": false,
313
+ "use_cache": false,
314
+ "use_sliding_window": false,
315
+ "vocab_size": 152064
316
+ },
317
+ "user_token_id": 872,
318
+ "video_token_index": 151656,
319
+ "vision_config": {
320
+ "_attn_implementation_autoset": true,
321
+ "_name_or_path": "",
322
+ "add_cross_attention": false,
323
+ "architectures": null,
324
+ "bad_words_ids": null,
325
+ "begin_suppress_tokens": null,
326
+ "bos_token_id": null,
327
+ "chunk_size_feed_forward": 0,
328
+ "cross_attention_hidden_size": null,
329
+ "decoder_start_token_id": null,
330
+ "depth": 32,
331
+ "diversity_penalty": 0.0,
332
+ "do_sample": false,
333
+ "dtype": "bfloat16",
334
+ "early_stopping": false,
335
+ "embed_dim": 1280,
336
+ "encoder_no_repeat_ngram_size": 0,
337
+ "eos_token_id": null,
338
+ "exponential_decay_length_penalty": null,
339
+ "finetuning_task": null,
340
+ "forced_bos_token_id": null,
341
+ "forced_eos_token_id": null,
342
+ "fullatt_block_indexes": [
343
+ 7,
344
+ 15,
345
+ 23,
346
+ 31
347
+ ],
348
+ "hidden_act": "silu",
349
+ "hidden_size": 1280,
350
+ "id2label": {
351
+ "0": "LABEL_0",
352
+ "1": "LABEL_1"
353
+ },
354
+ "in_channels": 3,
355
+ "in_chans": 3,
356
+ "init_std": 0.02,
357
+ "initializer_range": 0.02,
358
+ "intermediate_size": 3420,
359
+ "is_decoder": false,
360
+ "is_encoder_decoder": false,
361
+ "label2id": {
362
+ "LABEL_0": 0,
363
+ "LABEL_1": 1
364
+ },
365
+ "length_penalty": 1.0,
366
+ "max_length": 20,
367
+ "min_length": 0,
368
+ "model_type": "qwen2_5_omni_vision_encoder",
369
+ "no_repeat_ngram_size": 0,
370
+ "num_beam_groups": 1,
371
+ "num_beams": 1,
372
+ "num_heads": 16,
373
+ "num_return_sequences": 1,
374
+ "out_hidden_size": 3584,
375
+ "output_attentions": false,
376
+ "output_hidden_states": false,
377
+ "output_scores": false,
378
+ "pad_token_id": 151643,
379
+ "patch_size": 14,
380
+ "prefix": null,
381
+ "problem_type": null,
382
+ "pruned_heads": {},
383
+ "remove_invalid_values": false,
384
+ "repetition_penalty": 1.0,
385
+ "return_dict": true,
386
+ "return_dict_in_generate": false,
387
+ "sep_token_id": null,
388
+ "spatial_merge_size": 2,
389
+ "spatial_patch_size": 14,
390
+ "suppress_tokens": null,
391
+ "task_specific_params": null,
392
+ "temperature": 1.0,
393
+ "temporal_patch_size": 2,
394
+ "tf_legacy_loss": false,
395
+ "tie_encoder_decoder": false,
396
+ "tie_word_embeddings": true,
397
+ "tokenizer_class": null,
398
+ "tokens_per_second": 25,
399
+ "top_k": 50,
400
+ "top_p": 1.0,
401
+ "torchscript": false,
402
+ "typical_p": 1.0,
403
+ "use_bfloat16": false,
404
+ "window_size": 112
405
+ },
406
+ "vision_end_token_id": 151653,
407
+ "vision_start_token_id": 151652,
408
+ "vision_token_id": 151654
409
+ },
410
+ "token2wav_config": {
411
+ "_attn_implementation_autoset": true,
412
+ "bigvgan_config": {
413
+ "_attn_implementation_autoset": true,
414
+ "_name_or_path": "",
415
+ "add_cross_attention": false,
416
+ "architectures": null,
417
+ "bad_words_ids": null,
418
+ "begin_suppress_tokens": null,
419
+ "bos_token_id": null,
420
+ "chunk_size_feed_forward": 0,
421
+ "cross_attention_hidden_size": null,
422
+ "decoder_start_token_id": null,
423
+ "diversity_penalty": 0.0,
424
+ "do_sample": false,
425
+ "dtype": null,
426
+ "early_stopping": false,
427
+ "encoder_no_repeat_ngram_size": 0,
428
+ "eos_token_id": null,
429
+ "exponential_decay_length_penalty": null,
430
+ "finetuning_task": null,
431
+ "forced_bos_token_id": null,
432
+ "forced_eos_token_id": null,
433
+ "id2label": {
434
+ "0": "LABEL_0",
435
+ "1": "LABEL_1"
436
+ },
437
+ "is_decoder": false,
438
+ "is_encoder_decoder": false,
439
+ "label2id": {
440
+ "LABEL_0": 0,
441
+ "LABEL_1": 1
442
+ },
443
+ "length_penalty": 1.0,
444
+ "max_length": 20,
445
+ "mel_dim": 80,
446
+ "min_length": 0,
447
+ "model_type": "qwen2_5_omni_bigvgan",
448
+ "no_repeat_ngram_size": 0,
449
+ "num_beam_groups": 1,
450
+ "num_beams": 1,
451
+ "num_return_sequences": 1,
452
+ "output_attentions": false,
453
+ "output_hidden_states": false,
454
+ "output_scores": false,
455
+ "pad_token_id": null,
456
+ "prefix": null,
457
+ "problem_type": null,
458
+ "pruned_heads": {},
459
+ "remove_invalid_values": false,
460
+ "repetition_penalty": 1.0,
461
+ "resblock_dilation_sizes": [
462
+ [
463
+ 1,
464
+ 3,
465
+ 5
466
+ ],
467
+ [
468
+ 1,
469
+ 3,
470
+ 5
471
+ ],
472
+ [
473
+ 1,
474
+ 3,
475
+ 5
476
+ ]
477
+ ],
478
+ "resblock_kernel_sizes": [
479
+ 3,
480
+ 7,
481
+ 11
482
+ ],
483
+ "return_dict": true,
484
+ "return_dict_in_generate": false,
485
+ "sep_token_id": null,
486
+ "suppress_tokens": null,
487
+ "task_specific_params": null,
488
+ "temperature": 1.0,
489
+ "tf_legacy_loss": false,
490
+ "tie_encoder_decoder": false,
491
+ "tie_word_embeddings": true,
492
+ "tokenizer_class": null,
493
+ "top_k": 50,
494
+ "top_p": 1.0,
495
+ "torchscript": false,
496
+ "typical_p": 1.0,
497
+ "upsample_initial_channel": 1536,
498
+ "upsample_kernel_sizes": [
499
+ 11,
500
+ 7,
501
+ 4,
502
+ 4,
503
+ 4,
504
+ 4
505
+ ],
506
+ "upsample_rates": [
507
+ 5,
508
+ 3,
509
+ 2,
510
+ 2,
511
+ 2,
512
+ 2
513
+ ],
514
+ "use_bfloat16": false,
515
+ "use_bias_at_final": false
516
+ },
517
+ "dit_config": {
518
+ "_attn_implementation_autoset": true,
519
+ "_name_or_path": "",
520
+ "add_cross_attention": false,
521
+ "architectures": null,
522
+ "bad_words_ids": null,
523
+ "begin_suppress_tokens": null,
524
+ "block_size": 24,
525
+ "bos_token_id": null,
526
+ "chunk_size_feed_forward": 0,
527
+ "cross_attention_hidden_size": null,
528
+ "decoder_start_token_id": null,
529
+ "depth": 22,
530
+ "dim": 1024,
531
+ "diversity_penalty": 0.0,
532
+ "do_sample": false,
533
+ "dropout": 0.1,
534
+ "dtype": "float32",
535
+ "early_stopping": false,
536
+ "emb_dim": 512,
537
+ "enc_attention_channels": 64,
538
+ "enc_channels": [
539
+ 256,
540
+ 256,
541
+ 256,
542
+ 256,
543
+ 768
544
+ ],
545
+ "enc_dilations": [
546
+ 1,
547
+ 2,
548
+ 3,
549
+ 4,
550
+ 1
551
+ ],
552
+ "enc_dim": 128,
553
+ "enc_emb_dim": 192,
554
+ "enc_global_context": true,
555
+ "enc_kernel_sizes": [
556
+ 5,
557
+ 3,
558
+ 3,
559
+ 3,
560
+ 1
561
+ ],
562
+ "enc_lin_neurons": 192,
563
+ "enc_res2net_scale": 2,
564
+ "enc_se_channels": 64,
565
+ "encoder_no_repeat_ngram_size": 0,
566
+ "eos_token_id": null,
567
+ "exponential_decay_length_penalty": null,
568
+ "ff_mult": 2,
569
+ "finetuning_task": null,
570
+ "forced_bos_token_id": null,
571
+ "forced_eos_token_id": null,
572
+ "head_dim": 64,
573
+ "heads": 16,
574
+ "hidden_size": 1024,
575
+ "id2label": {
576
+ "0": "LABEL_0",
577
+ "1": "LABEL_1"
578
+ },
579
+ "is_decoder": false,
580
+ "is_encoder_decoder": false,
581
+ "label2id": {
582
+ "LABEL_0": 0,
583
+ "LABEL_1": 1
584
+ },
585
+ "length_penalty": 1.0,
586
+ "look_ahead_layers": [
587
+ 10
588
+ ],
589
+ "look_backward_layers": [
590
+ 0,
591
+ 20
592
+ ],
593
+ "max_length": 20,
594
+ "max_position_embeddings": 32768,
595
+ "mel_dim": 80,
596
+ "min_length": 0,
597
+ "model_type": "qwen2_5_omni_dit",
598
+ "no_repeat_ngram_size": 0,
599
+ "num_attention_heads": 16,
600
+ "num_beam_groups": 1,
601
+ "num_beams": 1,
602
+ "num_embeds": 8193,
603
+ "num_hidden_layers": 22,
604
+ "num_return_sequences": 1,
605
+ "output_attentions": false,
606
+ "output_hidden_states": false,
607
+ "output_scores": false,
608
+ "pad_token_id": null,
609
+ "prefix": null,
610
+ "problem_type": null,
611
+ "pruned_heads": {},
612
+ "remove_invalid_values": false,
613
+ "repeats": 2,
614
+ "repetition_penalty": 1.0,
615
+ "return_dict": true,
616
+ "return_dict_in_generate": false,
617
+ "rope_theta": 10000.0,
618
+ "sep_token_id": null,
619
+ "suppress_tokens": null,
620
+ "task_specific_params": null,
621
+ "temperature": 1.0,
622
+ "tf_legacy_loss": false,
623
+ "tie_encoder_decoder": false,
624
+ "tie_word_embeddings": true,
625
+ "tokenizer_class": null,
626
+ "top_k": 50,
627
+ "top_p": 1.0,
628
+ "torchscript": false,
629
+ "typical_p": 1.0,
630
+ "use_bfloat16": false
631
+ },
632
+ "dtype": "bfloat16",
633
+ "model_type": "qwen2_5_omni_token2wav"
634
+ },
635
+ "transformers_version": "4.57.1"
636
+ }
generation_config.json ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "eos_token_id": [
4
+ 151645,
5
+ 151643
6
+ ],
7
+ "transformers_version": "4.57.1"
8
+ }
merges.txt ADDED
The diff for this file is too large to render. See raw diff
 
model-00001-of-00004.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8d0949c0440f4227a450b4e2d75e8b4eb2b3075ddc7ee772bdca04e159923d0e
3
+ size 4985055536
model-00002-of-00004.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:cbae750086e210d7a33e31553294212fc316845aa0ea480b2e4db6b86c980000
3
+ size 4991496832
model-00003-of-00004.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e06a5f17b69c011624e227c53f8e1fc6501f073aabb15bf704ffea85bae320e5
3
+ size 4991496936
model-00004-of-00004.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2ed11d51b6f333636d96dbbb12c7721bed6dbaded4518b51c5413a8cd9794fb8
3
+ size 2895740064
model.safetensors.index.json ADDED
The diff for this file is too large to render. See raw diff
 
preprocessor_config.json ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "chunk_length": 300,
3
+ "dither": 0.0,
4
+ "feature_extractor_type": "WhisperFeatureExtractor",
5
+ "feature_size": 128,
6
+ "hop_length": 160,
7
+ "image_mean": [
8
+ 0.48145466,
9
+ 0.4578275,
10
+ 0.40821073
11
+ ],
12
+ "image_processor_type": "Qwen2VLImageProcessor",
13
+ "image_std": [
14
+ 0.26862954,
15
+ 0.26130258,
16
+ 0.27577711
17
+ ],
18
+ "max_pixels": 12845056,
19
+ "merge_size": 2,
20
+ "min_pixels": 3136,
21
+ "n_fft": 400,
22
+ "n_samples": 4800000,
23
+ "nb_max_frames": 30000,
24
+ "padding_side": "right",
25
+ "padding_value": 0.0,
26
+ "patch_size": 14,
27
+ "processor_class": "Qwen2_5OmniProcessor",
28
+ "return_attention_mask": true,
29
+ "sampling_rate": 16000,
30
+ "temporal_patch_size": 2
31
+ }
special_tokens_map.json ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "additional_special_tokens": [
3
+ "<|im_start|>",
4
+ "<|im_end|>",
5
+ "<|AUDIO|>",
6
+ "<|audio_bos|>",
7
+ "<|audio_eos|>",
8
+ "<|box_end|>",
9
+ "<|quad_start|>",
10
+ "<|quad_end|>",
11
+ "<|vision_bos|>",
12
+ "<|vision_eos|>",
13
+ "<|vision_pad|>",
14
+ "<|IMAGE|>",
15
+ "<|VIDEO|>"
16
+ ],
17
+ "audio_bos_token": "<|audio_bos|>",
18
+ "audio_eos_token": "<|audio_eos|>",
19
+ "audio_token": "<|AUDIO|>",
20
+ "eos_token": {
21
+ "content": "<|im_end|>",
22
+ "lstrip": false,
23
+ "normalized": false,
24
+ "rstrip": false,
25
+ "single_word": false
26
+ },
27
+ "image_token": "<|IMAGE|>",
28
+ "pad_token": {
29
+ "content": "<|endoftext|>",
30
+ "lstrip": false,
31
+ "normalized": false,
32
+ "rstrip": false,
33
+ "single_word": false
34
+ },
35
+ "video_token": "<|VIDEO|>",
36
+ "vision_bos_token": "<|vision_bos|>",
37
+ "vision_eos_token": "<|vision_eos|>"
38
+ }
spk_dict.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:6a05609b28f5d42b7b748f0f07592545c8f1f6885b9ae8fff64baf56e86b2a18
3
+ size 259544
tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8441917e39ae0244e06d704b95b3124795cec478e297f9afac39ba670d7e9d99
3
+ size 11421870
tokenizer_config.json ADDED
@@ -0,0 +1,222 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_prefix_space": false,
3
+ "added_tokens_decoder": {
4
+ "151643": {
5
+ "content": "<|endoftext|>",
6
+ "lstrip": false,
7
+ "normalized": false,
8
+ "rstrip": false,
9
+ "single_word": false,
10
+ "special": true
11
+ },
12
+ "151644": {
13
+ "content": "<|im_start|>",
14
+ "lstrip": false,
15
+ "normalized": false,
16
+ "rstrip": false,
17
+ "single_word": false,
18
+ "special": true
19
+ },
20
+ "151645": {
21
+ "content": "<|im_end|>",
22
+ "lstrip": false,
23
+ "normalized": false,
24
+ "rstrip": false,
25
+ "single_word": false,
26
+ "special": true
27
+ },
28
+ "151646": {
29
+ "content": "<|AUDIO|>",
30
+ "lstrip": false,
31
+ "normalized": false,
32
+ "rstrip": false,
33
+ "single_word": false,
34
+ "special": true
35
+ },
36
+ "151647": {
37
+ "content": "<|audio_bos|>",
38
+ "lstrip": false,
39
+ "normalized": false,
40
+ "rstrip": false,
41
+ "single_word": false,
42
+ "special": true
43
+ },
44
+ "151648": {
45
+ "content": "<|audio_eos|>",
46
+ "lstrip": false,
47
+ "normalized": false,
48
+ "rstrip": false,
49
+ "single_word": false,
50
+ "special": true
51
+ },
52
+ "151649": {
53
+ "content": "<|box_end|>",
54
+ "lstrip": false,
55
+ "normalized": false,
56
+ "rstrip": false,
57
+ "single_word": false,
58
+ "special": true
59
+ },
60
+ "151650": {
61
+ "content": "<|quad_start|>",
62
+ "lstrip": false,
63
+ "normalized": false,
64
+ "rstrip": false,
65
+ "single_word": false,
66
+ "special": true
67
+ },
68
+ "151651": {
69
+ "content": "<|quad_end|>",
70
+ "lstrip": false,
71
+ "normalized": false,
72
+ "rstrip": false,
73
+ "single_word": false,
74
+ "special": true
75
+ },
76
+ "151652": {
77
+ "content": "<|vision_bos|>",
78
+ "lstrip": false,
79
+ "normalized": false,
80
+ "rstrip": false,
81
+ "single_word": false,
82
+ "special": true
83
+ },
84
+ "151653": {
85
+ "content": "<|vision_eos|>",
86
+ "lstrip": false,
87
+ "normalized": false,
88
+ "rstrip": false,
89
+ "single_word": false,
90
+ "special": true
91
+ },
92
+ "151654": {
93
+ "content": "<|vision_pad|>",
94
+ "lstrip": false,
95
+ "normalized": false,
96
+ "rstrip": false,
97
+ "single_word": false,
98
+ "special": true
99
+ },
100
+ "151655": {
101
+ "content": "<|IMAGE|>",
102
+ "lstrip": false,
103
+ "normalized": false,
104
+ "rstrip": false,
105
+ "single_word": false,
106
+ "special": true
107
+ },
108
+ "151656": {
109
+ "content": "<|VIDEO|>",
110
+ "lstrip": false,
111
+ "normalized": false,
112
+ "rstrip": false,
113
+ "single_word": false,
114
+ "special": true
115
+ },
116
+ "151657": {
117
+ "content": "<tool_call>",
118
+ "lstrip": false,
119
+ "normalized": false,
120
+ "rstrip": false,
121
+ "single_word": false,
122
+ "special": false
123
+ },
124
+ "151658": {
125
+ "content": "</tool_call>",
126
+ "lstrip": false,
127
+ "normalized": false,
128
+ "rstrip": false,
129
+ "single_word": false,
130
+ "special": false
131
+ },
132
+ "151659": {
133
+ "content": "<|fim_prefix|>",
134
+ "lstrip": false,
135
+ "normalized": false,
136
+ "rstrip": false,
137
+ "single_word": false,
138
+ "special": false
139
+ },
140
+ "151660": {
141
+ "content": "<|fim_middle|>",
142
+ "lstrip": false,
143
+ "normalized": false,
144
+ "rstrip": false,
145
+ "single_word": false,
146
+ "special": false
147
+ },
148
+ "151661": {
149
+ "content": "<|fim_suffix|>",
150
+ "lstrip": false,
151
+ "normalized": false,
152
+ "rstrip": false,
153
+ "single_word": false,
154
+ "special": false
155
+ },
156
+ "151662": {
157
+ "content": "<|fim_pad|>",
158
+ "lstrip": false,
159
+ "normalized": false,
160
+ "rstrip": false,
161
+ "single_word": false,
162
+ "special": false
163
+ },
164
+ "151663": {
165
+ "content": "<|repo_name|>",
166
+ "lstrip": false,
167
+ "normalized": false,
168
+ "rstrip": false,
169
+ "single_word": false,
170
+ "special": false
171
+ },
172
+ "151664": {
173
+ "content": "<|file_sep|>",
174
+ "lstrip": false,
175
+ "normalized": false,
176
+ "rstrip": false,
177
+ "single_word": false,
178
+ "special": false
179
+ }
180
+ },
181
+ "additional_special_tokens": [
182
+ "<|im_start|>",
183
+ "<|im_end|>",
184
+ "<|AUDIO|>",
185
+ "<|audio_bos|>",
186
+ "<|audio_eos|>",
187
+ "<|box_end|>",
188
+ "<|quad_start|>",
189
+ "<|quad_end|>",
190
+ "<|vision_bos|>",
191
+ "<|vision_eos|>",
192
+ "<|vision_pad|>",
193
+ "<|IMAGE|>",
194
+ "<|VIDEO|>"
195
+ ],
196
+ "audio_bos_token": "<|audio_bos|>",
197
+ "audio_eos_token": "<|audio_eos|>",
198
+ "audio_token": "<|AUDIO|>",
199
+ "bos_token": null,
200
+ "clean_up_tokenization_spaces": false,
201
+ "eos_token": "<|im_end|>",
202
+ "errors": "replace",
203
+ "extra_special_tokens": {
204
+ "audio_bos_token": "<|audio_bos|>",
205
+ "audio_eos_token": "<|audio_eos|>",
206
+ "audio_token": "<|AUDIO|>",
207
+ "image_token": "<|IMAGE|>",
208
+ "video_token": "<|VIDEO|>",
209
+ "vision_bos_token": "<|vision_bos|>",
210
+ "vision_eos_token": "<|vision_eos|>"
211
+ },
212
+ "image_token": "<|IMAGE|>",
213
+ "model_max_length": 32768,
214
+ "pad_token": "<|endoftext|>",
215
+ "processor_class": "Qwen2_5OmniProcessor",
216
+ "split_special_tokens": false,
217
+ "tokenizer_class": "Qwen2Tokenizer",
218
+ "unk_token": null,
219
+ "video_token": "<|VIDEO|>",
220
+ "vision_bos_token": "<|vision_bos|>",
221
+ "vision_eos_token": "<|vision_eos|>"
222
+ }
video_preprocessor_config.json ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "chunk_length": 300,
3
+ "crop_size": null,
4
+ "data_format": "channels_first",
5
+ "default_to_square": true,
6
+ "device": null,
7
+ "dither": 0.0,
8
+ "do_center_crop": null,
9
+ "do_convert_rgb": true,
10
+ "do_normalize": true,
11
+ "do_rescale": true,
12
+ "do_resize": true,
13
+ "do_sample_frames": false,
14
+ "feature_extractor_type": "WhisperFeatureExtractor",
15
+ "feature_size": 128,
16
+ "fps": null,
17
+ "hop_length": 160,
18
+ "image_mean": [
19
+ 0.48145466,
20
+ 0.4578275,
21
+ 0.40821073
22
+ ],
23
+ "image_std": [
24
+ 0.26862954,
25
+ 0.26130258,
26
+ 0.27577711
27
+ ],
28
+ "input_data_format": null,
29
+ "max_frames": 768,
30
+ "max_pixels": 12845056,
31
+ "merge_size": 2,
32
+ "min_frames": 4,
33
+ "min_pixels": 3136,
34
+ "n_fft": 400,
35
+ "n_samples": 4800000,
36
+ "nb_max_frames": 30000,
37
+ "num_frames": null,
38
+ "pad_size": null,
39
+ "padding_side": "right",
40
+ "padding_value": 0.0,
41
+ "patch_size": 14,
42
+ "processor_class": "Qwen2_5OmniProcessor",
43
+ "resample": 3,
44
+ "rescale_factor": 0.00392156862745098,
45
+ "return_attention_mask": true,
46
+ "return_metadata": false,
47
+ "sampling_rate": 16000,
48
+ "size": {
49
+ "longest_edge": 12845056,
50
+ "shortest_edge": 3136
51
+ },
52
+ "temporal_patch_size": 2,
53
+ "video_metadata": null,
54
+ "video_processor_type": "Qwen2VLVideoProcessor"
55
+ }
vocab.json ADDED
The diff for this file is too large to render. See raw diff