33 releases (5 breaking)

new 0.6.1 Dec 25, 2024
0.5.2-beta.0 Dec 25, 2024
0.5.1 Oct 25, 2024
0.1.7-beta.0 Jul 13, 2024

#135 in Audio

Download history 39/week @ 2024-09-15 128/week @ 2024-09-29 2/week @ 2024-10-06 642/week @ 2024-10-13 358/week @ 2024-10-20 33/week @ 2024-10-27 10/week @ 2024-11-03 1/week @ 2024-11-10 6/week @ 2024-11-17 1/week @ 2024-11-24 264/week @ 2024-12-01 476/week @ 2024-12-08 159/week @ 2024-12-15 439/week @ 2024-12-22

1,338 downloads per month

MIT license

2.5MB
58K SLoC

C++ 35K SLoC // 0.0% comments Kotlin 10K SLoC // 0.1% comments Java 3.5K SLoC // 0.0% comments Dart 3K SLoC // 0.0% comments C 2.5K SLoC // 0.2% comments Rust 2K SLoC // 0.0% comments Batch 1K SLoC Prolog 269 SLoC Python 149 SLoC // 0.1% comments TypeScript 60 SLoC Shell 37 SLoC Forge Config 1 SLoC

sherpa-rs

Crates docs.rs License

Rust bindings to sherpa-onnx

Features

  • Spoken language detection
  • Speaker embedding (labeling)
  • Speaker diarization
  • Speech to text
  • Text to speech
  • Text punctuation
  • Voice activity detection
  • Audio tagging
  • Keyword spotting

Supported Platforms

  • Windows
  • Linux
  • macOS
  • Android
  • IOS

Install

cargo add sherpa-rs

Build

Please see BUILDING.md.

Feature flags

  • cuda: enable CUDA support
  • directml: enable DirectML support
  • tts: enable TTS
  • download-binaries: use prebuilt sherpa-onnx libraries for faster builds. cached.
  • static: use static sherpa-onnx libraries and link them statically.
  • sys: expose raw c bindings (sys crate)

Docs

See sherpa/intro.html

Examples

See examples

Models

All pretrained models available at sherpa/onnx/pretrained_models

Dependencies

~0.6–4.5MB
~69K SLoC