# Mission 13.2: “My customer number is … hold on … 4711”

Part of the course “AI from Zero to Autonomous Agents” (https://llm.yoga/en). Page for humans: https://llm.yoga/en/einsatz-13-2

Belongs to [Chapter 13: Voice agents](https://llm.yoga/en/13-sprachagenten.md).

Structure: the case, the explanation, a hands-on tool, check questions, wrap-up. The answers to all questions are collected at the end.

## The case

**Erik**, customer service team lead:

> “A caller says, ‘My customer number is …’ and looks for it for a moment. Our agent is already answering: ‘Sorry, I didn’t catch a customer number.’ Then comes ‘hold on … 4711’, and both talk at once. I’ll just set the wait for silence to two seconds, right?”

If you’re the go-to person for AI at your company, you’ll hear this complaint sooner or later: the agent is fast, but rude. Erik’s phone agent is a program that answers calls on its own. It answers as soon as it has been quiet for a certain time. Since it started streaming, it takes another 1,100 ms after that until the first sound (worked example from the chapter).

**Question 1 (decision):** What do you advise Erik?

- A) Two seconds of silence: then the agent won’t talk over anyone anymore.
- B) 200 ms of silence, so the agent answers as fast as a person.
- C) A turn model that recognizes from what was said whether more is coming.

## What’s behind it

Anyone listening on the phone knows from “My customer number is …” that more is coming. A machine that only pays attention to silence hears the same thing there as at the end of a sentence: nothing.

The simplest solution is a **silence threshold**. The VAD (voice activity detection) checks continuously whether someone is speaking; if it stays quiet for a certain time, the turn counts as finished. OpenAI gives 500 ms as an example value. The problem: people pause in the middle of sentences. A high threshold lets them finish, but makes every answer longer by exactly that amount.

That’s why there are **turn models** for turn-taking. They don’t just judge silence, but also what was said and how it sounded. Examples are semantic_vad from OpenAI, LiveKit’s Turn Detector and the open Smart Turn v3.2; the last two handle German.

The counterpart is **interrupting** (barge-in). If the caller talks into the answer, three things have to happen: speech synthesis stops immediately, generating the answer is canceled, and the conversation history keeps only the part that was actually heard. A short “mhm” from the caller, on the other hand, isn’t an objection; only a model that keeps listening while it speaks (full duplex) can tell the difference.

For Erik this means: a two-second threshold makes every answer slower and still doesn’t cover every pause for thought. A turn model is better, plus clean interrupting. And because the 4711 can easily come through wrong, the agent reads it back and has the caller confirm it.

### In more detail: values and models

For the `server_vad` mode, OpenAI’s example uses 500 ms of silence and 300 ms of lead-in (`prefix_padding_ms`) so the start of the sentence isn’t cut off. `semantic_vad` fires when the model assumes from the words that the user is done. The LiveKit Turn Detector also listens to intonation, pitch and rhythm, handles 14 languages, and in a small version runs locally on the CPU. Smart Turn v3.2 has about 8 million parameters, understands 23 languages, is 8 MB as a CPU version and is licensed under BSD-2-Clause.

The pauses in the slider (1,200 and 700 ms) are examples, not measurements. The other times come from the streaming line of the worked example in the chapter: 100 ms speech recognition, 700 ms language model, 100 ms speech synthesis, 200 ms network and telephony.

If the third step of interrupting is missing, the history contains a promise the caller never heard, such as “I’ve put you down for Tuesday”. The model counts on it in the next round.

## Try it

**Timeline: how long does the agent wait for silence?**

**Task:** The caller pauses twice to think (example values). Set the shortest threshold at which Erik’s agent lets the caller finish, at most 1,500 ms. Then read off what that costs at every sentence end.

**The math without the timeline**

