AV ASR Timestamp
Full speech-to-text with timestamps, all local — AV ASR Timestamp
- audio
- text
- json_result
- asr_result
This is the workhorse of ComfyUI-AV-FunASR. Feed it audio, and it transcribes the speech and gives you word-level timestamps - the raw material that the pack's subtitle formatter needs. If you're making subtitles, this is almost certainly the first node in the chain you touch. If your workflow needs a transcript at all, this is where it happens, entirely on your machine - no API key, no cloud upload, and no dependence on an English-audience model ecosystem.
It belongs to the avenstack "AV" (audio-visual) family of nodes, built around Alibaba's FunASR toolkit and models downloaded from ModelScope (China's answer to HuggingFace). That lineage matters, because the default model here is very much Chinese-first.
How it works
The node takes your AUDIO input, resamples it to 16kHz mono, saves it as a temp WAV, and hands it to FunASR's Paraformer model (the speech_seaco_paraformer_large_asr_nat-zh-cn-16k-common variant) with an FSMN voice-activity-detection model attached. The VAD finds the speech segments, the Paraformer transcribes them, and the result comes back with timestamps per word.
The model is loaded once and cached in memory (infer_ins_cache), so the first run is slow - it loads a multi-GB model - and subsequent runs are much faster. It runs on GPU if one is available and falls back to CPU otherwise; on CPU, count on it being slow.
The inputs that matter
- audio - any ComfyUI AUDIO output. A
LoadAudionode (core or from the VHS pack) or a video node that emits audio will do. - batch_size_s - default 300, range 30–300. This is how many seconds of audio FunASR processes per batch. Higher uses more VRAM but fewer round-trips; lower is gentler on memory. If you're GPU-poor or hitting OOM on long audio, knock it down.
- unload_model - default
false. Set it totrueand the node frees the model from VRAM after running, which is handy when you're chaining into heavy image/video generation and need the memory back.
The outputs
- text - the plain transcript, as a string. Wire it to any text node for display or reuse.
- json_result - the full result as JSON, including the
timestamparray with start/end milliseconds per word. The pack's example workflows preview this with ComfyUI Easy Use's "showAnything" node so you can sanity-check the alignment before formatting subtitles. - asr_result - the custom ASRRESULT type. This is the one that matters: it's what AV Format to Subtitle consumes. Nothing else in ComfyUI understands this type, so don't lose track of which wire goes where.
The honest caveats
The default model is zh-cn - Chinese speech recognition. It's genuinely good at Chinese; for English audio it will produce garbage. The pack's source has an internal map with English Paraformer models, but this node hardcodes the Chinese one, so you'd have to edit nodes.py to swap in an English model. If you're transcribing English, this isn't the node for you.
Also note the punctuation model is disabled (punc_model=None in the source). The transcript comes back as raw text - the sentence-splitting and punctuation you'd want in a final subtitle are the formatter node's job, not this one's.
Installing and first run
cd ComfyUI/custom_nodes
git clone https://github.com/avenstack/ComfyUI-AV-FunASR.git
cd ComfyUI-AV-FunASR
pip install -r requirements.txt
restart ComfyUI (or use ComfyUI Manager and search "ComfyUI-AV-FunASR"). Then the real work: download the Paraformer and FSMN-VAD models from modelscope.cn - links are in the README - and place them under ComfyUI/models/ASR/FunASR/iic/ with the exact names from the README's tree. Nothing downloads automatically.
Troubleshooting
ModuleNotFoundError: funasr/torchaudio-requirements.txtdoesn't list these even though the code imports them.pip install funasr torchaudiofixes it.- Model errors on first run - the model files are missing or in the wrong folder. The node creates the directory but never downloads; the README's
iic/...tree is the contract. - Slow first run - that's the model loading, not a hang. Let it finish once, then it caches.
- English in, nonsense out - see the caveats above; it's the model, not you.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| audio | AUDIO | — | |
| batch_size_s | INT | 30030–300 | — |
| unload_model | BOOLEAN | false | — |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| text | STRING | — |
| json_result | STRING | — |
| asr_result | ASRRESULT | — |