Skip to main content

Overview

The STT API provides various options to customize transcription behavior, from language selection to word-level timestamps.

Options Reference

Language Support

Specify the language code to improve accuracy:

Supported Languages

Language-specific models (e.g., whisper-tiny.en) only support that language but are more accurate and faster.

Punctuation

Add punctuation to transcription output:

Word Timestamps

Get timing information for each word:

Use Cases

  • Subtitles/Captions: Sync text with video
  • Karaoke: Highlight words as they’re spoken
  • Search: Jump to specific moments in audio
  • Accessibility: Show words as they’re spoken

Example: Subtitle Generator

Speaker Diarization

Identify different speakers in the audio:
Speaker diarization is computationally expensive and may not be available on all models. Check model documentation for support.

Sample Rate

Specify the audio sample rate if different from the default:
transcribeBuffer() accepts a Float32Array of PCM audio samples. The sample rate defaults to 16000 Hz if not specified in options.
For best results, record audio at 16kHz mono. Higher sample rates will be downsampled, which adds processing overhead.

Model Loading Options

Configure model loading:

Combining Options

Performance vs Accuracy

For best performance, always specify the language option rather than relying on auto-detection.

Transcribe

Basic transcription

STT Streaming

Real-time transcription

VAD

Voice Activity Detection