| { |
| "toolchain_version": "0.6.8", |
| "vendor": "Meta", |
| "family": "Llama-3.2", |
| "name": "Llama-3.2-3B-Instruct-4bit", |
| "size": "3B", |
| "quantization": "uint4", |
| "repo": "mlx-community/Llama-3.2-3B-Instruct-4bit", |
| "use_cases": [], |
| "model_type": "language_model", |
| "model_config": { |
| "model_config": { |
| "embedding_config": { |
| "type": "MLXQuantizedTiedEmbeddingConfig", |
| "input_scale": null, |
| "logit_soft_cap": null, |
| "group_size": 64, |
| "embedding_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "transformer_config": { |
| "global_rope_config": { |
| "type": "LlamaRoPEConfig", |
| "precision": "bfloat16", |
| "base": 500000.0, |
| "max_sequence_length": 131072, |
| "scaling_factor": 32.0, |
| "original_context_length": 8192, |
| "low_frequency_factor": 1.0, |
| "high_frequency_factor": 4.0 |
| }, |
| "local_rope_config": null, |
| "layer_configs": [ |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| }, |
| { |
| "pre_mixer_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mixer_config": { |
| "type": "AttentionConfig", |
| "qkv_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "out_projection_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "query_norm_config": null, |
| "key_norm_config": null, |
| "num_heads": 24, |
| "num_groups": 8, |
| "head_dim": 128, |
| "is_causal": true, |
| "scale": null, |
| "sliding_window_size": null, |
| "logit_soft_cap": null, |
| "has_sinks": false, |
| "has_qkv_biases": false, |
| "has_out_biases": false, |
| "has_gate": false, |
| "partial_rope_dim": null |
| }, |
| "post_mixer_norm_config": null, |
| "pre_mlp_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "mlp_config": { |
| "type": "DenseMLPConfig", |
| "linear_config": { |
| "type": "MLXQuantizedLinearConfig", |
| "group_size": 64, |
| "weight_quantization_mode": "uint4", |
| "activation_quantization_mode": null, |
| "activation_precision": "bfloat16" |
| }, |
| "activation": { |
| "type": "SiLU", |
| "alpha": 1.0 |
| }, |
| "has_up_biases": false, |
| "has_down_biases": false, |
| "gate_clipping": null, |
| "up_clipping": null |
| }, |
| "post_mlp_norm_config": null |
| } |
| ], |
| "output_norm_config": { |
| "scale_precision": "bfloat16", |
| "accumulation_precision": "float32", |
| "epsilon": 1e-05, |
| "scale_offset": null, |
| "upcast_mode": "only_normalization", |
| "subtract_mean": false, |
| "use_bias": false |
| }, |
| "model_dim": 3072, |
| "hidden_dim": 8192, |
| "context_length": 131072 |
| }, |
| "vocab_size": 128256 |
| }, |
| "message_processor_config": { |
| "prompt_template": "{{- bos_token }}\n{%- if custom_tools is defined %}\n {%- set tools = custom_tools %}\n{%- endif %}\n{%- if not tools_in_user_message is defined %}\n {%- set tools_in_user_message = true %}\n{%- endif %}\n{%- if not date_string is defined %}\n {%- if strftime_now is defined %}\n {%- set date_string = strftime_now(\"%d %b %Y\") %}\n {%- else %}\n {%- set date_string = \"26 Jul 2024\" %}\n {%- endif %}\n{%- endif %}\n{%- if not tools is defined %}\n {%- set tools = none %}\n{%- endif %}\n\n{#- This block extracts the system message, so we can slot it into the right place. #}\n{%- if messages[0]['role'] == 'system' %}\n {%- set system_message = messages[0]['content']|trim %}\n {%- set messages = messages[1:] %}\n{%- else %}\n {%- set system_message = \"\" %}\n{%- endif %}\n\n{#- System message #}\n{{- \"<|start_header_id|>system<|end_header_id|>\\n\\n\" }}\n{%- if tools is not none %}\n {{- \"Environment: ipython\\n\" }}\n{%- endif %}\n{{- \"Cutting Knowledge Date: December 2023\\n\" }}\n{{- \"Today Date: \" + date_string + \"\\n\\n\" }}\n{%- if tools is not none and not tools_in_user_message %}\n {{- \"You have access to the following functions. To call a function, please respond with JSON for a function call.\" }}\n {{- 'Respond in the format {\"name\": function name, \"parameters\": dictionary of argument name and its value}.' }}\n {{- \"Do not use variables.\\n\\n\" }}\n {%- for t in tools %}\n {{- t | tojson(indent=4) }}\n {{- \"\\n\\n\" }}\n {%- endfor %}\n{%- endif %}\n{{- system_message }}\n{{- \"<|eot_id|>\" }}\n\n{#- Custom tools are passed in a user message with some extra guidance #}\n{%- if tools_in_user_message and not tools is none %}\n {#- Extract the first user message so we can plug it in here #}\n {%- if messages | length != 0 %}\n {%- set first_user_message = messages[0]['content']|trim %}\n {%- set messages = messages[1:] %}\n {%- else %}\n {{- raise_exception(\"Cannot put tools in the first user message when there's no first user message!\") }}\n{%- endif %}\n {{- '<|start_header_id|>user<|end_header_id|>\\n\\n' -}}\n {{- \"Given the following functions, please respond with a JSON for a function call \" }}\n {{- \"with its proper arguments that best answers the given prompt.\\n\\n\" }}\n {{- 'Respond in the format {\"name\": function name, \"parameters\": dictionary of argument name and its value}.' }}\n {{- \"Do not use variables.\\n\\n\" }}\n {%- for t in tools %}\n {{- t | tojson(indent=4) }}\n {{- \"\\n\\n\" }}\n {%- endfor %}\n {{- first_user_message + \"<|eot_id|>\"}}\n{%- endif %}\n\n{%- for message in messages %}\n {%- if not (message.role == 'ipython' or message.role == 'tool' or 'tool_calls' in message) %}\n {{- '<|start_header_id|>' + message['role'] + '<|end_header_id|>\\n\\n'+ message['content'] | trim + '<|eot_id|>' }}\n {%- elif 'tool_calls' in message %}\n {%- if not message.tool_calls|length == 1 %}\n {{- raise_exception(\"This model only supports single tool-calls at once!\") }}\n {%- endif %}\n {%- set tool_call = message.tool_calls[0].function %}\n {{- '<|start_header_id|>assistant<|end_header_id|>\\n\\n' -}}\n {{- '{\"name\": \"' + tool_call.name + '\", ' }}\n {{- '\"parameters\": ' }}\n {{- tool_call.arguments | tojson }}\n {{- \"}\" }}\n {{- \"<|eot_id|>\" }}\n {%- elif message.role == \"tool\" or message.role == \"ipython\" %}\n {{- \"<|start_header_id|>ipython<|end_header_id|>\\n\\n\" }}\n {%- if message.content is mapping or message.content is iterable %}\n {{- message.content | tojson }}\n {%- else %}\n {{- message.content }}\n {%- endif %}\n {{- \"<|eot_id|>\" }}\n {%- endif %}\n{%- endfor %}\n{%- if add_generation_prompt %}\n {{- '<|start_header_id|>assistant<|end_header_id|>\\n\\n' }}\n{%- endif %}\n", |
| "output_parser_regex": null, |
| "system_role_name": "system", |
| "user_role_name": "user", |
| "assistant_role_name": "assistant", |
| "eos_token": "<|eot_id|>", |
| "bos_token": "<|begin_of_text|>", |
| "default_system_prompt": null |
| }, |
| "generation_config": { |
| "stop_token_ids": [ |
| 128001, |
| 128008, |
| 128009 |
| ], |
| "temperature": 0.6, |
| "top_k": 50, |
| "top_p": 0.9, |
| "min_p": null, |
| "banned_tokens": null |
| } |
| }, |
| "grammar_start_tokens": [] |
| } |