A learned critic can improve a pretrained flow-matching policy by steering sampled actions toward higher predicted value. However, even a critic that fits the behavior data well can provide misleading action gradients. Gradient components pointing away from the data-supported region are weakly constrained by behavior data and can lead guidance to exploit critic extrapolation errors. We introduce RetraQ (Retraction-based Q-guidance), which uses geometry encoded by the pretrained flow to constrain both the direction and the destination of critic guidance. A single velocity evaluation of the frozen flow defines a denoising map. RetraQ filters the critic gradient with the map's Jacobian and applies the map itself to correct the updated action. Our analysis characterizes when these operations approximate tangent filtering and retraction onto the behavior manifold. The same update guides actions at test time and provides targets for policy distillation and online reinforcement learning. In controlled studies, RetraQ improves true return while keeping refined actions close to the data-supported region, and its distillation targets remain more stable than those of raw critic ascent. In offline-to-online training on LIBERO and OGBench, RetraQ achieves higher mean final success than the evaluated critic-guidance baselines. On a real-world plug-insertion task, test-time RetraQ improves the success rate of a behavior-cloned policy from 55.0% to 76.7%. Online training further increases success to 98.3% in only 30 minutes and 100% within one hour.

Model the demonstrated actions for a state as a low-dimensional manifold . Critic values observed on determine how changes along tangent directions, but not along normal directions. Two critics that agree on every data-supported action can have arbitrarily different normal derivatives.
Raw ascent follows this unconstrained normal component off the support, into regions where a high predicted value is often just extrapolation error. Even a perfectly tangent step leaves a curved manifold at finite step size.
Two operations on an unknown manifold:
① a tangent projector to filter the update direction, and
② a retraction to correct the update destination.
Our key observation: a pretrained flow policy already supplies both, through a single map that costs one velocity evaluation.
Let be the frozen behavior-cloned flow and a guidance level. Treating an action as a partially-noised flow state gives the denoising map
Read the critic at an action sampled from the policy.
Keep the tangent part; suppress the normal part that behavior data cannot identify.
Take a finite step, then pull the endpoint back to the behavior support.
# v_ref: frozen BC velocity t_g = 0.9: guidance level Q: critic M = 1 refinement step def R(s, a): # denoising map of the frozen flow return t_g * a + (1 - t_g) * v_ref(s, t_g * a, t_g) def refine(s, a, eta): g = grad(Q(s, a), a) # ① critic gradient _, g_f = jvp(lambda x: R(s, x), (a,), (g,)) # ② filter: g_f = J_R g (one JVP) return stopgrad(R(s, a + eta * g_f)) # ③ step, then retract # offline-to-online (Algorithm 1); test-time guidance only runs refine() and executes a* pi.load(v_ref); eta = None; warm_up(Q, D_demo) # actor starts at BC, v_ref stays frozen while budget_left(): D.add(rollouts(pi, env)) for cycle in update_cycles(): td_update(Q, D); Q_hat = freeze(min(Q1, Q2)) for _ in range(actor_steps): s, a_exec = D.sample() # executed chunks if eta is None: # calibrate once, then hold fixed: eta = calibrate(s, a_exec, Q_hat) # |R(a + eta*g_f) - R(a)| = d_target a_tgt = refine(s, a_exec, eta) a_bc = bc_sample(v_ref, s) # behavior anchor loss = lam_imp * fm_loss(pi, s, a_tgt) + lam_bc * fm_loss(pi, s, a_bc) loss.backward(); opt.step()
For the population-optimal flow, with noise scale , the denoising map is a posterior mean and its Jacobian is a scaled posterior covariance (Tweedie's identity):
Near the manifold the posterior concentrates at the nearest manifold point and spreads only along it, so
A learned flow adds the error of its velocity field and of its input derivatives to both operators. Choosing is a trade-off: larger shrinks the terms, but for any velocity with bounded input derivatives as . That is the identity-Jacobian approximation used by prior guidance methods, and it filters nothing. We use () on all platforms.
Below is the ideal version of RetraQ, computed exactly in the browser. Behavior actions lie on a curve with thickness . The critic is correct on the curve but has an extrapolated normal slope off it (orange shading = , darker is higher). The star marks the true best action. and are the exact posterior mean and covariance of the data at noise level . They are what a perfectly trained flow would give.
Drag the black point anywhere to inspect a single step. Arrows are drawn at a common scale, so the shrinkage of the normal part is visible.
| Update | true value ↑ | dist. to ↓ |
|---|
A bimanual humanoid must pick up a charger plug and insert it into a power strip. The task is contact-rich and needs millimetre-level alignment. The platform is an AgiBot G02 dual-arm robot and the base policy is a behavior-cloned (55.0% success). We evaluate the same RetraQ update in three settings: offline-to-online RL, where refined actions are distilled back into the policy; test-time guidance of the frozen policy; and offline distillation of a fixed set of refined targets. Every evaluation uses 60 trials.
Third-person view, real-time playback. Green: RetraQ rollouts (success). Red: unguided BC rollouts (failure), shown for comparison.
| Method | 0 h | 0.5 h | 1.0 h |
|---|---|---|---|
| RetraQ | 55.0 | 98.3 | 100.0 |
| Q-VGM | 55.0 | 95.0 | 93.3 |
| QGF | 55.0 | 88.3 | 91.7 |
| FlowDPG | 55.0 | 88.3 | 86.7 |
Success rate (%) versus online training time after critic warm-up. All methods start from the same BC policy and the same warmed-up IQL critic, then train their own critics under the same interaction budget. Each entry is the mean over three training runs, with 60 trials per checkpoint and run. RetraQ reaches 98.3% within 30 minutes, 100% after one hour, and is the highest at every checkpoint.
Success rate (%), 60 trials per entry. Test-time guidance leaves all policy parameters fixed and refines actions only at detected fork states, using two fork critics (linear and nonlinear in the action deviation) trained on the same 270 forked rollouts. All guidance methods are displacement-matched to RetraQ, so they differ only in direction and destination. RetraQ's gain over BC is significant with Critic 1 (Fisher's exact test, ; with Critic 2); its margin over FlowDPG is not (). With the linear critic, Q-VGM's farthest-iterate selection leaves the data support and fails every trial. Offline distillation fits a fixed set of refined targets under one shared, much larger displacement budget, probing the critic far from its training data: Q-VGM targets make the policy hit the table, FlowDPG targets cause misaligned insertions, and RetraQ targets stay on par with BC (). Baselines are our implementations adapted to this setting.
Critic value for every executed action chunk, synchronized with the robot's head camera. In successful rollouts the value rises sharply as the plug approaches and seats in the socket. In failed rollouts it stays flat. Drag the slider to see how this structure emerges during online critic training. Click the chart to seek the video, and switch cameras to watch the same rollout from another viewpoint.
One action chunk = 30 frames at 30 FPS. Raw critic outputs, not normalized. Critic update counts range from 100 (after warm-up) to 340. The successful and failed rollouts come from different policies (online RetraQ and BC), so the comparison between them is illustrative. The chart cursor follows the head camera, whose frames are aligned with the critic values; the third-person recording is not frame-aligned, so the cursor is hidden in that view.
manifold, 30 refinement–distillation rounds, median over 8 actor seeds.
| Method | True objective ↑ | Dist. to , p95 ↓ |
|---|---|---|
| BC reference | 0.395 | 0.015 |
| Self-distillation | 0.266 | 0.081 |
| Raw ascent | −16.794 | 1.016 |
| Filter-only | −0.582 | 0.430 |
| Raw + | 0.774 | 0.073 |
| RetraQ | 0.827 | 0.028 |
RetraQ reaches the highest true objective while keeping refined actions closest to the known manifold: 2.6× closer than Raw + and 36× closer than raw ascent. This is the high-dimensional counterpart of the playground above.
Final online success (%), mean ± std over 3 actor seeds, 30 episodes per task and seed. Spatial: the 6 tasks with the lowest BC success; Goal and Object: all 10 tasks.
| Method | Spatial | Goal | Object |
|---|---|---|---|
| BC | 63.3 | 69.0 | 55.3 |
| AWR | 64.8 ± 0.6 | 71.9 ± 3.3 | 58.4 ± 0.7 |
| FlowDPG | 60.4 ± 3.6 | 68.1 ± 3.2 | 49.3 ± 8.0 |
| Q-VGM | 70.6 ± 0.6 | 73.6 ± 0.4 | 59.9 ± 2.0 |
| QAM | 61.5 ± 2.7 | 73.1 ± 0.7 | 60.9 ± 0.7 |
| Self-distillation | 35.7 ± 12.9 | 59.6 ± 11.9 | 42.2 ± 5.3 |
| Raw ascent | 59.3 ± 7.3 | 67.9 ± 5.8 | 56.6 ± 6.4 |
| Filter-only | 63.5 ± 10.1 | 70.9 ± 5.6 | 57.8 ± 6.0 |
| Raw + | 75.4 ± 1.7 | 79.4 ± 1.4 | 62.1 ± 6.7 |
| RetraQ | 78.1 ± 4.2 | 81.3 ± 3.7 | 66.4 ± 5.2 |
The retraction carries most of the gain; filtering adds another 1.9–4.3 points on every suite, consistent in sign but within the variation across three seeds.
Repeated offline distillation without new interaction is a limitation: on LIBERO, RetraQ degrades over three refinement rounds more than AWR or FlowDPG, so its stability advantage holds against raw ascent but not in general. Separating errors in the refined targets from errors in fitting them could help stabilize offline improvement. The Jacobian–vector product through the frozen flow also adds GPU memory. The geometric guarantees are local and asymptotic, and the learned filter weakens in high-dimensional action spaces (normal gain 0.84–0.97 at under a fixed training budget). Refinement also remains tied to the support of the frozen reference flow; combining RetraQ with exploration, or carefully updating the reference, could broaden the behaviors it can learn.
@misc{anonymous2027retraq,
title = {{RetraQ}: Manifold-Constrained Critic Guidance for Flow Policies in {RL}},
author = {Anonymous},
year = {2027},
note = {Under review at ICLR 2027}
}