Is there support for a feature in livekit which wo...
# ask-ai
b
Is there support for a feature in livekit which would make the agent say stuff like Um, mm hm, ok etc while the customer is speaking? or is there any way to make the agent give a contextual quick reply while waiting for the LLm to respond?
t
Thanks for reaching out, Aryan. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Thanks — I understand you want to know whether LiveKit can make an agent produce short filler sounds like “um / mm-hm / ok” while a customer is speaking, or otherwise give a quick contextual acknowledgement while waiting for an LLM response. Short answer • LiveKit does not have a built-in feature to automatically emit filler interjections during the customer’s speech (agents normally wait until the user turn completes before speaking). • You can, however, implement immediate acknowledgments or non-verbal feedback after the user finishes their turn, and there are ways to simulate responsiveness while the LLM is working. What you can do today • Quick verbal acknowledgments after user turn: ◦ Use the
on_user_turn_completed
lifecycle hook to trigger an immediate short utterance such as
session.say("Okay, let me check that for you.", allow_interruptions=False)
. This runs as soon as the user turn ends and gives the user immediate feedback while longer processing (RAG/tool calls/LLM) continues. • Background / non-verbal feedback during processing: ◦ Use the
BackgroundAudioPlayer
/
thinking_sound
option to play a short “thinking” or typing audio clip while the agent is processing. This provides audible feedback without speaking over the user. • Injecting custom audio (advanced): ◦ If you absolutely need short sounds played while the user is still speaking, it would require a custom implementation using low-latency event hooks and audio injection. LiveKit uses turn detection to determine when the user finished speaking, and agents don’t normally interrupt that flow—so this approach is advanced and not a built-in behavior. Trade-offs to consider • Speaking over the user can degrade turn-detection and natural conversation flow; usually it’s better to wait for end-of-turn and then give a brief acknowledgement. • Short post-turn replies + background “thinking” audio give the perception of responsiveness while avoiding interruptions and are simpler to implement. If you want, I can: • Show a short example of using
on_user_turn_completed
with
session.say()
to produce an immediate acknowledgement. • Describe how to enable and configure `thinking_sound`/`BackgroundAudioPlayer`. • Discuss what “custom audio injection during speech” would require so you can judge feasibility. Which of those would help most for your use case? Sources: Improving voice AI's turn detection with transformers | Pipeline nodes and hooks | LiveKit Documentation | Agent speech and audio | LiveKit Documentation