中文 English Deutsch Français
FlyAec› Blog› Voice assistants and smart speakers
ENGINEERING · AEC

AEC for Voice Assistants: Barge-In and Wake Words

A voice assistant lives inside its own loudspeaker. Cancelling its own playback in real time is what makes barge-in work.

By QingYin Audio Lab · November 5, 2026 · 8 min read

A voice assistant lives inside its own loudspeaker. Every reply it speaks, every bit of music it plays, returns through the air into its microphones. For the assistant to hear you while it is talking, its AEC must cancel its own output in real time; this is the barge-in problem.

This article covers the echo and far-end reference side of assistants and smart speakers. Microphone array beamforming and noise reduction for far-field listening belong to our sister site; here we focus on canceling the device's own playback so the user can interrupt.

Barge-in needs cancellation during playback

Barge-in means the user speaks while the assistant is still outputting audio, expecting the device to detect the interruption and stop. The far-end reference is the assistant's own synthesized speech and any media it is playing. The canceller must run continuously during output, not just during calls, and must hand a clean near-end signal to the wake-word and speech recognition engines.

If the echo is not removed, the recognizer hears a mix of the user and the assistant and either misses the barge-in or mis-transcribes it.

Protecting the wake word

The always-on wake-word detector runs on the same microphone stream. AEC must not distort the near-end speech that contains the wake word or the command that follows. Over-aggressive nonlinear processing that strips quiet speech will hurt wake-word detection, so the NLP after the linear canceller has to be tuned to leave near-end speech intact during double-talk.

The double-talk detector therefore does double duty: it protects the filter from divergence and protects the wake-word stream from being muted.

The barge-in requirement also changes the NLP design compared with a call. In a call, brief near-end speech during double-talk is common and the NLP can be moderately aggressive. For an assistant, the near-end is almost always the user's command, so the NLP must be near-transparent on the near-end while still removing the assistant's own playback. That pushes the design toward a correlation-gated suppressor that only acts where the far-end reference is actually present, leaving untouched bands alone.

Music playback is the hard reference

Music is a far harder reference signal than speech. It has a flat, sustained spectrum and high crest factor, which keeps the adaptive filter well excited but also exposes any nonlinearity in the speaker. The echo of music is more audible than the echo of speech because the ear notices missing or colored music, so the residual tolerance is tighter.

A good reference is the exact post-equalized signal sent to the amplifier, including any dynamic range compression the playback chain applies, so the canceller models what was actually radiated.

Streaming music also changes how you validate. Because music is continuous and non-stationary, the adaptive filter stays excited and rarely goes idle, which is good for tracking but means you rarely get the clean single-talk windows that make ERLE measurement easy. Plan measurements around scripted playback with known pauses, or rely on AECMOS for the in-the-wild case.

Full-duplex assistant conversations

Some assistants support a full-duplex mode where the user and assistant speak in a more natural back-and-forth. That is exactly the double-talk regime: the adaptive filter must freeze its update while the user talks over the assistant's voice, then resume. The detector choices here mirror those in dedicated double-talk detection work.

The risk in full-duplex mode is asymmetrical: the assistant's own long replies create long echo periods, and the user's barge-in tends to be short and quiet. The canceller must remove a sustained loud reference while protecting a brief soft near-end utterance, which pushes the NLP threshold toward caution.

How to test assistant AEC

Test barge-in directly: play assistant audio, inject a command, and confirm the recognizer sees it. Measure ERLE during single-talk playback and AECMOS on real barge-in recordings. Because there is no clean reference in a live home, AECMOS is usually the practical metric. See our measurement guide for setup details. Also verify the interrupt path end to end: inject the barge-in, then confirm the assistant actually stops its playback and the microphone is handed to the recognizer without a gap where echo leaks. A canceller that is mathematically correct but hands off late still fails the user-perceived barge-in.

The detector logic that protects the wake-word stream is the same as in Double-Talk Detection Methods, and the playback reference is detailed in Why AEC Needs a Far-End Reference.

Hear it on your own audio

Upload a real call recording and compare the AEC output on our demo page.

Try the live demo Request an evaluation
FAQ

Common questions

What is barge-in?

Barge-in is when the user speaks while the assistant is still playing audio, expecting the device to detect the interruption and stop or switch.

Why is music a hard reference?

Music has a flat sustained spectrum and high crest factor, exposes speaker nonlinearity, and its echo is more noticeable to the ear than speech echo.

Does AEC hurt wake-word detection?

Only if the nonlinear processor is too aggressive; tuning must leave near-end speech intact during double-talk so the wake word is preserved.

Which reference should the canceller use?

The exact post-equalized signal sent to the amplifier, including any playback compression, so it matches what was actually radiated.

How do you measure assistant AEC without a clean reference?

Use AECMOS on real barge-in recordings, plus ERLE during single-talk playback where the near-end is absent.