k-WM

k-WM: Predicting k Steps at Once for Long-Horizon Planning with World Models

Anonymous authors · ICLR 2027 submission

Overview figure: the four environments, next-step versus k-WM inference, and planning performance against planning time on Push-T.
Figure 1. Overview. We introduce k-WM, a minimal extension that lets a transformer-based world model predict \(k\) future latents from an action sequence in one forward pass instead of rolling out autoregressively. (a) We evaluate k-WM on four environments, Push-T, Maze, Cube, and Reacher. (b) Comparison of next-step WM and k-WM inference: the former needs \(k\) sequential predictor calls, the latter a single call over the padded input sequence. (c) Long-horizon gradient-based planning on Push-T (\(H{=}10\)): k-WM models (filled) achieve better performance and run faster than their next-step baselines (hollow), across two world model classes.

Abstract

Latent world models have become an appealing approach to visual control, enabling goal-conditioned optimization at test time and generalization across tasks with a single model. In practice, however, planning success remains limited to short horizons, and gradient-based planners driven by autoregressive rollouts still underperform sampling-based methods, despite their potential to optimize action sequences efficiently through model gradients. We hypothesize that two properties of next-step prediction contribute to these limitations: autoregressive rollouts compound prediction errors, and planning gradients must traverse a chain of nested model calls. We study a simple alternative: predicting the entire future sequence in a single forward pass. We introduce k-WM, a minimal extension to transformer-based JEPA world models: a multi-horizon training objective and input layout that let the predictor map a variable-length action sequence directly to the corresponding sequence of future latent states in a single forward pass. We apply k-WM to three classes of JEPA world models and evaluate on four environments. Overall, k-WM improves gradient-based planning by 37% and sampling-based planning by 15% over the existing next-step world models it extends. Our analysis shows that the gains cannot be explained by parallel rollout alone: improvements persist under autoregressive inference and coincide with substantial changes in the learned representation. Parallel prediction additionally reduces long-horizon inference cost. Together, k-WM offers a simple, broadly applicable path to more accurate and efficient long-horizon control.

Method

Details

k-WM changes only the predictor input layout and the training objective of a JEPA world model, leaving the encoder and predictor architecture unchanged.

Architecture: next-step world model training and autoregressive inference on the left, k-WM single-pass training and inference on the right.
Figure 2. Architecture. Left: standard next-step WM training with teacher forcing and autoregressive inference. Right: k-WM, which predicts multiple future latents in a single forward pass during both training and inference. In the diagram, c is the number of context latents the predictor is given (c = 3 here) and k is the number of future latents predicted: one call per step for the next-step model, one call for all k in k-WM. “reg.” is the model-specific anti-collapse regularizer on the encoder latents, and \(\mathcal{L}\) is the prediction loss between predicted and encoded target latents. Actions are concatenated with the latent tokens, and the last context latent is repeated to fill the future input positions. The inference process visualized here provides only one ground-truth frame, so the remaining history context must be bootstrapped from model predictions.

We implement k-WM on top of three classes of JEPA world models to test whether it helps across all of them. The classes differ in how the encoder is trained. Each k-WM model is compared with its next-step version, which has the same encoder, predictor and training recipe.

  • DINO-WM plans on frozen DINOv2 patch features.
  • DINO FT fine-tunes DINOv2 end to end.
  • LeWM trains a small ViT from scratch with the SIGReg regularizer.

Three quantities recur below. The training horizon \(k\) is the number of future latents the model learns to predict, and is 8 unless stated. The planning horizon \(H\) is the number of model steps the planner optimizes, and one model step is 5 environment steps. The chunk length \(d\) is the number of latents predicted per call at inference, so \(d=1\) is autoregressive.

Planning results

k-WM matches or beats its next-step baseline in most settings. The gain is largest with gradient-based planning.

Planning rollouts

Environments and datasets

Plans at \(H{=}10\) (50 environment steps), executed without replanning. Green means the goal was reached, red means it was not.

Push-T

2D manipulation: an agent pushes a T-shaped block to a goal configuration.

Start
Not rendered yet
Goal
Not rendered yet
Next-step (\(k=1\))
Not rendered yet
k-WM (\(k=8\))
Not rendered yet

Maze

2D navigation: the agent navigates to a goal inside a maze.

Start
Not rendered yet
Goal
Not rendered yet
Next-step (\(k=1\))
Not rendered yet
k-WM (\(k=8\))
Not rendered yet

