Class RealtimeTranscriptionSessionCreateRequest.TurnDetection
-
- All Implemented Interfaces:
public final class RealtimeTranscriptionSessionCreateRequest.TurnDetection
Configuration for turn detection. Can be set to
null
to turn off. Server VAD means that the model will detect the start and end of speech based on audio volume and respond at the end of user speech.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final class
RealtimeTranscriptionSessionCreateRequest.TurnDetection.Builder
A builder for TurnDetection.
public final class
RealtimeTranscriptionSessionCreateRequest.TurnDetection.Type
Type of turn detection. Only
server_vad
is currently supported for transcription sessions.
-
Method Summary
-
-
Method Detail
-
prefixPaddingMs
final Optional<Long> prefixPaddingMs()
Amount of audio to include before the VAD detected speech (in milliseconds). Defaults to 300ms.
-
silenceDurationMs
final Optional<Long> silenceDurationMs()
Duration of silence to detect speech stop (in milliseconds). Defaults to 500ms. With shorter values the model will respond more quickly, but may jump in on short pauses from the user.
-
threshold
final Optional<Double> threshold()
Activation threshold for VAD (0.0 to 1.0), this defaults to 0.5. A higher threshold will require louder audio to activate the model, and thus might perform better in noisy environments.
-
type
final Optional<RealtimeTranscriptionSessionCreateRequest.TurnDetection.Type> type()
Type of turn detection. Only
server_vad
is currently supported for transcription sessions.
-
_prefixPaddingMs
final JsonField<Long> _prefixPaddingMs()
Returns the raw JSON value of prefixPaddingMs.
Unlike prefixPaddingMs, this method doesn't throw if the JSON field has an unexpected type.
-
_silenceDurationMs
final JsonField<Long> _silenceDurationMs()
Returns the raw JSON value of silenceDurationMs.
Unlike silenceDurationMs, this method doesn't throw if the JSON field has an unexpected type.
-
_threshold
final JsonField<Double> _threshold()
Returns the raw JSON value of threshold.
Unlike threshold, this method doesn't throw if the JSON field has an unexpected type.
-
_type
final JsonField<RealtimeTranscriptionSessionCreateRequest.TurnDetection.Type> _type()
Returns the raw JSON value of type.
Unlike type, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final RealtimeTranscriptionSessionCreateRequest.TurnDetection.Builder toBuilder()
-
validate
final RealtimeTranscriptionSessionCreateRequest.TurnDetection validate()
-
builder
final static RealtimeTranscriptionSessionCreateRequest.TurnDetection.Builder builder()
Returns a mutable builder for constructing an instance of TurnDetection.
-
-
-
-