> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lokutor.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Godot API Reference

> Every class, property, signal and method of the Lokutor addon for Godot 0.2.0: LokutorAgent, LokutorLipSync, LokutorVoice, LokutorVoiceAgentClient, LokutorTTSClient, LokutorSTTClient, LokutorSpeechToTextClient and their helpers.

Version 0.2.0, Godot 4.3 or newer. Install it as in [Godot: introduction](https://docs.lokutor.com/sdks/godot/introduction.md). The names
match the [JavaScript](https://docs.lokutor.com/sdks/javascript/reference.md) and [Python](https://docs.lokutor.com/sdks/python/reference.md) SDKs; the
[parity table](https://docs.lokutor.com/guides/game-engines.md#the-same-sdk-everywhere) puts the four side by side.

Methods marked with `await` are coroutines. Signals are emitted on the main thread.

| Class | What it is |
| :- | :- |
| [`LokutorAgent`](#lokutoragent) | a character you can talk to |
| [`LokutorAction`](#lokutoraction) | an action wired in the Inspector |
| [`LokutorLipSync`](#lokutorlipsync) | a mouth |
| [`LokutorVoice`](#lokutorvoice) | a character that says written lines |
| [`LokutorVoiceAgentClient`](#lokutorvoiceagentclient) | a conversation, without the character |
| [`LokutorTTSClient`](#lokutorttsclient) | text to speech |
| [`LokutorSTTClient`](#lokutorsttclient) | transcription of a recording |
| [`LokutorSpeechToTextClient`](#lokutorspeechtotextclient) | live transcription |
| [`LokutorMicrophone`](#lokutormicrophone) | the microphone |
| [`LokutorVoicePlayer`](#lokutorvoiceplayer) | a voice being played |
| [`Lokutor`](#lokutor) | constants and discovery |
| [`LokutorAudio`](#lokutoraudio) | PCM helpers |
| [`LokutorError`](#lokutorerror) | an error |

## `LokutorAgent`

`extends Node3D`

Makes its parent character a voice agent: it listens through the microphone, answers in its own voice from where it stands (3D audio), moves its mouth, and calls your game's functions ("actions") when the conversation calls for it.

### LokutorAgent properties

**Account** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `api_key` | `String` | `""` | Your Lokutor API key (dashboard > API keys). Fine while prototyping; a shipped game should set `ticket_provider` so the key stays on your server. Empty: the `LOKUTOR_API_KEY` environment variable, and in a web browser no key at all (see [Games in a browser](https://docs.lokutor.com/guides/game-web.md)). |
| `agent_id` | `String` | `""` | Optional: an agent built in the Lokutor dashboard. Its persona, voice and language are used unless set below. |

**Character** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `persona` | `String` | `"You are a friendly villager in a fantasy town. Answer in one or two short sentences."` | Who the character is, what it knows and how it talks. |
| `context_heading` | `String` | `"Right now in the game:"` | The line above what `set_context` tells the character. Write it in the language of the persona. |
| `voice` | `String` | `"F1"` | F1-F5 (female) or M1-M5 (male), or a voice id from the Lokutor dashboard. |
| `language` | `String` | `"en"` | en, es, fr, pt, ca, gl, eu... or "auto": the character follows the language the player speaks. Empty = the default ("en"; a dashboard agent keeps its own). |
| `pitch` | `float` | `0.0` | Shifts the voice up or down: small creatures, giants. -12.0 to 12.0. |
| `start_on_ready` | `bool` | `true` | Start talking as soon as the scene starts. Off: call start\_conversation() (e.g. when the player walks up). |
| `auto_reconnect` | `bool` | `true` | Open the connection again when it drops; the character then starts a fresh conversation. |

**Voice** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `spatial_voice` | `bool` | `true` | The voice comes from this node's position (3D). Off: heard the same everywhere. |
| `voice_bus` | `StringName` | `&"Master"` | The audio bus the voice plays on: put a radio, a cave or a giant's chest on it. |
| `voice_output` | `Node` | — | Play through your own AudioStreamPlayer, AudioStreamPlayer2D (2D games) or AudioStreamPlayer3D. |

**Microphone** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `mic_mode` | `MicMode` | `MicMode.ALWAYS` | `ALWAYS`: the microphone is open and the server detects turns. `PUSH_TO_TALK`: heard only while the action is held. `OFF`: no microphone; the character hears only `feed_microphone()`. |
| `push_to_talk_action` | `StringName` | `&""` | An Input Map action held to talk in PUSH\_TO\_TALK mode (or call set\_talking()). |
| `mute_mic_while_speaking` | `bool` | `true` | Mutes the microphone while the character talks, so speakers can't make it interrupt itself, and while any other `LokutorAgent` or `LokutorVoice` does, so that it does not answer them. Turn off when players use headphones and should be able to interrupt. |
| `guard_against_echo` | `bool` | `true` | With the microphone open while the character talks, what the player "said" may be the character's own last words coming back from the speakers: that is not passed on as `player_said`, `echo_heard` is emitted, and `mute_mic_while_speaking` is turned on. |

**Lip sync** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `lip_sync` | `LokutorLipSync` | — | A LokutorLipSync: blend shapes of any rig, jaw bones, 2D sprites. Or use the simple options below. |
| `jaw` | `Node3D` | — | A jaw (or head part) rotated around its local X axis as the character speaks. |
| `jaw_max_angle_degrees` | `float` | `12.0` | How far the jaw turns at its widest. |
| `face` | `MeshInstance3D` | — | Or a face mesh: the 15 viseme shapes are found by name. |
| `mouth_blend_shape` | `StringName` | `&""` | A mesh with only a mouth-open blend shape: its name. |
| `mouth_gain` | `float` | `1.5` | Loudness multiplier of a mouth without visemes. 0.2 to 5.0. |

**Game actions** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `actions` | `Array[LokutorAction]` | `[]` | Actions the character can use, wired to methods in the Inspector. |
| `action_filler` | `bool` | `false` | The server has the character say "One moment" or the like while an action runs, or what the model wrote before it. Off: it says nothing until its answer. |
| `speak_before_actions` | `bool` | `true` | What it begins to say before it calls an action is heard. Turn it off with an action that it must call before it answers ("how funny that was"): the model can write its plan there. |

**From code**

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `ticket_provider` | `Callable` | — | For a shipped game: returns (or awaits) a short-lived ticket from **your** server, which calls `POST https://api.lokutor.com/ws-ticket` with the API key. |
| `url` | `String` | `Lokutor.VOICE_AGENT_URL` | The voice agent endpoint. Change it for a local server or a proxy. |
| `llm` | `Dictionary` | `{}` | Your own language model behind an OpenAI-compatible endpoint: `{base_url, api_key, model, headers, tools, speculative_llm}`. Set before `start_conversation()`. |
| `on_llm_request` | `Callable` | — | Your own model, running in the game (see `LokutorVoiceAgentClient.on_llm_request`). |
| `state` | `State` | `State.DISCONNECTED` | What the conversation is doing now. |
| `mouth_open` | `float` | `0.0` | How open the mouth should be right now, 0 to 1, following the audio being heard. |
| `muted` | `bool` | `false` | The player's microphone is off: the character hears silence. |
| `is_speaking` | `bool` | — | The character's voice is being heard. Read only. |
| `session_id` | `String` | — | The server's id of this session. Read only. |
| `playback_rate` | `int` | — | Rate of the character's voice. Read only. |
| `client` | `LokutorVoiceAgentClient` | — | The conversation underneath, for what this node does not cover. Null until `start_conversation()`. |
| `player` | `LokutorVoicePlayer` | — | The voice's player. Null until `start_conversation()`. |
| `microphone` | `LokutorMicrophone` | — | The microphone. Null until `start_conversation()`, or with `mic_mode` off. |
| `record_output` | `bool` | `false` | For tests: when true, everything the character says is also appended to recorded\_output (mono). |
| `recorded_output` | `PackedFloat32Array` | — | What `record_output` kept. |
| `simulate_audio_device` | `bool` | `false` | No sound card (headless runs, servers): the voice is consumed in real time without being played. |

### LokutorAgent signals

| Signal | Emitted when |
| :- | :- |
| `player_said(text: String)` | What the player said, once the turn is over. |
| `player_said_partial(text: String)` | The player's words while they are still talking. |
| `character_said(text: String)` | What the character is about to say. `Lokutor.strip_tags(text)` takes out `[laugh]` and the like for subtitles. |
| `character_interrupted(heard: String)` | The player cut the character off; `heard` is what they actually heard. |
| `state_changed(state: State)` | The conversation moved to another `State`. |
| `action_called(action_name: String, args: Dictionary, result: String)` | An action ran: its name, the arguments the character chose, and what it returned. |
| `error_occurred(code: String, message: String)` | Something failed. `code` is one of the [error codes](https://docs.lokutor.com/api-reference/errors.md). |
| `conversation_ended(reason: String)` | The conversation is over: why. |
| `reconnecting()` | The connection dropped and is being opened again. |
| `reconnected()` | It is open again, in a fresh conversation. |
| `visemes_received(list: Array)` | Mouth shapes of the reply, as they arrive: `[{v, c, t, d}]`. `LokutorLipSync` already uses them. |
| `voice_played(samples: PackedFloat32Array, rate: int)` | The character's voice, as it is played: for another character, or a recorder, that listens to it. |
| `session_limit(seconds: float, reason: String)` | The server announced how many seconds this session may still run, and why. In a browser it is also sent to the page (`Lokutor.tell_page`). |
| `echo_heard(text: String)` | The microphone heard the character's own words (speakers, no headphones). The line is not passed on as `player_said`, and `mute_mic_while_speaking` is turned on. |
| `demo_limit(limit: String, message: String)` | The lokutor.com demo (a browser with no key) ended or refused this conversation: `"call"` (it reached its length), `"daily"` (the visitor's minutes for today are used) or `"busy"` (the demo is full right now), and the server's words. Also sent to the page. |

### LokutorAgent methods

#### `add_action(action_name: String, description: String, handler: Callable, params: Dictionary = {}) -> void`

Lets the character call a game function. `params` maps each argument to a description (`{"item": "Which item"}`) or to a JSON-schema dictionary (`{"item": {"type": "string", "enum": [...]}}`). The handler receives a Dictionary of arguments and returns a short sentence saying what happened; it may `await`. Works before or during a conversation.

#### `remove_action(action_name: String) -> void`

The character can no longer call it.

#### `start_conversation() -> void`

Opens the conversation: the character greets the player and starts listening.

#### `stop_conversation() -> void`

Ends the conversation and releases the microphone.

#### `set_persona(new_persona: String) -> void`

Changes who the character is, mid-conversation.

#### `set_context(key: String, value) -> void`

Tells the character something about the game right now (`"Time left"`, `"20 seconds"`), without rewriting its persona. A value of `null` takes it out. Changes in the same quarter second are sent together. A dashboard agent needs a `persona` for this: its own prompt cannot be extended from the game.

#### `set_voice(new_voice: String) -> void`

Changes the voice, mid-conversation.

#### `set_language(new_language: String) -> void`

Changes the language, mid-conversation. `"auto"`: the character follows the language the player speaks.

#### `set_pitch(new_pitch: float) -> void`

Shifts the voice up or down, mid-conversation.

#### `reset_conversation() -> void`

Forgets the conversation so far: the character starts fresh.

#### `get_transcript() -> Array`

The conversation so far, or the last one: `[{role, text, timestamp}]`.

#### `set_talking(talking: bool) -> void`

Push-to-talk from any input: true while the player holds the button.

#### `feed_microphone(samples: PackedFloat32Array, rate: int) -> void`

Sends audio you captured yourself (mono floats at `rate`), e.g. from another source or another character.

#### `heard_seconds() -> float`

How much of the current reply has been heard, in seconds: the clock visemes are read against.

#### `voice_level() -> float`

Loudness of the character's voice right now, 0 to 1.

#### `is_echo(heard: String) -> bool`

Whether `heard` is the character's own recent words coming back through the microphone: three words or more, and three in four of them among what it said in its last replies. `guard_against_echo` uses it.

### LokutorAgent.State

What the conversation is doing. Values: `DISCONNECTED`, `CONNECTING`, `READY`, `PLAYER_TALKING`, `THINKING`, `SPEAKING`.

### LokutorAgent.MicMode

When the character hears the player. Values: `ALWAYS`, `PUSH_TO_TALK`, `OFF`.

## `LokutorAction`

`extends Resource`

A game action set up in the Inspector: when the character decides to use it, `method` is called on the node at `target`. See [Actions](https://docs.lokutor.com/sdks/godot/actions.md).

### LokutorAction properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `action_name` | `String` | `"open_gate"` | What the character calls it, e.g. open\_gate. Letters, digits and \_ only. |
| `description` | `String` | `"Opens the town gate for the player."` | When the character should use it, in plain words. |
| `reply` | `String` | `"The gate is now open."` | What the character is told happened, so it can say so. |
| `target` | `NodePath` | — | The node to call, relative to the LokutorAgent. |
| `method` | `StringName` | — | The method to call on it (no arguments). |

## `LokutorLipSync`

`extends Node`

Moves a mouth with a voice. Give it a face (blend shapes), a jaw, or a 2D sprite with mouth frames; LokutorAgent and LokutorVoice feed it visemes and the clock of what is being heard. See [Lip sync](https://docs.lokutor.com/sdks/godot/lip-sync.md).

### LokutorLipSync properties

**Blend shapes** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `faces` | `Array[MeshInstance3D]` | `[]` | The meshes whose mouth moves: usually the face, plus teeth or tongue if they have the shapes too. |
| `mapping` | `Dictionary` | `{}` | Your rig, when its names are not recognised: viseme name to blend shapes and weights, `{"aa": {"gape": 0.8}}`. |

**Jaw** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `jaw` | `Node3D` | — | A jaw (or head part) rotated around its local X axis. |
| `skeleton` | `Skeleton3D` | — | Or a bone of a skeleton. |
| `jaw_bone` | `String` | `""` | The bone's name. |
| `jaw_max_angle_degrees` | `float` | `12.0` | How far the jaw turns at its widest. |

**2D** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `sprite` | `Node` | — | A Sprite2D, AnimatedSprite2D or any node with a `frame` property, whose frames are mouths. |
| `sprite_frames` | `Dictionary` | `{}` | Frame for each viseme. Empty: 0 closed, 1 slightly open, 2 open, 3 round (if the sprite has them). |

**Feel** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `intensity` | `float` | `1.0` | How far the mouth opens. 0.0 to 2.0. |
| `lead` | `float` | `0.05` | Seconds the mouth leads the sound: people open before they speak. 0.0 to 0.2. |
| `blend` | `float` | `0.07` | Seconds over which one shape melts into the next. 0.05 is crisp and cartoonish, 0.12 soft. 0.01 to 0.3. |
| `loudness` | `float` | `0.35` | How much quiet speech closes the mouth, 0 to 1. 0.0 to 1.0. |
| `stepped_fps` | `float` | `0.0` | Steps per second of the mouth, for a hand-drawn look (12 = animation on twos). 0 = smooth. |

**From code**

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `mouth_open` | `float` | `0.0` | How open the mouth is, 0 to 1. |
| `weights` | `PackedFloat32Array` | `PackedFloat32Array()` | Weight of each of the 15 visemes right now, in `Lokutor.VISEMES` order. |
| `current` | `String` | `"sil"` | The strongest one. |
| `gain` | `float` | `1.5` | Loudness multiplier for mouths that follow the loudness (no visemes). |

### LokutorLipSync signals

| Signal | Emitted when |
| :- | :- |
| `viseme_changed(viseme: String)` | The mouth changed shape. Use it to swap sprites or sounds yourself; `weights` has the blend between shapes. |

### LokutorLipSync methods

#### `bind() -> void`

Finds the blend shapes again, after changing faces or mapping at runtime.

#### `rig() -> Rig`

Which kind of mouth was found.

#### `push_visemes(list: Array, source: Object = null) -> void`

The visemes of the reply being heard, as they arrive: `[{v, t, d}]`. `source` is whose voice it is, when several share the mouth.

#### `clear(source: Object = null) -> void`

A new reply, or silence: the mouth closes. Without a source, whoever is speaking.

#### `has_visemes() -> bool`

Whether the voice being heard has visemes. Without them the mouth follows the loudness.

#### `release(source: Object = null) -> void`

This voice is gone: the mouth closes, or follows another.

#### `advance(heard: float, level: float, speaking: bool, delta: float, source: Object = null) -> void`

One frame of the mouth. `heard` is how much of the reply has been heard (`LokutorVoicePlayer.heard_seconds()`), `level` its loudness, `speaking` whether it is playing at all. Called for you by LokutorAgent and LokutorVoice.

### LokutorLipSync.Rig

The kinds of mouth it finds in a face. Values: `NONE`, `VISEMES`, `VRM`, `ARKIT`, `MOUTH_OPEN`, `CUSTOM`.

### LokutorLipSync constants

| Constant | Type | Value | Description |
| :- | :- | :- | :- |
| `OPENNESS` | `Array` | — | How open each viseme is (0 to 1), for jaws and mouth-open shapes. |
| `VRM` | `Array` | — | The five VRM mouths of each viseme. |
| `ARKIT` | `Array` | — | The ARKit blend shapes of each viseme. |

## `LokutorVoice`

`extends Node3D`

A character that says written lines (barks, narration, tutorials): text to speech played from its place in the world, with lip sync. Lines are kept on disk, so a line said again costs nothing and starts at once. See [Speech](https://docs.lokutor.com/sdks/godot/speech.md).

### LokutorVoice properties

**Account** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `api_key` | `String` | `""` | Empty: the `LOKUTOR_API_KEY` environment variable. |

**Voice** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `voice` | `String` | `"F1"` | `F1`-`F5`, `M1`-`M5`, or a voice id from the dashboard. |
| `language` | `String` | `"en"` | The language of its lines. |
| `spatial_voice` | `bool` | `true` | The voice comes from this node's position (3D). Off: heard the same everywhere. |
| `voice_bus` | `StringName` | `&"Master"` | The audio bus the voice plays on. |
| `voice_output` | `Node` | — | Play through your own AudioStreamPlayer, AudioStreamPlayer2D or AudioStreamPlayer3D. |
| `mutes_microphones` | `bool` | `true` | Agents do not listen while this voice is heard (see `mute_mic_while_speaking`). Off for a voice too far away to reach the player's microphone. |
| `cache_dir` | `String` | `"user://lokutor_voices"` | Where lines are kept. Empty: nowhere. `res://voices` ships recorded lines with the game (see `save_lines_to()`). |

**Lip sync** (in the Inspector)

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `lip_sync` | `LokutorLipSync` | — | A `LokutorLipSync`. It can be the same one a LokutorAgent uses: the mouth follows whoever is speaking. |
| `jaw` | `Node3D` | — | Or a jaw, rotated around its local X axis. |
| `face` | `MeshInstance3D` | — | Or a face mesh whose mouth is found by name. |

**From code**

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `ticket_provider` | `Callable` | — | For a shipped game: returns (or awaits) a short-lived ticket from **your** server. |
| `url` | `String` | `Lokutor.TTS_URL` | The text-to-speech endpoint. |
| `simulate_audio_device` | `bool` | `false` | No sound card (headless runs, servers): lines are consumed in real time without being played. |
| `mouth_open` | `float` | `0.0` | How open the mouth should be right now, 0 to 1. |
| `speaking` | `bool` | — | A line is being said. Read only. |
| `tts` | `LokutorTTSClient` | — | The client underneath. |
| `player` | `LokutorVoicePlayer` | — | The voice's player. |

### LokutorVoice signals

| Signal | Emitted when |
| :- | :- |
| `line_started(text: String)` | A line is being heard. |
| `line_finished(text: String)` | It has been heard to the end, or was stopped. |
| `error_occurred(code: String, message: String)` | A line could not be made. `code` is one of the [error codes](https://docs.lokutor.com/api-reference/errors.md). |
| `demo_limit(limit: String, message: String)` | The lokutor.com demo (a browser with no key) would not make a line: `"daily"`, `"busy"` or `"call"`, as `LokutorAgent.demo_limit`. In a browser with no key every LokutorVoice speaks through one shared connection. |

### LokutorVoice methods

#### `say(text: String, options: Dictionary = {}) -> bool`

Says a line; with `await`, returns when it has been heard (`true`) or could not be said (`false`). Lines wait for each other. Options override the voice for this line: `voice`, `language`, `interrupt` (say it now, dropping what is being said).

#### `stop() -> void`

Stops at once and forgets the lines waiting.

#### `preload_lines(lines: PackedStringArray, options: Dictionary = {}) -> void`

Fetches lines before they are needed, so they start at once and, once kept, work without a network. Use it with `await`.

#### `has_line(text: String, options: Dictionary = {}) -> bool`

Whether a line is already on disk.

#### `save_lines_to(folder: String, lines: PackedStringArray, options: Dictionary = {}) -> void`

Keeps lines in a project folder (run it from the editor or a tool script): set `cache_dir` to it and ship the game with its lines recorded. Use it with `await`.

## `LokutorVoiceAgentClient`

`extends Node`

A voice conversation over `/ws/agent`, with the same options, methods and events as `VoiceAgentClient` in the JavaScript and Python SDKs. Add it to the tree and call `open()`.

For a character in a scene use LokutorAgent, which adds the microphone, the 3D voice, lip sync and actions on top of this. Use this one when you want the conversation and nothing else. Two names differ from JavaScript because Godot's Object already has them: `connect()` is `open()` and `disconnect()` is `close()`.

### LokutorVoiceAgentClient properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `api_key` | `String` | `""` | An API key, or a `wst_` ticket. Fine while prototyping; a shipped game should set `auth`. |
| `auth` | `Callable` | — | Called (and awaited) before every connect and reconnect for the credential to use: have it ask your server for a ticket (`POST https://api.lokutor.com/ws-ticket`), so the key never ships with the game. |
| `agent_id` | `String` | `""` | An agent from the dashboard. Then `voice`, `language` and `prompt` are sent only if you set them. |
| `server_url` | `String` | `Lokutor.VOICE_AGENT_URL` | The voice agent endpoint. |
| `tools` | `Array` | `[]` | Functions the agent may call, as OpenAI tool definitions. |
| `want_visemes` | `bool` | `false` | Ask for visemes. |
| `llm` | `Dictionary` | `{}` | Your own OpenAI-compatible endpoint: `{base_url, api_key, model, headers, tools, speculative_llm}`. See [Bring your own LLM](https://docs.lokutor.com/guides/bring-your-own-llm.md). |
| `on_llm_request` | `Callable` | — | Your model runs in the game: `func(messages: Array, tools: Array, reply: LokutorVoiceAgentClient.LlmReply)`. Return the reply as a String, or call `reply.chunk(text)` as it is produced. |
| `llm_tools` | `String` | `"auto"` | `"none"`: the agent's tools are not sent to `on_llm_request`. |
| `auto_reconnect` | `bool` | `true` | Open the connection again when it drops (2 s, 4 s, 8 s, 10 s, 10 s). |
| `max_reconnect_attempts` | `int` | `5` | Attempts before giving up. |
| `connect_timeout` | `float` | `15.0` | Seconds to wait for the connection. |
| `user_agent` | `String` | `"lokutor-godot/" + Lokutor.VERSION` | Sent when connecting. |
| `prompt` | `String` | `""` | The system prompt. |
| `voice` | `String` | `"F1"` | `F1`-`F5`, `M1`-`M5`, or a voice id from the dashboard. |
| `language` | `String` | `"en"` | `"auto"` or `""`: the agent follows the player's language. |
| `pitch` | `float` | `0.0` | Shifts the voice up or down. |
| `generation` | `int` | `0` | The reply being spoken. Grows by one with each reply of a session. |
| `session_id` | `String` | `""` | The server's id of this session. |
| `playback_rate` | `int` | `Lokutor.OUTPUT_RATE` | Rate of the agent's audio, announced by the server. |
| `input_rate` | `int` | `Lokutor.INPUT_RATE` | Rate the server expects of the microphone. |
| `connected` | `bool` | — | The session is open. Read only. |
| `microphone` | `LokutorMicrophone` | — | Set by `start_managed()`: the microphone this client runs. |
| `player` | `LokutorVoicePlayer` | — | Set by `start_managed()`: the speaker this client runs. |

### LokutorVoiceAgentClient signals

| Signal | Emitted when |
| :- | :- |
| `transcription(text: String)` | A final line of player speech. |
| `transcription_partial(text: String)` | The player's words while they are still talking. Not stored in `get_transcript()`. |
| `response(text: String)` | What the agent is about to say. |
| `audio(pcm16: PackedByteArray, generation: int)` | The agent's voice: 16-bit PCM, mono, at `playback_rate`. Audio of replies already superseded never gets here. |
| `visemes(list: Array, generation: int)` | Mouth shapes of the reply: `[{v, c, t, d}]`, `t` and `d` in seconds from the reply's first sample. |
| `status(value: String)` | `connected`, `listening`, `thinking`, `speaking`, `interrupted`, acknowledgements, and the client's own `reconnecting` and `disconnected`. |
| `error(err: LokutorError)` | Something failed, as a [`LokutorError`](#lokutorerror). |
| `tool_call(call: Dictionary)` | The agent wants a function called: `{name, arguments, call_id}`; `arguments` is a JSON string. Answer with `submit_tool_result(call_id, result)`. |
| `generation_started(generation: int)` | A new reply has begun: whatever was queued of the previous one must not be played. |
| `transcript_truncated(heard: String, full: String)` | The player cut the agent off: `heard` is what they heard of `full`. |
| `transcript_revised(text: String, previous: String)` | The player's paused sentence and its continuation became one line: `text` replaces `previous`. |
| `session_limit(seconds: float, reason: String)` | How many seconds this session may still run, when the server sets a limit. |
| `reconnected()` | A dropped connection was opened again. It is a new server session: the agent does not remember the old one. |
| `ended(code: int, reason: String)` | The server ended the session on purpose; no reconnection follows. |

### LokutorVoiceAgentClient methods

#### `static create(config: Dictionary) -> LokutorVoiceAgentClient`

A client from a dictionary of options, as in JavaScript: `LokutorVoiceAgentClient.create({"api_key": key, "prompt": "You are Mira.", "voice": "F2", "visemes": true})`. Add it to the tree.

#### `configure(config: Dictionary) -> LokutorVoiceAgentClient`

Sets options by name. `on_transcription`, `on_response`, `on_audio`, `on_visemes`, `on_status` and `on_error` connect a callback.

#### `open() -> bool`

Opens the session and sends the configuration. Returns `true` once connected, `false` if it could not (the reason is emitted as `error`). Use it with `await`.

#### `close() -> void`

Ends the session and releases the microphone.

#### `start_managed() -> bool`

Runs the microphone and the speaker too: a whole conversation in one call. Use it with `await`.

#### `send_audio(pcm16: PackedByteArray) -> void`

Sends microphone audio: 16-bit PCM, 16 kHz, mono. Keep sending it (silence too): the server measures pauses in it.

#### `send_audio_float(samples: PackedFloat32Array, rate: int) -> void`

The same from float samples at any rate.

#### `update_prompt(new_prompt: String) -> void`

Replaces the prompt, mid-session.

#### `update_voice(new_voice: String) -> void`

Changes the voice, mid-session.

#### `update_language(new_language: String) -> void`

Changes the language, mid-session.

#### `update_tools(new_tools: Array) -> void`

Replaces the tools, mid-session.

#### `update_pitch(new_pitch: float) -> void`

Shifts the voice's pitch for the rest of the session.

#### `update_visemes(enabled: bool) -> void`

Asks for visemes, or stops asking, from the next reply on.

#### `reset() -> void`

Clears the conversation: the agent starts fresh.

#### `submit_tool_result(call_id: String, result) -> void`

Answers a `tool_call`. `result` is a String, or anything JSON can carry.

#### `get_transcript() -> Array`

The conversation so far: `[{role, text, timestamp}]`, `timestamp` in milliseconds (`Time.get_ticks_msec()`).

#### `get_transcript_text() -> String`

The same as text, a line each.

#### `toggle_mute() -> bool`

Mutes or unmutes the managed microphone; returns whether it is now muted.

#### `get_amplitude() -> float`

The managed microphone's loudness, 0 to 1.

#### `static fetch_voices(base_url: String = Lokutor.VOICE_AGENT_URL) -> Array`

As [`Lokutor.fetch_voices()`](#lokutor). Use it with `await`.

#### `static fetch_languages(base_url: String = Lokutor.VOICE_AGENT_URL) -> Array`

As `Lokutor.fetch_languages()`. Use it with `await`.

#### `static fetch_models(base_url: String = Lokutor.VOICE_AGENT_URL) -> Array`

As `Lokutor.fetch_models()`. Use it with `await`.

#### `static fetch_config(base_url: String = Lokutor.VOICE_AGENT_URL) -> Dictionary`

As `Lokutor.fetch_config()`. Use it with `await`.

#### `static fetch_status(base_url: String = Lokutor.VOICE_AGENT_URL) -> Dictionary`

As `Lokutor.fetch_status()`. Use it with `await`.

#### `static fetch_health(base_url: String = Lokutor.VOICE_AGENT_URL) -> Dictionary`

As `Lokutor.fetch_health()`. Use it with `await`.

#### `config_messages() -> Array`

The configuration sent on connect, in order. `rates` is last: it starts the conversation.

#### `handle_message(text: String) -> void`

Handles one message from the server. Public so tests can feed it.

#### `static normalize_visemes(payload) -> Array`

`[{v, c, t, d}]` from what the server sends. A missing duration lasts until the next one starts.

### LokutorVoiceAgentClient constants

| Constant | Type | Value | Description |
| :- | :- | :- | :- |
| `RECONNECTABLE` | `Array` | — | The same list as `Lokutor.RECONNECTABLE_CLOSE_CODES`. |

### `LlmReply`

`extends RefCounted`

The reply of your own model to one llm\_request. Stop when `cancelled` turns true: the player spoke over it.

#### LlmReply properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `cancelled` | `bool` | `false` | The player spoke over the reply: stop. |

#### LlmReply methods

##### `chunk(text: String) -> void`

More text. Lokutor starts speaking at the first sentence.

##### `tool_call(tool_name: String, arguments, id := "") -> void`

One of the agent's tools to call. `arguments` is a JSON string, or anything JSON can carry.

##### `done() -> void`

The reply is complete. Returning from the handler does it for you.

##### `fail(message: String) -> void`

The model failed: the agent is told so.

## `LokutorTTSClient`

`extends Node`

Text to speech over `/ws/tts`, as `TTSClient` in the JavaScript and Python SDKs. Add it to the tree. For a character that says written lines use LokutorVoice, which plays them and moves the mouth.

### LokutorTTSClient properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `api_key` | `String` | `""` | An API key, or a `wst_` ticket. |
| `auth` | `Callable` | — | Called (and awaited) for the credential: a ticket from your server, in a shipped game. |
| `server_url` | `String` | `Lokutor.TTS_URL` | The text-to-speech endpoint. |
| `keep_open_seconds` | `float` | `8.0` | Keep the connection open this long after a request, so the next one skips the handshake. It counts as a session. |

### LokutorTTSClient signals

| Signal | Emitted when |
| :- | :- |
| `audio(pcm16: PackedByteArray)` | 16-bit PCM, 44.1 kHz, mono, as it is generated. |
| `visemes(list: Array)` | `[{v, c, t, d}]`, `t` from the request's first sample. |
| `ttfb(ms: int)` | Milliseconds until the first audio. |
| `error(err: LokutorError)` | A request failed, as a [`LokutorError`](#lokutorerror). |

### LokutorTTSClient methods

#### `synthesize(text: String, options: Dictionary = {}) -> Dictionary`

Speaks `text` and returns `{ok, audio, sample_rate, visemes, error}` when it is complete; `audio` and `visemes` are also emitted as they arrive. Requests run one after another.

Options: `voice`, `language`, `speed`, `steps`, `visemes`, `temperature`, `dictionary_ids`, `pronunciations`; the callbacks `on_audio`, `on_visemes`, `on_ttfb`, `on_error`; and `ticket`, any RefCounted of yours to `cancel(ticket)` this request alone. Use it with `await`.

#### `cancel(ticket: RefCounted = null) -> void`

Stops the request being spoken and forgets the ones waiting. With the ticket given to `synthesize()`, only that one.

#### `close() -> void`

Cancels, and closes the connection.

#### `handle_message(text: String) -> void`

Handles one text frame. Public so tests can feed it.

### LokutorTTSClient constants

| Constant | Type | Value | Description |
| :- | :- | :- | :- |
| `FIRST_AUDIO_S` | `float` | `30.0` | Seconds to wait for the first audio. |
| `STALL_S` | `float` | `15.0` | Seconds to wait between chunks afterwards. |

## `LokutorSTTClient`

`extends RefCounted`

Transcribes one complete recording (`POST /stt/transcribe`), as `STTClient` in the JavaScript and Python SDKs. For speech as it happens use LokutorSpeechToTextClient.

```gdscript theme={null}
LokutorSTTClient.new(api_key: String = "")
```

### LokutorSTTClient properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `api_key` | `String` | `""` | An API key, or a `wst_` ticket. |
| `auth` | `Callable` | — | Called (and awaited) for the credential. |
| `server_url` | `String` | `Lokutor.STT_URL` | The API's address: only its host is used. |

### LokutorSTTClient methods

#### `transcribe(audio: PackedByteArray, options: Dictionary = {}) -> Dictionary`

`audio` is 16-bit PCM mono (give `sample_rate`) or a whole WAV file's bytes. Options: `sample_rate`, `format` (`"pcm16"` or `"wav"`), `language`, `keyterms`. Returns `{ok, text, latency_ms, engine, sample_rate, language, duration_seconds, segments, error}`. Use it with `await`.

## `LokutorSpeechToTextClient`

`extends Node`

Speech to text as the player talks, over `/ws/stt`: voice commands, dictation, captions. No language model and no voice. As `SpeechToTextClient` in the JavaScript SDK. Add it to the tree and call `open()`.

### LokutorSpeechToTextClient properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `api_key` | `String` | `""` | An API key, or a `wst_` ticket. |
| `auth` | `Callable` | — | Called (and awaited) for the credential. |
| `server_url` | `String` | `Lokutor.STT_URL` | The live transcription endpoint. |
| `language` | `String` | `"en"` | The language spoken. |
| `vad` | `String` | `"silero"` | How speech is detected: `"silero"` (default) or `"rms"`. |
| `keyterms` | `Array` | `[]` | Names and terms to write your way when what is heard is close. |
| `use_microphone` | `bool` | `true` | Capture the microphone. Off: send your own audio with `send_audio()`. |
| `microphone` | `LokutorMicrophone` | — | The microphone it runs. |
| `connected` | `bool` | — | The session is open. Read only. |

### LokutorSpeechToTextClient signals

| Signal | Emitted when |
| :- | :- |
| `partial_transcript(text: String)` | The best guess so far, while the player talks. |
| `final_transcript(text: String)` | The player finished a sentence. |
| `error(err: LokutorError)` | Something failed, as a [`LokutorError`](#lokutorerror). |
| `status_changed(value: String)` | `connecting`, `connected`, `disconnected`. |

### LokutorSpeechToTextClient methods

#### `open() -> bool`

Connects and starts listening. True once connected. Use it with `await`.

#### `close() -> void`

Ends the session and releases the microphone.

#### `send_audio(pcm16: PackedByteArray) -> void`

16-bit PCM, 16 kHz, mono. Keep sending silence: the end of an utterance is measured in it.

#### `end_utterance() -> void`

Finishes whatever is being said now.

#### `handle_message(text: String) -> void`

Handles one message. Public so tests can feed it.

## `LokutorMicrophone`

`extends Node`

The player's microphone as 16 kHz PCM, ready to send. Needs **Project Settings > Audio > Driver > Enable Input** (enabling the plugin turns it on).

### LokutorMicrophone properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `muted` | `bool` | `false` | Sends silence instead of the microphone (the server still needs to hear pauses). |
| `gate` | `Callable` | — | Called each frame, if set: return false to send silence (push to talk, or the character is talking). |
| `level` | `float` | `0.0` | Loudness, 0 to 1. |
| `running` | `bool` | — | Capturing. Read only. |

### LokutorMicrophone signals

| Signal | Emitted when |
| :- | :- |
| `captured(pcm16: PackedByteArray)` | 16-bit PCM, 16 kHz, mono. |
| `captured_float(samples: PackedFloat32Array, rate: int)` | The same before conversion: mono floats at `rate`. |

### LokutorMicrophone methods

#### `start() -> bool`

Starts capturing. `false` when the project has no audio input.

#### `stop() -> void`

Releases it.

#### `static devices() -> PackedStringArray`

The microphones of this computer. Choose one with `AudioServer.input_device`.

## `LokutorVoicePlayer`

`extends Node3D`

Plays a voice as it arrives and knows, to a few milliseconds, how much of it has been heard: lip sync and the microphone's echo guard run on that clock, not on the network's.

### LokutorVoicePlayer properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `output` | `Node` | — | Play through your own AudioStreamPlayer, AudioStreamPlayer2D or AudioStreamPlayer3D. Empty: one is made. |
| `spatial` | `bool` | `false` | Without an `output`: play from this node's place in the world (3D). |
| `bus` | `StringName` | `&"Master"` | The audio bus it plays on. |
| `rate` | `int` | `Lokutor.OUTPUT_RATE` | Rate of the audio pushed. Changing it restarts the output. |
| `generation` | `int` | `0` | The reply being played. |
| `level` | `float` | `0.0` | Loudness of what is being heard, 0 to 1. |
| `simulate_audio_device` | `bool` | `false` | No sound card (headless runs, servers, tests): the voice is consumed in real time without being played. |
| `record` | `bool` | `false` | Everything heard is also appended to `recorded` (mono). |
| `recorded` | `PackedFloat32Array` | `PackedFloat32Array()` | What `record` kept. |

### LokutorVoicePlayer signals

| Signal | Emitted when |
| :- | :- |
| `voice_played(samples: PackedFloat32Array, rate: int)` | Samples handed to the sound card, as they are: for a character that another character listens to. |
| `started(generation: int)` | The first sound of a reply is being heard. |
| `finished(generation: int)` | The last sound of a reply has been heard. |

### LokutorVoicePlayer methods

#### `begin(new_generation: int) -> void`

A new reply begins: what was queued of the previous one is dropped, and time counts from 0.

#### `push(pcm16: PackedByteArray, for_generation: int = generation) -> void`

Queues voice (16-bit PCM, mono, at `rate`). Audio of an older reply is ignored.

#### `clear() -> void`

Stops at once and forgets what was queued.

#### `is_playing() -> bool`

Voice is waiting or playing.

#### `queued_seconds() -> float`

Voice waiting to be given to the sound card, in seconds.

#### `is_audible() -> bool`

The voice can still reach the microphone: waiting, in the sound card's buffers, or echoing in the room.

#### `static echo_tail_ms() -> int`

How long the room's echo lasts here: `ECHO_TAIL_MOBILE_MS` on a phone or in a web browser, `ECHO_TAIL_MS` anywhere else.

#### `heard_seconds() -> float`

How much of the current reply has been heard, in seconds: the clock viseme times are read against.

### LokutorVoicePlayer constants

| Constant | Type | Value | Description |
| :- | :- | :- | :- |
| `BUFFER_S` | `float` | `0.25` | Seconds of the sound card's buffer. |
| `ECHO_TAIL_MS` | `int` | `250` | After the voice stops, the room's echo still reaches the microphone for a moment: `is_audible()` stays true this long. |
| `ECHO_TAIL_MOBILE_MS` | `int` | `700` | The same on a phone or in a web browser, whose loudspeakers are beside the microphone and whose echo cancellation is slower. |

## `Lokutor`

`extends RefCounted`

Constants and helpers shared by the Lokutor nodes: voices, languages, visemes, addresses, and the public [discovery](https://docs.lokutor.com/sdk/discovery.md) endpoints, which need no API key.

### Lokutor properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `tls_options` | `TLSOptions` | `null` | Static. How every connection of the SDK checks the server's certificate; `null` is the engine's own way. For a server of yours with its own certificate authority: `Lokutor.tls_options = TLSOptions.client(load("res://company.crt"))`. |

### Lokutor methods

#### `static keyless_allowed() -> bool`

Whether a session may open with no key at all: in a web browser, where the server decides. Lokutor's own pages (lokutor.com) get its bounded demo; every other site is refused with `auth.missing_key`.

#### `static page_args() -> Dictionary`

In a browser, the parameters of the page's address (`?lang=es&level=1` is `{"lang": "es", "level": "1"}`); elsewhere `{}`. A web build has no command line: this is where a game's options come from there.

#### `static tell_page(type: String, data: Dictionary = {}) -> void`

In a browser, tells the page the game is embedded in (or its own page) what happened, as a `message` event with `{source: "lokutor", type, ...data}`. The SDK sends `"session_limit"` `{seconds, reason}` and `"demo_limit"` `{limit, message}` by itself. Elsewhere it does nothing.

#### `static language_to_wire(language: String) -> String`

The value the protocol carries for a language: `"auto"` and `""` are both `""` (follow the player).

#### `static strip_tags(text: String) -> String`

A line without the [expression tags](https://docs.lokutor.com/api-reference/expression-tags.md) the voice performs (`[laugh]`, `[sad]`...), for subtitles.

#### `static viseme_id(viseme_name: String) -> int`

The id (0-14) of a viseme name, whatever its case; 0 (closed) for an unknown one.

#### `static http_origin(url: String) -> String`

`ws://host/path` becomes `http://host`.

#### `static fetch_voices(base_url: String = VOICE_AGENT_URL) -> Array`

Voices the API offers: `[{id, name, gender, languages}]`. Use it with `await`.

#### `static fetch_languages(base_url: String = VOICE_AGENT_URL) -> Array`

Languages the API offers: `[{code, name}]`. Use it with `await`.

#### `static fetch_models(base_url: String = VOICE_AGENT_URL) -> Array`

Speech models: `[{name, description, default}]`. Use it with `await`.

#### `static fetch_config(base_url: String = VOICE_AGENT_URL) -> Dictionary`

Request limits and defaults: `{max_text_length, min_speed, max_speed, min_steps, max_steps, sample_rate, channels}`. Use it with `await`.

#### `static fetch_status(base_url: String = VOICE_AGENT_URL) -> Dictionary`

Runtime status of the service. Use it with `await`.

#### `static fetch_health(base_url: String = VOICE_AGENT_URL) -> Dictionary`

Readiness (`GET /ready`): `{ready, status}`. Use it with `await`.

#### `static request_json(url: String, method := HTTPClient.METHOD_GET, headers := PackedStringArray(), body := "", timeout := 15.0) -> Dictionary`

One HTTP request. Returns `{ok, status, body, error, result}`: `body` is the parsed JSON, `error` a LokutorError or null, `result` what `HTTPRequest` said (`HTTPRequest.RESULT_*`). Use it with `await`.

### Lokutor constants

| Constant | Type | Value | Description |
| :- | :- | :- | :- |
| `VERSION` | `String` | `"0.2.0"` | The version of the addon. |
| `VOICE_AGENT_URL` | `String` | `"wss://api.lokutor.com/ws/agent"` | The voice agent endpoint. |
| `TTS_URL` | `String` | `"wss://api.lokutor.com/ws/tts"` | The text-to-speech endpoint. |
| `STT_URL` | `String` | `"wss://api.lokutor.com/ws/stt"` | The live transcription endpoint. |
| `VOICES` | `PackedStringArray` | `["F1", "F2", "F3", "F4", "F5", "M1", "M2", "M3", "M4", "M5"]` | Voice slots: each is a native speaker of the language in use. GET /voices has the live list. |
| `LANGUAGES` | `Dictionary` | — | Languages the API documents for SDKs. fetch\_languages() has the live list. |
| `AUTO_LANGUAGE` | `String` | `"auto"` | Pass as a voice agent's language so the character follows the language the player speaks. |
| `VISEMES` | `PackedStringArray` | — | The 15 mouth shapes, by id. Viseme events carry the id (`v`) and the name (`c`). |
| `INPUT_RATE` | `int` | `16000` | Rate of the audio the API takes (16-bit PCM, mono). |
| `OUTPUT_RATE` | `int` | `44100` | Rate of the audio the API sends (16-bit PCM, mono). |
| `RECONNECTABLE_CLOSE_CODES` | `Array` | `[1001, 1006, 1011, 1012, 1013, 1014]` | Close codes after which a session is opened again: the connection dropped or the server went away. Every other close is the server ending the session on purpose. |

## `LokutorAudio`

`extends RefCounted`

Audio helpers, named as in the JavaScript and Python SDKs.

### LokutorAudio methods

#### `static pcm16_to_float32(pcm: PackedByteArray) -> PackedFloat32Array`

16-bit PCM to floats, -1 to 1.

#### `static float32_to_pcm16(samples: PackedFloat32Array) -> PackedByteArray`

Floats to 16-bit PCM, clipped.

#### `static calculate_rms(samples: PackedFloat32Array) -> float`

Loudness (root mean square).

#### `static normalize_audio(samples: PackedFloat32Array, target_peak := 0.95) -> PackedFloat32Array`

The same audio, scaled so its loudest sample is `target_peak`.

#### `static resample(samples: PackedFloat32Array, from_rate: int, to_rate: int) -> PackedFloat32Array`

A whole recording at another rate.

#### `static wav_bytes(pcm: PackedByteArray, rate: int) -> PackedByteArray`

A whole PCM16 mono recording as a WAV file's bytes.

### `StreamResampler`

`extends RefCounted`

Streaming mono resampler: audio can be pushed in blocks of any size and its phase is kept across them. Downsampling averages the input over each output step, which is enough anti-aliasing for speech.

```gdscript theme={null}
LokutorAudio.StreamResampler.new(from: int, to: int)
```

#### StreamResampler properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `from_rate` | `int` | — | Rate of the input. |
| `to_rate` | `int` | — | Rate of the output. |

#### StreamResampler methods

##### `reset() -> void`

Forgets the phase: the next block starts a new stream.

##### `process(input: PackedFloat32Array) -> PackedFloat32Array`

The next block, resampled.

## `LokutorError`

`extends RefCounted`

An error from the API or the SDK. `code` is one of the [error codes](https://docs.lokutor.com/api-reference/errors.md), the same as in the JavaScript and Python SDKs.

```gdscript theme={null}
LokutorError.new(code: String = "internal.error", message: String = "", detail: String = "", retryable = null)
```

### LokutorError properties

| Property | Type | Default | Description |
| :- | :- | :- | :- |
| `code` | `String` | — | One of the [error codes](https://docs.lokutor.com/api-reference/errors.md). |
| `message` | `String` | — | What happened, in a sentence. |
| `detail` | `String` | — | More, if the server said it. |
| `retryable` | `bool` | — | Whether the same request can work later. Servers say so; otherwise it follows from the code. |

### LokutorError methods

#### `static from_server(data) -> LokutorError`

From a server's error payload: `{code, message, detail, retryable}`, or a plain string.

#### `static demo_limit(reason: String) -> String`

Which of the lokutor.com demo's limits a connection's close reason names: `"call"`, `"daily"`, `"busy"`, or `""` for none.

#### `static from_demo_close(reason: String) -> LokutorError`

The demo's refusal or end as an error: `auth.time_limited`, with `demo_call`, `demo_daily` or `demo_busy` in `detail` (only `demo_daily` is not retryable today). Null when the reason is not one of the demo's.

### LokutorError constants

| Constant | Type | Value | Description |
| :- | :- | :- | :- |
| `FATAL` | `PackedStringArray` | — | Codes that another attempt cannot fix. |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.