fix(video): make one-frame scene sampling deterministic - #11344
Merged
Merged
Conversation
diegosouzapw
marked this pull request as draft
August 24, 2026 06:02
Owner
Author
|
Exact-base CI classification (snapshot: 2026-08-24 07:17 UTC; base
No PR-specific defect is proven by these failures, so no noise commit was added. This is not a claim that the full CI suite is green; the PR remains open and draft. |
diegosouzapw
marked this pull request as ready for review
August 24, 2026 12:24
This was referenced Aug 24, 2026
This was referenced Aug 26, 2026
Merged
muhamadgalihsaputra
pushed a commit
to niyatna/NiyatnaRoute
that referenced
this pull request
Sep 27, 2026
…#11344) Merged via consolidated batch validation. Makes scene_aware Video Bridge sampling deterministic for a one-frame budget: falls back to the midpoint of the active full-video/focus window and reports policyEffective: uniform (a single scene candidate can't preserve both temporal ends). Adds opt-in real-FFmpeg fixture matrix (rapid edge cuts, one-frame budget, static/gradual scenes, sub-second clips, detector failure). Static gates green; own regression suite (videoBridgeSampler.test.ts, video-bridge-sampler-ffmpeg.test.ts) passed in the combined-batch run. Related to diegosouzapw#9760. Thanks!
muhamadgalihsaputra
pushed a commit
to niyatna/NiyatnaRoute
that referenced
this pull request
Sep 27, 2026
…apw#11344/diegosouzapw#11381/diegosouzapw#11362/diegosouzapw#11382/diegosouzapw#11383 growth These entries were already validated in an earlier merge-batch worktree but never reached origin (worktree discarded before pushing). Re-adding them here since diegosouzapw#11355's test/route.ts growth (1215->1237) is now live on origin/release/v3.8.50 and fails the frozen cap otherwise.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
scene_awareVideo Bridge sampling deterministic when the caller allows only one frame.policyEffective: "uniform", because one scene candidate cannot preserve both temporal ends.Related Issues
Validation
Choose the change type and focused loop from the
Contribution Golden Path. The full unit suite,
Vitest, the 60% coverage gate, and the production build all run in CI on this PR (#8329):
npm run lintPost-rebase evidence against the then-live
release/v3.8.50tip:npm run typecheck:core: PASS.npm run typecheck:noimplicit:core: BASE-RED outside this PR inopen-sse/translator/response/openai-responses/pureHelpers.ts(implicit-anydiagnostics from the current release tip); this branch changes neither that file nor
the no-implicit config.
npm run check:docs-all: PASS; only the existing soft executor-count/version notices were reported.git diff --check: PASS.npm run lintpassed before the final base-only rebase; the affected files were linted again after rebase.Tests Added Or Updated
tests/unit/guardrails/videoBridgeSampler.test.tstests/integration/video-bridge-sampler-ffmpeg.test.tsThe real-FFmpeg matrix is intentionally opt-in because FFmpeg is an optional operational dependency:
Without the environment variable, the integration collector records an explicit skip instead of hiding the missing runtime dependency.
Coverage Notes
0.25sand7.75swith a one-frame budget previously selected the final candidate and still claimedscene_aware; it now selects the deterministic4smidpoint and reportsuniform.[2s, 8s]resolves to5sand retains the normalized focus metadata.ffprobe/ffmpegcommands and verifies extraction, not only selection helpers.segment_awarebehavior or the FU-07 structural sampler.Reviewer Notes