Class RealtimeAudioInputTurnDetection.SemanticVad
-
- All Implemented Interfaces:
public final class RealtimeAudioInputTurnDetection.SemanticVad
Server-side semantic turn detection which uses a model to determine when the user has finished speaking.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final class
RealtimeAudioInputTurnDetection.SemanticVad.Builder
A builder for SemanticVad.
public final class
RealtimeAudioInputTurnDetection.SemanticVad.Eagerness
Used only for
semantic_vad
mode. The eagerness of the model to respond.low
will wait longer for the user to continue speaking,high
will respond more quickly.auto
is the default and is equivalent tomedium
.low
,medium
, andhigh
have max timeouts of 8s, 4s, and 2s respectively.
-
Method Summary
Modifier and Type Method Description final JsonValue
_type()
Type of turn detection, semantic_vad
to turn on Semantic VAD.final Optional<Boolean>
createResponse()
Whether or not to automatically generate a response when a VAD stop event occurs. final Optional<RealtimeAudioInputTurnDetection.SemanticVad.Eagerness>
eagerness()
Used only for semantic_vad
mode.final Optional<Boolean>
interruptResponse()
Whether or not to automatically interrupt any ongoing response with output to the default conversation (i.e. final JsonField<Boolean>
_createResponse()
Returns the raw JSON value of createResponse. final JsonField<RealtimeAudioInputTurnDetection.SemanticVad.Eagerness>
_eagerness()
Returns the raw JSON value of eagerness. final JsonField<Boolean>
_interruptResponse()
Returns the raw JSON value of interruptResponse. final Map<String, JsonValue>
_additionalProperties()
final RealtimeAudioInputTurnDetection.SemanticVad.Builder
toBuilder()
final RealtimeAudioInputTurnDetection.SemanticVad
validate()
final Boolean
isValid()
Boolean
equals(Object other)
Integer
hashCode()
String
toString()
final static RealtimeAudioInputTurnDetection.SemanticVad.Builder
builder()
Returns a mutable builder for constructing an instance of SemanticVad. -
-
Method Detail
-
_type
final JsonValue _type()
Type of turn detection,
semantic_vad
to turn on Semantic VAD.Expected to always return the following:
JsonValue.from("semantic_vad")
However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
createResponse
final Optional<Boolean> createResponse()
Whether or not to automatically generate a response when a VAD stop event occurs.
-
eagerness
final Optional<RealtimeAudioInputTurnDetection.SemanticVad.Eagerness> eagerness()
Used only for
semantic_vad
mode. The eagerness of the model to respond.low
will wait longer for the user to continue speaking,high
will respond more quickly.auto
is the default and is equivalent tomedium
.low
,medium
, andhigh
have max timeouts of 8s, 4s, and 2s respectively.
-
interruptResponse
final Optional<Boolean> interruptResponse()
Whether or not to automatically interrupt any ongoing response with output to the default conversation (i.e.
conversation
ofauto
) when a VAD start event occurs.
-
_createResponse
final JsonField<Boolean> _createResponse()
Returns the raw JSON value of createResponse.
Unlike createResponse, this method doesn't throw if the JSON field has an unexpected type.
-
_eagerness
final JsonField<RealtimeAudioInputTurnDetection.SemanticVad.Eagerness> _eagerness()
Returns the raw JSON value of eagerness.
Unlike eagerness, this method doesn't throw if the JSON field has an unexpected type.
-
_interruptResponse
final JsonField<Boolean> _interruptResponse()
Returns the raw JSON value of interruptResponse.
Unlike interruptResponse, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final RealtimeAudioInputTurnDetection.SemanticVad.Builder toBuilder()
-
validate
final RealtimeAudioInputTurnDetection.SemanticVad validate()
-
builder
final static RealtimeAudioInputTurnDetection.SemanticVad.Builder builder()
Returns a mutable builder for constructing an instance of SemanticVad.
-
-
-
-