Both user and agent join, I can hear both in the e...
# ask-ai
a
Both user and agent join, I can hear both in the egress, but it seems like sometimes, the user does not hear the agent. Is this a known issue
t
Thanks for reaching out, Anne. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
I understand how frustrating it can be when a user can't hear the agent in a LiveKit room. Let’s walk through some steps together to help resolve this: 1. First, please make sure the user has interacted with the page (like clicking a button), since browsers often block audio autoplay until there's some interaction. 2. Next, double-check that the agent’s audio is enabled and published properly. It’s important that the agent has a valid Text-to-Speech (TTS) model set up and that
RoomOutputOptions.audioEnabled
is set to
true
. 3. Also, confirm the user is subscribed to the agent’s audio track by monitoring events such as
trackPublished
and
trackSubscribed
. This helps ensure the connection is working as expected. 4. Keep in mind that some browsers, especially Safari on iOS, have stricter rules and may require explicit user interaction to allow audio playback. 5. Don’t forget to include a
<roomaudiorenderer/>
component in your frontend—it helps automatically play incoming audio tracks smoothly. If you’re still facing issues after trying these, enabling LiveKit SDK logging can provide detailed insights into connection and media events, which is really helpful for troubleshooting. Please feel free to reach out if you’d like me to guide you through any of these steps—I’m here to help! Sources: README.md | client/web/src/app/page.tsx | Web and mobile frontends | LiveKit Docs | SIP troubleshooting guide | LiveKit Docs | README.md