Flow MatchingReinforcement Learningvia SDE Inference

Stochastic training. Deterministic deployment.

Maojiang Su1,*Tsung-En Lin2,*Jerry Yao-Chieh Hu1,*Guo Ye1Haoran Lu1Shang Wu1Zhaoran Wang1Han Liu1

1 Northwestern University 2 National Taiwan University

* Equal contribution

Manuscript updated November 18, 2026

Explore the recorded results

Better pretraining.
Closer SDE and ODE rewards.

Switch between three base models to see how training-time SDE rewards compare with ODE deployment.

SDE training. ODE evaluation.

SDEODE
Mean SDE and ODE reward trajectories across eighty fine-tuning updates. The complete figures are also available below.
Pretraining qualityStrong

Same architecture. Different pretraining checkpoints.

80

Move the cursor to inspect a recorded update.

Reward at the selected update

SDE reward—
ODE reward—

Transfer & model fidelity

Violation rate (all updates)—
Monitored FM loss—

The curves use the nine original CIFAR-10 histories included with the paper code.

Means and one-standard-deviation bands over seeds 42, 43, and 44. The violation rate is computed from consecutive changes after seed averaging.

The framework

Stochastic inference.
One RL framework.

A unified view connects generative-model fine-tuning and flow-policy optimization through the inner MDP induced by SDE inference.

SDE inference defines a Gaussian inner MDP. A terminal reward gives flow matching RL, and composition with an environment gives flow policy optimization.
Stochastic inference defines an inner MDP. The same construction supports generative-model fine-tuning and flow-policy optimization in an environment.

Reward fine-tuning of flow models

Each stochastic inference transition is an action in an inner MDP. A terminal reward guides policy-gradient updates, including GRPO, without an external environment.

Flow policies in an environment

The inner inference MDP is composed with the environment MDP. An entire denoising chain produces the action chunk executed in the environment.

Our instantiation

FMPO-CPPO learns from the full inference chain.

ChainPPO combines a clipped surrogate for the complete inference chain with an auxiliary clipped surrogate for individual inference steps. Log-ratios are normalized by the action-chunk dimension.

JFMPO-CPPO = Jchain + α Jstep

The experiments use α = 0.25, a chain clip of 0.02, a step clip of 0.01, and noise schedule λt = a(1 − t). The normalized ratios are tempered surrogates, as explained in Section 3.3.

How existing methods fit the framework
Representative instantiations
MethodSettingSurrogateNoise level λt
Flow-GRPOGenerative fine-tuningGRPOa(1 − t)/t
DanceGRPOGenerative fine-tuningGRPOConstant
ReinFlowPolicy optimizationPPOLearnable
Flow-SDEPolicy optimizationPPOa(1 − t)/t
FMPO-CPPOPolicy optimizationChainPPOa(1 − t)

Theoretical foundations

When does stochastic
training transfer?

The analysis separates the inference mismatch from the reward improvement achieved by RL.

Correctness · Theorem 4.1

Small flow-matching error controls the inference gap.

TV(pT, qT) ≤ O(√ε)

When the learned velocity approximates the reference flow well, SDE and ODE inference induce close terminal distributions. Here ε is the square root of the integrated squared velocity error.

Performance transfer · Theorem 4.2

SDE improvements transfer beyond the mismatch penalty.

JODE(θk+1) ≥ JODE(θk) + Δk − 2R(δk + δk+1)

For a bounded terminal reward, deployment improves when the SDE reward gain exceeds the distributional mismatch penalties at the old and new parameters.

These guarantees hold under the approximation and regularity assumptions in the paper, with early stopping time T < 1. Better pretraining and controlled fine-tuning help keep the mismatch small.

Experimental studies

Gaussian bridges.
Control. Image generation.

Synthetic validation

Sections 5.1–5.2

Gaussian bridges make the reference velocity available analytically. Varying pretraining quality reveals the SDE–ODE distribution gap and the reliability of one-step reward transfer.

TV distance versus flow-matching error, transfer violation rates, and paired SDE and ODE reward trajectories.
Published synthetic results: distributional error scaling, transfer violations, and reward trajectories. Original plot labels are reproduced from the paper; the repository documents the error-axis convention.

Continuous control with FMPO-CPPO

Section 5.3

On Ant, Humanoid, and Walker2d, FMPO-CPPO achieves higher evaluation reward than ReinFlow and Flow-SDE, with comparable performance on Hopper. Curves show the mean and one standard deviation across five seeds.

ODE evaluation reward curves for Ant-v2, Hopper-v2, Humanoid-v3, and Walker2d-v2, comparing Flow-SDE, ReinFlow, and FMPO-CPPO.
Published evaluation curves under ODE deployment. The repository includes all 60 CSVs used to recreate these comparisons.

CIFAR-10: pretraining quality matters

Section 5.4

Weak, Medium, and Strong class-conditional flow models are fine-tuned with SDE GRPO for 80 updates. Better-pretrained models show closer SDE and ODE reward trajectories; bands show one standard deviation over three seeds.

ODE and SDE rewards for weak, medium, and strong CIFAR-10 models, plus validation flow-matching loss during fine-tuning.
Reward trajectories and validation conditional flow-matching loss from the paper. Nine original fine-tuning histories are available in the code repository.

ODE reward-decrease rate conditioned on SDE improvement

Weak
0.467
Medium
0.419
Strong
0.413

Computed on seed-averaged reward trajectories before taking consecutive-update differences, as in the paper.

Auxiliary-loss ablation

Removing the step-wise auxiliary term retains similar performance on Ant, Hopper, and Humanoid; the full method performs better on Walker2d.

Published FMPO-CPPO versus NoAux ablation curves across four continuous-control tasks.
Published ablation from Appendix G. The repository provides the NoAux launcher; the original NoAux run logs were not supplied.

Abstract

We develop a unified framework for flow-based reinforcement learning (RL) grounded in diffusion–flow duality and establish its theoretical foundations. The framework enables RL for deterministic flow matching inference by introducing diffusion stochastic inference dynamics that supports exploration while admitting deterministic deployment. We show that our framework subsumes several existing flow-based RL methods as special cases and inspire effective new methods. Then we provide theoretical foundations for the frameworks by establishing the correctness and performance transfer guarantee. Specifically, we prove that the policies optimized under stochastic dynamics close to deterministic dynamics at deployment when the pretrained model is well-trained. Moreover, we show that the policy improvement achieved under training-time SDE inference transfers to deployment-time ODE inference. Experiments on synthetic and continuous-control tasks validate the theory and demonstrate the proposed algorithms’ effectiveness.

Research resources

Read, inspect, reproduce.

The paper and code include the framework, proofs, training entry points, and the available experiment records.

Citation

@misc{su2026flowmatchingrl,
  title  = {Flow Matching Reinforcement Learning via SDE Inference},
  author = {Su, Maojiang and Lin, Tsung-En and Hu, Jerry Yao-Chieh and Ye, Guo and Lu, Haoran and Wu, Shang and Wang, Zhaoran and Liu, Han},
  year   = {2026},
  note   = {Manuscript updated November 18, 2026}
}