YiYiXu HF Staff commited on
Commit
8eb6ace
·
verified ·
1 Parent(s): a1ab3a8

Add tiny MiniMax Music 3 modular fixtures

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/tokenizer.json filter=lfs diff=lfs merge=lfs -text
condition_encoder/config.json ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_class_name": "MiniMaxMusic3ConditionEncoder",
3
+ "_diffusers_version": "0.40.0.dev0",
4
+ "condition_hidden_dim": 16,
5
+ "input_hop_length": 960,
6
+ "input_sampling_rate": 24000,
7
+ "num_condition_layers": 8,
8
+ "out_dim": 16,
9
+ "output_hop_length": 512,
10
+ "output_sampling_rate": 44100
11
+ }
condition_encoder/diffusion_pytorch_model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e2b3f5931885597a2128694ae01ecbd632ec89cc605fb8c0dcce8aa062d7ba35
3
+ size 3492
language_model/config.json ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "architectures": [
3
+ "Qwen3ForCausalLM"
4
+ ],
5
+ "attention_bias": false,
6
+ "attention_dropout": 0.0,
7
+ "bos_token_id": null,
8
+ "dtype": "float32",
9
+ "eos_token_id": null,
10
+ "head_dim": 8,
11
+ "hidden_act": "silu",
12
+ "hidden_size": 16,
13
+ "initializer_range": 0.02,
14
+ "intermediate_size": 32,
15
+ "layer_types": [
16
+ "full_attention",
17
+ "full_attention"
18
+ ],
19
+ "max_position_embeddings": 512,
20
+ "max_window_layers": 28,
21
+ "model_type": "qwen3",
22
+ "num_attention_heads": 2,
23
+ "num_hidden_layers": 2,
24
+ "num_key_value_heads": 1,
25
+ "pad_token_id": null,
26
+ "rms_norm_eps": 1e-06,
27
+ "rope_parameters": {
28
+ "rope_theta": 10000.0,
29
+ "rope_type": "default"
30
+ },
31
+ "sliding_window": null,
32
+ "tie_word_embeddings": false,
33
+ "transformers_version": "5.13.0.dev0",
34
+ "use_cache": true,
35
+ "use_sliding_window": false,
36
+ "vocab_size": 168059
37
+ }
language_model/generation_config.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "output_attentions": false,
4
+ "output_hidden_states": false,
5
+ "transformers_version": "5.13.0.dev0",
6
+ "use_cache": true
7
+ }
language_model/model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b9147f3d89ff7b5a9676a3b696d7f3cb8fadf8929bdabb98207e2b10b64b6ef6
3
+ size 21533072
modular_model_index.json ADDED
@@ -0,0 +1,103 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_blocks_class_name": "MiniMaxMusic3Blocks",
3
+ "_class_name": "MiniMaxMusic3ModularPipeline",
4
+ "_diffusers_version": "0.40.0.dev0",
5
+ "condition_encoder": [
6
+ "diffusers",
7
+ "MiniMaxMusic3ConditionEncoder",
8
+ {
9
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
10
+ "revision": null,
11
+ "subfolder": "condition_encoder",
12
+ "type_hint": [
13
+ "diffusers",
14
+ "MiniMaxMusic3ConditionEncoder"
15
+ ],
16
+ "variant": null
17
+ }
18
+ ],
19
+ "language_model": [
20
+ "transformers",
21
+ "Qwen3ForCausalLM",
22
+ {
23
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
24
+ "revision": null,
25
+ "subfolder": "language_model",
26
+ "type_hint": [
27
+ "transformers",
28
+ "Qwen3ForCausalLM"
29
+ ],
30
+ "variant": null
31
+ }
32
+ ],
33
+ "rvq_depth_decoder": [
34
+ "diffusers",
35
+ "MiniMaxMusic3RVQDepthDecoder",
36
+ {
37
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
38
+ "revision": null,
39
+ "subfolder": "rvq_depth_decoder",
40
+ "type_hint": [
41
+ "diffusers",
42
+ "MiniMaxMusic3RVQDepthDecoder"
43
+ ],
44
+ "variant": null
45
+ }
46
+ ],
47
+ "scheduler": [
48
+ "diffusers",
49
+ "FlowMatchEulerDiscreteScheduler",
50
+ {
51
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
52
+ "revision": null,
53
+ "subfolder": "scheduler",
54
+ "type_hint": [
55
+ "diffusers",
56
+ "FlowMatchEulerDiscreteScheduler"
57
+ ],
58
+ "variant": null
59
+ }
60
+ ],
61
+ "tokenizer": [
62
+ "transformers",
63
+ "Qwen2Tokenizer",
64
+ {
65
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
66
+ "revision": null,
67
+ "subfolder": "tokenizer",
68
+ "type_hint": [
69
+ "transformers",
70
+ "Qwen2Tokenizer"
71
+ ],
72
+ "variant": null
73
+ }
74
+ ],
75
+ "transformer": [
76
+ "diffusers",
77
+ "MiniMaxMusic3Transformer1DModel",
78
+ {
79
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
80
+ "revision": null,
81
+ "subfolder": "transformer",
82
+ "type_hint": [
83
+ "diffusers",
84
+ "MiniMaxMusic3Transformer1DModel"
85
+ ],
86
+ "variant": null
87
+ }
88
+ ],
89
+ "vocoder": [
90
+ "diffusers",
91
+ "MiniMaxMusic3Vocoder",
92
+ {
93
+ "pretrained_model_name_or_path": "hf-internal-testing/tiny-minimax-music3-modular-pipe",
94
+ "revision": null,
95
+ "subfolder": "vocoder",
96
+ "type_hint": [
97
+ "diffusers",
98
+ "MiniMaxMusic3Vocoder"
99
+ ],
100
+ "variant": null
101
+ }
102
+ ]
103
+ }
rvq_depth_decoder/config.json ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_class_name": "MiniMaxMusic3RVQDepthDecoder",
3
+ "_diffusers_version": "0.40.0.dev0",
4
+ "audio_vocab_size": 8,
5
+ "hidden_size": 16,
6
+ "intermediate_size": 32,
7
+ "max_position_embeddings": 16,
8
+ "num_attention_heads": 2,
9
+ "num_codebooks": 8,
10
+ "num_layers": 1
11
+ }
rvq_depth_decoder/diffusion_pytorch_model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:14def4ef335b56e8a8d1270a41243bb27a8b0bb37ae06e09eefcb2d9c3b32c34
3
+ size 21392
scheduler/scheduler_config.json ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_class_name": "FlowMatchEulerDiscreteScheduler",
3
+ "_diffusers_version": "0.40.0.dev0",
4
+ "base_image_seq_len": 256,
5
+ "base_shift": 0.5,
6
+ "invert_sigmas": true,
7
+ "max_image_seq_len": 4096,
8
+ "max_shift": 1.15,
9
+ "num_train_timesteps": 1,
10
+ "shift": 1.0,
11
+ "shift_terminal": null,
12
+ "stochastic_sampling": false,
13
+ "time_shift_type": "exponential",
14
+ "use_beta_sigmas": false,
15
+ "use_dynamic_shifting": false,
16
+ "use_exponential_sigmas": false,
17
+ "use_karras_sigmas": false
18
+ }
tokenizer/chat_template.jinja ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {%- if tools %}
2
+ {{- '<|im_start|>system\n' }}
3
+ {%- if messages[0].role == 'system' %}
4
+ {{- messages[0].content + '\n\n' }}
5
+ {%- endif %}
6
+ {{- "# Tools\n\nYou may call one or more functions to assist with the user query.\n\nYou are provided with function signatures within <tools></tools> XML tags:\n<tools>" }}
7
+ {%- for tool in tools %}
8
+ {{- "\n" }}
9
+ {{- tool | tojson }}
10
+ {%- endfor %}
11
+ {{- "\n</tools>\n\nFor each function call, return a json object with function name and arguments within <tool_call></tool_call> XML tags:\n<tool_call>\n{\"name\": <function-name>, \"arguments\": <args-json-object>}\n</tool_call><|im_end|>\n" }}
12
+ {%- else %}
13
+ {%- if messages[0].role == 'system' %}
14
+ {{- '<|im_start|>system\n' + messages[0].content + '<|im_end|>\n' }}
15
+ {%- endif %}
16
+ {%- endif %}
17
+ {%- set ns = namespace(multi_step_tool=true, last_query_index=messages|length - 1) %}
18
+ {%- for message in messages[::-1] %}
19
+ {%- set index = (messages|length - 1) - loop.index0 %}
20
+ {%- if ns.multi_step_tool and message.role == "user" and not(message.content.startswith('<tool_response>') and message.content.endswith('</tool_response>')) %}
21
+ {%- set ns.multi_step_tool = false %}
22
+ {%- set ns.last_query_index = index %}
23
+ {%- endif %}
24
+ {%- endfor %}
25
+ {%- for message in messages %}
26
+ {%- if (message.role == "user") or (message.role == "system" and not loop.first) %}
27
+ {{- '<|im_start|>' + message.role + '\n' + message.content + '<|im_end|>' + '\n' }}
28
+ {%- elif message.role == "assistant" %}
29
+ {%- set content = message.content %}
30
+ {%- set reasoning_content = '' %}
31
+ {%- if message.reasoning_content is defined and message.reasoning_content is not none %}
32
+ {%- set reasoning_content = message.reasoning_content %}
33
+ {%- else %}
34
+ {%- if '</think>' in message.content %}
35
+ {%- set content = message.content.split('</think>')[-1].lstrip('\n') %}
36
+ {%- set reasoning_content = message.content.split('</think>')[0].rstrip('\n').split('<think>')[-1].lstrip('\n') %}
37
+ {%- endif %}
38
+ {%- endif %}
39
+ {%- if loop.index0 > ns.last_query_index %}
40
+ {%- if loop.last or (not loop.last and reasoning_content) %}
41
+ {{- '<|im_start|>' + message.role + '\n<think>\n' + reasoning_content.strip('\n') + '\n</think>\n\n' + content.lstrip('\n') }}
42
+ {%- else %}
43
+ {{- '<|im_start|>' + message.role + '\n' + content }}
44
+ {%- endif %}
45
+ {%- else %}
46
+ {{- '<|im_start|>' + message.role + '\n' + content }}
47
+ {%- endif %}
48
+ {%- if message.tool_calls %}
49
+ {%- for tool_call in message.tool_calls %}
50
+ {%- if (loop.first and content) or (not loop.first) %}
51
+ {{- '\n' }}
52
+ {%- endif %}
53
+ {%- if tool_call.function %}
54
+ {%- set tool_call = tool_call.function %}
55
+ {%- endif %}
56
+ {{- '<tool_call>\n{"name": "' }}
57
+ {{- tool_call.name }}
58
+ {{- '", "arguments": ' }}
59
+ {%- if tool_call.arguments is string %}
60
+ {{- tool_call.arguments }}
61
+ {%- else %}
62
+ {{- tool_call.arguments | tojson }}
63
+ {%- endif %}
64
+ {{- '}\n</tool_call>' }}
65
+ {%- endfor %}
66
+ {%- endif %}
67
+ {{- '<|im_end|>\n' }}
68
+ {%- elif message.role == "tool" %}
69
+ {%- if loop.first or (messages[loop.index0 - 1].role != "tool") %}
70
+ {{- '<|im_start|>user' }}
71
+ {%- endif %}
72
+ {{- '\n<tool_response>\n' }}
73
+ {{- message.content }}
74
+ {{- '\n</tool_response>' }}
75
+ {%- if loop.last or (messages[loop.index0 + 1].role != "tool") %}
76
+ {{- '<|im_end|>\n' }}
77
+ {%- endif %}
78
+ {%- endif %}
79
+ {%- endfor %}
80
+ {%- if add_generation_prompt %}
81
+ {{- '<|im_start|>assistant\n' }}
82
+ {%- if enable_thinking is defined and enable_thinking is false %}
83
+ {{- '<think>\n\n</think>\n\n' }}
84
+ {%- endif %}
85
+ {%- endif %}
tokenizer/tokenizer.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:93623af029cdc69b87f2864d3b2cc2424fdf16684f15e139b5b9d08ec34ced91
3
+ size 11423701
tokenizer/tokenizer_config.json ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "add_prefix_space": false,
3
+ "backend": "tokenizers",
4
+ "bos_token": null,
5
+ "clean_up_tokenization_spaces": false,
6
+ "eos_token": "<|im_end|>",
7
+ "errors": "replace",
8
+ "is_local": false,
9
+ "local_files_only": false,
10
+ "model_max_length": 131072,
11
+ "pad_token": "<|endoftext|>",
12
+ "split_special_tokens": false,
13
+ "tokenizer_class": "Qwen2Tokenizer",
14
+ "unk_token": null
15
+ }
transformer/config.json ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_class_name": "MiniMaxMusic3Transformer1DModel",
3
+ "_diffusers_version": "0.40.0.dev0",
4
+ "attention_head_dim": 8,
5
+ "condition_dim": 16,
6
+ "ff_inner_dim": 32,
7
+ "fourier_embedding_dim": 8,
8
+ "in_channels": 8,
9
+ "num_attention_heads": 2,
10
+ "num_layers": 2,
11
+ "rotary_dim": 4
12
+ }
transformer/diffusion_pytorch_model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:f64a7159bad770566d091d02235e84d9b971d6e0d2544247e7186a69b50afba1
3
+ size 33320
vocoder/config.json ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_class_name": "MiniMaxMusic3Vocoder",
3
+ "_diffusers_version": "0.40.0.dev0",
4
+ "decoder_hidden_dim": 8,
5
+ "decoder_input_dim": 8,
6
+ "latent_channels": 8,
7
+ "sampling_rate": 44100,
8
+ "upsampling_ratios": [
9
+ 2,
10
+ 2
11
+ ]
12
+ }
vocoder/diffusion_pytorch_model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d479a6a24d746a3cadd0d46b4606bdfbf98bc8d0440b774ece8bdc3c6e95077e
3
+ size 11024