📍 Join the 1st DeepEval meetup in SF, this Friday 5pm PT. RSVP on Luma →
💥 Introducing JevEval: Jev-as-a-Judge for LLM evaluation. Read the post →
Voice AgentsAudio Defects

Abrupt Cut-off

Beta
Multi-turn
Referenceless
Chatbot
Voice

The abrupt cut-off metric checks whether your voice agent's replies stop mid-sound, as in "Your balance is two hundred and" followed by nothing. It returns the share of agent replies that end cleanly, between 0 and 1.

0.0s / 3.3s

Required Arguments

To use the AbruptCutoffMetric, you'll have to provide a ConversationalTestCase with audio on the test case as a stereo recording of the whole call*, or audio on the agent's turns.

When the test case has full call audio, it's used even if the turns have audio too. With per-turn audio only, give every clip an Audio.start_time, or stream cuts can't be found.

* Full call audio has to be stereo, with the caller and agent on separate channels. Mono full call audio is ignored, because the two voices can't be told apart.

Usage

The AbruptCutoffMetric() can be used for end-to-end evaluation of voice calls, such as ones produced by the ConversationSimulator in voice mode:

from deepeval import evaluate
from deepeval.dataset import ConversationalGolden
from deepeval.metrics import AbruptCutoffMetric
from deepeval.simulator import ConversationSimulator
from deepeval.voice import ElevenLabsConnector, VoiceConfig


golden = ConversationalGolden(
    scenario="The user asks the agent to look up an order by its number.",
    expected_outcome="The agent reads back the order status.",
)

simulator = ConversationSimulator(
    voice_config=VoiceConfig(
        connector=ElevenLabsConnector(agent_id="your-agent-id"),
    )
)
test_cases = simulator.simulate([golden])

metric = AbruptCutoffMetric(threshold=0.8)
evaluate(test_cases=test_cases, metrics=[metric])

There are THREE optional parameters specific to the AbruptCutoffMetric, on top of the common voice metric parameters:

  • [Optional] use_speech_detection: a boolean which when set to True, only counts the caller as talking when speech is detected on their channel, so background noise doesn't excuse a cut-off. It also helps find the dead streams that excuse a stop. Defaulted to True.
  • [Optional] eval_mode: "deterministic" or "hybrid". In "hybrid", each cut-off is double-checked by an audio decision model before it counts. Defaulted to the configured voice eval mode ("deterministic" unless set).
  • [Optional] audio_decision_model: the model that does the second check in "hybrid" mode. Defaulted to HumeDecisionModel().

As a standalone

You can also run the AbruptCutoffMetric on a single test case as a standalone, one-off execution:

metric.measure(test_cases[0])

print(metric.score, metric.reason)
print(metric.score_breakdown)

See Events for what score_breakdown contains.

Events

Each reply that was cut off shows up in score_breakdown as one event. Here is what the example call, read from full call audio, returns:

{
    "eligible_turns": 4,
    "turns_with_events": 1,
    "events": [
        {
            "type": "abrupt_cutoff",
            "duration_seconds": 0.02,
            "start_time": 11.58,
            "mark": "moment",
            "timing_source": "call_recording",
            "description": "Agent's audio cut off abruptly",
            "reply_start": 10.0,
            "stopped_at_seconds": 11.6,
        }
    ],
    "skipped": [],
    "timing_source": "call_recording",
}
FieldWhat it means
reply_startWhen the cut reply started, in seconds into the call
stopped_at_secondsWhen its sound stopped
start_timeWhere the 20 ms checked before the stop begins
duration_secondsAlways 0.02: the 20 ms that were checked

With per-turn audio, events name the turn and where in its clip the cut happened. A cut at the end of a clip has type "abrupt_cutoff", and a stream cut has type "stream_cut". In this call, the agent's turn 1 stops mid-word and turn 2 picks up 0.5 seconds later:

{
    "eligible_turns": 4,
    "turns_with_events": 1,
    "events": [
        {
            "type": "stream_cut",
            "turn": 1,
            "role": "assistant",
            "offset_seconds": 1.125,
            "duration_seconds": 0.0,
            "start_time": 4.625,
            "mark": "moment",
            "timing_source": "turn_timestamps",
            "description": "Agent's audio cut off abruptly",
            "position": "end",
            "evidence": "abrupt_end",
            "gap_seconds": 0.5,
            "resumed_turn": 2,
        }
    ],
    "skipped": [],
    "timing_source": "turn_timestamps",
}
FieldWhat it means
offset_secondsFor abrupt_cutoff, where the 20 ms checked before the stop begins, in seconds from the start of the clip. For stream_cut, where the clip stops or its dead air begins
duration_seconds0.02 for abrupt_cutoff, 0 for stream_cut
evidenceWhy a stream cut counts: "abrupt_end" when the clip stops mid-sound, "trailing_dead_run" when it ends in dead air
gap_secondsHow long after the clip ended the agent's next clip started
resumed_turnThe turn where the agent picked back up
role, positionOn stream cuts only: whose turn it is, and whether the cut is near the start, middle or end of the clip