Cube

3D manipulation: a robot arm picks and places a cube.

Start
Not rendered yet
Goal
Not rendered yet
Next-step (\(k=1\))
Not rendered yet
k-WM (\(k=8\))
Not rendered yet

Reacher

2D control: a two-joint arm reaches a target joint configuration.

Start
Not rendered yet
Goal
Not rendered yet
Next-step (\(k=1\))
Not rendered yet
k-WM (\(k=8\))
Not rendered yet

Short horizon

Details

Multi-horizon training performs on par with or better than its matched next-step baseline across most settings, despite receiving supervision over substantially longer prediction horizons. The gain is largest when the encoder is trained end to end, as in DINO FT and LeWM.

MethodObjectiveCEMGDAvg. Δ
Push-TMazeCubeReacherPush-TMazeCubeReacherCEMGD
k-WM vs. next-step
DINO-WMnext-step 83.3±1.292.7±4.251.3±7.031.3±4.6 66.0±3.540.0±6.058.7±6.413.3±3.1
k-WM 82.0±6.986.7±5.063.3±1.232.0±5.3 70.7±8.166.7±13.356.7±7.018.7±3.1 +1.3+8.7
DINO FTnext-step 78.0±6.062.0±7.250.7±3.142.7±6.4 63.3±4.214.7±4.248.7±7.044.0±2.0
k-WM 90.0±2.086.7±2.355.3±1.286.0†±3.5 83.3±4.658.0±9.247.3±5.082.0†±5.3 +21.2+25.0
LeWM (concat)next-step 73.3±5.889.3±2.049.3±2.549.3±5.7 74.7±4.217.3±5.048.7±6.410.7±4.1
k-WM 90.0±0.082.0±5.362.0±3.548.0±4.0 83.3±4.247.3±8.161.3±3.110.7±5.0 +5.3+12.8
Prior world models
LeWM (AdaLN) 87.3±5.079.3±9.264.0±3.524.7±3.1 83.3±4.226.7±4.268.0±3.56.7±3.1
Fast LeWM 86.7±4.179.3±4.258.0±9.217.3±3.1 88.0±5.360.0±0.060.7±5.06.7±3.1
Straightening 85.3±8.381.3±4.267.3±6.18.0±3.5 87.3±2.369.3±4.274.7±1.26.0±2.0
Table 1. Short-horizon planning (\(H{=}5\)). Success rate (%) with CEM and gradient descent (GD), mean ± std over 3 seeds × 50 episodes. Top: each world model class with k-WM (shaded) against its next-step version with the same encoder, predictor and training recipe. Bottom: prior world models, re-run with the same planning protocol. Bold: better of each pair; pink: best in the column; †: k-WM model rolled out autoregressively (see Analysis). Avg. Δ: k-WM minus next-step, averaged over environments from unrounded success counts.

Long horizon

Details

DINO FT maintains an overall advantage over its next-step counterpart, and multi-horizon LeWM shows a growing advantage over the original AdaLN LeWM as the horizon increases.

Success rate against planning horizon 5 to 10 for the four environments, CEM on the top row and gradient descent on the bottom row.
Figure 3. Long-horizon planning. Success rate as a function of planning horizon \(H \in \{5,\dots,10\}\) across four environments, using CEM (top) and gradient-based planning (bottom). Solid lines denote k-WM models; dashed lines denote next-step baselines. DINO FT and DINO-WM use the same encoder and predictor architectures within each pair; the LeWM baseline uses the original AdaLN predictor. Curves show mean success rates; error bars show ± std over 3 seeds. Reacher rollout uses \(d=1\).

Open-loop rollout quality

Details

k-WM rollouts are sometimes more accurate, but this does not explain all of the planning gain.

Probe-decoded state error against rollout step for each environment, k-WM solid and next-step dashed.
Figure 4. Open-loop rollout error. Error between the ground-truth states and states decoded by a linear probe from the predicted latent, vs. rollout step, on validation trajectories (lower is better). Solid: k-WM models rolled out with the largest chunk size; dashed: next-step baselines. The probe is fit per encoder on its training latents. Band: ±1 standard error over 488 windows for Push-T and 1000 windows for the other environments.

Push-T

Decoded Push-T rollout frames: ground truth, next-step baseline, and k-WM.

Still from the paper. Add static/videos/rollout/pusht_dinoft.mp4 and the video replaces it.

