Skip to content

Unify frame sampling, add fast mode, and support bundled-app transcription#1

Open
Justrada wants to merge 1 commit into
mainfrom
unified-frame-sampler-fast-mode
Open

Unify frame sampling, add fast mode, and support bundled-app transcription#1
Justrada wants to merge 1 commit into
mainfrom
unified-frame-sampler-fast-mode

Conversation

@Justrada

Copy link
Copy Markdown
Owner

What changed

Replaces the codec-specific I-frame extraction path with a single
binary-subdivision sampler that works for any codec. Frames are grabbed
in coverage-priority order (endpoints → midpoint → quarters → eighths…) and
bounded by both a max_frames cap and a time_budget, so faster machines
and shorter clips naturally get denser coverage — no per-codec branching.

Highlights

  • core/frames.py — drop the ALL_INTRA_CODECS special case. New
    sample_frames() (capped subdivision + similarity filtering) and
    sample_fast_frames() (N equidistant frames, no filtering).
  • core/schemas.py — new settings: max_frames, time_budget,
    fast_mode, fast_frame_count.
  • core/transcribe.py — mlx-whisper now falls back to a subprocess
    using whichever Python interpreter has it installed, so transcription works
    in the packaged app; the in-process path is kept for running from source.
  • core/llm.py — thread a logger into LLM clients; clearer
    transcript-summary logging plus a retry on the first failure.
  • AutoBin.spec — bundle mlx_whisper + huggingface_hub into the
    frozen build.
  • gui/ — surface fast mode and the new sampling knobs through the
    settings panel, and wire them through the orchestrator and workers.
  • .gitignore — ignore *.LRV test footage and node_modules / the
    remotion out/ dir.

Why

Per-codec branching was fragile and gave inconsistent coverage. A unified,
budget-bounded sampler is simpler and adapts to the machine/clip. Fast mode
gives a quick low-cost pass (few frames, tiny whisper, single LLM batch).
Subprocess transcription unblocks the packaged/bundled app.

Reviewer notes

  • Unrelated untracked items in the working tree (a remotion/ experiment
    with node_modules, a docs flowchart, and a test .LRV clip) are
    intentionally excluded from this PR; the heavy ones are now gitignored.
  • No automated tests in this repo — changes exercised manually via the GUI.

🤖 Generated with Claude Code

…ption

Replace codec-specific I-frame extraction with a single binary-subdivision
sampler that works for any codec. Frames are grabbed in coverage-priority
order (endpoints → midpoint → quarters → eighths…) and capped by both a
max_frames count and a time budget, so faster machines and smaller clips
naturally get denser coverage without per-codec special-casing.

- core/frames.py: remove ALL_INTRA_CODECS branch; add sample_frames (capped
  subdivision) and sample_fast_frames (N equidistant frames, no filtering).
- core/schemas.py: new settings — max_frames, time_budget, fast_mode,
  fast_frame_count.
- core/transcribe.py: mlx-whisper now falls back to a subprocess using a
  Python interpreter that has it installed, so transcription works in the
  packaged app; in-process path retained for running from source.
- core/llm.py: thread logging into LLM clients; clearer transcript-summary
  logs and a retry on first failure.
- AutoBin.spec: bundle mlx_whisper + huggingface_hub for the frozen build.
- gui/: wire fast mode and the new sampling settings through the settings
  panel, orchestrator, and workers.

.gitignore: ignore *.LRV test footage and node_modules / remotion out dir.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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