Skip to content

Per-show longest ad break, false-start bumpers, ads missing from the feed's transcript - #24

Merged
dben merged 5 commits into
mainfrom
claude/serene-mccarthy-9sqwaf
Oct 24, 2026
Merged

dben merged 5 commits into
mainfrom
claude/serene-mccarthy-9sqwaf

Conversation

@dben

@dben dben commented Oct 24, 2026

Copy link
Copy Markdown
Owner

Fixes a bumper played before a short notice cutting everything up to the next break (BtB, "Part Two: Peter Attia and the Cult of Longevity": 26:59–38:16 cut where only 34:01–38:13 was a break), and adds a check that cuts what a feed's transcript leaves out.

Break detection

  • Longest ad break is a per-show setting, 8 minutes by default (it was a fixed 10). --max-break for the CLI.
  • A second bumper-in starts a break over. A break never holds two, so the first was a false start, or its bumper-out was missed.
  • A bumper-out with a bumper-in within 15 s of it leads into a break, unless known ads came since the break opened. In the Attia episode the false break ended at the closing half of a back-to-back sting pair (#46, #47) going into the real break.

Missing from the transcript (podblock/app/missing.py)

Shows with inserted ads usually make their feed's transcript before the ads go in. For those shows, each download is transcribed too and lined up with the feed's transcript word for word.

  • Stretches of 20 s or more get cut when whisper heard speech the transcript doesn't have, or when the download runs much longer than the transcript between the same two words. They show on the timeline as Not in transcript and in chapters as ad breaks.
  • A break found from bumpers that is mostly what the transcript has is dropped. This only applies once the transcript has been seen to leave ads out.
  • Once checked, whisper's captions are served in place of the feed's transcript, whose times run behind after each ad. The feed's transcript stays on the episode, unserved, to check against.
  • Each stretch has Don't cut this on the timeline, kept for that episode.
  • Settings checkbox, on by default. It shows only when the transcriber is set and the feed lists transcripts in its newest 20 items, or the check was turned on.

Schema

  • 18: podcasts.max_break
  • 19: podcasts.transcript_check, episodes.missing_cuts, episodes.missing_kept

Main's timings table keeps step 17.

Testing

  • 249 tests pass, ruff clean.
  • New tests cover the break rules (one built from the Attia episode's timings), the alignment, the captions check, the per-episode keep and the settings checkbox.
  • Not yet run against real feeds or seen in a browser.

Generated by Claude Code

A bumper-in played before a short notice opened a break that ran on to the
next bumper-out, cutting the episode between them. A break never holds a
second bumper-in, so one now starts the break again; and the longest gap
between a bumper-in and bumper-out is a podcast setting (5 minutes by
default, down from a fixed 10), with --max-break for the CLI.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KeJQXPPUL3Cgbt5ESv2qyM
…came first

A sting played before a notice opened a break that ended at the closing half
of a back-to-back sting pair going into the real break. With no known ads
since a break opened, such a bumper-out is skipped and the bumper-in after it
starts the break over.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KeJQXPPUL3Cgbt5ESv2qyM
The max_break column moves to migration 18, after main's timings table.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KeJQXPPUL3Cgbt5ESv2qyM
Shows with inserted ads make their feed's transcript before the ads go in.
For such a show (a checkbox in its settings, on by default when the
transcriber is set and the feed has transcripts), each download is
transcribed too and lined up with the feed's transcript word for word.
Speech with nothing for it in the transcript, or audio running on much
longer than the transcript between the same two words, is cut when it lasts
20 s or more, and shown on the timeline as Not in transcript. A break found
from bumpers that is mostly what the transcript has is dropped, once the
transcript is known to leave ads out.

The feed's transcript stays the one served; what was heard is saved as its
word times, which intro and outro phrases now use too.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KeJQXPPUL3Cgbt5ESv2qyM
…s for checked shows

- Each Not in transcript stretch on the timeline has Don't cut this, saved
  with the episode's other changes. A kept stretch is stored as its span, and
  one found later that is mostly inside it stays kept.
- Once a checked episode is transcribed, its captions are served in place of
  the feed's transcript, whose times run behind after each inserted ad. The
  feed's transcripts stay on the episode, unserved, to check against.
- The checkbox shows only when the feed lists transcripts in its newest 20
  items (under a millisecond to look), or the check was turned on.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KeJQXPPUL3Cgbt5ESv2qyM
@dben
dben merged commit 826dcdf into main Oct 24, 2026
5 checks passed
@dben
dben deleted the claude/serene-mccarthy-9sqwaf branch October 24, 2026 13:25
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.

2 participants