FunASR

modelscopeMIT活跃维护

开源语音识别工具包,覆盖训练、推理、流式 ASR、VAD、标点恢复和说话人分离全流程,并提供 OpenAI 兼容与 MCP 服务接口。

Open-source speech recognition toolkit for training, inference, streaming ASR, VAD, punctuation, speaker diarization pipelines, and OpenAI-compatible/MCP serving.

v1.4.24发布于 2026-11-08 05:12 UTC20,981star +24 / 7 天2,116fork同步于 2026-11-10 05:22 UTC

怎么上手

由 README 提炼,执行前请确认
pip install torch torchaudio
pip install funasr
硬件要求按 README 说明

README 未给出具体显存要求;CPU 可跑(SenseVoiceSmall 示例用 device="cpu"),GPU 需先按 NVIDIA 驱动安装对应 PyTorch CUDA wheel,并用 torch.cuda.is_available() 确认后再用 device="cuda"。

纯 CPU 可运行需要 CUDA多卡 / 张量并行有 Docker 镜像
下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

工业级语音识别工具包,覆盖离线、流式与边缘部署的 ASR 全流程

开源语音识别工具包,覆盖训练、推理、流式 ASR、VAD、标点恢复和说话人分离全流程,并提供 OpenAI 兼容与 MCP 服务接口。

核心能力

  • 用 AutoModel 串联 VAD、ASR、标点与说话人流水线
  • 支持 Paraformer 流式识别,按 chunk 逐块喂音频
  • 提供 SenseVoiceSmall 多语种识别并输出情感与音频事件标签
  • 用 CAM++ 提取说话人嵌入并对 VAD 分段聚类编号
  • 支持 vLLM 批量加速与 OpenAI 兼容、MCP 服务化部署

容易踩的坑

必须先装匹配的 PyTorch 和 torchaudio,再装 funasr,否则 GPU 不可用;模型首次运行会从 ModelScope/HuggingFace 下载权重,需联网;Silero VAD 需额外执行 pip install "funasr[silero]";Nano 与 MLT-Nano 是不同 checkpoint,语言覆盖不可混用。

内容由模型根据 README 生成,可能不完整或不准确,以官方文档为准。看原文 README

最近发版

