Skip to content

fix: insert missing space between sentences in Whisper transcripts#184

Open
nitishkp001 wants to merge 1 commit into
Starmel:masterfrom
nitishkp001:fix/107-missing-space-between-sentences
Open

fix: insert missing space between sentences in Whisper transcripts#184
nitishkp001 wants to merge 1 commit into
Starmel:masterfrom
nitishkp001:fix/107-missing-space-between-sentences

Conversation

@nitishkp001

Copy link
Copy Markdown

Summary

  • whisper.cpp segments don't always carry a leading space, so consecutive sentences (within one segment, e.g. "...day.Next sentence", or across segments) could end up glued together with no space.
  • After joining segments, insert a space after sentence-ending punctuation (., !, ?) when immediately followed by a letter. Skipped when timestamps are shown since that mode already separates entries visually.

Fixes #107

Test plan

  • Transcribe a multi-sentence recording with Whisper (turbo/small) and confirm sentences are separated by a space, not glued together.
  • Confirm timestamp mode output is unaffected.

whisper.cpp segments sometimes lack a leading space, so consecutive
sentences within or across segments could be glued together
("...day.Next sentence"). Insert a space after sentence-ending
punctuation when it's immediately followed by a letter.

Fixes Starmel#107
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Missing space between sentences.

1 participant