Figure 9. Push-T rollout. Decoded latent of DINO FT with k-WM vs. next-step DINO FT, 120-environment-step rollout.

Cube

Decoded Cube rollout frames: ground truth, next-step baseline, and k-WM.

Still from the paper. Add static/videos/rollout/cube_dinoft.mp4 and the video replaces it.

Figure 10. Cube rollout. Decoded latent of DINO FT with k-WM vs. next-step DINO FT, 120-environment-step rollout.

Planning speed

Details

Fewer sequential predictor calls make planning up to 3.3× faster for long-horizon GD.

Planning speed-up of k-WM over the next-step baseline, and planning time across models on a log scale.
Figure 5. Planning speed on Push-T. Planning time is measured in seconds, with compile and bf16, on one L40S. CEM optimizes with 300 samples and 30 iterations; GD optimizes for 500 steps. (a), (b): Speed-up of k-WM over the next-step baseline. (c): Planning time across different models, including Temporal Straightening (TS) and Fast LeWM (Appendix D); x-axis is on a logarithmic scale.

Analysis

Choosing the training horizon k

Details

Planning performance changes systematically with \(k\). DINO FT is relatively insensitive to it, while LeWM responds more sharply, and on Reacher success jumps at \(k=5\).

Heatmaps of planning success against training sequence length and planning goal horizon for DINO FT and LeWM on Push-T and Reacher.
Figure 6. Training horizon vs. goal horizon. Planning success rate (%) as a function of the training sequence length (columns) and the planning goal horizon \(H\) (rows), for DINO FT and LeWM on Push-T and Reacher, with CEM. Mean over 3 planning seeds × 50 episodes.

Separating multi-horizon training from parallel inference

Details

Autoregressively trained models also beat the next-step baseline in some settings, so parallel rollout alone does not explain the gain. The effect of chunk length depends on the task and planner.

EnvironmentPlannerRollout chunk lengthAR training windowNext-step
1246103
Push-TCEM 47.0±9.552.7±9.556.0±5.350.0±5.3 48.7±8.346.0±8.730.7±9.9
GD 44.7±2.350.7±3.153.3±9.038.0±7.2 46.7±10.346.7±6.424.7±4.2
ReacherCEM 84.7±4.280.7±5.077.3±7.672.0±2.0 76.0±2.058.0±9.240.7±10.1
GD 68.7±1.212.7±2.322.0±5.360.7±1.2 51.3±13.322.0±2.039.3±6.4
Table 2. Rollout and training ablation. Planning success rate (%, ↑) of DINO FT at \(H{=}8\) when varying the inference chunk length \(d\) or autoregressive (AR) training window, mean ± std over 3 seeds. All models except the next-step baseline are trained with \(k=8\); the AR models are trained over the full 10-step rollout window (10) or with a three-token sliding window (3). Bold: highest mean per row.

What the multi-horizon objective teaches the encoder

Details

Longer-horizon training makes the encoder keep state information it previously represented weakly. On Maze, latent distance follows the corridor distance more closely as the training horizon grows. On Push-T and Reacher, ground-truth state becomes increasingly linearly decodable, and latent distance tracks distance in state more faithfully, gradually on Push-T and through a sharp transition on Reacher.

Maze cells coloured by latent distance to an anchor cell, for corridor distance, frozen DINOv2 CLS, and DINO FT trained at k = 1, 2, 4, 8 and 16.
Figure 11. Latent distance to an anchor cell on Maze. Each row uses one anchor cell (star). (a) Corridor distance from the anchor, in blocks. (b–g) Mean latent squared distance between the frames in each cell and the 30 frames nearest the anchor, normalized such that 1 is the distance between two random frames, for the frozen DINOv2 CLS embedding (b) and DINO FT trained with \(k=1,2,4,8,16\) (c–g). Walls are grey.
Linear probe error and latent distance against state distance for DINO FT and LeWM as the training horizon grows.
Figure 7. State alignment of the DINO FT (top) and LeWM (bottom) latents vs. training horizon. (a, b) Fraction of the ground-truth state variance that cannot be explained by a linear probe from the latent representation (\(1-R^2\), Push-T states: T keypoints, Reacher states: arm pose), with one dash per trained model. (c, d) Latent squared distance, normalized such that the expected distance between a random pair of frames is 1, versus ground-truth state distance for pairs of frames matched on the remaining state variables (agent position on Push-T, second joint on Reacher). Darker curves indicate longer training horizons.