Class AudioTranscription
-
- All Implemented Interfaces:
public final class AudioTranscription
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classAudioTranscription.BuilderA builder for AudioTranscription.
public final classAudioTranscription.DelayControls how long the model waits before emitting transcription text. Higher values can improve transcription accuracy at the cost of latency. Only supported with
gpt-realtime-whisperin GA Realtime sessions.public final classAudioTranscription.ModelThe model to use for transcription. Current options are
whisper-1,gpt-4o-mini-transcribe,gpt-4o-mini-transcribe-2025-12-15,gpt-4o-transcribe,gpt-4o-transcribe-diarize, andgpt-realtime-whisper. Usegpt-4o-transcribe-diarizewhen you need diarization with speaker labels.
-
Method Summary
Modifier and Type Method Description final Optional<AudioTranscription.Delay>delay()Controls how long the model waits before emitting transcription text. final Optional<String>language()The language of the input audio. final Optional<AudioTranscription.Model>model()The model to use for transcription. final Optional<String>prompt()An optional text to guide the model's style or continue a previous audio segment. final JsonField<AudioTranscription.Delay>_delay()Returns the raw JSON value of delay. final JsonField<String>_language()Returns the raw JSON value of language. final JsonField<AudioTranscription.Model>_model()Returns the raw JSON value of model. final JsonField<String>_prompt()Returns the raw JSON value of prompt. final Map<String, JsonValue>_additionalProperties()final AudioTranscription.BuildertoBuilder()final AudioTranscriptionvalidate()Validates that the types of all values in this object match their expected types recursively. final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static AudioTranscription.Builderbuilder()Returns a mutable builder for constructing an instance of AudioTranscription. -
-
Method Detail
-
delay
final Optional<AudioTranscription.Delay> delay()
Controls how long the model waits before emitting transcription text. Higher values can improve transcription accuracy at the cost of latency. Only supported with
gpt-realtime-whisperin GA Realtime sessions.
-
language
final Optional<String> language()
The language of the input audio. Supplying the input language in ISO-639-1 (e.g.
en) format will improve accuracy and latency.
-
model
final Optional<AudioTranscription.Model> model()
The model to use for transcription. Current options are
whisper-1,gpt-4o-mini-transcribe,gpt-4o-mini-transcribe-2025-12-15,gpt-4o-transcribe,gpt-4o-transcribe-diarize, andgpt-realtime-whisper. Usegpt-4o-transcribe-diarizewhen you need diarization with speaker labels.
-
prompt
final Optional<String> prompt()
An optional text to guide the model's style or continue a previous audio segment. For
whisper-1, the prompt is a list of keywords. Forgpt-4o-transcribemodels (excludinggpt-4o-transcribe-diarize), the prompt is a free text string, for example "expect words related to technology". Prompt is not supported withgpt-realtime-whisperin GA Realtime sessions.
-
_delay
final JsonField<AudioTranscription.Delay> _delay()
Returns the raw JSON value of delay.
Unlike delay, this method doesn't throw if the JSON field has an unexpected type.
-
_language
final JsonField<String> _language()
Returns the raw JSON value of language.
Unlike language, this method doesn't throw if the JSON field has an unexpected type.
-
_model
final JsonField<AudioTranscription.Model> _model()
Returns the raw JSON value of model.
Unlike model, this method doesn't throw if the JSON field has an unexpected type.
-
_prompt
final JsonField<String> _prompt()
Returns the raw JSON value of prompt.
Unlike prompt, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final AudioTranscription.Builder toBuilder()
-
validate
final AudioTranscription validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
builder
final static AudioTranscription.Builder builder()
Returns a mutable builder for constructing an instance of AudioTranscription.
-
-
-
-