Skip to content

feat(subtitles): HBO Max official bilingual subtitles — 2nd adapter on the streaming framework - #1

Open
semantic-craft wants to merge 1 commit into
feat/streaming-adapters-netflixfrom
feat/streaming-adapters-hbo
Open

feat(subtitles): HBO Max official bilingual subtitles — 2nd adapter on the streaming framework#1
semantic-craft wants to merge 1 commit into
feat/streaming-adapters-netflixfrom
feat/streaming-adapters-hbo

Conversation

@semantic-craft

Copy link
Copy Markdown
Owner

HBO Max / Max — second adapter on the streaming framework

Stacks on mengxi-ream#1757 (the framework PR). This is the proof the adapter design generalizes: adding HBO Max is a +386-line delta that reuses the shared capture → source/target selection → bilingual alignment pipeline unchanged.

  • hbo-max adapter + a minimal DASH MPD parser for HBO's segmented WebVTT subtitles
  • extends the MAIN-world interceptor to capture HBO's .vtt / .mpd responses, and the content-script bootstrap to non-/watch/ players
  • same StreamingSiteAdapter, same StreamingSubtitlesFetcher, same registry — no new plumbing

Its base is the Netflix framework branch, so this diff is only the HBO delta and stays under the 1000-line new-contributor threshold. Once mengxi-ream#1757 merges into main, this reopens against mengxi-ream:main as a clean ~386-line PR.

Tests

  • DASH manifest → segmented WebVTT tracks
  • HBO WebVTT segment parsing with DASH segment-start offsets

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1b97d046ef

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +31 to +32
if (!offsetMs || !fragments.length || fragments[0].start + 5_000 >= offsetMs)
return fragments

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Apply DASH offsets to relative WebVTT segments

For DASH tracks whose WebVTT segment cues are relative to the segment, this guard skips applying the segment offset whenever the offset is less than 5s (or the first local cue starts near the segment offset). The parser in this commit commonly produces early segmentStartMs values such as 1000/2000ms, so those segments would all render near 0s instead of their DASH timeline positions, breaking subtitle timing and bilingual alignment for segmented HBO tracks. The relative/absolute check needs to distinguish absolute cue timestamps without dropping valid relative offsets.

Useful? React with 👍 / 👎.

Second adapter on the streaming subtitle framework from the Netflix PR, proving
it generalizes beyond one site:

- hbo-max adapter + minimal DASH MPD parser for HBO's segmented WebVTT subtitles.
- Extends the MAIN-world interceptor to capture HBO's .vtt / .mpd responses and
  the content-script bootstrap to non-/watch/ players.
- Reuses the shared source/target selection + bilingual alignment unchanged.

Stacks on the Netflix framework PR; diff here is only the HBO delta.
@semantic-craft
semantic-craft force-pushed the feat/streaming-adapters-hbo branch from 1b97d04 to b1470c1 Compare June 28, 2026 12:51
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.

1 participant