Hey everyone, we are getting a big spike in users ...
# agents
p
Hey everyone, we are getting a big spike in users ciomplaining that their sessions are getting cut, and for what we have been investigating it seems to be an echoing issue, the agent hears itself through the speakers and then it interrupts what it's saying. Most of the complaints seem to come from Android users. We are currently using: • Python ◦ Livekit agents 1.4.2 ◦ Livekit 1.1.2 ◦ Livekit Noise Cancellation 0.2.5 ▪︎
AudioInputOptions(noise_cancellation=noise_cancellation.BVC())
• Android ◦ Livekit 2.20.2 • iOS ◦ Livekit 2.7.2 Is it possible this has something to do with the backend noise cancellation plugin? Should we instead use instead Client noise cancellation using the Krisp filter?
p
It sounds like the echo is coming from how audio is captured and played back on Android devices. Backend BVC noise cancellation can help, but it doesn’t eliminate echo caused by speakers feeding back into the mic. For Android, enabling client-side noise/echo suppression (like Krisp) is usually more effective, since it processes the audio before it reaches the server. I can help you test switching to client-side Krisp noise cancellation and tune the settings to stop these session interruptions. @prehistoric-lion-61312
p
Are there any downsides to Krisp, like added latency? Should we use Krisp at the same time of using Backend BVC noise cancelling? I am now trying with the latest Livekit client on Android and see if that fixes the issue... The very odd thing is that this happens after a set of tasks in my code that are a mix of playing multiple audios and doing some cyclic tasks. And then when you come out of that experience the issue appears more often than not (but not 100% of the time).
So far the update seems to help... I tried 4 times without reproducing it while before I could reproduce like 75% of the times... 🤞
l
I don't remember any specific changes in the recent Android client SDK related to echo cancellation, but it's a good first thing to try. I thought echo cancellation on the local audio track should be enabled by default though: https://docs.livekit.io/reference/client-sdk-android/livekit-android-sdk/io.livekit.android.room.track/-local-audio-track-options/index.html Looking on GitHub I see this, which is similar: https://github.com/livekit/client-sdk-android/issues/840
p
Oddly enough I think the update solves it... at least locally. I will submit a version today to the Play Store because I have many users complaining 😞 Hopefully it will fix it for all of them. Any ideas on the Krisp stuff? @lively-winter-88668 Should we use it if we are already using BVC?
l
Krisp is already used within the Backend BVC noise cancellation. On the client, I'm not sure what Android is using, but it does sound like an echo cancellation issue from what you described rather than noise supression (which should be enabled by default in the SDK) - if it's fixed in the latest SDK, maybe there was a bug. For latency, again I'm not sure about the client-side (sorry), but the Krisp in BVC adds only negligible latency
p
Thanks for the help both 🙂