The Transcription API provides high-quality speech transcription. It supports automatic language detection, word-level timestamp alignment, speaker diarization, and speaker verification via reference audio samples.
Features include:
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
audio_file | string | Yes | — | URL to an audio file, or base64-encoded audio data (optionally with data: URI prefix). |
language | string | No | null | ISO language code (e.g. en, fr). If omitted, automatic detection is performed. |
language_detection_min_prob | float | No | 0 | Minimum probability threshold for language detection. |
language_detection_max_tries | int | No | 5 | Maximum number of language detection attempts. |
initial_prompt | string | No | null | Optional prompt text for the first transcription window. Useful for vocabulary hints. |
batch_size | int | No | 64 | Batch size for parallelized transcription. Lower values use less VRAM. |
temperature | float | No | 0 | Sampling temperature. Higher values produce more random output. |
vad_onset | float | No | 0.500 | Voice Activity Detection onset threshold. |
vad_offset | float | No | 0.363 | Voice Activity Detection offset threshold. |
align_output | bool | No | false | Enable word-level timestamp alignment. |
diarization | bool | No | false | Enable speaker diarization (assigns speaker IDs to segments). |
min_speakers | int | No | null | Minimum number of speakers. Only used when diarization is enabled. |
max_speakers | int | No | null | Maximum number of speakers. Only used when diarization is enabled. |
speaker_verification | bool | No | false | Enable speaker verification against reference samples. |
speaker_samples | list | No | [] | List of {"name", "url"} objects for speaker verification. |
debug | bool | No | false | Include compute/inference times and memory usage in the response. |
{
"input": {
"audio_file": "https://example.com/audio/sample.wav"
}
}
Send audio directly as base64-encoded data instead of a URL. Both raw base64 and data URI formats are supported:
{
"input": {
"audio_file": "data:audio/wav;base64,UklGRi..."
}
}
/runsync, 10 MB for /run.
Compress audio to MP3 or OGG before encoding for larger files.
{
"input": {
"audio_file": "https://example.com/audio/sample.wav",
"align_output": true,
"batch_size": 32,
"debug": true
}
}
{
"input": {
"audio_file": "https://example.com/audio/sample.wav",
"language": "en",
"batch_size": 32,
"temperature": 0.2,
"align_output": true,
"diarization": true,
"min_speakers": 2,
"max_speakers": 5,
"debug": true
}
}
Provide reference audio for known speakers. There is no hard limit on the number of samples, but precision may decrease with many speakers.
{
"input": {
"audio_file": "https://example.com/audio/meeting.mp3",
"language": "en",
"batch_size": 32,
"align_output": true,
"diarization": true,
"min_speakers": 2,
"max_speakers": 5,
"speaker_verification": true,
"speaker_samples": [
{"name": "Alice", "url": "https://example.com/alice.wav"},
{"name": "Bob", "url": "https://example.com/bob.wav"}
]
}
}
{
"segments": [
{
"start": 0.0,
"end": 2.5,
"text": "Transcribed text segment one.",
"words": [
{"word": "Transcribed", "start": 0.1, "end": 0.7},
{"word": "text", "start": 0.8, "end": 1.2},
{"word": "segment", "start": 1.3, "end": 1.9},
{"word": "one.", "start": 2.0, "end": 2.4}
]
}
],
"detected_language": "en",
"language_probability": 0.997
}
{
"segments": [
{
"start": 0.0,
"end": 2.5,
"text": "Hello, how are you?",
"speaker": "SPEAKER_01",
"words": [
{"word": "Hello,", "start": 0.1, "end": 0.5, "speaker": "SPEAKER_01"},
{"word": "how", "start": 0.6, "end": 0.9, "speaker": "SPEAKER_01"},
{"word": "are", "start": 1.0, "end": 1.3, "speaker": "SPEAKER_01"},
{"word": "you?", "start": 1.4, "end": 1.8, "speaker": "SPEAKER_01"}
]
},
{
"start": 2.5,
"end": 5.0,
"text": "I'm doing well, thanks.",
"speaker": "SPEAKER_02",
"words": [
{"word": "I'm", "start": 2.6, "end": 2.9, "speaker": "SPEAKER_02"},
{"word": "doing", "start": 3.0, "end": 3.4, "speaker": "SPEAKER_02"},
{"word": "well,", "start": 3.5, "end": 3.9, "speaker": "SPEAKER_02"},
{"word": "thanks.","start": 4.0, "end": 4.5, "speaker": "SPEAKER_02"}
]
}
],
"detected_language": "en",
"language_probability": 0.997,
"speakers": {
"SPEAKER_01": {"name": "Alice", "time": 2.5},
"SPEAKER_02": {"name": "Bob", "time": 2.5}
}
}
batch_size based on available VRAM. Lower values reduce memory usage.