straight-lighter-73455
10/04/2025, 4:55 PMtall-airline-16756
10/04/2025, 4:55 PMtall-airline-16756
10/04/2025, 4:56 PMstraight-lighter-73455
10/04/2025, 5:01 PMtall-airline-16756
10/04/2025, 5:01 PMpip install livekit-plugins-deepgram to add it to your project.
2. Set Up Authentication: Make sure you have your Deepgram API key handy, and set it as an environment variable called DEEPGRAM_API_KEY.
3. Initialize the STT Service: You can use the deepgram.STT() or deepgram.STTv2() class to configure your transcription model. For example:
from livekit.plugins import deepgram
stt = deepgram.STTv2(model="flux-general-en", sample_rate=16000)
4. Handle Transcription Events: Be sure to subscribe to the user_input_transcribed event so you can process the transcription output smoothly.
5. Integrate with an AgentSession: Create an AgentSession and pass your STT instance to it to tie everything together.
If you’d like, I can provide more detailed code examples or help you with advanced configurations—just let me know! I’m here to support you every step of the way.
Sources: examples/voice_agents/speaker_id_multi_speaker.py | docs/index.yaml | Deepgram STT | LiveKit Docs | Deepgram STT plugin guide | LiveKit Docs