5 个版本v1.4.24
  1. v1.4.24最新正式版2026-11-08 · 2026-11-08 05:12 UTC

    Final Publication Acceptance

    GitHub Release and PyPI 1.4.24 are both published. Both distributions were downloaded from official PyPI and match the accepted GitHub assets by SHA-256 and size:

    • funasr-1.4.24-py3-none-any.whl: 1015161 bytes; SHA-256 c2678ebb77c7dfba1d85a79749ad30b441159b87d17eff901e0c6ad4ebcc06c7.
    • funasr-1.4.24.tar.gz: 1081873 bytes; SHA-256 522dcb493be75aa57d8183e6197b4431c5e02fade689eda90cfd91f76e5edb57.

    The official sdist download resumed after a transport timeout using an exact HTTP 206 range; the original partial and failure receipts were retained. The wheel was not downloaded again and PyPI was not re-uploaded.

    FunASR 1.4.24

    Source: 20f26b7c4905d010768ec91206149df2a90104b6 / tag v1.4.24.

    Fix

    Deliver #3852: ignore empty non-linguistic symbols instead of allowing the character/phoneme tokenizer scan to stall. Deliver #3853: correct variance normalization for padded utterances. Deliver #3854: preserve valid CIF output and gradients when a batch mixes utterances with zero and nonzero fires, including dynamic ONNX batches.

    Compatibility: checkpoints trained with both norm_means=True and norm_vars=True require recognition-quality reevaluation after the corrected normalization. norm_vars=False remains the default. Local checkpoint round trips are not a pretrained recognition-quality evaluation.

    This does not claim pretrained ASR quality, Windows/NPU acceptance or a full repository-suite result.

    The separately released funasr-onnx==0.4.9 and funasr-torch==0.1.6 have their own tags, packages and verification. This root-package release does not republish them. PR #3848 is not included. This release does not claim every EOS path is fixed.

    Verification Scope

    • New candidate release/README checks: 45 cases, 0 skips. Related docs/package/release checks: 104 cases, 2 explicitly recorded skips; no failures or errors.
    • Actual installed candidate and final wheels: 37 passing CPU/ONNX cases each covering tokenizer symbols, variance normalization, local checkpoint round trips, repository-audio inference and CIF dynamic batches. The 27 CUDA parametrizations are intentionally skipped locally and separately covered by bound prior hardware evidence. All 439 package files and 13 entrypoints match the accepted source.
    • Reused 24 tokenizer/CTC cases, 34 FP32 CIF cases and four normalizer repository-audio cases including six CUDA inference calls on L20Z, after rehashing 33,870 sealed evidence files and 18 helpers and binding the exact source to the installed wheel. The 106-case normalizer acceptance retains 102 unchanged cases and four repaired audio checks. Earlier harness/TF32-fixture failures remain preserved; they are not silently discarded or counted as passes. This release performs no new GPU execution and makes no pretrained-quality or full-Paraformer-export claim.
    • The local candidate build and candidate/final package checks, tests and installations use private HOME/cache directories and separate network namespaces with verified network-unreachable probes. The final-tag build runs in GitHub Actions under the existing release workflow, not the local network namespace. No newly downloaded pretrained weights are used. The separately reported #3848 test-download incident is not an authorization or validation input for this release.
    • Release-head CI was accepted from actual logs and recorded artifact inventories. The roadmap job checked out the pure head; the other head workflows used GitHub's temporary PR merge commit. Both checkout trees were verified against the exact candidate. Merged-main and final-tag source checkouts were separately verified. The main API-doc workflow also checked out only the retained Chinese API page from gh-pages into previous-pages; this separate documentation input was recorded, not treated as inference source. The newly downloaded Python wheel/sdist p
  2. v1.4.232026-11-07 · 2026-11-07 05:04 UTC
    查看更新说明

    Final Publication Acceptance

    GitHub Release and PyPI 1.4.23 are both published. Both distributions were downloaded from official PyPI and match the accepted GitHub assets by SHA-256 and size:

    • funasr-1.4.23-py3-none-any.whl: 1014744 bytes; SHA-256 28f6696ad882d1273c371675ac35b427d2e548a2e736e42ef16d56cd96d17785.
    • funasr-1.4.23.tar.gz: 1075334 bytes; SHA-256 89a2e1ba43468391bd603e952dd6fe306020719d82f99cd15bbdd2b130afd2f3.

    FunASR 1.4.23

    Source: efe5504e388613e5298e1f93d5ca9f861700b489 / tag v1.4.23.

    Fix

    Deliver #3849: initialize the valid-frame cursor for the online frontend with lfr_m=lfr_n=1, and avoid redundant empty final offline VAD chunks for exact input multiples. Deliver #3783: supplied token_list IDs map to model pieces before text conversion. With a supplied vocabulary, SentencePiece ids2tokens returns list[str] pieces; use tokens2text for text. Without a supplied vocabulary, legacy decoded-text behavior is preserved.

    This does not claim pretrained ASR quality, Windows/NPU acceptance or a full repository-suite result.

    The separately released funasr-onnx==0.4.9 and funasr-torch==0.1.6 have their own tags, packages and verification. This root-package release does not republish them. PR #3848 is not included. Explicit streaming-empty-input and nonempty tails producing zero features are outside the #3849 hardware acceptance; this release does not claim every EOS path is fixed.

    Verification Scope

    • New candidate release/README checks: 45 cases, 0 skips. Related docs/package/release checks: 104 cases, 2 explicitly recorded skips; no failures or errors.
    • Actual installed candidate and final wheels: 61 CPU contracts each covering no-LFR feature/chunk handling, analytic VAD finalization and tokenizer vocabulary semantics. Local tiny SentencePiece and controlled acoustic fixtures are not pretrained quality or hardware inference. All 439 package files and 13 entrypoints match the accepted source.
    • Reused 16 direct FP32/BF16 frontend cases, 12 FP32 VAD cases and 12 FP32/BF16 tokenizer/decoder cases from #3849/#3783 after rehashing their sealed raw receipts and binding the exact source to the installed wheel. The earlier frontend run's six failed VAD cases remain recorded; the later corrected VAD run passed all 12. This release performs no new GPU execution and makes no pretrained-quality claim.
    • The local candidate build and candidate/final package checks, tests and installations use private HOME/cache directories and separate network namespaces with verified network-unreachable probes. The final-tag build runs in GitHub Actions under the existing release workflow, not the local network namespace. No newly downloaded pretrained weights are used. The separately reported #3848 test-download incident is not an authorization or validation input for this release.
    • Exact release-head and merged-main CI were accepted from their actual logs, with artifact inventories recorded. The final-tag workflow and the newly downloaded Python wheel/sdist passed byte/metadata/archive/source checks, strict Twine, offline installation, actual import and CLI checks.
    • The 10 unchanged runtime archives reuse complete cache bytes freshly hashed against new asset metadata and the existing runtime source release. They were not rebuilt or re-executed. SHA256SUMS covers all 12 payloads. This is not a new runtime-hardware claim.
    • No full repository-suite, production-environment upgrade, Nano benchmark or adoption/growth claim is made.

    What's Changed

  3. runtime-onnx-v0.4.9FunASR ONNX runtime v0.4.92026-11-06 · 2026-11-06 22:50 UTC
    查看更新说明

    Standalone funasr-onnx 0.4.9. This is not a new root funasr release.

    This release includes the already accepted offline VAD fix from #3846: empty or sub-frame inputs preserve one result per input without invoking ONNX Runtime for zero-frame features. It also includes #3847: empty punctuation chunks return without tokenization or inference while preserving streaming cache state.

    The hosted standalone-package workflow now runs the #3847 regression on Python 3.11 and 3.12. Exact-head and merged-main CI each passed 9 release contracts, 6 offline VAD cases, 5 empty-punctuation cases, the existing installed/runtime regressions, Product site, browser, documentation, build, Twine, and clean package checks. Local fail-closed private-network validation also passed 45 source/contract tests, 38 installed-wheel tests, and installed-sdist origin verification.

    These are CPU runtime-wrapper fixes. No model weights changed, no model was downloaded or loaded for this release, and no ASR-quality claim is made.

    Install: pip install -U funasr-onnx==0.4.9.

    Assets: wheel, sdist, and SHA256SUMS covering those two payloads. PyPI is the final upload step and is accepted only after downloading the official bytes.

  4. v1.4.222026-11-05 · 2026-11-05 17:05 UTC
    查看更新说明

    Final Publication Acceptance

    GitHub Release and PyPI 1.4.22 are both published. Both distributions were downloaded from official PyPI and match the accepted GitHub assets by SHA-256 and size:

    • funasr-1.4.22-py3-none-any.whl: 1014515 bytes; SHA-256 83525bb5f185e29032f840f232eb226080ffa37e9d86988893faa225e609dc35.
    • funasr-1.4.22.tar.gz: 1069356 bytes; SHA-256 db8c67f2bf36df25bd26e724d7a432ec04667e877cd81119d8d388a58ae82eb0.

    FunASR 1.4.22

    Source: dedefbf643289098e5473fa0cc6ce085e2e9533e / tag v1.4.22.

    Fix

    Deliver #3841: merge_length_s passed to generate() takes precedence over construction-time/default merge length. Deliver #3833: the dynamic silence schedule is evaluated per frame using the current speech-segment duration, not accumulated chunk time; the fixed-threshold opt-out remains available.

    This does not claim pretrained ASR quality, Windows/NPU acceptance or a full repository-suite result.

    The separately released funasr-onnx==0.4.8 and funasr-torch==0.1.6 have their own tags, packages and verification. This root-package release does not republish them. The separately reproduced no-LFR frontend exception is not fixed by this release.

    Verification Scope

    • New candidate release/README checks: 45 cases, 0 skips. Related docs/package/release checks: 104 cases, 2 explicitly recorded skips; no failures or errors.
    • Actual installed candidate wheel: 9 CPU unit contracts covering per-call/construction/default merge length and dynamic/fixed VAD scheduling. Their mocked boundaries are not hardware inference. All 439 package files and 13 entrypoints match the accepted source.
    • Reused the 32 AutoModel and 24 VAD real L20Z FP32 analytic integration cases from #3841/#3833 after rehashing their sealed raw receipts and binding the exact source to the installed wheel. Their separate prior runs record 216521 CUDA events in total. This is not a new GPU execution, BF16 run or pretrained-quality validation.
    • Exact release-head and merged-main CI were accepted with actual logs/artifacts. The final-tag workflow and the newly downloaded Python wheel/sdist passed byte/metadata/archive/source checks, strict Twine, offline installation, actual import and CLI checks.
    • The 10 unchanged runtime archives reuse complete cache bytes freshly hashed against new asset metadata and the existing runtime source release. They were not rebuilt or re-executed. SHA256SUMS covers all 12 payloads. This is not a new runtime-hardware claim.
    • No full repository-suite, production-environment upgrade, Nano benchmark or adoption/growth claim is made.

    What's Changed

    New Contributors

  5. runtime-torch-v0.1.6FunASR Torch runtime v0.1.62026-11-05 · 2026-11-05 11:37 UTC
    查看更新说明

    Standalone Torch Runtime 0.1.6

    Includes #3842: the standalone CMVN reader now accepts blank lines and raises a file-specific ValueError for missing or truncated statistics. Valid float64 statistics and shipped feature output remain unchanged.

    python -m pip install -U "funasr-torch>=0.1.6"
    

    funasr-torch is distributed separately from funasr. This is a CPU parser/package fix, not a model-weight or ASR-accuracy update.

    The wheel and source distribution contain the accepted runtime source. Validation covers both standalone frontends, blank/truncated/missing/compact CMVN input, shipped am.mvn feature equality, package contracts, build/install metadata, and exact-head/main CI. It does not claim model inference, new GPU execution, Windows/NPU acceptance, or a full suite.

    Assets: wheel, source distribution, and SHA256SUMS covering both payloads. GitHub asset bytes are verified before publication; PyPI upload and official payload-byte verification follow separately. The root FunASR latest release remains v1.4.21.

