Class TranscriptionTextSegmentEvent
-
- All Implemented Interfaces:
public final class TranscriptionTextSegmentEventEmitted when a diarized transcription returns a completed segment with speaker information. Only emitted when you create a transcription with
streamset totrueandresponse_formatset todiarized_json.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classTranscriptionTextSegmentEvent.BuilderA builder for TranscriptionTextSegmentEvent.
-
Method Summary
Modifier and Type Method Description final Stringid()Unique identifier for the segment. final Floatend()End timestamp of the segment in seconds. final Stringspeaker()Speaker label for this segment. final Floatstart()Start timestamp of the segment in seconds. final Stringtext()Transcript text for this segment. final JsonValue_type()The type of the event. final JsonField<String>_id()Returns the raw JSON value of id. final JsonField<Float>_end()Returns the raw JSON value of end. final JsonField<String>_speaker()Returns the raw JSON value of speaker. final JsonField<Float>_start()Returns the raw JSON value of start. final JsonField<String>_text()Returns the raw JSON value of text. final Map<String, JsonValue>_additionalProperties()final TranscriptionTextSegmentEvent.BuildertoBuilder()final TranscriptionTextSegmentEventvalidate()final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static TranscriptionTextSegmentEvent.Builderbuilder()Returns a mutable builder for constructing an instance of TranscriptionTextSegmentEvent. -
-
Method Detail
-
_type
final JsonValue _type()
The type of the event. Always
transcript.text.segment.Expected to always return the following:
JsonValue.from("transcript.text.segment")However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
_id
final JsonField<String> _id()
Returns the raw JSON value of id.
Unlike id, this method doesn't throw if the JSON field has an unexpected type.
-
_end
final JsonField<Float> _end()
Returns the raw JSON value of end.
Unlike end, this method doesn't throw if the JSON field has an unexpected type.
-
_speaker
final JsonField<String> _speaker()
Returns the raw JSON value of speaker.
Unlike speaker, this method doesn't throw if the JSON field has an unexpected type.
-
_start
final JsonField<Float> _start()
Returns the raw JSON value of start.
Unlike start, this method doesn't throw if the JSON field has an unexpected type.
-
_text
final JsonField<String> _text()
Returns the raw JSON value of text.
Unlike text, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final TranscriptionTextSegmentEvent.Builder toBuilder()
-
validate
final TranscriptionTextSegmentEvent validate()
-
builder
final static TranscriptionTextSegmentEvent.Builder builder()
Returns a mutable builder for constructing an instance of TranscriptionTextSegmentEvent.
The following fields are required:
.id() .end() .speaker() .start() .text()
-
-
-
-