Skip to content

Keep short words between removed silences - #115

Merged
wassgha merged 1 commit into
wassgha:mainfrom
Bortlesboat:fix-silence-cuts-short-words
Oct 29, 2026
Merged

wassgha merged 1 commit into
wassgha:mainfrom
Bortlesboat:fix-silence-cuts-short-words

Conversation

@Bortlesboat

Copy link
Copy Markdown
Contributor

Remove silences cuts the pause on each side of a word, and when the word is shorter than about 0.25s the two cuts were close enough that addManualCut and getCutRanges joined them into one cut over the word. The word dropped out of the edit and Restore silences had nothing to bring back. Manual cuts now only join when they overlap or touch, and getCutRanges will not bridge a gap that holds a kept word. Added a test in silences-test.ts.

Fixes #90

Remove silences cuts the pause on each side of a word. When the word is
shorter than ~0.25s, the two cuts were less than MERGE_GAP apart, so
addManualCut and getCutRanges joined them into one cut that covered the
word. The word dropped out of the edit and Restore silences found no
word-free cut to bring back.

Manual cuts now only join when they overlap or touch, and getCutRanges
no longer bridges a gap that holds a kept word.
@vercel

vercel Bot commented Oct 26, 2026

Copy link
Copy Markdown

@Bortlesboat is attempting to deploy a commit to the wassgha's projects Team on Vercel.

A member of the Team first needs to authorize it.

@wassgha
wassgha merged commit 547ca8d into wassgha:main Oct 29, 2026
1 check failed
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.

Restore not working

2 participants