Clips that can't be decoded are listed under skipped. Every event also has the fields all voice events share, such as mark and description.

eligible_turns is how many agent replies were counted and turns_with_events how many were cut off. The score is the share that weren't.

How Is It Calculated?

The AbruptCutoffMetric score is calculated according to the following equation:

Abrupt Cut-off=Number of Agent Replies Without a Cut-offTotal Number of Agent Replies\text{Abrupt Cut-off} = \frac{\text{Number of Agent Replies Without a Cut-off}}{\text{Total Number of Agent Replies}}

Counting agent replies

CallerAgentreply 1reply 20s2s4s6s8s10s

With full call audio, each reply is a timed reply, so a pause under 1 second doesn't end it: reply 1 above is one reply even though the agent paused mid-way. With per-turn audio, each agent clip that decodes is one reply. A reply counts as cut off at most once.

Cut-off criteria

A finished reply fades out. A cut one stops at near full volume.

CallerAgentfades outstops at full volume0s2s4s6s8s

Only the stop at the very end of each reply, within 0.05 seconds of it, is checked, not stops mid-reply. The reply is flagged if that stop is a cut-off, except when:

  • the caller made 0.2 seconds or more of sound from 1 second before it to 0.2 seconds after, or
  • the full call audio ends within 0.05 seconds, which Unexpected Call End judges instead.

A stop is a cut-off when the last 20 ms of sound before it are:

CheckRule
Still at speech volumeAt least 80% of the median level of the second before
Above the backgroundMore than 10 dB above the background noise. With per-turn audio, only checked on clips of 2 seconds or more
Not quiet residueAbove about −30 dBFS

Even then, a stop isn't a cut-off when:

  • the text of the agent's reply ends a sentence, with ., ?, ! or …. The reply was said in full, however sharply its last sound stops. With full call audio, the text is that of the agent turn whose clip the stop falls in, so this only applies when the turns also have audio with an Audio.start_time. With full call audio alone it isn't checked.
  • a dead stream starts within 0.3 seconds of the stop. The agent's audio went dead and then carried on, so it's a hole in the reply for Dead Stream to judge.

If there's nothing to count, the metric is skipped.

Per-turn audio

Without full call audio, only the end of each agent clip is checked, with the same level rules. Otherwise:

  • The caller check and the end-of-call check need full call audio, so they don't apply. Instead, a clip with interrupted=True is never flagged.
  • The text checked for a finished sentence is the turn's own content.
  • A clip is also flagged as a stream cut when it ends mid-sound, or in 1 second or more of digital silence, and the agent's own clip is next on the call, starting within 15 seconds. This needs an Audio.start_time on every clip.
  • A cut isn't flagged when a dead stream starts within 0.3 seconds of it, as above. This also needs the clip's Audio.start_time.

Second check

In the hybrid eval mode, each cut-off is double-checked before it counts. The audio decision model hears about 5 seconds of the agent's side of the call around it and is asked:

Does the speaker's voice cut off abruptly, mid-word or mid-sentence?

If the model judges "no" more likely than "yes", the cut-off is dismissed and doesn't count against the score.

Agentcut-off0s2s4s6s8s
The model hears the shaded 5 seconds around the cut-off.

Example call

A short call where the agent sometimes stops mid-word.

CallerAgentcleanclean: caller spokecut offclean: call ended0s2s4s6s8s10s12s14s
Agent replyHow it endsCut off?
2.8 – 5.0 sFades outNo
6.3 – 7.9 sFull volume, but the caller was talkingNo
10.0 – 11.6 sFull volume, caller silent, and the reply's text stops mid-sentenceYes
13.2 – 14.0 sStill going when the full call audio endsNo
4 replies1 cut off → 3/4 = 0.75

FAQs

Why isn't a reply the simulated caller interrupted flagged?
A successful barge-in stops the agent mid-word on purpose. With per-turn audio, those turns carry interrupted=True and count as clean replies. With full call audio, the caller is heard speaking up, which excuses the stop too.
How is this different from Dead Stream?
It depends on where the audio picks back up. When a clip stops and the agent carries on in its next clip, the listener hears a reply that stops, so it's reported here once, as a stream cut. When the audio goes dead and carries on inside the same clip or reply, it's a hole in the reply: DeadStreamMetric reports it, and this metric doesn't.
Does this metric call an LLM or an external speech model?
Not by default. Detection is deterministic and runs locally over the audio, so it has no model or token cost. In the "hybrid" eval mode, each cut-off is also checked by an audio decision model, at one paid request per cut-off.
Does it check the caller's audio too?
No. Only the agent's replies are scored. The caller is your simulator's TTS voice or a real customer, so their audio says nothing about the agent. With full call audio, the caller's channel is only used to tell whether the caller spoke up when the agent stopped.

On this page