Skip to main content
STTOptions is generated. Import it from @runanywhere/proto-ts/stt_options. Both transcribe and transcribeStream accept a Partial<STTOptions>.

Fields

The SDK fills the defaults above before encoding the request, so an omitted field is not the same as a proto zero.

Language

STTLanguage is an enum, not a string. Its members carry the two-letter wire tag.
For a regional variant set languageCode: 'en-GB'; consumers prefer it over the enum. Language-specific models such as whisper-tiny.en only handle their one language, and specifying it is both faster and more accurate than auto-detection.

Word timestamps

enableWordTimestamps is on by default. Timings arrive in STTOutput.words as WordTimestamp entries, not in a segments array.

Diarization

Diarization is expensive and backend-dependent. speakerIds stays empty when the loaded model does not support it.

Sample rate

16 kHz mono is what the STT frontends expect, and it is the SDK default for both the request and AudioCaptureManager. Passing a higher rate makes the backend downsample, which costs time and buys nothing.

Alternatives

Performance

Transcribe

Buffer transcription

STT Streaming

Live partial results

VAD

Voice activity detection