sherpa-ncnn

k2-fsaApache-2.0长期未更新

基于新一代 Kaldi 和 ncnn 的离线实时语音识别与语音活动检测引擎,无需联网即可在手机、嵌入式板卡和桌面端跑起来。

Real-time speech recognition and voice activity detection (VAD) using next-gen Kaldi with ncnn without Internet connection. Support iOS, Android, Linux, macOS, Windows, Raspberry Pi, VisionFive2, LicheePi4A etc.

v2.1.15发布于 2025-09-16 08:09 UTC1,800star222fork同步于 2026-11-07 07:30 UTC

怎么上手

由 README 提炼,执行前请确认
README 未给出具体安装命令,需参考文档 https://k2-fsa.github.io/sherpa/ncnn/index.html 从源码编译
硬件要求按 README 说明

README 未说明显存或具体 GPU 型号要求;支持 x86、x86_64、arm32、arm64、riscv64 架构,可运行于 Linux、macOS、Windows、Android、iOS、NodeJS、WebAssembly、树莓派、RV1126、LicheePi4A、VisionFive 2、旭日X3派等平台。

下载:源码 zip·GitHub Releases(安装包)本站不镜像安装包

项目说明

由 README 自动翻译提炼

基于新一代 Kaldi 与 ncnn 的离线实时语音识别、语音合成与 VAD 工具,可跑在手机和嵌入式板子上

基于新一代 Kaldi 和 ncnn 的离线实时语音识别与语音活动检测引擎,无需联网即可在手机、嵌入式板卡和桌面端跑起来。

核心能力

  • 用 ncnn 推理,不依赖 PyTorch 等框架
  • 支持流式语音识别、TTS 与 VAD 三类功能
  • 提供 C/C++/Python/Go/C#/Kotlin/JS/Swift 接口
  • 可静态编译,产物只依赖系统库
  • 覆盖 Android、iOS、WebAssembly、树莓派、RISC-V 等平台

容易踩的坑

需自行从 releases/tag/models 下载预训练模型,仓库不含模型文件;安装与构建步骤不在 README 中,需查阅在线文档;README 未说明默认端口等运行参数

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

最近发版

5 个版本v2.1.15
  1. v2.1.15最新正式版2025-09-16 · 2025-09-16 08:09 UTC

    What's Changed

    Full Changelog: https://github.com/k2-fsa/sherpa-ncnn/compare/v2.1.14...v2.1.15

  2. asr-models2025-09-13 · 2025-09-13 10:48 UTC

    这个版本没有写更新说明。

  3. v2.1.142025-09-05 · 2025-09-05 15:43 UTC
    查看更新说明

    What's Changed

    Full Changelog: https://github.com/k2-fsa/sherpa-ncnn/compare/v2.1.13...v2.1.14

  4. v2.1.132025-09-03 · 2025-09-03 15:42 UTC
    查看更新说明

    What's Changed

    New Contributors

    Full Changelog: https://github.com/k2-fsa/sherpa-ncnn/compare/v2.1.11...v2.1.13

  5. tts-models2025-08-15 · 2025-08-15 10:08 UTC

    这个版本没有写更新说明。

用户点评

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

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

    README 原文

    未翻译

    Supported functions

    Real-time Speech recognitionSpeech synthesisVoice activity detection
    ✔️✔️✔️

    Supported platforms

    ArchitectureAndroidiOSWindowsmacOSlinux
    x64✔️✔️✔️✔️
    x86✔️✔️
    arm64✔️✔️✔️✔️✔️
    arm32✔️✔️
    riscv64✔️

    Supported programming languages

    1. C++2. C3. Python4. JavaScript
    ✔️✔️✔️✔️
    5. Go6. C#7. Kotlin8. Swift
    ✔️✔️✔️✔️

    It also supports WebAssembly.

    Introduction

    This repository supports running the following functions locally

    • Streaming speech-to-text (i.e., real-time speech recognition)
    • Text to speech (e.g., vits models from piper)
    • VAD (e.g., silero-vad)

    on the following platforms and operating systems:

    with the following APIs

    • C++, C, Python, Go, C#
    • Kotlin
    • JavaScript
    • Swift

    We support all platforms that ncnn supports.

    Everything can be compiled from source with static link. The generated executable depends only on system libraries.

    HINT: It does not depend on PyTorch or any other inference frameworks other than ncnn.

    Please see the documentation https://k2-fsa.github.io/sherpa/ncnn/index.html for installation and usages, e.g.,

    • How to build an Android app
    • How to download and use pre-trained models

    We provide a few YouTube videos for demonstration about real-time speech recognition with sherpa-ncnn using a microphone:

    Links for pre-built Android APKs

    DescriptionURL
    Streaming speech recognitionAddress

    Links for pre-trained models

    https://github.com/k2-fsa/sherpa-ncnn/releases/tag/models

    Useful links

    How to reach us

    Please see https://k2-fsa.github.io/sherpa/social-groups.html for 新一代 Kaldi 微信交流群 and QQ 交流群.

    See also