LFM2-8B-A1B-ONNX / config.json
mlabonne's picture
optimize onnx exports + reduce file sizes with QMoE ops (#1)
bf78ab5
{
"architectures": [
"Lfm2MoeForCausalLM"
],
"bos_token_id": 1,
"conv_L_cache": 3,
"conv_bias": false,
"dtype": "bfloat16",
"eos_token_id": 7,
"hidden_size": 2048,
"initializer_range": 0.02,
"intermediate_size": 7168,
"layer_types": [
"conv",
"conv",
"full_attention",
"conv",
"conv",
"conv",
"full_attention",
"conv",
"conv",
"conv",
"full_attention",
"conv",
"conv",
"conv",
"full_attention",
"conv",
"conv",
"conv",
"full_attention",
"conv",
"conv",
"full_attention",
"conv",
"conv"
],
"max_position_embeddings": 128000,
"model_type": "lfm2_moe",
"moe_intermediate_size": 1792,
"norm_eps": 1e-05,
"norm_topk_prob": true,
"num_attention_heads": 32,
"num_dense_layers": 2,
"num_experts": 32,
"num_experts_per_tok": 4,
"num_hidden_layers": 24,
"num_key_value_heads": 8,
"pad_token_id": 0,
"rope_parameters": {
"rope_theta": 1000000.0,
"rope_type": "default"
},
"routed_scaling_factor": 1.0,
"transformers_version": "5.0.0.dev0",
"use_cache": true,
"use_expert_bias": true,
"vocab_size": 65536,
"transformers.js_config": {
"use_external_data_format": {
"model.onnx": 22,
"model_fp16.onnx": 9,
"model_q4.onnx": 3,
"model_q4f16.onnx": 3
},
"kv_cache_dtype": {
"q4f16": "float16",
"fp16": "float16"
}
}
}