Usage guide
Setup, environment variables, and Python/JavaScript/Go usage examples.
CartesiaSTT
Streaming speech-to-text with Cartesia’s Ink models over WebSocket. A good choice for low-latency transcription in real-time voice agents. Authenticates with CARTESIA_API_KEY from your environment, or an explicitapi_key.
Fields
str
default:"UNSET"
Transcription model, e.g. “ink-whisper”. Defaults to ‘ink-whisper’.
str
default:"UNSET"
ISO 639-1 language code of the speech, e.g. “en” or “es”. Only applies to ink-whisper models. Defaults to ‘en’.
int | None
default:"UNSET"
Sample rate of incoming audio in Hz. Leave unset to detect it automatically. Defaults to None (not set).
int | None
default:"UNSET"
Sample rate in Hz of the audio sent to Cartesia; leave unset to use 16000. Defaults to None (not set).
int | None
default:"UNSET"
Deprecated alias for input_sample_rate; do not pass both. Defaults to None (not set).
str
default:"UNSET"
WebSocket URL of the Cartesia speech-to-text endpoint. Change only for a proxy or private deployment. Defaults to ‘wss://api.cartesia.ai/stt/websocket’.
bool
default:"True"
Set to True to send partial transcripts to the client as well as final ones. Partial results are still used for interruptions and turn detection either way. Defaults to True.