How to use flux deepgram model for STT in Node.js ...
# ask-ai
b
How to use flux deepgram model for STT in Node.js SDK?
t
Thanks for reaching out, Dmytro. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Thank you for your question! The "flux" model for Deepgram STT isn't currently documented for use with the Node.js SDK. But no worries—you can definitely use supported models like
nova-3
with the
@livekit/agents-plugin-deepgram
package. Here's a simple example to get you started:
Copy code
import * as deepgram from '@livekit/agents-plugin-deepgram';

const stt = new deepgram.STT({ model: 'nova-3' });
Just make sure you have your
DEEPGRAM_API_KEY
set in your environment variables for authentication. If you run into any issues or want to explore other models, please feel free to reach out—I'm here to help! Sources: livekit-plugins/livekit-plugins-deepgram/livekit/plugins/deepgram/stt_v2.py | .cursor/rules/agent-core.mdc | Deepgram STT plugin guide | LiveKit Docs | Deepgram STT | LiveKit docs
b
Does nova-3 supports built-in turn detection logic?
t
Hi there! Just to let you know, the
nova-3
model doesn’t come with built-in turn detection logic. But no worries—you can easily set up turn detection externally using LiveKit’s turn detector plugin, which offers smart, context-aware detection. Here’s a simple way to get it up and running: 1. First, install the necessary plugins by running:
pip install "livekit-agents[deepgram,silero,turn-detector]~=1.0"
2. Next, download the turn detection model files with:
python your_agent.py download-files
3. Then, configure your
AgentSession
to include the turn detector like this:
Copy code
from livekit.agents import AgentSession
from livekit.plugins import deepgram, silero
from livekit.plugins.turn_detector.english import EnglishModel

session = AgentSession(
    vad=silero.VAD.load(),
    stt=deepgram.STT(model="nova-3"),
    turn_detection=EnglishModel(),
)
If you're working in a multilingual environment, you can swap out
EnglishModel()
for
MultilingualModel()
to better suit your needs. Please feel free to reach out if you have any questions or need a hand with this—I’m here to help! Sources: examples/voice_agents/realtime_turn_detector.py | examples/src/realtime_turn_detector.ts