SenseVoice

阿里开源语音识别模型 · 官方链接

简介

SenseVoice 是阿里通义实验室开源的语音识别模型,支持中、英、日、粤、韩五种语言,具备情感识别和音频事件检测能力。Small 版本 ONNX 量化后可在 CPU 上实时推理。

特性

安装

# 下载 ONNX 模型
pip install onnxruntime numpy
# 从 ModelScope 下载模型
pip install modelscope
from modelscope import snapshot_download
snapshot_download("iic/SenseVoiceSmall", local_dir="./SenseVoiceSmall")
# 或从 HuggingFace
huggingface-cli download FunAudioLLM/SenseVoiceSmall

常用命令

# Python 推理示例
import onnxruntime as ort
session = ort.InferenceSession("model_quant.onnx")
# 命令行工具(需安装 sherpa-onnx)
pip install sherpa-onnx
sherpa-onnx-offline-tts --help
更多信息请访问 SenseVoice 官方网站