Classifier-free guidance (CFG) typically applies a shared scale to all latent tokens, although their velocity predictions evolve differently during sampling. We introduce Trajectory-Adaptive Classifier-Free Guidance (TrajCFG), a training-free method for flow-matching models that adapts token-wise guidance using historical changes in guided velocity direction. TrajCFG maps this feedback to bounded scales, assigning stronger guidance to larger directional changes and weaker guidance to more consistent directions. It combines adjacent-step and interval-normalized longer-span feedback, reusing standard CFG predictions without additional model evaluations. Controlled diagnostics and ablations examine the roles of directional feedback, token-wise allocation, and history-span fusion. Experiments on text-to-video, image-to-video, text-to-audio-video, text-to-image, and image-to-3D generation show improvements over base samplers across multiple backbones. For text-to-video generation, TrajCFG improves VBench Total scores by 0.30-0.75 points over the strongest evaluated baseline on each of three backbones. These results support historical directional feedback as a broadly applicable signal for fine-grained guidance allocation. The project page is available at https://jyliu-98.github.io/trajcfg-project-page/.
Figures & tables
Figure 1: Overview of TrajCFG. Standard CFG uses a fixed scale (purple), while TrajCFG (teal) adapts each token’s scale using guided velocities from the two most recent completed steps. Larger historical angles yield stronger guidance; smaller angles yield weaker guidance. Predictions are reused without extra model evaluations. For clarity, the illustration shows adjacent-step feedback. Trajectories are schematic.
Figure 2: Content-related structure in historical angles. Generated frames and historical velocity-angle maps at sampling step k=5 from Wan2.2-14B on Dynamic-Bench. Warmer colors indicate larger angular changes.
Figure 3: CFG response by historical angle group. Groups are fixed across candidate CFG scales. Clean-latent MSE differences are relative to CFG =5 (negative is better); shading indicates standard deviations.
Method
Wan2.1-1.3B
Wan2.2-5B
Wan2.2-14B
Time
VBench
Dynamic-Bench
VBench
Dynamic-Bench
VBench
Dynamic-Bench
Qual.
Sem.
Total
Mot.
Over.
Avg.
Qual.
Sem.
Total
Mot.
Over.
Avg.
Qual.
Sem.
Total
Mot.
Over.
Avg.
Base
83.03
72.77
80.98
96.40
22.36
66.18
82.88
74.52
81.21
96.58
24.00
67.45
82.93
73.05
80.96
98.14
23.47
69.14
1.0 ×
CFG-Zero
82.69
73.95
80.94
97.13
23.81
66.64
83.79
74.84
82.00
96.68
24.19
67.94
83.32
75.27
81.71
98.02
25.18
69.41
1.0 ×
CFG-Ctrl
83.65
72.68
81.45
97.28
24.18
66.90
84.12
76.75
82.64
96.95
24.09
67.42
83.09
76.11
81.70
98.38
24.79
69.50
1.0 ×
PAG
83.24
73.92
81.38
97.15
23.89
67.25
83.37
76.14
81.93
96.91
24.11
67.63
83.07
73.31
81.12
98.11
24.90
69.46
1.5 ×
Table 1: Text-to-video generation results on VBench and Dynamic-Bench. VBench reports the official Quality (Qual.), Semantic (Sem.), and Total scores. For Dynamic-Bench, Mot., Over., and Avg. denote Motion Smoothness, Overall Consistency, and the average over evaluated VBench dimensions under the custom protocol. Higher scores are better. Runtime is measured relative to Base ( 1.0× ). Best and second-best scores in each metric column are bold and underlined, respectively.
Method
Cosmos-Predict2.5-2B
Wan2.2-5B
Wan2.2-14B
Time
VBench-I2V
PAI-Bench-G
VBench-I2V
PAI-Bench-G
VBench-I2V
PAI-Bench-G
Img.
Mot.
Qual.
Img.
Mot.
Qual.
Img.
Mot.
Qual.
Img.
Mot.
Qual.
Img.
Mot.
Qual.
Img.
Mot.
Qual.
Base
98.46
99.09
66.87
96.76
99.09
61.32
98.74
99.02
67.49
97.14
98.72
59.56
98.51
98.77
66.87
96.69
98.50
58.86
1.0 ×
CFG-Zero
98.53
99.14
67.07
96.83
99.13
61.61
98.25
98.92
67.17
96.86
98.72
60.00
97.69
98.69
65.65
96.44
98.48
58.52
1.0 ×
CFG-Ctrl
98.13
98.97
66.88
95.85
98.37
60.93
98.37
99.10
66.37
97.23
98.97
59.81
98.48
98.79
66.63
96.42
98.52
58.18
1.0 ×
PAG
98.46
99.10
66.87
96.71
99.08
61.62
98.71
99.02
67.37
96.95
98.69
60.26
98.20
98.76
66.85
96.66
98.53
58.69
1.5 ×
Table 2: Image-to-video generation results on VBench-I2V and PAI-Bench-G. Img. (Image Alignment) denotes the mean of I2V Subject and I2V Background; Mot. denotes Motion Smoothness; and Qual. denotes the mean of Aesthetic Quality and Imaging Quality. Higher scores are better. Runtime is measured relative to Base ( 1.0× ). Best and second-best scores in each metric column are bold and underlined, respectively.
Figure 4: Qualitative comparisons for video generation. (a) TrajCFG is compared with Base on Wan2.1-1.3B/VBench (left) and CFG-Zero on Wan2.2-14B/Dynamic-Bench (right). (b) TrajCFG is compared with CFG-Ctrl on Cosmos-Predict2.5-2B/VBench-I2V (left) and SRVS on Wan2.2-14B/PAI-Bench-G (right); input images appear beside the prompts. Guidance-scale rows visualize TrajCFG’s token-wise scales at sampling step k=5 , with warmer colors indicating stronger guidance. Red boxes highlight artifacts in the competing-method sequences.
Variant
Wan2.1-1.3B
Wan2.2-5B
Quality
Semantic
Total
Quality
Semantic
Total
TrajCFG (Full)
84.06
75.37
82.32
84.82
77.45
83.35
Q1
Time-only
83.94
73.17
81.78
84.62
76.94
83.08
Sample-wise
83.83
74.02
81.87
84.48
76.34
82.85
Q2
Shuffled allocation
83.77
73.67
81.75
84.43
76.73
82.89
Reversed allocation
83.70
72.96
81.55
84.55
75.82
82.81
Table 3: Ablation study of TrajCFG for text-to-video generation on VBench. We report the official Quality, Semantic, and Total scores (higher is better). Fusion weights (w1,w2) correspond to adjacent-step ( h=1 ) and stride-2 ( h=2 ) guidance estimates, respectively; TrajCFG (Full) uses (0.8,0.2) . Best and second-best scores in each metric column are bold and underlined, respectively.
Backbone
Method
VABench
T2AV-Compass
Visual Realism ↑
Audio Aes. ↑
T-A ↑
A-V ↑
Desync ↓
VT ↑
AA ↑
T-A ↑
A-V ↑
DS ↓
LTX-2.3
Base
4.615
3.345
0.3118
0.2490
0.5911
7.295
6.709
0.1722
0.2469
0.7140
TrajCFG
4.638
3.351
0.3202
0.2567
0.5685
7.510
6.738
0.1735
0.2481
0.7016
Ovi
Base
4.522
3.282
0.3288
0.1564
0.7659
6.714
6.676
0.0897
0.1596
0.9624
TrajCFG
4.547
3.364
0.3316
0.1654
0.7080
7.199
6.733
0.0922
0.1622
0.9356
Table 4: Text-to-audio-video results. Audio Aes., T-A, A-V, VT, AA, and DS denote Audio Aesthetics, text–audio alignment, audio–visual alignment, Video Technological, Audio Attribute, and DeSync. Lower is better for Desync and DS; best scores within each backbone are bold.
Backbone
Method
GenEval
DPG-Bench
Single Obj. ↑
Two Obj. ↑
Counting ↑
Colors ↑
Position ↑
Attr. Bind. ↑
Overall ↑
Global ↑
Entity ↑
Attribute ↑
Relation ↑
Other ↑
Overall ↑
Qwen-Image
Base
0.9875
0.9318
0.6094
0.8324
0.4950
0.5825
0.7412
89.39
90.84
89.48
91.76
90.63
87.11
TrajCFG
0.9906
0.9394
0.6188
0.8617
0.4950
0.6050
0.7517
91.03
93.20
90.40
93.21
94.35
87.19
SD3-Medium
Base
0.9969
0.8611
0.6125
0.8351
0.3125
0.5650
0.7021
86.98
84.24
86.26
87.30
85.19
83.56
TrajCFG
1.0000
0.8813
0.6344
0.8484
0.3225
0.5975
0.7140
88.35
86.37
86.55
89.38
86.15
83.99
Table 5: Text-to-image results. Higher is better; best scores within each backbone are bold, including ties.
Backbone
Method
Shape
Texture
ULIP-T ↑
ULIP-I ↑
Uni3D-T ↑
Uni3D-I ↑
CMMD ↓
FIDCLIP↓
CLIP-score ↑
LPIPS ↓
Hunyuan3D 2.0
Base
0.1753
0.2277
0.2190
0.2714
0.0571
0.0606
0.2503
0.1015
TrajCFG
0.1762
0.2290
0.2198
0.2719
0.0532
0.0581
0.2505
0.1008
Table 6: Image-to-3D results on GSO. Metrics follow Hunyuan3D 2.0; -T and -I denote mesh–text and mesh–image similarity. Arrows indicate direction; best scores are bold.
Appendix figures & tables13 assets
Supplementary material from the paper’s appendix.
Appendix
Task
Backbone
sbase
smin
smax
ρlo
Steps
T2V
Wan2.1-1.3B
6.0
5.0
10.0
0.95
40
Wan2.2-5B
5.0
3.0
10.0
0.95
40
Wan2.2-14B
3.5
1.0
10.0
0.90
40
I2V
Cosmos-Predict2.5-2B
5.0
4.0
9.0
0.90
35
Wan2.2-5B
5.0
2.0
10.0
0.95
40
Wan2.2-14B
2.5
1.0
7.0
0.95
40
Appendix
Table 7: Hyperparameter settings for each task and backbone.
Figure 5: Additional qualitative comparisons for text-to-video generation. Results are shown for Wan2.1-1.3B, Wan2.2-5B, and Wan2.2-14B on VBench and Dynamic-Bench. Each example presents selected frames from Base and TrajCFG together with the token-wise guidance map produced by TrajCFG; red boxes mark representative Base failures.
Figure 6: Additional qualitative comparisons for image-to-video generation. The three rows show Cosmos-Predict2.5-2B, Wan2.2-5B, and Wan2.2-14B, while the left and right columns use VBench-I2V and PAI-Bench-G, respectively. Each example presents the input image, selected frames from Base and TrajCFG, and the token-wise guidance map produced by TrajCFG; red boxes mark representative Base failures.
Figure 7: Qualitative comparisons for text-to-audio-video generation. The four examples show Ovi on VABench (upper left), Ovi on T2AV-Compass (upper right), LTX-2.3 on VABench (lower left), and LTX-2.3 on T2AV-Compass (lower right). Each example pairs selected video frames with the corresponding audio waveform. Arrows mark sound-event intervals, while red boxes highlight spatial or temporal discrepancies in Base.
Figure 8: Qualitative comparisons for text-to-image generation. The four groups show SD3-Medium on GenEval (upper left), SD3-Medium on DPG-Bench (upper right), Qwen-Image on GenEval (lower left), and Qwen-Image on DPG-Bench (lower right). Within each group, Base and TrajCFG are shown in the top and bottom rows, respectively. Red text highlights selected prompt requirements.
Figure 9: Qualitative comparisons for image-to-3D generation. Input images and two rendered views from Base and TrajCFG. Red boxes highlight appearance discrepancies in Base.
Backbone
Method
Aesthetic
Appearance
Background
Color
Dynamic
Human
Imaging
Motion
Multiple
Object
Quality
Style
Consistency
Degree
Action
Quality
Smoothness
Objects
Class
Wan2.1-1.3B
Base
64.11
22.04
96.70
84.71
65.28
91.00
62.92
98.00
71.19
87.42
CFG-Zero
65.26
22.16
95.61
87.67
68.90
93.00
64.91
97.41
69.74
86.31
CFG-Ctrl
64.49
22.12
96.77
86.69
68.06
93.00
64.80
98.09
68.90
84.97
PAG
64.76
22.24
96.58
85.62
66.67
93.00
64.71
97.89
70.50
85.76
SRVS
64.87
22.37
96.64
82.77
66.67
92.00
64.94
98.19
71.49
88.92
Appendix
Table 8: Complete per-dimension results for text-to-video (T2V) generation on VBench.
Backbone
Variant
Aesthetic
Appearance
Background
Color
Dynamic
Human
Imaging
Motion
Multiple
Object
Quality
Style
Consistency
Degree
Action
Quality
Smoothness
Objects
Class
Wan2.1-1.3B
TrajCFG (Full)
65.48
22.45
96.90
86.82
70.83
93.75
64.71
98.12
75.68
89.14
Time-only
64.49
22.08
97.14
85.06
69.44
95.00
65.02
98.16
72.26
86.55
Sample-wise
64.17
22.13
97.02
86.77
69.44
95.00
64.90
98.15
71.04
87.10
Shuffled allocation
64.12
22.17
96.99
84.68
69.44
94.00
64.63
98.15
72.26
87.74
Reversed allocation
64.01
22.28
96.98
86.67
69.44
94.00
64.32
98.16
69.59
85.21
Appendix
Table 9: Complete per-dimension ablation results for text-to-video (T2V) generation on VBench.
Backbone
Method
Subject
Background
Motion
Aesthetic
Imaging
Overall
Consistency
Consistency
Smoothness
Quality
Quality
Consistency
Wan2.1-1.3B
Base
85.54
91.42
96.40
45.17
56.21
22.36
CFG-Zero
85.75
91.38
97.13
46.39
55.40
23.81
CFG-Ctrl
86.80
92.47
97.28
44.40
56.27
24.18
PAG
87.27
92.55
97.15
46.23
56.40
23.89
SRVS
87.27
92.65
97.38
47.07
56.39
24.15
Appendix
Table 10: Complete per-dimension results for text-to-video (T2V) generation on Dynamic-Bench.
Backbone
Method
I2V
I2V
Subject
Background
Motion
Aesthetic
Imaging
Overall
Subject
Background
Consistency
Consistency
Smoothness
Quality
Quality
Consistency
Cosmos-Predict2.5-2B
Base
98.18
98.74
96.00
96.18
99.09
62.23
71.51
23.48
CFG-Zero
98.26
98.79
96.39
96.42
99.14
62.46
71.67
23.50
CFG-Ctrl
97.83
98.43
95.37
95.53
98.97
62.21
71.55
23.36
PAG
98.18
98.74
95.95
96.16
99.10
62.25
71.49
23.44
SRVS
97.77
98.47
94.68
96.07
99.11
62.27
71.48
23.42
Appendix
Table 11: Complete per-dimension results for image-to-video (I2V) generation on VBench-I2V.
Backbone
Method
I2V
I2V
Subject
Background
Motion
Aesthetic
Imaging
Overall
Subject
Background
Consistency
Consistency
Smoothness
Quality
Quality
Consistency
Cosmos-Predict2.5-2B
Base
96.27
97.25
92.43
94.17
99.09
52.46
70.18
21.18
CFG-Zero
96.33
97.32
92.70
94.38
99.13
52.83
70.38
21.19
CFG-Ctrl
95.33
96.36
91.23
93.54
98.37
51.59
70.27
20.94
PAG
96.21
97.21
92.14
94.08
99.08
52.87
70.36
21.17
SRVS
95.40
96.65
91.67
93.71
99.10
52.86
70.43
21.15
Appendix
Table 12: Complete per-dimension results for image-to-video (I2V) generation on PAI-Bench-G.
Backbone
Method
Speech
Audio
T–V
T–A
A–V
Lip–Sync
Desync ↓
Alignment
Expressiveness
Visual
Audio
Audio
Visual
Q&N
Aes.
Align.
Align.
Align.
Realism
Realism
QA
QA
LTX-2.3
Base
2.698
3.345
0.1928
0.3118
0.2490
2.752
0.5911
4.470
4.299
4.615
4.032
0.7049
0.6616
TrajCFG
2.763
3.351
0.1963
0.3202
0.2567
2.555
0.5685
4.479
4.321
4.638
4.066
0.7178
0.6730
Ovi
Base
3.181
3.282
0.1968
0.3288
0.1564
4.420
0.7659
4.189
4.138
4.522
4.063
0.5251
0.5948
TrajCFG
3.463
3.364
0.1977
0.3316
0.1654
4.780
0.7080
4.179
4.141
4.547
4.074
0.5257
0.5953
Appendix
Table 13: Complete per-dimension results for text-to-audio-video (T2AV) generation on VABench. Lower is better for Desync.
Backbone
Method
Video Quality
Audio Quality
Cross-modal Alignment
VT ↑
VA ↑
AA ↑
SQ ↑
A–V ↑
T–A ↑
T–V ↑
DS ↓
LS ↑
LTX-2.3
Base
7.295
4.921
6.709
1.562
0.2469
0.1722
0.0432
0.7140
2.484
TrajCFG
7.510
4.924
6.738
1.578
0.2481
0.1735
0.0423
0.7016
2.820
Ovi
Base
6.714
4.516
6.676
1.566
0.1596
0.0897
0.0297
0.9624
1.939
TrajCFG
7.199
4.555
6.733
1.665
0.1622
0.0922
0.0316
0.9356
2.449
Appendix
Table 14: Complete per-dimension results for text-to-audio-video (T2AV) generation on T2AV-Compass. Lower is better for DS.
Classifier-free guidance (CFG) improves conditional generation in Flow Matching, but strong guidance can distort the generated distribution and reduce diversity. We provide a geometric account of this behavior by viewing Flow Matching as a time-varying gradient flow and characterizing how CFG reshapes its underlying potential. This view explains how stronger alignment can be accompanied by mean displacement and trajectory concentration, and motivates controlling guidance through the model-implied terminal posterior mean. We therefore propose Posterior-Mean-Capped CFG (PMC-CFG), a training-free, per-sample method that adaptively retains the strongest feasible guidance without additional network evaluations. Experiments on synthetic and large-scale image-generation benchmarks show that PMC-CFG limits guidance-induced distortion and concentration while improving the alignment--diversity trade-off, with particularly strong benefits when nominal guidance is large.
Jishen Peng, Zheng Ma
School of Mathematical Sciences, Shanghai Jiao Tong University, Shanghai, China · Institute of Natural Sciences, MOE-LSC, Shanghai Jiao Tong University, Shanghai, China · Qing Yuan Research Institute, Shanghai Jiao Tong University, Shanghai, China +1
Classifier-Free Guidance (CFG) is essential for high-fidelity conditional generation in flow matching, yet it imposes significant computational overhead by requiring dual forward passes at each sampling step. In this work, we address this bottleneck by introducing P-Guide, a framework that achieves high-quality guidance through a single inference pass by modulating only the initial latent state. We further show that, under a first-order approximation, P-Guide is equivalent to CFG in the sense that it steers generation from the prior space, without requiring explicit velocity field extrapolation during sampling. We consider both homoscedastic and heteroscedastic priors, and find that jointly modeling the mean and variance enables adaptive loss attenuation and improved robustness to data uncertainty. Extensive experiments demonstrate that P-Guide reduces inference latency by approximately 50% while maintaining fidelity and prompt alignment competitive with standard dual-pass CFG baselines.
Xin Peng, Ang Gao
School of Physical Science and Technology, Beijing University of Posts and Telecommunications, Beijing, China
Classifier-free guidance (CFG) is the primary control over how strongly text semantics move a flow-based sampler, yet standard practice holds its scale fixed across the entire ODE trajectory. This is a fundamental mismatch: early steps are noise-dominated and carry weak semantic signal, while late steps commit image structure and demand stronger directional commitment; more critically, the value of any guidance strength depends on whether the guided velocity is consistent with the model's current dynamics or working against them. We propose Velocity-Adaptive Guidance Scale (VAGS), a training-free replacement that multiplies the nominal scale by a bounded factor combining a temporal signal-level term with the cosine similarity between task-relevant velocity fields. For inversion-free editing, VAGS measures the alignment between source- and target-guided velocities, so edit strength at each step reflects local compatibility between preservation and transformation. For generation, VAGS-Gen uses the alignment between unconditional and conditional velocities as the analogous signal. Neither variant requires fine-tuning, auxiliary networks, or extra forward passes, and fixed CFG is recovered as a special case. On PIE-Bench and DIV2K for editing, and COCO17, CUB-200, and Flickr30K for generation, VAGS consistently improves structural fidelity and generation quality over fixed CFG and recent training-free guidance variants. The code is publicly available at https://github.com/Harvard-AI-and-Robotics-Lab/Velocity_Adaptive_Guidance_Scale.
Yan Luo, Ahmadou Aidara, Jingyi Lu +3
Harvard AI and Robotics Lab, Harvard University · School of Computing and Data Science, The University of Hong Kong · Kempner Institute for the Study of Natural and Artificial Intelligence, Harvard University