Repository navigation
fix(cli): diff stops counting a fast move as an extra cut - #6978
Conversation
A regenerated shot never lines up with a whip frame by frame, so diff listed every fast move. A jump now counts only above the original's own motion around it. fails without the fix: reads a change no stronger than the original's motion as the same fast move
jrusso1020
left a comment
There was a problem hiding this comment.
Reviewed at d29fb1537840d9593af85f0e5b4589a8d10f683a.
The motion comparison is applied only to unmatched cuts, leaves missing cuts unchanged, and excludes original cut spans from its local motion baseline.
Need: yes · Size: ok, two files · Reuse: classifiedCuts, frameChanges and existing cut matching · Simpler: already minimal · Structure: fine
Risk: low — local diff diagnostic/classification change, no generation or billing path changed.
Validation: node node_modules/vitest/vitest.mjs run src/measure/diff.test.ts src/measure/diff-segments.test.ts src/measure/diff-people.test.ts: 35 passed on this exact head, including the existing delayed-cut regression. Disabling the new unmatched-cut motion filter makes its suppression witness fail while its quiet-baseline/true-cut and delayed-original-cut unit controls still pass. Independent source-module controls cover 24/30/60 fps windows, first/last transitions and multi-frame original-cut exclusion.
The 1.5 threshold is a disclosed heuristic: weaker real cuts during fast motion can be suppressed. I did not rerun the eight-render museum/bench corpus or validate its reported counts.
Verdict: APPROVE
Reasoning: No blocking regression found in the changed path and its callers. The limited scope and disclosed validation limits support landing.
— hf-review
… miao/diff-extra-cuts-against-motion # Conflicts: # packages/cli/src/measure/diff.test.ts # packages/cli/src/measure/diff.ts
jrusso1020
left a comment
There was a problem hiding this comment.
Reviewed at ddbd50d9faa4cb1b95a5fca9603462e73e3277fc (merge-only re-review).
The resolution preserves both reviewed changes: cutsBeyondMotion and cutReport are byte-identical to approved d29fb1537; rateWarning, projectRate and their warning insertion are byte-identical to approved #6976 at 029fc5ee4. Against the merged main parent, only the two original diff files change.
Need: yes · Size: ok, two-file increment · Reuse: existing cut classifier and composition FPS parser · Simpler: already minimal · Structure: fine
Risk: low — combines the two previously reviewed diff changes without changing their logic.
Validation: node node_modules/vitest/vitest.mjs run src/measure/diff.test.ts src/measure/diff-segments.test.ts src/measure/diff-people.test.ts: 38 passed on this head, including frame-rate warnings, motion suppression and delayed cuts. Independent source review found no merge-resolution blocker. No film-corpus or full browser project-capture rerun; the disclosed 1.5x heuristic limitation remains.
Verdict: APPROVE
Reasoning: Both implementations and their tests survive the resolution; no new blocker found. Unrelated main changes are inherited, outside this focused merge review.
— hf-review
Add heygen-com#6973 and heygen-com#6978, which merged ahead of the release PR and shipped in v0.9.0 without an entry. Correct the PLAN_TOO_LARGE upgrade note: the plan-size cap only applied to Plan v1, and Plan v2 never raises it. Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
What
hyperframes diffno longer counts a jump in yours as an extra cut when the original moves just as hard at that moment. Those go tonot_cutsasfast.Why
From the reverse-any-video feedback. A regenerated shot never lines up with a whip frame by frame, so
difflisted 10 to 16 extra cuts on the museum film, all inside its fast moves. Those hid the real problems: the code-first render's visible purple block was one line among 10.How
cutsBeyondMotioncompares each unmatched cut in yours with the strongest change in the original within a quarter second. It stays an extra cut only aboveOVER_MOTION(1.5x) of that. The original's own cuts are left out of the comparison, otherwise a cut a few frames late would hide behind the real one.missingdoes not change.Extra cuts from the real
diff, on 8 renders. Before is after plus the cuts moved tofast; none of these originals has afastof its own:The other bench renders had no extra cuts, so this rule cannot change them.
Test plan
fails without the fix:
diff.test.ts"reads a change no stronger than the original's motion as the same fast move"diff.test.ts,diff-segments.test.ts,diff-people.test.ts: 35 passed, including "reports a cut a few frames late as missing and extra".ali, 6 inig03: all 28 the detector found stayed extra cuts, including those inside whips. Two splices were not found by the detector itself.ali,ig03,cindy) show the same change in the original.OVER_MOTIONis tuned on these films. A weak real cut inside a fast move can still pass as motion.