SPAgent: Adaptive Task Decomposition and Model Selection for General Video Generation and Editing

Rong-Cheng Tu, Wenhao Sun, Zhao Jin, Jingyi Liao, Jiaxing Huang, Dacheng Tao

TL;DR

This paper introduces SPAgent, an intelligent system that automatically coordinates various open-source video generation and editing models to fulfill diverse user requests. By intelligently recognizing user intent, planning execution routes, and selecting the best models for each step, SPAgent significantly lowers the barrier to entry for complex video creation and editing tasks.

What Problem Does This Paper Address?

The field of AI-powered video generation and editing has seen rapid progress, with many powerful open-source models emerging. However, these models are often specialized for specific tasks (e.g., text-to-video, image-to-video, video editing). To achieve complex video creation or editing goals, users typically need to manually chain these models together. This process is incredibly challenging, requiring deep technical knowledge of each model's capabilities, limitations, and how to best combine them. This complexity creates a high barrier to entry, preventing many users from leveraging the full potential of these tools. SPAgent aims to solve this by automating the coordination of these diverse models.

Methods

SPAgent employs a three-step framework to achieve its goal:

  1. Decoupled Intent Recognition (DIR): This module first identifies the types of user input (text, image, video) and then assesses the semantic alignment between them. It also predicts the subject of the desired video. This helps in understanding the user's underlying intent, even with multimodal inputs.
  2. Principle-guided Route Planning (PRP): Based on the recognized intent, this module plans an ordered sequence of tasks (an "execution route") to achieve the user's goal. It uses predefined principles derived from analyzing common video generation and editing workflows to ensure logical task sequencing. The system generates two potential routes to offer flexibility.
  3. Capability-based Models Selection (CMS): For each task in the planned routes, SPAgent selects the most suitable model from its tool library. This selection is based on a detailed understanding of each model's strengths and weaknesses across different subjects and tasks, which is learned from performance statistics.

Additionally, SPAgent features a Video Quality Evaluation capability. This allows it to autonomously assess the quality of videos produced by new models and automatically integrate them into its tool library, enabling continuous expansion and improvement without manual intervention.

Datasets

The authors introduced a manually annotated multi-task generative video dataset. This dataset was curated to cover six distinct categories (sports, transportation, people, animals, objects, landscapes) and includes text, image, and video inputs. For each input, it provides descriptive prompts and three editing prompts (foreground, background, style). The output videos were annotated with quality scores (Mean Opinion Score - MOS) based on intrinsic quality and prompt alignment.

Key Insights and Ideas

  • The "Swiss Army Knife" of Video AI: The core idea is that no single model is perfect for all video tasks. By intelligently orchestrating a collection of specialized models, a much more versatile and powerful system can be built.
  • Intent is Key: Accurately understanding what the user wants to achieve, especially with mixed-media inputs, is crucial. SPAgent's DIR module is vital for this.
  • Planning Before Doing: Simply picking the "best" model for a single step isn't enough. A well-defined sequence of operations (route planning) is necessary for complex tasks, much like a recipe.
  • Self-Improving Tool Library: The ability for the system to learn about and integrate new models autonomously is a significant step towards more adaptable AI systems. This reduces the burden on developers and researchers to constantly update the system manually.

Key Results

  • SPAgent achieved higher overall video generation and editing quality compared to individual tools and baseline methods, as measured by Mean Opinion Score (MOS). For example, in the Text-to-Video task, SPAgent's MOS reached 12.386, outperforming individual tools.
  • The system demonstrated a 100% task completion rate for Text-to-Video and Image-to-Video tasks, and high accuracy for Video-to-Video tasks, comparable to powerful models like GPT-40.
  • Ablation studies showed that each component of SPAgent (DIR, PRP, CMS) contributes significantly to its performance, with the "One-Step" variant (omitting decomposition and planning) performing the worst.
  • The autonomous tool expansion capability was validated by successfully integrating a new model (CogVideoX) and observing improved video quality in relevant scenarios.

Limitations and Future Work

  • Manual Annotation Effort: While the dataset is valuable, its manual annotation process is labor-intensive.
  • Model Selection Precision: While SPAgent performs well, the paper notes that it aims for the "top two" model lists, implying there's still room for improvement in pinpointing the absolute best model every time.
  • Future Work: The authors suggest further research into more sophisticated route planning principles and exploring more complex multi-modal reasoning tasks. The ability to autonomously expand its tool library is highlighted as a key future direction.

Summary updated

BibTeX
@article{tu2026spagent,
  author = {Rong-Cheng Tu and Wenhao Sun and Zhao Jin and Jingyi Liao and Jiaxing Huang and Dacheng Tao},
  title = {{SPAgent: Adaptive Task Decomposition and Model Selection for General Video Generation and Editing}},
  journal = {IEEE Trans. Image Process.},
  year = {2026},
  doi = {10.1109/tip.2026.3673949},
}
Figure