Nodes/comfyui-mimoasr/🎯 MiMo ASR Loader
ComfyUI Node

🎯 MiMo ASR Loader

The 8B model that brings serious speech recognition to ComfyUI β€” if you survive the install

By aadebugerΒ·Created 3 months agoΒ·Updated 3 months agoΒ· 0
🎯 MiMo ASR Loader
    • model
    β—„model_path./models/MiMo-V2.5-ASRβ–Ί
    β—„tokenizer_path./models/MiMo-Audio-Tokenizerβ–Ί
    β—„repo_pathβ–Ί
    β—„force_reloadfalseβ–Ί

    If you've been feeding audio into Whisper outside ComfyUI and pasting the text back in, this is the node that ends that dance. 🎯 MiMo ASR Loader loads Xiaomi's MiMo-V2.5-ASR, an 8B end-to-end speech recognition model, plus its audio tokenizer, and hands the pair to the companion Transcribe node as a single MIMO_ASR_MODEL wire. What you get for the effort: native Mandarin-English code-switching, real coverage of Wu, Cantonese, Hokkien, Sichuanese and other Chinese dialects, song lyrics, and punctuation generated by the model itself rather than bolted on afterward.

    A quick honesty note up front: this is not a two-minute ComfyUI Manager install. It's an 8B model with hard dependency pins, and the README is unusually blunt about it. If you're on a 24 GB card with a CUDA toolkit, it works - but budget an afternoon the first time.

    How it works

    The upstream MimoAudio class isn't pip-installable - the repo's imports only resolve when the repo root is on sys.path. So this loader takes a path to a local clone of XiaomiMiMo/MiMo-V2.5-ASR and injects it into sys.path at runtime. Everything heavy (torch, transformers) is imported lazily, only when you actually run the node, so ComfyUI doesn't crawl at startup.

    Two design choices matter in practice. First, loading the 8B model takes 30–60 seconds on a 3090 and eats roughly 17 GB of VRAM, so the loader keeps a process-wide cache keyed by the three paths. Rerun the same workflow and it's instant; change any path and it reloads. Second, the upstream __init__ takes positional args even though the HF card shows kwargs - this node calls it positionally, so it works against both old and new upstream commits.

    The inputs that matter

    • model_path - local folder with the MiMo-V2.5-ASR safetensors. Use an absolute path; the default ./models/... only works from ComfyUI's working directory, which is where "path does not exist" errors come from.
    • tokenizer_path - local folder for MiMo-Audio-Tokenizer. Same advice: absolute path.
    • repo_path - the clone of the upstream repo, i.e. the folder that contains src/mimo_audio/. Leave it blank and it falls back to the MIMO_ASR_REPO env var; set neither and you get a helpful error instead of a crash.
    • force_reload (optional) - bypass the in-memory cache if you've swapped weights mid-session.

    The single output, model, is a custom MIMO_ASR_MODEL type that only feeds into MiMoASRTranscribe - you can't read text out of the loader, so don't look for it.

    Installing it - the real way

    Manager can install the pack itself (search "comfyui-mimoasr"), but it won't do the rest. Full walkthrough is in the README; the order that works:

    cd ComfyUI/custom_nodes
    git clone https://github.com/aadebuger/ComfyUI-MiMoASR.git
    
    # 1. Clone the upstream repo (MimoAudio is not pip-installable)
    git clone https://github.com/XiaomiMiMo/MiMo-V2.5-ASR.git /opt/repos/MiMo-V2.5-ASR
    # if src/mimo_audio/ is missing: git submodule update --init --recursive
    
    # 2. Weights: ~16-32 GB on disk, point HF_HOME at a big disk first
    export HF_HOME=/big_disk/hf_cache
    hf download XiaomiMiMo/MiMo-V2.5-ASR --local-dir /big_disk/models/MiMo-V2.5-ASR
    hf download XiaomiMiMo/MiMo-Audio-Tokenizer --local-dir /big_disk/models/MiMo-Audio-Tokenizer
    
    # 3. In ComfyUI's venv: pinned transformers + deps
    uv pip install "transformers==4.49.0" "tokenizers>=0.21,<0.22" --force-reinstall
    uv pip install accelerate librosa scipy zhon torchaudio
    
    # 4. flash-attn - required, no SDPA fallback in the tokenizer encoder
    uv pip install flash-attn==2.7.4.post1   # only if cu12 + torch 2.6 + py3.12
    # otherwise build from source: 20-40 min, see README Step 5
    

    Then launch ComfyUI with HF_HOME and MIMO_ASR_REPO exported. The two dependency pins are the traps. transformers must be exactly 4.49.0 - newer versions changed the tied-weights API and the model breaks with AttributeError: 'MiMoAudioTokenizer' has no attribute 'all_tied_weights_keys'. And flash-attn is mandatory, not optional, because the audio tokenizer calls flash_attn_varlen_func with no fallback; a silently-failed build shows up as TypeError: 'NoneType' object is not callable. Since the whole node pack lives in your ComfyUI venv with zero isolation (the same structural problem the ecosystem keeps tripping on), a transformers downgrade can break other nodes that want >=4.57 - read the README's compatibility table before you commit.

    Category🎯 MiMo ASR

    Inputs (4)

    NameTypeDefaultDescription
    model_pathSTRING./models/MiMo-V2.5-ASRLocal path to the MiMo-V2.5-ASR weights (downloaded from XiaomiMiMo/MiMo-V2.5-ASR).
    tokenizer_pathSTRING./models/MiMo-Audio-TokenizerLocal path to the MiMo-Audio-Tokenizer (downloaded from XiaomiMiMo/MiMo-Audio-Tokenizer).
    repo_pathSTRINGPath to a clone of XiaomiMiMo/MiMo-V2.5-ASR (the folder containing src/mimo_audio/). Leave blank to read from the MIMO_ASR_REPO env var.
    force_reloadoptBOOLEANfalseBypass the in-memory model cache.

    Outputs (1)

    NameTypeDescription
    modelMIMO_ASR_MODELβ€”