nemo_automodel.components.models.qwen2_5_omni.state_dict_adapter
nemo_automodel.components.models.qwen2_5_omni.state_dict_adapter
Module Contents
Classes
Data
API
Bases: StateDictAdapter
HF Qwen2.5-Omni checkpoint adapter (thinker-only path).
HF Qwen/Qwen2.5-Omni-* checkpoints store keys under three top-level
prefixes: thinker.*, talker.*, token2wav.*. For ASR/text
fine-tuning we only train the Thinker, so this adapter:
- on
from_hf: dropstalker.*andtoken2wav.*keys and strips thethinker.prefix so keys align with our NeMo Thinker class. - on
to_hf: re-adds thethinker.prefix so the saved checkpoint can be merged back with the original talker/token2wav shards.
Qwen2.5-Omni-3B is dense (no MoE), so no expert grouping logic is needed — this is a thin key-renaming adapter.
Namespace a native key the way the HF omni checkpoint expects.
PEFT adapter keys keep their base_model.model. outer prefix, so for
those the thinker. namespace goes inside it — matching how PEFT
names modules on the actual HF omni model.
Remove the omni checkpoint’s thinker. namespace.
Namespace adapter_config.json target_modules under thinker..
Without it, PEFT’s suffix matching on the full omni model also hits the talker’s structurally identical submodules and injects adapter modules the saved file has no weights for.