Studio: route lfm2_moe (LFM2-8B-A1B) to transformers 5.3.0

LFM2-8B-A1B and any other lfm2_moe checkpoint were missing from the
transformers tier tables, so they fell through to the default 4.57.x
sidecar, which does not register lfm2_moe and errors with
"not supported yet in transformers==4.57.6". Only lfm2_vl was listed.

Add Lfm2MoeForCausalLM / lfm2_moe to the 5.3.0 tier (lfm2_moe is
registered in transformers 5.3.0). get_transformers_tier now returns
530 for LFM2-8B-A1B and the model loads and trains as expected.
This commit is contained in:
Daniel Han 2026-07-09 14:29:07 +00:00
parent b5aef63c03
commit 567dedd3d6

View file

@ -173,6 +173,7 @@ _TRANSFORMERS_530_ARCHITECTURES: set[str] = {
"Qwen3MoeForCausalLM",
"Qwen3NextForCausalLM",
"Glm4MoeLiteForCausalLM",
"Lfm2MoeForCausalLM",
"Lfm2VlForConditionalGeneration",
}
_TRANSFORMERS_530_MODEL_TYPES: set[str] = {
@ -183,6 +184,7 @@ _TRANSFORMERS_530_MODEL_TYPES: set[str] = {
"qwen3_moe",
"qwen3_next",
"glm4_moe_lite",
"lfm2_moe",
"lfm2_vl",
}