Class WordInfo.Builder

java.lang.Object
com.google.genai.gaos.models.interactions.WordInfo.Builder
Enclosing class:
WordInfo

public static final class WordInfo.Builder extends Object
  • Method Details

    • endIndex

      public WordInfo.Builder endIndex(@Nullable Integer endIndex)
      End of the attributed segment, exclusive.
    • endOffset

      public WordInfo.Builder endOffset(@Nullable String endOffset)
      End offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
    • speaker

      public WordInfo.Builder speaker(@Nullable String speaker)
      Optional. Speaker label for this word (e.g. "spk_1", "spk_2"). Present when diarization_mode is set in TranscriptionConfig.
    • startIndex

      public WordInfo.Builder startIndex(@Nullable Integer startIndex)
      Start of segment of the response that is attributed to this source.

      Index indicates the start of the segment, measured in bytes.

    • startOffset

      public WordInfo.Builder startOffset(@Nullable String startOffset)
      Start offset in time of the word relative to the start of the audio. Present when timestamp_granularities contains "word".
    • text

      public WordInfo.Builder text(@Nullable String text)
      The transcribed word.
    • build

      public WordInfo build()