Repository navigation
feat: add whisper STT extension using faster-whisper - #1984
Conversation
- Implements text-to-speech using NVIDIA Riva Speech Skills - Supports streaming synthesis with gRPC - Includes comprehensive tests and documentation - Follows TTS2 interface pattern Closes TEN-framework#1964
- Implements text-to-speech using Speechmatics TTS API - Supports low-latency streaming synthesis (sub-150ms) - Includes 4 voice options (UK and US English) - Comprehensive tests and documentation - Follows TTS2 HTTP interface pattern Closes TEN-framework#1965
- Implements ASR extension for OpenAI Whisper model - Uses faster-whisper library (4x faster than openai/whisper) - Supports all Whisper model sizes (tiny to large-v3) - CPU and GPU execution with multiple compute types - 99+ languages support with auto-detection - Translation to English capability - VAD filtering with Silero VAD - Auto-reconnection with exponential backoff - Audio dumping for debugging - Keep mode buffer strategy for timestamp accuracy - 25 unit tests with mock-based testing - Comprehensive documentation and examples Closes TEN-framework#1969
|
your folder is wrong. it should start with ai_agents folder instead of agents folder. pls kindly help fix it. |
Hi @plutoless, Thank you for the review! I've checked the PR and the extension files are already in the correct path:
This matches the structure referenced in #2005. The files have been in this location since the PR was created (commit 1f7d959). Could you please verify on your end? The PR should be ready for review. Thank you! |
please check the ci result, especially for AI Agents Build & Test ci task. you will need to fix the format, lint and test issues before merging. you may refer to this pr for how we fixed relevant ci task for nvidia extension |
|
to run lint property. pls run |
…-framework into feature/whisper-stt # Please enter a commit message to explain why this merge is necessary, # especially if it merges an updated upstream into a topic branch. # # Lines starting with '#' will be ignored, and an empty message aborts # the commit.
Extension dependencies (pydantic, numpy, faster-whisper) are not installed during the lint phase, causing false positive import errors. Disabling E0401 allows pylint to focus on actual code quality issues. Tested locally: score improved from 9.49/10 to 10.00/10
|
LGTM thank you for the PR! |
Description
This PR adds a Whisper STT (Speech-to-Text) extension for the TEN Framework using the faster-whisper library.
Closes #1969
Features
AsyncASRBaseExtensionfollowing TEN Framework patternsImplementation Details
Architecture
WhisperSTTExtension- Main ASR extension classWhisperClient- Handles faster-whisper model and inferenceWhisperSTTConfig- Pass-through params design for flexibilityFiles Added (14 files, 1,324 lines)
whisper_stt_python/extension.py- Main extension implementationwhisper_stt_python/whisper_client.py- Faster-whisper client wrapperwhisper_stt_python/config.py- Configuration managementwhisper_stt_python/reconnect_manager.py- Auto-reconnection logicwhisper_stt_python/addon.py- Extension entry pointwhisper_stt_python/const.py- Constantswhisper_stt_python/manifest.json- Extension metadatawhisper_stt_python/property.json- Default configurationwhisper_stt_python/requirements.txt- Dependencieswhisper_stt_python/README.md- Comprehensive documentationwhisper_stt_python/tests/test_config.py- Config tests (10 tests)whisper_stt_python/tests/test_extension.py- Extension tests (15 tests)Testing
Configuration Example
{ "params": { "model": "base", "device": "cpu", "compute_type": "int8", "language": "en", "task": "transcribe", "sample_rate": 16000 } }