# End of turn

> When Baton says a speaker has finished, how to trade speed against false cut-offs, and the answers and hints that come with a turn.

Source: https://docs.joinin.ai/baton/v2/guides/end-of-turn/ · Last updated 21 Oct 2026

People pause mid-sentence all the time. Baton sends `turn.end` when it is confident the speaker has finished, or when the silence runs out the timeout.

## How a turn ends

`turn.end` arrives after the speaker goes quiet, in one of two ways:

- Baton is confident the turn is complete (`by: "score"`). `p_eot` is the probability, from 0 to 1, that the turn is complete.
- The silence has gone on long enough that the turn ends anyway (`by: "timeout"`). The limit depends on the operating point.

If the speaker starts again within 2 s of `turn.end`, Baton sends `turn.resumed`. Treat that turn end as cancelled: see [Resumed turns].

Turn events always arrive. To also see each stretch of speech (`vad.start`, `vad.end`), add `vad` to `signals` in `session.start`. That changes only what you are sent, never when a turn ends.

## Resumed turns

`turn.resumed` means the `turn.end` before it was a pause, not the end: the same speaker started again within 2 s of it. `after_ms` is how long after `turn.end` they did. Every operating point has the same 2 s window, counted from `turn.end`, so the silence a turn end must outlast to stand is the operating point's delay plus 2 s: about 2.2 s for `cutoff_10pct`, 3.5 s for `patient`.

Handle it on every operating point, and expect it most on `patient`. `patient` exists for people who pause for a long time mid-answer, and some of those pauses are longer than its 1.5 s delay. On a 40 s meeting monologue with thinking pauses of 1.5 to 3.5 s, every `patient` `turn.end` was followed by `turn.resumed`. That is the operating point working as intended: each turn end was a cut-off, and `turn.resumed` is how you recover from it. The turn is not lost. It carries on, and its real end gets a new `turn.end`.

What to do:

