enableWordTimeOffsets

How to get word level timings

worth noting that time stamps don't come as default, you need to add this attribute to configenableWordTimeOffsets

same thing for punctuaiton with enableAutomaticPunctuation

and speaker diarization enableSpeakerDiarization

const config = {
  enableWordTimeOffsets: true,
  enableAutomaticPunctuation: true,
  enableSpeakerDiarization: true,
  encoding: encoding,
  sampleRateHertz: sampleRateHertz,
  languageCode: languageCode,
};

more details and full code example see

https://cloud.google.com/speech-to-text/docs/async-time-offsetsarrow-up-right

https://cloud.google.com/speech-to-text/docs/automatic-punctuationarrow-up-right

https://cloud.google.com/speech-to-text/docs/multiple-voicesarrow-up-right

Last updated

Was this helpful?