Abstract
Recent text-to-video (T2V) diffusion models have demonstrated impressive generation capabilities across various domains. However, these models often generate videos that have misalignments with text prompts, especially when the prompts describe complex scenes with multiple objects and attributes. To address this, we introduce VideoRepair, a novel model-agnostic, training-free video refinement framework that automatically identifies fine-grained text-video misalignments and generates explicit spatial and textual feedback, enabling a T2V diffusion model to perform targeted, localized refinements. VideoRepair consists of two stages: In (1) video refinement planning, we first detect misalignments by generating fine-grained evaluation questions and answering them using an MLLM. Based on video evaluation outputs, we identify accurately generated objects and construct localized prompts to precisely refine misaligned regions. In (2) localized refinement, we enhance video alignment by 'repairing' the misaligned regions from the original video while preserving the correctly generated areas. This is achieved by frame-wise region decomposition using our Region-Preserving Segmentation (RPS) module. On two popular video generation benchmarks (EvalCrafter and T2V-CompBench), VideoRepair substantially outperforms recent baselines across various text-video alignment metrics.
Introduction
While modern text-to-video (T2V) diffusion models produce high-fidelity motion, they frequently struggle with compositional alignment. For instance, a prompt requesting "two bears and one person making pizza" might result in a video with three bears and no person, or a bear and a person but no pizza. Existing solutions typically rely on iterative prompt optimization—which is computationally expensive and lacks spatial precision—or layout-guided generation, which often produces visual artifacts where objects appear "pasted" onto the background.
VideoRepair addresses these issues by identifying which parts of a generated video are already correct and should be preserved, versus which specific regions require targeted correction.
Methodology
VideoRepair operates as a two-stage, training-free framework that can be integrated with any diffusion-based T2V model.
1. Video Refinement Planning
The process begins with a structured inspection of the initial video. An LLM generates fine-grained, object-centric questions based on the prompt (e.g., "Is there exactly one bear?"). A Multi-modal Large Language Model (MLLM) then "watches" the video to answer these questions. Based on this feedback, the system identifies Preserving Objects ($O^*$)—elements that were correctly generated—and formulates a Refinement Prompt ($p^r$) to address missing or incorrect components.
2. Localized Refinement
The "repair" stage focuses on regenerating only the faulty regions while maintaining the integrity of the correct ones.
- Region-Preserving Segmentation (RPS): Using a Vision-Language Model (Molmo) and Semantic-SAM, the system creates precise masks for the objects to be preserved.
- Localized Noise Re-initialization: During the diffusion process, the latent noise for preserved regions is kept from the original video to ensure temporal and visual consistency. Noise for the misaligned regions is resampled.
- Localized Text Guidance: The original prompt is applied to preserved areas, while the refinement prompt guides the generation of the "repaired" regions.
Experiments and Results
The framework was evaluated using three base models (VideoCrafter2, T2V-turbo, and CogVideoX-5B) across two major benchmarks: EvalCrafter and T2V-CompBench.
VideoRepair consistently outperformed baselines such as OPT2I and SLD. On EvalCrafter, it achieved relative alignment gains of +6.22% for VideoCrafter2 and +7.65% for T2V-turbo. On T2V-CompBench, which focuses on compositional logic, the framework showed significant improvements in numeracy and spatial relationships, with relative gains reaching up to +15.87%.
Discussion and Conclusion
A key insight of this work is that preservation is as critical as correction; completely regenerating a video to fix a minor error often destroys correctly generated elements. By masking and preserving valid latents, VideoRepair maintains superior temporal and visual continuity compared to holistic regeneration methods.
While highly effective, VideoRepair's performance is currently bounded by the capabilities of the "inspector" MLLM and the underlying segmentation model. Future work may explore 3D-aware temporal masking to better handle fast-moving objects and tighter integration with more advanced MLLMs for the planning stage.
Summary updated