Skip to content

v1.2.0 - Word timestamps in lyrics

Choose a tag to compare

@jotapemj jotapemj released this 03 Aug 18:51
· 39 commits to main since this release

feat(lyrics): word timestamps and phrase-gap splitting

Two closely related improvements to lyrics.json.

What changed

  • Each segments[i] now carries a words array with per-word timestamps (start, end, text).
  • Whisper segments that spanned multiple phrases (side effect of enabling word timestamps) are now split where the silence between consecutive words exceeds 2 s, so each emitted segment stays a karaoke-usable size.
  • Segment id is a global counter across the split output.

Rolled up patch since v1.1.0

  • v1.0.1 / v1.1.1: metadata.txt written for non-MP3 formats; seg.end tightened via internal word_timestamps. See tags for details.

Client impact

  • Backwards compatible: clients that already render line-by-line karaoke keep working unchanged (they can ignore the new words field).
  • New in this release: clients that want word-by-word highlighting can iterate segments[i].words.
  • The words array may be empty for a segment when Whisper fails to align words for it; clients should fall back to segment-level timing in that case.