Class WordInfo
java.lang.Object
com.google.genai.gaos.models.interactions.WordInfo
- All Implemented Interfaces:
Annotation
WordInfo
Word-level ASR annotation for transcription output. Carries the word text, optional timing, and optional speaker attribution.
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic WordInfo.Builderbuilder()endIndex()End of the attributed segment, exclusive.End offset in time of the word relative to the start of the audio.booleaninthashCode()speaker()Optional.Start of segment of the response that is attributed to this source.Start offset in time of the word relative to the start of the audio.text()The transcribed word.toString()type()withEndIndex(Integer endIndex) End of the attributed segment, exclusive.withEndOffset(String endOffset) End offset in time of the word relative to the start of the audio.withSpeaker(String speaker) Optional.withStartIndex(Integer startIndex) Start of segment of the response that is attributed to this source.withStartOffset(String startOffset) Start offset in time of the word relative to the start of the audio.The transcribed word.
-
Constructor Details
-
WordInfo
-
WordInfo
public WordInfo()
-
-
Method Details
-
endIndex
End of the attributed segment, exclusive. -
endOffset
End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word". -
speaker
Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig. -
startIndex
Start of segment of the response that is attributed to this source.Index indicates the start of the segment, measured in bytes.
-
startOffset
Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word". -
text
The transcribed word. -
type
- Specified by:
typein interfaceAnnotation
-
builder
-
withEndIndex
End of the attributed segment, exclusive. -
withEndOffset
End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word". -
withSpeaker
Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig. -
withStartIndex
Start of segment of the response that is attributed to this source.Index indicates the start of the segment, measured in bytes.
-
withStartOffset
Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word". -
withText
The transcribed word. -
equals
-
hashCode
public int hashCode() -
toString
-