用户点评

登录用户的真实使用记录,可按版本和硬件筛选
共 0 条

    还没有人点评。第一个说出真实体验的人最有价值。

    README 原文

    未翻译

    (简体中文|English|日本語|한국어)


    Quick Start

    Native Transformers

    For Fun-ASR-Nano transcription with the Hugging Face API, start with the Transformers 5.17.0 CPU quickstart. No FunASR toolkit or remote Python code is needed.

    Space · Notebook · Python / batch examples

    FunASR toolkit and pipelines

    Open In Colab

    No local setup? Open the Colab quickstart to transcribe a public sample or upload your own audio in a browser.

    Found FunASR useful? Star the project so more builders can find it.

    # CPU-only installs can use the default PyPI wheels.
    pip install torch torchaudio
    pip install funasr
    

    For GPU quickstarts, install the PyTorch and torchaudio wheels that match your NVIDIA driver from pytorch.org before installing FunASR. After installation, confirm the GPU is visible:

    python - <<'PY'
    import torch
    print(torch.cuda.is_available())
    PY
    

    Only use device="cuda" when this prints True; otherwise use device="cpu" or reinstall PyTorch with the correct CUDA wheel.

    FunASR toolkit GPU example: Fun-ASR-Nano (Chinese, English, Japanese, and Chinese dialect groups and regional accents; the separate native Transformers CPU path is linked above):

    from funasr import AutoModel
    
    model = AutoModel(model="FunAudioLLM/Fun-ASR-Nano-2512", device="cuda")
    result = model.generate(input="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/ASR/test_audio/asr_example_zh.wav")
    print(result[0]["text"])
    

    For the separate 31-language checkpoint, use Fun-ASR-MLT-Nano-2512. Language coverage is checkpoint-specific, so Nano and MLT-Nano should be treated as distinct model choices.

    For a CPU-first example with five-language ASR plus emotion and audio-event tags, use SenseVoiceSmall. The pipeline below combines it with FSMN-VAD and CAM++ for speaker-aware VAD segments; these are not native speaker outputs of the SenseVoiceSmall checkpoint. See the SenseVoice paper, Hugging Face checkpoint, and GGUF edge checkpoint.

    from funasr import AutoModel
    from funasr.utils.postprocess_utils import rich_transcription_postprocess
    
    model = AutoModel(model="iic/SenseVoiceSmall", vad_model="fsmn-vad", spk_model="cam++", device="cpu")
    result = model.generate(
        input="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/ASR/test_audio/asr_example_zh.wav",
        batch_size_s=300,
    )
    
    # The AutoModel pipeline returns VAD segments with speaker ids and timestamps:
    for seg in result[0]["sentence_info"]:
        print(f"[{seg['start']/1000:.1f}s] Speaker {seg['spk']}: {rich_transcription_postprocess(seg['sentence'])}")
    

    This prints each returned segment's start time in seconds, anonymous speaker index, and text with SenseVoice tags removed. Text and segment boundaries depend on the audio and checkpoint; no fixed transcript is asserted here.

    CAM++ extracts spk_embedding vectors. AutoModel clusters those embeddings and assigns speaker indices to VAD segments. Indices are local to a recording, not known-person identities. See the SDK contract for the component and result boundaries. Change to device="cuda" only after verifying a compatible GPU environment as described above.

    Scale & deploy the flagship

    At scale, accelerate Fun-ASR-Nano with vLLM (batch processing):

    from funasr.auto.auto_model_vllm import AutoModelVLLM
    
    model = AutoModelVLLM(model="FunAudioLLM/Fun-ASR-Nano-2512", tensor_parallel_size=1)
    results = model.generate(["audio1.wav", "audio2.wav"], language="auto")
    

    Deploy as API server: Local SenseVoice CPU recipe · Nano GPU serving and pinned vLLM setup

    Use with AI agents: MCP Server for Claude/Cursor · OpenAI API for LangChain/Dify/AutoGen

    Use with voice agents: OpenClaw realtime plugin (experimental; requires an unmerged upstream SDK patch) · Hugging Face speech-to-speech with SenseVoice (merged source checkout; not in v1.0.0)

    Why FunASR?

    FunASR is a toolkit: choose the task, checkpoint, and runtime separately. Support in one model or adapter does not imply support in every serving backend.

    TaskCheckpoint or pipelineRuntime entrypointImportant limitation
    File transcription with emotion/event tagsSenseVoiceSmallPython AutoModel, CPU or GPUFive-language checkpoint; tags do not identify speakers.
    LLM-based file transcriptionFun-ASR-NanoAutoModel; split-engine AutoModelVLLM for the documented GPU pathBase Nano covers zh/en/ja and Chinese dialects/accents; timestamp support depends on checkpoint and path.
    Broader multilingual transcriptionFun-ASR-MLT-NanoPython AutoModelSeparate 31-language checkpoint; do not transfer its coverage to base Nano.
    Chunked live transcriptionParaformer-zh-streamingStreaming SDK or runtime WebSocket serviceUse the streaming checkpoint and per-session cache, not an offline checkpoint.
    Speaker-aware file transcriptionSenseVoiceSmall + FSMN-VAD + CAM++AutoModel with VAD and embedding clusteringAnonymous indices within a recording, not enrolled-speaker identification.
    Joint text, timestamps, and speakersMOSS-Transcribe-Diarize, third-party OpenMOSSFunASR adapter or upstream backend in the MOSS guideOffline, recording-local anonymous labels; no external VAD/speaker pipeline for its unified path.
    Native CPU/edge transcriptionFun-ASR-Nano or SenseVoiceSmall GGUFllama.cpp runtimeRequires matching converted weights; GGUF is not a Python AutoModel checkpoint.

    See the Model Zoo and deployment matrix for checkpoint, interface, and licensing boundaries. Benchmark on your own audio and hardware before choosing a runtime.

    Trying FunASR for the first time? Use the Colab quickstart before setting up a local environment. Choosing a first model? Start with the model selection guide. Planning a switch from Whisper or a cloud ASR provider? Use the migration guide and benchmark example to test representative audio, map features, and roll out safely.


    Installation

    pip install funasr
    
    git clone https://github.com/modelscope/FunASR.git && cd FunASR
    pip install -e ./
    

    Requirements: Python ≥ 3.8. Install PyTorch + torchaudio first (pytorch.org), then pip install funasr.


    Model Zoo

    This list includes third-party models. OpenMOSS publishes MOSS-Transcribe-Diarize; FunASR provides an adapter, not ownership of its weights. Its unified path is offline, with anonymous labels scoped to each recording, not realtime or known-person identification. Model licenses are separate from the toolkit's MIT license.

    ModelTaskLanguagesParamsLinks
    Fun-ASR-NanoASRzh/en/ja + Chinese dialects and accents800M⭐ HF / Transformers · HF / FunASR GGUF
    Fun-ASR-MLT-NanoASR31 languages800M⭐ 🤗
    SenseVoiceSmallASR + emotion + eventszh/en/ja/ko/yue234M⭐ 🤗 GGUF paper
    MOSS-Transcribe-DiarizeThird-party OpenMOSS: offline ASR + timestamps + anonymous speakersSee official cardSee official card🤗 guide
    Paraformer-zhASR + timestampszh/en220M⭐ 🤗
    Paraformer-zh-streamingStreaming ASRzh/en220M⭐ 🤗
    Qwen3-ASRASR, 52 languagesmultilingual1.7Busage
    GLM-ASR-NanoASR, 17 languagesmultilingual1.5Busage
    Whisper-large-v3ASR + translationmultilingual1550Musage
    Whisper-large-v3-turboASR + translationmultilingual809Musage
    ct-puncPunctuationzh/en290M⭐ 🤗
    fsmn-vadVADzh/en0.4M⭐ 🤗
    cam++Speaker embeddings (pipeline component)—7.2M⭐ 🤗
    emotion2vec+largeEmotion recognition—300M⭐ 🤗

    Usage

    Python tutorial · SDK parameters and outputs · Training · Model registration

    from funasr import AutoModel
    
    # Chinese production (VAD + ASR + punctuation + speaker)
    model = AutoModel(model="paraformer-zh", vad_model="fsmn-vad", punc_model="ct-punc", spk_model="cam++", device="cuda")
    result = model.generate(input="https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/ASR/test_audio/asr_example_zh.wav", hotword="关键词 20")
    
    # Optional Silero VAD (install first: python -m pip install "funasr[silero]")
    model = AutoModel(
        model="paraformer-zh", vad_model="silero-vad", device="cuda",
        vad_kwargs={"silero_threshold": 0.5, "silero_min_silence_duration_ms": 100},
    )
    result = model.generate(input="audio.wav")
    
    # Streaming real-time (feed audio chunk by chunk)
    import soundfile as sf
    model = AutoModel(model="paraformer-zh-streaming", device="cuda")
    audio, sr = sf.read("speech.wav", dtype="float32")   # 16 kHz mono
    chunk_size = [0, 10, 5]                               # 600 ms chunks
    chunk_stride = chunk_size[1] * 960
    cache = {}
    n_chunks = (len(audio) - 1) // chunk_stride + 1
    for i in range(n_chunks):
        chunk = audio[i * chunk_stride : (i + 1) * chunk_stride]
        res = model.generate(input=chunk, cache=cache, is_final=(i == n_chunks - 1),
                             chunk_size=chunk_size, encoder_chunk_look_back=4, decoder_chunk_look_back=1)
        if res[0]["text"]:
            print(res[0]["text"], end="", flush=True)
    
    # Emotion recognition
    model = AutoModel(model="emotion2vec_plus_large", device="cuda")
    result = model.generate(input="audio.wav", granularity="utterance")
    

    CLI (Agent-Friendly)

    # Transcribe audio (simplest)
    funasr audio.wav
    
    # JSON output (for AI agents)
    funasr audio.wav --output-format json
    
    # SRT subtitles
    funasr audio.wav --output-format srt --output-dir ./subs
    
    # Speaker diarization + timestamps
    funasr audio.wav --spk --timestamps -f json
    
    # Choose model and language
    funasr audio.wav --model paraformer --language zh
    
    # Batch transcribe
    funasr *.wav --output-format srt --output-dir ./output
    

    Available models: sensevoice (default), paraformer, paraformer-en, fun-asr-nano


    Deploy

    Start a local SenseVoice CPU service from a fresh directory in a POSIX shell with Python 3.11. This installs the PyPI release into a separate environment, not this source checkout. Keep the unauthenticated service on loopback; use the security guide before exposing it to other clients.

    python3.11 -m venv .venv-funasr-http
    . .venv-funasr-http/bin/activate
    python -m pip install torch torchaudio
    python -m pip install funasr fastapi uvicorn python-multipart
    python -m pip check
    funasr-server --host 127.0.0.1 --port 8000 --model sensevoice --device cpu
    

    Wait for model download and server startup. In a second terminal, use the same directory and curl 7.76+ to download a public Chinese audio sample and transcribe it. The request uses the preloaded model; no fixed transcript or speaker labels are promised.

    curl --fail --location https://isv-data.oss-cn-hangzhou.aliyuncs.com/ics/MaaS/ASR/test_audio/BAC009S0764W0121.wav -o sample.wav && \
    curl --fail-with-body http://127.0.0.1:8000/v1/audio/transcriptions \
      -F [email protected] \
      -F model=sensevoice \
      -F response_format=verbose_json
    

    For offline joint ASR and anonymous speaker labels (moss-transcribe-diarize), prepare the separate environment in the MOSS service, Docker, Kubernetes, vLLM, SGLang, LocalAI, and FunClip guide →. It is an alternative service, not another command in the CPU environment. Stop the CPU service before reusing port 8000. For Nano GPU serving, follow the pinned split-engine guide and inspect the actual backend logs; selecting a model does not by itself prove that vLLM was loaded.

    # Docker streaming service
    docker pull registry.cn-hangzhou.aliyuncs.com/funasr_repo/funasr:funasr-runtime-sdk-online-cpu-0.1.12
    

    CPU / Edge — llama.cpp / GGUF (no GPU, no Python)

    Run SenseVoice / Paraformer / Fun-ASR-Nano as a single self-contained binary on CPU and edge devices — this is to FunASR what whisper.cpp is to Whisper, but with ~3× lower CER than whisper.cpp on Chinese. Built-in FSMN-VAD, no Python at runtime.

    # Linux / macOS: run from the extracted release directory
    bash download-funasr-model.sh sensevoice ./gguf        # or: paraformer | nano
    ./llama-funasr-sensevoice -m ./gguf/sensevoice-small-q8.gguf --vad ./gguf/fsmn-vad.gguf -a audio.wav
    # → 欢迎大家来体验达摩院推出的语音识别模型
    
    # Windows PowerShell: run from the extracted archive root (with the `hf` CLI installed)
    hf download FunAudioLLM/SenseVoiceSmall-GGUF sensevoice-small-q8.gguf --local-dir .\gguf
    hf download FunAudioLLM/fsmn-vad-GGUF fsmn-vad.gguf --local-dir .\gguf
    .\llama-funasr-sensevoice.exe -m .\gguf\sensevoice-small-q8.gguf --vad .\gguf\fsmn-vad.gguf -a audio.wav
    # Use the windows-x64-vulkan package with a current AMD, Intel, or NVIDIA Vulkan driver:
    .\llama-funasr-sensevoice.exe -m .\gguf\sensevoice-small-q8.gguf --vad .\gguf\fsmn-vad.gguf -a audio.wav --backend vulkan
    # Use the windows-x64-cuda package on RTX 30-class GPUs:
    .\llama-funasr-sensevoice.exe -m .\gguf\sensevoice-small-q8.gguf --vad .\gguf\fsmn-vad.gguf -a audio.wav --backend cuda
    

    Use funasr-llamacpp-linux-x64-vulkan.tar.gz on Linux GPU systems with a working Vulkan driver/ICD:

    ./llama-funasr-sensevoice -m ./gguf/sensevoice-small-q8.gguf --vad ./gguf/fsmn-vad.gguf -a audio.wav --backend vulkan
    

    The Windows Vulkan ZIP uses the system Vulkan loader supplied by the GPU driver; installing the Vulkan SDK is only necessary when building from source. Both Vulkan packages currently accelerate SenseVoiceSmall.

    Tagged releases provide two Windows CUDA packages. The standard windows-x64-cuda ZIP targets CUDA architecture 86, while windows-x64-cuda-blackwell targets architecture 120 (sm_120) for RTX 50 / Blackwell GPUs. Both ZIPs bundle the required cuBLAS DLLs and use the static MSVC runtime, so users need a compatible NVIDIA driver but not a separate CUDA Toolkit installation. CI verifies the architecture and package boundary; it does not prove inference on physical Blackwell hardware.

    Prebuilt binaries: Releases · v0.2.6 · Linux Vulkan tarball · Windows Vulkan zip · Windows CUDA zip · Windows Blackwell CUDA zip · Download & quickstart: funasr.com/deploy/llama-cpp · GGUF models: Hugging Face · Docs & benchmarks: runtime/llama.cpp/

    OpenAI API example → · Gradio demo → · Client recipes → · JavaScript/TypeScript recipes → · Kubernetes template → · Workflow recipes → · Postman collection → · OpenAPI spec → · Security guide → · Deployment matrix → · Deployment docs → · Agent integration →


    Benchmark

    The historical benchmark report and split-engine measurements retain their original results. They are separate records, not universal speed rankings or production capacity guarantees.

    Use the RTFx and reproducibility notes to compare checkpoint/revision, audio set, hardware, batching, warmup, timing scope, and CER/WER. Offline throughput is not streaming latency. The migration benchmark example helps measure your own recordings with the same evaluation scope.


    What's new

    • MOSS-Transcribe-Diarize brings long-form ASR, timestamps, and anonymous speaker labels to FunASR services, Docker, Kubernetes, vLLM/SGLang workflows, and FunClip. Deploy MOSS ->
    • FunASR 1.4.24 ignores empty non-linguistic symbols to prevent tokenizer loops, fixes padded variance normalization, and prevents CIF crashes in mixed batches containing zero-fire samples. Fix #3852, fix #3853, fix #3854. A checkpoint trained with both norm_means=True and norm_vars=True needs recognition-quality reevaluation because normalized features change; norm_vars=False remains the default. Install with python -m pip install -U "funasr==1.4.24". Release and verification scope -> FunASR 1.4.23 fixes the online frontend cursor for lfr_m=lfr_n=1 and redundant empty final offline VAD chunks. With a supplied token_list, SentencePiece ids2tokens returns model pieces; use tokens2text for text. Without token_list, legacy text decoding is unchanged. Fix #3849, fix #3783. Release and verification scope -> FunASR 1.4.22 honors per-call merge_length_s and evaluates dynamic VAD silence thresholds per frame using the current segment duration, preserving the fixed-threshold opt-out. Fix #3841, fix #3833. Release and verification scope -> FunASR 1.4.21 preserves the streaming punctuation cache on empty or whitespace chunks; nonempty inference is unchanged. Fix #3824. Release and verification scope -> FunASR 1.4.20 preserves the original optional speaker dependency failure in a chained ImportError when spk_model is requested, while ASR-only construction remains available. Fix #3819. Release and verification scope -> FunASR 1.4.19 handles empty-token Paraformer batches, enforces max_speakers for automatic clustering, and adds validated JSON-object --hf_overrides support to realtime WebSocket serving. Release and verification scope -> Previous release FunASR 1.4.18 fixes cross-script hotword misreplacement, filtered-token timestamp alignment, and Chinese VAD sentence/speaker drift. Release and verification scope -> Earlier release: FunASR 1.4.17 adds explicit PCM16 input and improves timestamp, hotword, speaker-sample-rate, and long-segment streaming handling. Release and verification scope -> Earlier release: FunASR 1.4.16 preserves explicit VAD, punctuation, and speaker-model device placement across inference calls, and adds tested native Transformers adoption guides. Release and verification scope ->
    • Native Transformers: Released 5.17.0 supports Fun-ASR-Nano with the official -hf checkpoint, CPU examples and a notebook. Get started ->

    See GitHub Releases for the complete changelog and downloadable assets.


    Community

    Start with troubleshooting before reporting a problem. Include your exact model, runtime, environment and a minimal reproduction.

    📖 Documentation🐛 Issues
    💬 Discussions🤗 HuggingFace
    🤝 Contributing🌐 funasr.com
    🗺️ Repository roles & roadmap📈 Growth plan
    🧩 Community projects💡 Use-case showcase

    Star History

    License

    Citations

    @inproceedings{gao2023funasr,
      author={Zhifu Gao and others},
      title={FunASR: A Fundamental End-to-End Speech Recognition Toolkit},
      booktitle={INTERSPEECH},
      year={2023}
    }