From 95c97123dda803f8ff0c3e6e1fdb637ed6ca4acc Mon Sep 17 00:00:00 2001 From: digital-garbage <133010426+digital-garbage@users.noreply.github.com> Date: Mon, 15 Jun 2026 10:05:50 +0300 Subject: [PATCH] Stage 1 (diag): dump both splits on SCENE SPLIT MISMATCH The mismatch is structural, not a transform: generation splits the EXPANDED prompt (qcut/cut already replaced by their expansions) while attribution splits the RAW prompt (qcut/cut still live as triggers). Dump both splits' scene texts + keys so we can see exactly which words cause the raw split to over-count, before building the unified raw-first splitter. Co-Authored-By: Claude Opus 4.8 --- conditioning.py | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/conditioning.py b/conditioning.py index 1b76f8f0..79d814ad 100644 --- a/conditioning.py +++ b/conditioning.py @@ -12648,11 +12648,19 @@ class FunPackVideoRefinerV2(FunPackVideoRefiner): if len(canonical_scene_keys) == len(split_scene_texts): scene_refinement_keys = canonical_scene_keys else: + # DIAGNOSTIC: dump both splits so we can see exactly where they diverge. The text + # split is on the EXPANDED prompt (generation), the key split is on the RAW prompt + # (split_scenes). Trimmed to 80 chars/scene. + _canon = split_scenes(_raw_positive_prompt).get("scenes", []) print( - f"[FunPackVideoRefinerV2] SCENE SPLIT MISMATCH: text split has " - f"{len(split_scene_texts)} scene(s) but the raw key split has " - f"{len(canonical_scene_keys)} — a prompt transform changed the scene structure. " - f"Falling back to default-key attribution for this run." + f"[FunPackVideoRefinerV2] SCENE SPLIT MISMATCH: expanded/text split = " + f"{len(split_scene_texts)} scene(s), raw/key split = {len(canonical_scene_keys)}. " + f"Falling back to default-key attribution for this run.\n" + f" RAW key-split scenes ({len(_canon)}):\n" + + "\n".join(f" [{i}] keys={sorted(s.get('keys') or [])} :: {(s.get('raw') or '')[:80]!r}" + for i, s in enumerate(_canon)) + + f"\n EXPANDED text-split scenes ({len(split_scene_texts)}):\n" + + "\n".join(f" [{i}] {str(t)[:80]!r}" for i, t in enumerate(split_scene_texts)) ) scene_refinement_keys = [set() for _ in split_scene_texts]