Voice Agent Barge-In Latency: Handling Real-Time Interruptions Without Audio Artifacts

TLDR: Voice agent barge-in is the full-duplex capability allowing callers to interrupt an AI agent mid-sentence. True interruption latency is not just speech detection, it spans Voice Activity Detection (VAD) trigger, playback buffer flush, text-to-speech (TTS) stream cancellation, and dialogue state rollback. Research on conversational turn-taking by Stivers et al. shows natural human turn gaps hover near 200ms, while delayed interruption creates jarring speech collisions. This engineering guide explains acoustic echo cancellation, dual-layer VAD architectures, client buffer purging, and why production voice pipelines require orchestration above individual TTS providers.
Voice agent barge-in is the real-time mechanism that detects human speech while an agent is actively speaking, halts downstream synthesis, purges buffered audio, and returns conversational control to the caller. The core technical hurdle is not simply detecting voice activity, it is orchestrating an instantaneous system rollback across transport, audio hardware, and synthesis engines without clipping or stale state. When interruption latency exceeds human conversational tolerances, users talk over the machine, leading to cognitive fatigue, conversational collisions, and broken telephony workflows.
Engineering teams often optimize time to first byte while completely ignoring interruption mechanics. A voice agent that begins speaking in 100ms but takes 800ms to shut up when interrupted feels completely unnatural to a human caller.
What is voice agent barge-in and why does interruption latency matter?
Voice agent barge-in is the capability of a voice system to detect when a user begins speaking during agent playback, immediately truncate synthesized audio output, and transition into an active listening state. In telephony and WebRTC voice systems, callers naturally interject to correct a misunderstood name, clarify intent, or skip lengthy system prompts.
Interruption latency is the total elapsed time between the acoustic onset of the user's interrupting syllable and the exact moment audio emission physically ceases on the caller's speaker. In human-to-human conversation, floor transfer gaps average approximately 200ms, with interruptions resolving within 100ms to 250ms.
When voice agent interruption latency climbs above 400ms, callers experience acoustic overlap. The user starts talking, the agent continues speaking for two or three words, the user pauses assuming the agent did not hear them, and both parties resume simultaneously in a classic conversational deadlock. Minimizing interruption latency is the single most critical factor in achieving fluid, human-grade conversational pacing across automated support and conversational assistants.
How does the end-to-end voice interruption pipeline work?
A production barge-in pipeline is an orchestrated circuit comprising acoustic echo cancellation, voice activity detection, transport signaling, client buffer clearing, and generation cancellation.
- Acoustic Echo Cancellation (AEC): The caller's microphone captures ambient voice alongside agent playback leaking from the speaker or telephone receiver. The AEC module subtracts the reference playback signal from the microphone input signal to prevent the agent from interrupting itself on its own audio output.
- Speech Classification via VAD: The cleaned audio stream feeds a streaming VAD module, such as Silero VAD, which analyzes audio in 10ms to 30ms frames. The detector flags speech probability against a calibrated confidence threshold, distinguishing vocal acoustic energy from steady background noise.
- Turn Arbitration: The system validates whether the classified audio represents a legitimate turn claim or a transient background disturbance, such as a brief cough, keyboard tap, or office door closure.
- Local Buffer Evacuation: The local audio sink flushes its unplayed PCM or Opus sample buffer. Even if the server stops sending audio over the network, frames already queued in the client driver will continue playing unless explicitly purged.
- Upstream Stream Cancellation: The application sends a cancellation frame across the persistent WebSocket or WebRTC data channel to the TTS provider, preventing continued token consumption and wasteful inference billing.
What causes high interruption latency and audio overrun in production?
High interruption latency stems from accumulated delays across audio buffering, network round-trips, and poor protocol design rather than raw neural inference alone. In production voice architectures, four primary bottlenecks cause agents to talk over users.
1. Client-Side Playback Buffer Bloat
Most media players buffer 200ms to 500ms of incoming audio to prevent jitter-induced underruns. When a user interrupts, stopping the inbound network stream does nothing to the audio already sitting in the OS ring buffer or browser AudioContext. Without an imperative AudioBufferSourceNode.stop() or telephony CLEAR_BUFFER command, the agent continues speaking from local cache.
2. Network Round-Trip Overhead on WebSockets
In naive server-centric architectures, voice activity detected on the client device must travel over the network to a central backend before a cancellation command is dispatched to the TTS vendor. If round-trip latency to the server is 80ms, and the cancellation API call to the TTS engine takes 60ms, over 140ms of unnecessary latency is introduced before upstream generation halts.
3. Acoustic Echo Leakage and Aggressive AEC Filtering
Poor acoustic echo cancellation causes two distinct failure modes: false self-interruptions (where the agent hears itself and stops talking) or over-attenuation (where aggressive residual echo suppression muffles the user's interrupting voice). If the AEC suppresses the first syllable of the user's speech, the VAD cannot trigger until the second or third word, adding 300ms to 600ms of apparent barge-in lag.
4. Dialogue History Desynchronization
When an interruption occurs, the agent's language model has already generated tokens that were never heard by the user. If the dialogue manager fails to truncate the conversation history at the exact timestamp of interruption, the agent's subsequent responses will reference context the user never received, derailing the conversation.
How do you measure true barge-in latency vs raw VAD speed?
True barge-in latency cannot be measured by inspecting VAD log timestamps in isolation. You must measure the acoustic gap directly from the physical audio timeline using multi-track logging.
| Metric Component | Measurement Boundary | Typical Target | Failure Threshold |
|---|---|---|---|
| VAD Onset Delay | User voice onset to VAD classification event | 60ms – 120ms | > 200ms |
| Transport Dispatch | VAD trigger to server cancellation packet emit | 10ms – 30ms | > 80ms |
| TTS Engine Truncation | Cancellation receipt to stream termination | 20ms – 50ms | > 150ms |
| Client Audio Flush | Signal arrival to physical speaker silence | 5ms – 25ms | > 100ms |
| Total Acoustic Interruption | User speech onset to caller speaker silence | 150ms – 250ms | > 400ms |
To benchmark your pipeline in staging:
- Record the dual-channel audio stream where Channel 1 contains raw user microphone input and Channel 2 contains acoustic output captured directly from the playback transducer.
- Introduce controlled user speech tokens (such as "Stop", "Wait", or "Actually") at randomized offsets during active agent speech synthesis.
- Calculate the time delta between the first detectable energy spike on Channel 1 and the exact zero-crossing where Channel 2 amplitude drops to silence.
- Log the volume of overrun audio in milliseconds of spoken text delivered after the interruption started to verify that users are not subjected to lingering sentences.
How do leading streaming TTS APIs handle mid-stream cancellation?
Different text-to-speech providers implement divergent protocols for aborting synthesis mid-flight. When designing a low-latency voice pipeline, your orchestration layer must adapt to each engine's cancellation interface.
Deepgram provides native voice agent WebSocket streams supporting clear messages that instruct the server to flush unstreamed audio immediately while maintaining the persistent connection. ElevenLabs provides low-latency WebSocket endpoints where client sessions can reset the active generation context. Cartesia utilizes low-latency WebSocket protocols designed for sub-100ms chunk delivery with explicit stream cancellation frames.
| Provider / Engine | Protocol Support | Mid-Stream Cancellation Mechanism | Typical Cancellation Latency |
|---|---|---|---|
| Deepgram Aura-2 | WebSocket, REST | WebSocket Clear / Flush command | 20ms – 40ms |
| ElevenLabs Flash v2.5 | WebSocket, HTTP Stream | Context reset / Socket flush frame | 30ms – 60ms |
| Cartesia Sonic | WebSocket | Context cancel event on active stream | 20ms – 45ms |
| Inworld Realtime TTS-2 | WebSocket, gRPC | Stream abort message | 25ms – 50ms |
If your system uses naive HTTP chunked streaming instead of full-duplex WebSockets, interrupting requires abruptly terminating the TCP connection. Re-establishing TLS handshakes on the next turn consumes an additional 80ms to 150ms, crippling conversational responsiveness.
How do you handle backchannels without accidental agent cutoff?
A backchannel is a short verbal acknowledgment, such as "uh-huh", "yeah", "mm-hmm", or "okay", spoken by a listener to signal comprehension without attempting to take the conversational floor.
Naive barge-in implementations treat all voice activity identically: the caller says "mm-hmm" to show they are listening, the energy-based VAD trips, and the agent abruptly stops talking mid-explanation. This creates an irritating experience where the agent stutters repeatedly whenever the user demonstrates active listening.
Production architectures resolve this with a dual-stage turn arbiter:
- Acoustic Energy & Pitch Detection: A lightweight acoustic model identifies incoming sound within 30ms. Instead of immediately killing agent synthesis, it temporarily ducks the agent's playback volume by 6dB to 10dB.
- Streaming Phoneme Classification: An ultra-fast local keyword detector or small language model evaluates the first 150ms to 250ms of audio.
- Turn Arbitration Logic: If the transcribed token is an acknowledged backchannel token ("yeah", "okay", "right"), the agent restores playback volume and continues synthesis without interruption. If the caller produces a turn-claiming token ("wait", "no that's wrong", "how much"), the arbiter immediately executes the hard buffer flush and halts synthesis.
What is the production checklist for voice agent interruption handling?
Deploying reliable, low-latency barge-in requires validating every component of the conversational loop before scaling to live traffic:
- Hardware Echo Cancellation: Enable hardware or WebRTC-level AEC to suppress acoustic bleed across speakerphones and mobile devices.
- Low Frame Size VAD: Configure streaming VAD frame sizes between 20ms and 30ms to minimize algorithmic detection latency.
- Imperative Audio Flush: Ensure your client audio driver executes an immediate buffer wipe rather than waiting for queued samples to drain naturally.
- Duplex Transport Protocol: Utilize persistent WebSockets or WebRTC data channels for TTS delivery to support instantaneous cancellation signals without socket teardown.
- Backchannel Filtering: Implement an intent filter or volume-ducking state to prevent affirmative listener acknowledgments from killing agent speech.
- Turn Rollback & State Pruning: Update your dialogue manager to truncate the agent's conversation history at the exact character index spoken prior to interruption, preventing the LLM from hallucinating that it delivered unread lines.
- Multi-Model Orchestration: Decouple your voice architecture from single-vendor streaming quirks with an intelligent production layer.
Onepin is a voice workflow platform that orchestrates, validates, and ships production-ready audio across 100+ TTS models. In real-time voice applications, rapid model routing must coexist with uncompromising pronunciation accuracy, clean audio formats, and unified streaming controls. When an agent interrupts or swaps engines mid-call, Onepin maintains standardized latency envelopes and quality gates across providers, ensuring your voice agents deliver flawless, human-grade conversational turns at scale.
Explore the technical documentation at onepin.ai/docs. For further architectural insights, review our guides on streaming TTS latency, TTS quality validation checklists, and what TTS orchestration is.
Frequently asked questions
- What is barge-in in an AI voice agent?
- Barge-in is the conversational capability that lets a human speaker interrupt an AI voice agent while the agent is actively talking. The system must instantly halt speech synthesis playback, discard buffered audio, and switch back to listening mode without clipping or freezing.
- What is the difference between VAD latency and interruption latency?
- Voice Activity Detection (VAD) latency measures only the time required for a model to classify incoming sound as human speech, typically 50ms to 200ms. Interruption latency measures the entire end-to-end elapsed time from the user's first interrupting syllable until playback on the speaker stops and downstream TTS generation cancels.
- Why do AI voice agents talk over users during interruptions?
- Agents speak over users due to unpurged client audio buffers, acoustic echo leakage triggering false speech loops, and high cancellation round-trip latency to the text-to-speech provider. If the audio player buffers 400ms of pre-rendered speech and lacks a hardware-level flush command, the user hears an awkward conversational collision.
- How do backchannels differ from true conversational interruptions?
- A backchannel is a brief human acknowledgment such as 'uh-huh', 'okay', or 'right' indicating active listening without claiming the speaking turn. Systems using naive energy-based VAD mistakenly halt agent speech on backchannels, whereas modern semantic turn-taking models filter brief filler words to keep synthesis flowing.
- How does Onepin support real-time voice agent production?
- Onepin is a voice workflow platform that orchestrates, validates, and ships production-ready audio across 100+ TTS models. It provides unified streaming contracts, pronunciation lexicons, and automated audio validation so enterprise teams deploy real-time voice workflows without single-model vendor lock-in.