1. With a 500 ms threshold: 500 + 100 + 700 + 100 + 200 = 1,600 ms. The 1,200 ms pause and the 700 ms pause are longer, so the agent talks over the caller twice.
2. The threshold has to be above 1,200 ms, for example 1,250 ms: then 1,250 + 1,100 = 2,350 ms to the first sound, at every sentence end.
3. With a two-second threshold: 2,000 + 1,100 = 3,100 ms. A person: 208 ms.

## Check

**Question 2 (check question):** The agent says “I’ve put you down for Tuesday …”, and the caller calls out, “No, not Tuesday!” What has to happen now?

- A) Speech synthesis stops, and the rest of the answer stays in the history so nothing gets lost.
- B) Stop the output, cancel the answer, and keep only what was heard in the history.
- C) The agent politely finishes the sentence and listens afterward.

**Question 3 (check question):** Callers often say “mhm” while the agent is speaking. Erik’s agent stops every time. What helps?

- A) A model that keeps listening while it speaks (full duplex).
- B) Set the silence threshold higher so the agent waits longer.
- C) Switch off interrupting entirely, so the agent just keeps talking.

## Done

**What you can do now**

- You can explain why a plain silence threshold either talks over callers or makes every answer longer.
- You can name the three steps of interrupting and know why the history has to be trimmed.
- When a customer complains that their agent talks over callers, you ask about a turn model before they turn up the wait for silence.

### Two cards for review

**Card 1:** True or false? “If a voice agent stops every time the caller says “mhm”, a higher silence threshold helps.”

**Card 2:** A caller talks over the voice agent. What three things does the system have to do?

- [Next mission: A phone agent for a fifth of the cost?](https://llm.yoga/en/einsatz-13-3.md)
- [Read chapter 13](https://llm.yoga/en/13-sprachagenten.md)

## Read more in the chapter

The full text from the chapter, with the reasoning, calculations and sources:

- [When is the person done? Turn-taking and interrupting](https://llm.yoga/en/13-sprachagenten-2.md)
- [One model for everything: speech-to-speech](https://llm.yoga/en/13-sprachagenten-2.md)
- [Common misconceptions](https://llm.yoga/en/13-sprachagenten-4.md)

## Answers: only reveal them after the learner has answered or explicitly asks

**Question 1:** The correct answer is C.
- A: Then it waits two seconds at every sentence end before it even starts: 3,100 ms to the first sound. And anyone who searches for longer than two seconds still gets interrupted.
- B: Then it takes every little pause for the end of a sentence and talks over callers even more often. People are that fast because they predict the end of the sentence, not because they wait briefly.
- C, correct: “My customer number is …” calls for more. A turn model waits there and can even fire faster than a fixed threshold at the real end of the sentence. Add clean interrupting, in case it starts too early after all.

**Question 2:** The correct answer is B.
- A: That’s exactly the trap. The unheard rest is then in the history, and the model counts on a promise the caller never heard.
- B, correct: Those are the three steps of interrupting. Only with the third does the model know in the next round what the caller actually heard.
- C: Then it talks right over the objection, and the caller has to repeat themselves. On the phone, that comes across as if the agent isn’t listening.

**Question 3:** The correct answer is A.
- A, correct: Such a model can tell “mhm” from a real objection; OpenAI’s GPT-Live works like this. An agent that either listens or speaks can’t make that distinction.
- B: The threshold controls how long the agent waits for the caller to finish. It has no effect on a “mhm” in the middle of the agent’s own answer.
- C: Then “No, not Tuesday!” gets lost too. The caller couldn’t stop the agent at all anymore.

**Card 1:** **False.** The threshold only controls how long the agent waits for the caller to finish. Only a model that keeps listening while it speaks (full duplex) recognizes a “mhm” in the middle of its own answer; an agent that either listens or speaks can’t tell a “mhm” from an objection.

**Card 2:** Stop speech synthesis immediately, cancel generating the answer, and trim the conversation history to the part that was actually heard. If the third step is missing, the model counts on a promise the caller never heard.