- **Your reply has not started playing:** drop it, and wait for the next `turn.end`.
- **Your reply is already playing:** the user is now talking over your agent. With `bargein` in your `signals` and `agent.speech` messages, you also get `bargein.onset` and `bargein.class` for the same speech; let them decide whether your agent stops ([Barge-in](https://docs.joinin.ai/baton/v2/guides/barge-in/)).
- **Counting turns:** `session.summary.turns` counts turn ends minus those `turn.resumed` cancelled.
- **Hints and expected answers** for a cancelled turn end are cancelled with it, and come again with the turn's next `turn.end`.

If `turn.resumed` comes too often for your product, choose a slower operating point or raise `action_delay_ms` rather than ignoring it: a `turn.end` with no `turn.resumed` within 2 s is final.

## Operating points

Each operating point is a published trade-off between speed and **false cut-offs** (pauses wrongly ended as turns), measured on Baton's end-of-turn benchmark.

| Operating point | Mean latency | False cut-offs | Good for |
|---|---|---|---|
| `cutoff_10pct` | 317 ms | ≈ 10 % | Speed matters most and a short re-ask is cheap: bookings, support, confirmations |
| `cutoff_5pct` | 563 ms | ≈ 5 % | Most conversations: the balanced choice |
| `cutoff_2pct` | 861 ms | ≈ 2 % | People pause to think and an interruption costs more than a short wait: interviews, brainstorms |
| `patient` | 1658 ms | ≈ 1 % | Being cut off is unacceptable: slow, reflective answers with long pauses, coaching, therapy |

Latency is the mean delay from the end of speech to `turn.end`. English values, the same on `/v2/stream` and `/v2/room`; points for all 14 supported languages are published at [`GET /v2/eot/profiles`](https://docs.joinin.ai/baton/v2/reference/http-listEotProfiles/).

`patient` never ends a turn before 1.5 s of silence, and waits up to 6 s when unsure. It is for people who pause for a second or more mid-answer. It is slower everywhere, and slowest in languages where Baton is rarely sure a turn is over: check that language's numbers at `GET /v2/eot/profiles`.

## Choosing one

Set `eot` in `session.start`, by name or by the latency you can afford. Without `eot`, a session uses its `mode`'s default:

| `mode` | Default | Why |
|---|---|---|
| `transactional_call` (the default mode) | `cutoff_10pct` | Short, goal-driven exchanges should feel instant; an early turn end costs a quick "sorry, go on". |
| `working_session` | `cutoff_5pct` | Back-and-forth collaboration: balanced. |
| `one_on_one` | `cutoff_5pct` | Answers can run longer: balanced. Move to `cutoff_2pct` or `patient` if your users pause a lot. |
| `brainstorm` | `cutoff_2pct` | People think out loud and trail off mid-idea. |
| `formal` | `cutoff_2pct` | Interviews and considered answers, where interrupting reads as rude. |

No mode defaults to `patient`: name it when your users need the most room.

```
{
  "type": "session.start",
  "api_key": "baton_...",
  "eot": {"profile": "cutoff_5pct"}
}

```

```
{
  "type": "session.start",
  "api_key": "baton_...",
  "eot": {"latency_budget_ms": 600}
}

```

A latency budget picks the `cutoff_*` point with the closest mean latency; ties go to the faster one. With `{"latency_budget_ms": 600}`, a session gets `cutoff_5pct` (563 ms). A budget never picks `patient`; name it.

`session.started` reports the point in use:

```
{
  "type": "session.started",
  "schema_version": 2,
  "session_id": "3f7c...",
  "tier": "full",
  "signals": [],
  "eot": {
    "profile": "cutoff_5pct",
    "action_delay_ms": 300,
    "timeout_ms": 3000,
    "overridden": [],
    "rule": "score_point",
    "mean_latency_ms": 563,
    "cutoff_rate": 0.0482
  }
}

```

## Setting the delay and timeout yourself

Each point is three settings: how confident Baton must be, the silence before that confidence may end the turn (`action_delay_ms`), and the silence after which the turn ends anyway (`timeout_ms`). You can set the last two over any point; the confidence stays the point's.

```
{
  "type": "session.start",
  "api_key": "baton_...",
  "eot": {"profile": "patient", "timeout_ms": 8000}
}

```

`action_delay_ms` takes 0–5000 and `timeout_ms` 500–15000, both whole milliseconds, with the timeout no shorter than the delay. Anything else closes the socket with 1008. `session.started` then lists what you set in `overridden`, and reports `mean_latency_ms` and `cutoff_rate` as `null`: they were measured for the point's own settings, not yours.

A late answer needs no setting: no turn is open until the user speaks. What a longer delay protects is a pause in the middle of an answer.

## Conversation context

On `/v2/stream` and `/v2/room`, pass the conversation so far in `messages`. Baton uses it to judge whether an utterance is complete: "Paris" after "Where are you flying?" is a full answer.

`messages` is read once, at `session.start`. Baton keeps using it for the whole session; there is no message to update it, and `agent.speech` `text` is not added to it.

```
{
  "type": "session.start",
  "api_key": "baton_...",
  "messages": [
    {
      "role": "assistant",
      "content": "What city are you flying to?"
    }
  ]
}

```

## Your agent's echo

When the user hears your agent through a speaker, the microphone picks your agent up again, and it sounds like speech. Tell Baton what your agent says, with `text` and `duration_s` (or `words`) on `agent.speech` ([Barge-in](https://docs.joinin.ai/baton/v2/guides/barge-in/#tell-baton-what-your-agent-says)), and your agent's own voice:

- opens no turn, so there is no phantom `turn.end` when your agent finishes;
- never interrupts the silence of a turn that is already open;
- never stops your agent.

The user is still heard over it. A stop word, one of your `answer` keywords, or real speech of their own opens their turn while your agent talks. Expect a short wait when the user talks over a quiet echo without a keyword: Baton may hold the turn until your agent's echo ends.

Without these fields, `agent.speech` changes nothing about turns.

**Send `end` when your agent stops early.** If playback is cut short (the user interrupted, or your agent changed its mind), send `agent.speech` `end` with the same `utterance_id` and the `duration_s` that actually played. Until `end` arrives, Baton expects your agent's voice for the whole `duration_s` you announced, so the user's reply in that time is first checked against it and its turn can open a moment late.

### Turning echo handling off

If your audio never carries your agent's voice (headphones, a phone line, or your own echo cancellation), start the session with `"echo": "off"`:

```
{"type": "session.start", "api_key": "baton_...", "echo": "off", "signals": ["vad", "bargein"]}

```

Speech over your agent is then the user's at once: it opens their turn and counts as barge-in, with no wait to rule out an echo. Keep sending `agent.speech` start and end: barge-in and expected answers still use them. `session.started` carries `"echo": "on"` or `"off"`, whichever is in force. The default is `"on"`; leave it on whenever the microphone may hear your agent, or your agent's own voice will open turns and interrupt it.

### Quick answers

The most basic exchange is a short question, and "yes", "no" or "seven" straight back. That answer often starts before your agent's echo has died away, and is over before it can be transcribed. Baton still opens its turn, and with `expect` on the question it tells you which answer it was:

- Send `expect` with the question (see [Expected answers]). Once your agent has finished, a one-word answer from the list opens the user's turn at once.
- A turn opened this way is dated from when the user spoke, not from when Baton decided, so `vad.start` (with `vad` in your `signals`) can carry a `t` earlier than the audio just processed.

Measured offline on short questions (3–5 words) answered with a single word 0.1–2.5 s after the question ends, with `expect` set: at 0.3 s or later every answer opened its turn with the right `answer` over headphones, a speakerphone echo at −12 dB and a faint one at −25 dB; at 0.1 s, 24/24, 22/24 and 23/24. The question alone opened nothing.

Live on our test server, the same kind of test: over headphones 23/24 at 0.1 s and 24/24 from 0.3 s; on a speakerphone 19/24 at 0.1 s, 23/24 at 0.3–0.6 s and 24/24 from 1.0 s. A question alone opened no turn.

## Expected answers

Use this when your agent asks a question with a few possible answers: "How do you feel now?", "Yes or no?", "Pick a number from one to ten". `answer` tells you which of your answers the user gave, with a confidence, so your agent can act on it straight away instead of interpreting a transcript.

**1. Send the answers with the question.** Put `expect` on the `agent.speech` `start` that asks it:

```
{"type": "agent.speech", "phase": "start", "utterance_id": "u8",
 "text": "How do you feel now?", "expect": ["feel good", "feel bad"]}

```

**2. Read the answer.** It belongs to the user's next turn, and arrives in one of two places:

- **On the `turn.end` itself**, when it is ready in time. This is common for a turn that ended by timeout.
- **In a `turn.answer` shortly after**, when it is not. Live, it typically arrives 2–3 s after the `turn.end`, occasionally about 4 s, never more than 6 s. Its `turn_t` is the `t` of the `turn.end` it belongs to: match on that.

```
{"type": "turn.end", "seq": 12, "t": 14.2, "speaker": "user",
 "p_eot": 0.82, "latency_ms": 300, "by": "score",
 "profile": "cutoff_5pct"}
{"type": "turn.answer", "seq": 13, "turn_t": 14.2,
 "answer": {"match": "feel good", "score": 0.91,
            "runner_up": "feel bad",
            "scores": {"feel good": 0.91, "feel bad": 0.06,
                       "none": 0.03}}}

```

A turn that followed `expect` gets exactly one answer: on its `turn.end` or in one `turn.answer`, never both. If `turn.end` has no `answer` field, wait for the `turn.answer`.

**3. Act on it.**

- `match` is the answer the user gave, as you sent it. It is `null` when they said none of them ("none" scored highest): treat it as an open answer, and use your transcript or ask again.
- `score` is the confidence in `match` (or in "none of them" when `match` is `null`), from 0 to 1. At 0.9 or more, act on it. Below that, confirm: "Was that a yes?".
- `runner_up` is the next most likely answer, and `scores` has every answer's confidence and `none`'s, summing to 1. Use them when two answers are close.
- `answer` itself is `null` when Baton could not tell: the session's language is not English, or no result came within 6 s.

**Good to know.**

- `expect` covers the next turn only, then is cleared. Any later `agent.speech` `start` replaces it: with `expect`, by the new list; without, by none. If your agent says something more after the question ("Take your time."), send `expect` again on that utterance.
- `expect` answers do not cut your agent short while it is still talking. For that, also list them as `answer` [keywords](https://docs.joinin.ai/baton/v2/guides/barge-in/#stop-words-and-answers).
- A `turn.resumed` cancels the answer with its turn end; the answer comes again with the turn's next `turn.end`.
- **Ending the session:** a `turn.answer` still pending at `session.end` is not sent. If you need it, wait for it (at most 6 s after the `turn.end`) before you send `session.end`.
- Rules: 1 to 20 answers, 1 to 4 words and at most 60 characters each. Case, punctuation and number spelling don't matter ("seven" and "7" are the same answer, so you can't send both), and `none` is reserved. Anything else closes the session with 1008. English only: the session's language must be `en` (the default, or the first of an allowed set) or `auto`.
- Expected answers and their scores are never logged or stored.

## Hints

Short answers are the words most often lost: an isolated "Yes." or "Two" can end a turn with no words at all, and an agent waiting for words that never come leaves the user hanging. When Baton heard speech in a turn but no clear words, `hint` carries its best guess at what was said.

**Where it arrives.** Like an answer, in one of two places:

- **On the `turn.end` itself**, when it is ready in time (common for a turn that ended by timeout):

`json {"type": "turn.end", "seq": 6, "t": 9.6, "speaker": "user", "p_eot": 0.12, "latency_ms": 6000, "by": "timeout", "profile": "patient", "hint": {"suspect": "speech_without_words", "text": "Yes.", "certainty": "low"}}`

- **In a `turn.hint` shortly after**, typically 2–3 s after the `turn.end`, occasionally about 4 s, never more than 6 s. `turn_t` is the `t` of the `turn.end` it belongs to:

`json {"type": "turn.hint", "seq": 4, "turn_t": 3.0, "hint": {"suspect": "speech_without_words", "text": "Yes.", "certainty": "low"}}`

There is no hint when every word was heard, and at most one per turn end.

**Act on it.**

- `text` is Baton's best guess. Treat it as a guess to confirm, not a transcript: it can hold a word that was not said. A good use is "Sorry, was that a yes?" instead of silence.
- `text` can be empty: Baton heard speech but could not make out any words. Ask the user to repeat.
- `certainty` is always `low` today: confirm before acting on `text`.
- `suspect` says what looked missed: `speech_without_words` (speech, but no words at all), `undecoded_tail` (speech after the last word), `few_words` (fewer words than the speech suggests).
- When the turn also had `expect` and the answer is confident (`score` 0.9 or more), the hint's `text` is that answer.

**Good to know.**

- A `turn.resumed` cancels any hint for the turn end it cancels.
- In a room, a word counts as heard once it is in the room's transcript (`asr.partial` or `asr.final`), also when it arrives just after the `turn.end`. A hint there means words your transcript is missing, not a second version of words it has.
- A `turn.hint` still pending at `session.end` is not sent: wait for it if you need it.
- Hints, like transcripts, are never logged or stored.
