FlowOpt Policy: Learning to Optimize Actions with Flows

Augustinos D. Saravanos, Oswin So, Chuchu FanarXiv 2026

TL;DR

When robots or autonomous agents plan ahead, they usually either rely on rigid, handcrafted sampling rules or on generative models that guess actions without checking if they actually work. FlowOpt Policy bridges these two worlds by learning how to optimize rather than what to output: it uses a learned conditional flow to iteratively transport a population of candidate action sequences toward lower-cost solutions, guided by their simulated rollout scores. Because it conditions on costs rather than raw states, it adapts to brand-new objectives at deployment without retraining.

What Problem Does This Paper Address?

Model predictive control (MPC) requires repeatedly solving gnarly, non-convex optimization problems over action sequences under tight time budgets. Historically, two paradigms have tackled this, each with a blind spot:

  1. Sampling-based planners (like MPPI and CEM) sample candidate action sequences, score them using a predictive model, and refit a proposal distribution around the winners. They are derivative-free and parallelizable, but their update rules are fixed and handcrafted—they never learn from experience across similar planning problems.
  2. Generative action policies (based on diffusion or flow models) learn complex action distributions from data, conditioned on the current state. However, they output actions directly without rolling them out through a predictive model to refine them. If the task objective or constraints change at test time, they often fail without retraining.

The authors ask: Can we keep the model-in-the-loop search of MPC, but learn the population update rule itself from data?

Methods

FlowOpt Policy frames each planning iteration as a learned transport over a population of candidate action sequences. Instead of compressing candidates into a Gaussian and resampling, a learned velocity field moves the candidates directly in action space over a continuous flow time $\tau \in [0, 1]$:

Figure 1: Conceptual overview. Our method FlowOpt Policy iteratively transports a pop- ulation of candidate action sequences via a learned flow toward lower cost, conditioned on their rollout scores, bridging model predictive control, generative modeling and learning-to-optimize.
  • Theoretical grounding: The update is derived from a heat–proximal splitting of the Wasserstein gradient flow of a free-energy objective. The "heat" substep adds Gaussian noise to re-expand the population, while the "proximal" substep—approximated by the learned flow—pulls candidates toward lower-cost regions.
  • Self-supervised training: No expert demonstrations are needed. During training, the policy runs in closed loop, and a higher-budget sampling-based teacher evaluates extra candidates around the current population. A linear assignment pairs the perturbed population with the best teacher-evaluated targets, providing clean, straight-path flow-matching targets.
  • Population attention: The velocity field uses cross-attention over the evaluated population. Each candidate attends to all other candidates and their scores, using standardized costs and normalized ranks. This makes the optimizer permutation-equivariant and invariant to the scale of both actions and costs.

Datasets

Rather than static offline datasets, FlowOpt Policy is trained and evaluated in closed-loop simulation across six tasks:

  • Physics-based simulators: CarNav (navigation among moving obstacles), HalfCheetah and Walker (from MuJoCo), and Push-T.
  • Learned world models: HalfCheetah-WM and Humanoid-WM, where planners roll out trajectories inside a frozen TD-MPC2 latent world model.

Key Insights and Ideas

  • Classical planners are special cases of attention: The authors prove that an entropy-regularized proximal step naturally takes the form of dot-product attention. When the attention logits ignore the query candidate and depend only on costs, one Euler step recovers MPPI and CEM as restricted, query-independent corners. Learning the attention projections lets different candidates draw information from different promising regions rather than collapsing to a single average.
  • Learning to optimize beats learning what to output: By conditioning the flow on rollout costs instead of states, FlowOpt Policy decouples the optimization mechanic from the specific task state. When an unseen objective appears at test time, the shift is captured in the standardized rollout costs, allowing the planner to adapt on the fly.
  • Direct transport beats Gaussian refitting: Even when compared against a learned baseline that updates a Gaussian proposal using the exact same network backbone and training data, transporting the candidates directly yields substantially better performance.

Key Results

  • Outperforming planners at equal budgets: Across all six physics and world-model tasks, FlowOpt Policy achieves the strongest performance profiles, beating MPPI, CEM, CMA-ES, DIAL-MPC, and a Learned Gaussian Update (LGU) baseline. On Push-T, it reaches a 99.0% success rate, compared to 86.5% for LGU.
  • Zero-shot generalization to unseen objectives: Compared to a state-conditioned Flow Policy (sharing the same architecture and training), FlowOpt Policy generalizes far better under distribution shifts—such as increasing obstacles in CarNav (from 3 to 4 or 8), widening initial block ranges or altering friction in Push-T, or adding a brand-new control-rate penalty absent from training.
  • Ablations matter: Removing population attention drops the Push-T success rate by 30.2 percentage points (to 68.8%), and reducing flow integration to a single Euler step drops it by 50.0 points (to 49.0%).

Limitations and Future Work

  • Distribution tailoring: As a learning-to-optimize method, the learned transport is still shaped by the training distribution.
  • Myopic supervision: The teacher supervises a single finite-horizon population update rather than the full closed-loop return; pairing the optimizer with a learned terminal value function is a natural next step.
  • World-model exploitation: Because FlowOpt Policy aggressively drives candidates into low-cost regions, it can exploit inaccuracies in a learned world model if it wanders into unvalidated states.

Summary updated

BibTeX
@misc{saravanos2026flowopt,
  author = {Augustinos D. Saravanos and Oswin So and Chuchu Fan},
  title = {{FlowOpt Policy: Learning to Optimize Actions with Flows}},
  year = {2026},
  eprint = {2611.40804},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.40804},
}
Figure