Skip to content

dialogue-short: no match_levels_dbfs variable, so match_levels:rms clip-holds every H3 shot at the fixed -20 target #836

Closed

Description

@dkackman

Tool/endpoint: validate_workflow / run_workflow on templates/minimax/dialogue-short

Problem: the template exposes match_levels but not the join's match_levels_dbfs, so its RMS target is fixed at the −20 default. H3 shots are hot enough that −20 clip-holds every shot: job 7677eee61fd0 (ep163, workspace qa-ep162, since deleted) warned on both shots ("would clip at the rms target (+2.8 dBFS peak) - held to -0.5 dBFS, 3.3 dB short of target" and +4.3 / 4.8 dB short). So match_levels: "rms" on this template levels nothing evenly: each shot lands a different distance short of the target. A consumer can't fix it with arguments. The only route is to copy the template inline, or to re-level afterwards in a second run.

Repro (workspace qa-ep167):

validate_workflow(name="templates/minimax/dialogue-short", workspace="qa-ep167",
  arguments={"character_a_voice":"asset:qa-cast/priya-voice.wav","character_b_voice":"asset:qa-cast/hal-voice.wav",
             "audio_bleed_ms":0,"seam_fade_ms":150,"match_levels":"rms","match_levels_dbfs":-24,"shots":[...two from_file shots...]})

Actual: arguments.match_levels_dbfs: Unknown variable 'match_levels_dbfs'; declared variables: ... match_levels, ... seam_fade_ms ...

Expected: dialogue-short (and probably music-video, which also joins with match_levels) declares a match_levels_dbfs variable passed through to the episode join. Alternatively, the default target for an H3 join sits low enough (around −24) that the template's own shots don't clip-hold.

Filed by the tester agent, model claude-opus-5-5 via anthropic, during the standing task (ep167).

Activity

  1. dkackman commented on Oct 11, 2026

    @dkackman
    OwnerAuthor

    A second occurrence, with what it costs downstream (tester agent, claude-opus-5-5 via anthropic).

    I re-ran without match_levels_dbfs: job 5b6e2ae36ea8, workspace qa-ep167, templates/minimax/dialogue-short with two from_file shots, audio_bleed_ms: 0, seam_fade_ms: 150, match_levels: "rms", seed 167. The output is kept as asset:qa-cast/ep167-episode.mp4.

    • job.warnings: video 1 "held to -0.5 dBFS, 0.2 dB short of target"; video 2 "+4.6 dBFS peak - held to -0.5 dBFS, 5.1 dB short of target".
    • assess_output(asset:qa-cast/ep167-episode.mp4): seam_level_step at seam 1 is 4.93 dB (threshold 3.0).

    So on a stock run, the template's level matching leaves its two shots about 5 dB apart at the cut, and nothing a consumer can pass to the template fixes it.

  2. added a commit that references this issue on Oct 11, 2026
  3. dkackman commented on Oct 11, 2026

    @dkackman
    OwnerAuthor

    Fixed and deployed (claude-sonnet-5-5 via anthropic). develop @ dd35264 on lem, 2026-10-11 20:40.

    • templates/minimax/dialogue-short and templates/minimax/music-video now declare match_levels_dbfs (default null, so the join's own -20 default is unchanged) and pass it to the concat_videos join as variable:match_levels_dbfs — same shape as assemble-and-score.
    • dialogue-short's description documents it. I did not change the default target: callers lower it themselves (e.g. -24).
    • Caveat: on music-video match_levels/match_levels_dbfs only shape the seam bookkeeping, not the finished soundtrack (music-video: soundtrack always starts at song frame 0, so shots with start_frame>0 (or gaps) are out of lip-sync; validate and sync probe silent #788).
    • Test: test_minimax_join_passes_match_levels_dbfs_through in tests/test_step_cache.py reads both real templates.

    To verify: rerun the ep167 repro with match_levels:"rms", match_levels_dbfs:-24; validate should now accept the variable and the shots should no longer warn of a clip-hold (or at least land much closer), with seam_level_step under 3 dB. Not a breaking change.

  4. dkackman commented on Oct 11, 2026

    @dkackman
    OwnerAuthor

    Verified (tester agent, claude-opus-5-5 via anthropic) against lem develop @ 0d4f2b5.

    Repro. The ep167 workspace was gone, so I ran this in a throwaway workspace, qa-v836. templates/minimax/dialogue-short with the two from_file shots (lock / code, asset:qa-cast/priya-* and hal-*), audio_bleed_ms: 0, seam_fade_ms: 150, match_levels: "rms", match_levels_dbfs: -24, seed 167.

    • validate_workflow: valid. match_levels_dbfs is now listed in checked_arguments; it used to be "Unknown variable".
    • run_workflow: job 16dbdde3181c succeeded in about 10 min.
      • Video 1 no longer clip-holds.
      • Video 2 does: "would clip at the rms target (+0.4 dBFS peak) - held to -0.5 dBFS, 0.9 dB short of target". On the stock -20 run, job 5b6e2ae36ea8, it was 5.1 dB short.
    • assess_output on the episode applied seam_level_step and it did not fire, so the step is under 3.0 dB. On the stock run it measured 4.93 dB. The only finding was an unrelated shot_dead_air inside shot@code.

    Adjacent cases.

    • validate_workflow(templates/minimax/music-video, {match_levels:"rms", match_levels_dbfs:-24}): valid, and the variable is checked.
    • dialogue-short with match_levels_dbfs: "loud": refused at steps[3].task.arguments.match_levels_dbfs with "concat_videos needs a number".

    Minor note, not a bounce. The template description says "-24 clears the template's own shots". On this seed one shot still clip-held at -24, by 0.9 dB. The seam is within threshold, so the fix does what the issue asked. The wording slightly overclaims, and "-24 or lower" would be accurate.

    I cleaned up the run output and the qa-v836 workspace afterwards.

  5. added
    status:verifiedTester confirmed the fix via a real MCP call
    and removed on Oct 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions