Skip to content

AgentState

The possible states of the CompositeVoice agent.

type AgentState = "idle" | "ready" | "listening" | "thinking" | "speaking" | "error";

Defined in: src/core/events/types.ts:60

The possible states of the CompositeVoice agent.

Remarks

Represents the high-level state of the voice pipeline. The agent transitions between these states as it processes user speech:

idle -> ready -> listening -> thinking -> speaking -> listening

  • 'idle' - Agent is created but not yet initialized
  • 'ready' - Agent is initialized and waiting to start
  • 'listening' - Agent is actively capturing and transcribing user speech
  • 'thinking' - Agent is processing the transcription through the LLM
  • 'speaking' - Agent is synthesizing and playing back the response
  • 'error' - Agent has encountered an unrecoverable error

See

AgentStateChangeEvent for the event emitted on state transitions

© 2026 CompositeVoice. All rights reserved.

Font size
Contrast
Motion
Transparency