When you hear voice agents, you imagine phone bots, real-time speech recognition, natural-sounding TTS, turn-taking, interruptions, 200ms latency, and so on.
But when you start building one, you hit a host of other, less flashy, annoying issues. The earliest problem: an echo of the agent’s voice returns via the speaker, right after the agent speaks. It starts transcribing its own voice thinking it is the user speaking.
Of course, you can wear headphones or toggle mute but that kills the experience.
This affects local, WebSocket, and phone-based agents alike.
The solution is well-known but not available off-the-shelf. You need to have an acoustic echo cancelation (AEC) module in the path from input audio to the agent, with the TTS audio output as the reference. AEC algorithms can then cut away the echo+noise.
Thanks to a recent AEC implementation in Python, I was finally able to get a smooth *hands-head-free* local Agent experience. STT (whisper), TTS(kokoro) both running locally.
Getting AEC working isn’t straightforward either, watch the full video to learn how to do that.
And AEC is only one of many voice-AI blockers: barge-in failures, short-audio transcription errors, background speakers, and more, long before getting to production scale.
Check out my Voice AI playlist on YouTube where I discuss many blockers to voice agents in production.
This implementation is part of mulive - a lightweight, nimble voice AI library I’m building to create interactive voice-video applications. I’ll be posting more about it soon.


