Skip to content

Add vad_threshold parameter to AssemblyAI STT plugin#4880

Open
AhmadIbrahiim wants to merge 3 commits intolivekit:mainfrom
AhmadIbrahiim:add-assemblyai-vad-threshold
Open

Add vad_threshold parameter to AssemblyAI STT plugin#4880
AhmadIbrahiim wants to merge 3 commits intolivekit:mainfrom
AhmadIbrahiim:add-assemblyai-vad-threshold

Conversation

@AhmadIbrahiim
Copy link
Contributor

Summary

  • Add support for the vad_threshold parameter from AssemblyAI's streaming API
  • This allows users to configure VAD sensitivity (0-1 range) for different audio environments

Changes

  • Added vad_threshold to STTOptions dataclass
  • Added vad_threshold parameter to STT.__init__()
  • Added vad_threshold to STT.update_options() and SpeechStream.update_options()
  • Include vad_threshold in WebSocket connection config

API Reference

From AssemblyAI's docs:

The threshold for voice activity detection (VAD). A value between 0 and 1 that determines how sensitive the VAD is. Lower values make the VAD more sensitive, meaning it will detect quieter speech. Higher values make the VAD less sensitive. The default value is 0.5.

Closes #4879

Add support for the vad_threshold parameter from AssemblyAI's streaming
API. This allows users to configure VAD sensitivity (0-1 range) for
different audio environments.

Closes livekit#4879
Add unit tests covering:
- Default value (NOT_GIVEN)
- Setting value in constructor
- Boundary values (0 and 1)
- Dynamic updates via update_options
- Interaction with other options
- Partial updates
@AhmadIbrahiim
Copy link
Contributor Author

AhmadIbrahiim commented Feb 18, 2026

Hi @theomonnom @davidzhao 👋

This PR adds support for the vad_threshold parameter from AssemblyAI's streaming API. We need this to configure VAD sensitivity for different audio environments.

Would appreciate a review when you have a moment. Thanks!

@chenghao-mou
Copy link
Member

/test-stt

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add vad_threshold parameter support to AssemblyAI STT plugin

2 participants