{}{
"type": "close"
}{
"type": "config",
"turn": {
"start_threshold": 0.8,
"eager_end_threshold": 0.6,
"end_threshold": 0.3,
"end_timeout_ms": 5600
}
}{
"type": "connected",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.start",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.update",
"transcript": "Hey can you help",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.eager_end",
"transcript": "Hey can you help me with something?",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.resume",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.end",
"transcript": "Hey can you help me with something?",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "error",
"title": "Invalid model",
"message": "The model is not valid, make sure it is a valid model ID.",
"error_code": "model_not_found",
"doc_url": "https://docs.cartesia.ai/build-with-cartesia/stt/latest",
"status_code": 400,
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}リアルタイム音声認識 (自動)
Realtime speech transcription with built-in turn detection
ink-2 supports English, French, Hindi, Japanese, and Spanish. ink-preview supports 44 languages.
Both detect the language automatically.
{}{
"type": "close"
}{
"type": "config",
"turn": {
"start_threshold": 0.8,
"eager_end_threshold": 0.6,
"end_threshold": 0.3,
"end_timeout_ms": 5600
}
}{
"type": "connected",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.start",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.update",
"transcript": "Hey can you help",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.eager_end",
"transcript": "Hey can you help me with something?",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.resume",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "turn.end",
"transcript": "Hey can you help me with something?",
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}{
"type": "error",
"title": "Invalid model",
"message": "The model is not valid, make sure it is a valid model ID.",
"error_code": "model_not_found",
"doc_url": "https://docs.cartesia.ai/build-with-cartesia/stt/latest",
"status_code": 400,
"request_id": "2ff8af53-4d38-479d-8287-58940f01c701"
}Use an API key when you're calling from a trusted server.
Use a short-lived access token when calling from a browser or client app. Learn more here.
Send raw audio as binary WebSocket messages, in small chunks such as 100 ms.
The audio must match the encoding and sample_rate query parameters.
Send a JSON formatted close command as a WebSocket text message to close the session cleanly. The model processes all buffered audio into events.
Change turn detection settings, keyterms, or language hints mid-stream
Fires once when the WebSocket connection opens.
You don't need to wait for this event before sending audio.
Marks the start of a user turn. Fires soon after the user starts speaking.
Use this event to interrupt your agent so it doesn't talk over the user.
Fires repeatedly as the model transcribes the current user turn.
Fires when the model predicts that the user might be done speaking.
Fires after turn.eager_end if the user turn has not actually ended.
Marks the end of a user turn.
Error information for STT WebSocket connections
Was this page helpful?