# Live text events

> The events that carry what was said, as text, while the conversation runs, and what Kheelona does and does not keep.

Source: https://docs.voice.kheelona.com/concepts/live-text/

While a session runs, Kheelona sends you the text of the conversation, so you can show captions, animate a character or
keep your own records. The text is sent live. **Kheelona does not keep it.** No audio and no conversation text is stored
or logged.

## The events

| Event | What it carries |
|---|---|
| `transcript.final` | What the person said: `turn`, `text`, `language`, `language_stage`, `language_beta`. One per turn, once it is understood. A typed turn gets one too. |
| `reply.sentence` | A sentence of the reply as it starts to play: `reply_id`, `index`, `text`, `emotion`. The text has no emotion tags in it. When the voice speaks several sentences in one go, the event for a later sentence is sent at the moment its audio is estimated to start, to within a fraction of a second. |
| `reply.started` and `reply.done` | The start and the end of a reply. `reply.done` has the `reason`: `completed`, `interrupted`, `safety` or `error`. |
| `state` | `listening`, `thinking` or `speaking`: for a face, a light or a talk button. |
| `input.speech_started` and `input.speech_stopped` | Speech was detected, and the turn ended. |
| `interrupted` | The person talked over the voice. `heard_ms` is how much of the reply they heard. |
| `safety` | A safety rule acted: a stage, a category and an action, never the words. See [Safety levels](https://docs.voice.kheelona.com/concepts/safety-levels.md). |

Every field is in the [server events reference](https://docs.voice.kheelona.com/reference/generated/events/server.md). Ignore event types and fields you
don't know: new ones can be added without a new version.

In the browser SDK the same events have names such as `transcript` and `replySentence`. See the
[browser SDK guide](https://docs.voice.kheelona.com/guides/browser-sdk.md#events).

## What the text is

- `transcript.final` is what the speech recogniser heard. It can be wrong, more so in beta and alpha languages (see [Languages](https://docs.voice.kheelona.com/concepts/languages.md)), so show it as what
  was heard, not as what was said.
- `reply.sentence` is what the voice says. It is the text of the audio that is playing, one sentence at a time.
- There is no partial text. The person's words arrive after they have finished, and a reply arrives one sentence at a time.
- Some replies come with no `transcript.final` before them: a greeting, a short line that invites the person to go on, a
  request to say it again, and the check-in and goodbye of a quiet session. They are ordinary replies. See
  [Turn-taking](https://docs.voice.kheelona.com/concepts/turn-taking.md).

## What happens to the text

- Kheelona sends it to you and forgets it. Not in logs, not in the connection records, not in usage.
- You receive the only copy. What you do with it is your responsibility. See [Captions](https://docs.voice.kheelona.com/guides/captions.md).
- The `instructions` you send are never stored in readable form either.
