Source-linked AI summary
TemplateCraft: Agentic Visual Template Generation
Hongjie Yu, Zhiyuan Fan, Yuzhe Zhang, Jiangcun Du, Zhicheng Gao, Yuhong Zhang, Xiaokai Zhan, Zongshi Xie
TL;DR
Reusable visual-template generation remains underexplored, although deployable workflows must coordinate replaceable inputs, persistent assets, and visual-output checks across steps. TemplateCraft uses a four-stage pipeline and a Planner–Evaluator loop that applies execution feedback, targeted rollback, and memory to produce client-executable templates. With long-term memory, TemplateCraft reaches 66.7%/50.0% on image/video tasks, gains of 10.0/20.0 percentage points over Planner-only.
Problem
Reusable visual-template generation remains underexplored, although deployable workflows must coordinate replaceable inputs, persistent assets, and visual-output checks across steps.
Source: §1 · p. 1Method
TemplateCraft uses a four-stage pipeline and a Planner–Evaluator loop that applies execution feedback, targeted rollback, and memory to produce client-executable templates.
Source: §1 · pp. 1–2Results
With long-term memory, TemplateCraft reaches 66.7%/50.0% on image/video tasks, gains of 10.0/20.0 percentage points over Planner-only.
Source: §3.3 · p. 4Takeaways & Limitations
TemplateCraft’s gains are in template-generation reliability, adherence, and reuse rather than generator-dependent perceptual quality.
Source: §3.2 · p. 4, §4 · p. 4At reuse, only the user input changes; the template specification, persistent assets, and workflow remain fixed.
Source: §2.1 · p. 2
Abstract
from arXiv · showhide
The growing popularity of short videos has driven demand for one-click content creation. Visual templates turn uploaded images into personalized content with preset effects, but reusable template generation still requires substantial manual effort in asset preparation and tool orchestration. We propose TemplateCraft, a multi-agent system that converts natural-language instructions into client-executable templates through planning, material generation, effect-workflow generation, and protocol compilation. Its Planner-Evaluator loop uses execution feedback for targeted rollback, while stage-level and long-term memory support revision without parameter updates. We evaluate TemplateCraft on TemplateBench, derived from 60 real-world templates. With the same Qwen3-VL backbone, TemplateCraft raises image/video generation success rates from 56.7%/30.0% to 66.7%/50.0% over Planner-only (best-of-three) and improves template adherence and style consistency. With additional evaluation and revision, it matches or exceeds a GPT-4o Planner-only baseline on selected metrics. Persistent assets further improve cross-input style consistency.
1. INTRODUCTION
Visual templates reduce users’ tool-selection and orchestration burden, but creating reusable templates still demands manual asset preparation and workflow refinement. TemplateCraft addresses this gap with a staged generation system, feedback-driven revision, and a benchmark for evaluating reuse.
1. INTRODUCTION
- Reusable visual templates simplify content creation for users, while designers still manually devise effects, prepare assets, and refine workflows for new themes.The introduction frames template generation as converting creative ideas into deployable workflows that different users can execute.Source: §1 · p. 1
- Prior work supports content generation and workflow orchestration, but reusable templates additionally require replaceable inputs, persistent assets, and visual-output checks after inputs change.The introduction identifies successful execution alone as insufficient and notes that revision must locate where a workflow needs correction.Source: §1 · p. 1
- TemplateCraft organizes generation into planning, material generation, effect-workflow generation, and protocol compilation, with execution feedback directing rollback to the earliest stage needing revision.Stage memory supports revision within a task, while long-term memory stores diagnostic knowledge for reuse across tasks without parameter updates.Source: §1 · pp. 1–2
- TemplateBench contains 30 image-template and 30 video-template tasks, each with a creative instruction, scoring rules, and five test input sets.The benchmark is derived from production templates in KwaiCut, and experiments examine feedback-driven revision, long-term memory, and shared persistent assets.Source: §1 · pp. 1–2
2. TEMPLATECRAFT
TemplateCraft formalizes reusable templates as parameterized content programs and builds them through planning, asset preparation, effect-workflow generation, and protocol compilation. A Planner–Evaluator loop uses execution feedback and memory to target revisions.
2.1. Template
- A template combines a specification, persistent assets, and an effect workflow; during reuse, only the user input changes.The workflow executes with the new input and retained assets to produce the output.Source: §2.1 · p. 2
2.2. Template Generation Stages
- Template planning retrieves a category skill relevant to the instruction and uses it with the available tools to produce specification P.Skills capture recurring creative concepts, shot organization, input requirements, duration, and tool combinations.Source: §2.2 · p. 2
- Material generation prepares simulated user inputs and persistent assets; the asset store S contains both, with persistent assets retained for template reuse.Persistent assets provide visual or motion conditioning signals.Source: §2.2 · p. 2
- Effect-workflow generation plans tool operations from specification P, material store S, and tool descriptions, then executes the workflow to produce a preview.Each declared asset must contribute to the final output in its specified role.Source: §2.2 · p. 2
- Protocol compilation converts variable references, parameters, and step dependencies into a client-executable sequence and packages required assets.User inputs become replaceable slots, while persistent assets are retained and linked to generation steps.Source: §2.2 · p. 2
2.3.1. Memory
- The Planner–Evaluator loop revises specifications and workflows using execution feedback, while task memory records stage states and long-term memory supplies experience from completed tasks.Long-term memory is available to the Evaluator, which can consolidate recurring errors and revision traces.Source: §2.3 · p. 2, §2.3.1 · p. 3
2.3.2. Planner
- The Planner generates stage-specific specifications or workflows and, after rollback, revises the selected stage using its artifact, historical summary, and feedback.During normal execution, the Planner does not read stage submemory.Source: §2.3.2 · p. 3
2.3.3. Evaluator
- The Evaluator diagnoses candidate outputs or execution failures, routes revision to the earliest stage needing change, and preserves preceding artifacts during rollback.Routing can target planning, material generation, or effect-workflow generation; evaluation and revision occur during template generation.Source: §2.3.3 · p. 3
3. EXPERIMENTS
The experiments evaluate whether TemplateCraft produces reusable templates that satisfy creative requirements across inputs, and whether feedback-driven revision and persistent assets improve that capability. TemplateBench tests 30 image and 30 video tasks using five fixed input sets per task.
3.1. TemplateBench
- TemplateBench contains 30 image-template and 30 video-template tasks, each with five fixed test-input sets, a creative brief, and scoring rules.Templates are frozen before execution on the test sets; video tasks additionally assess interaction, camera changes, continuity, and audiovisual timing.Source: §3.1 · p. 3, Figure 2 · p. 3
3.2. RQ1: Template Quality
- TemplateCraft improves image/video template adherence from 0.5168/0.4034 to 0.6583/0.6534 over Planner-only, while its reusability gains indicate better reuse.Perceptual-quality leaders vary by metric; TemplateCraft’s main gains are in reliability, adherence, and reuse.Source: §3.2 · p. 4, Table 1 · p. 4
3.3. RQ2: Multi-Agent Capabilities
- With long-term memory, TemplateCraft reaches 66.7%/50.0% image/video generation success, gains of 10.0/20.0 percentage points over Planner-only, and the highest TA among Qwen-based template-generation variants.Planner-CoT raises video success from 30.0% to 43.3% while leaving image success unchanged; Planner–Evaluator raises image success to 63.3%.Source: §3.3 · p. 4, Figure 3 · p. 4
- Against GPT-4o Planner-only, TemplateCraft matches image generation success and improves video success from 40.0% to 50.0% and video TA from 0.6383 to 0.6534, although image TA is lower.The comparison uses additional evaluation and revision calls.Source: §3.3 · p. 4
3.4. RQ3: Persistent Assets
- Requiring persistent assets improves template reusability for both image and video tasks, with a larger gain on video.The comparison uses all 60 TemplateBench tasks and measures cross-input style consistency using TR.Source: §3.4 · p. 4, Figure 3 · p. 4
4. CONCLUSION
TemplateCraft converts natural-language creative instructions into reusable visual templates through a staged multi-agent pipeline. Experiments report improvements over Planner-only and benefits from targeted revision, memory, and persistent assets.
4. CONCLUSION
- TemplateCraft combines a staged pipeline, feedback-driven revision, and long-term memory to support reusable visual-template generation.The system converts natural-language creative instructions into reusable templates.Source: §4 · p. 4
- With the same Qwen3-VL backbone, TemplateCraft improves template generation success and adherence over Planner-only for image and video templates.It achieves the highest adherence and video reusability among template-generating methods.Source: §4 · p. 4
- The full Qwen-based system matches or exceeds GPT-4o Planner-only on selected metrics, with additional evaluation and revision calls.The conclusion also reports that shared persistent assets help preserve style across inputs.Source: §4 · p. 4
5. COMPLIANCE WITH ETHICAL STANDARDS
The study reports its ethical scope, validation procedure, data handling, and intended-use boundary.
5. COMPLIANCE WITH ETHICAL STANDARDS
- The study involved no biomedical intervention or animal experimentation.TemplateCraft is not intended for high-stakes decisions about individuals.Source: §5 · p. 5
- Three raters assessed a stratified sample of 120 outputs using a shared five-point rubric, with method identities and implementations concealed.Only task scores were recorded, and only aggregate agreement is reported.Source: §5 · p. 5
- TemplateBench uses abstract specifications and rubrics derived from KwaiCut usage patterns, not original client assets or user-uploaded content.Test assets and generated outputs were used under applicable permissions.Source: §5 · p. 5