Skip to content

Add Speech Translator sample app (on-device zh<->en speech-to-speech translation) #330

Open

Description

Summary

Add a new sample application, Speech Translator, under samples/apps/speech-translator/: an on-device Chinese <-> English speech-to-speech translator running on the Snapdragon NPU (HTP) through QAI AppBuilder.

Details

  • Pipelines: zh2en (Zipformer ASR -> OpusMT zh->en -> PiperTTS-EN) and en2zh (Zipformer ASR -> OpusMT en->zh -> MeloTTS-ZH).
  • Input from microphone, WAV file (--audio) or text (--text, skips ASR); output is the translated text plus a WAV file with optional playback.
  • All models are QNN context binaries (.bin), auto-downloaded on first use, chosen by chip (Snapdragon X Elite / X2 Elite).
  • Self-contained single file (SpeechTranslator.py), import-safe, usable as a library via Init / Inference / Release.

Scope

  • New: samples/apps/speech-translator/{SpeechTranslator.py, README.md, requirements.txt}
  • Docs: add the app to samples/apps/README.md and samples/README.md.
  • run_inference.py needs no change (it only launches single-model scripts under samples/models/).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions