I am currently using openai, assembly n inworld vi...
# ask-ai
g
I am currently using openai, assembly n inworld via livekit plugin n my latency is at 2459ms which is a buzzkill in terms of customer experience. each of these services claiming to have max 300ms each so with server i should be at max 1200ms but i m no where close. What is the best way to achieve my latency goals and get them under 1200ms?
t
Thanks for reaching out, Snehaal. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Hey there! To help reduce latency in your LiveKit setup with OpenAI, AssemblyAI, and Inworld, here are some friendly tips you can try: • Optimize Network Proximity: Try to deploy your server as close as possible to the APIs of OpenAI, AssemblyAI, and Inworld. This helps cut down on those round-trip times. • Enable Streaming: Streaming APIs are your friend for real-time processing! For instance, it’s better to avoid non-streaming STT solutions like OpenAI Whisper if you want things to happen in real time. • Parallel Processing: Running STT and LLM tasks side-by-side can really help speed things up and reduce delays. • Adjust Plugin Parameters: For AssemblyAI, tweaking settings like
buffer_size_seconds
and
end_of_turn_confidence_threshold
can make transcription quicker. And for OpenAI STT, playing with
silence_duration_ms
can improve how segmentation works. • Monitor Metrics: Keep an eye on LiveKit’s metrics API to track things like Time To First Token (TTFT) and Time To First Byte (TTFB) — this way, you can spot any bottlenecks easily. • Pre-Connect Buffer: Turning this on can help reduce startup latency when users start voice interactions. • Evaluate Providers: It’s always good to benchmark latency across STT, TTS, and LLM services so you can pick the fastest options for your region. Following these steps should get you closer to that latency goal of under 1200ms. And hey, if you want a hand with any specific settings or have questions, just let me know — I’m here to help! Sources: Live Conversations with AI using ChatGPT and WebRTC | Live Conversations with AI using ChatGPT and WebRTC | livekit-plugins/livekit-plugins-assemblyai/livekit/plugins/assemblyai/stt.p... | Voice Assistants | livekit/livekit_composite | DeepWiki | Voice Assistants | livekit/livekit_composite | DeepWiki