Loop-Count Schedules in Looped Transformers: An Empirical Study

Konstantin KolokolovarXiv 2026

TL;DR

When training a "looped" transformer—where you reuse the same block of layers multiple times—the most important decision isn't how many times you loop, but whether you ever let the model finish in just one pass. If training includes single-pass runs, the model gets "lazy" and treats extra loops as tiny corrections; if you force it to loop at least twice, it learns to treat every pass as a full-strength layer, leading to better performance and more robust "thinking" at inference time.

What Problem Does This Paper Address?

Looped transformers are the "recyclers" of the AI world. Instead of having 12 different layers, you might have one really good layer and run it 12 times. This saves a massive amount of parameters, making models smaller and more efficient.

However, there’s a catch: how do you train them? Recent research suggests that varying the number of loops ($R$) during training helps the model generalize. But we didn't really know why certain schedules worked better than others. Does the model treat extra loops as "more of the same" (like adding more depth) or as "polishing" (iterative refinement)? This paper dives into the mechanics of these loop schedules to see how they change the internal "gates" of the model.

Methods

The author trained a series of decoder-only transformers (ranging from 46M to 110M parameters) on a 2B-token dataset. The key architectural tweak was adding learned residual gates ($\alpha$) to every loop pass. These gates act like volume knobs: a gate near 1.0 means the pass is a full-strength layer, while a gate near 0.1 means it’s just a tiny nudge to the data.

The study compared three training schedules for the loop count $R$:

  1. Fixed $R=2$: Every training step runs the block exactly twice.
  2. Sampled $\{1, \dots, 6\}$: The model sometimes sees 1 pass, sometimes 6.
  3. Sampled $\{2, 3, 4\}$: The model always sees at least 2 passes.

They also tested a "Static KV" variant, where the model computes the Keys and Values once on the first pass and reuses them for all subsequent loops, significantly saving memory.

Figure 1. The model. Tokens are embedded and pass through N stacked blocks; each block runs once ungated and then R −1 more times with the same weights and gated residual updates, after which a final normalization, the tied output projection and a softmax give the next-token distribution. R=1 is the plain model. In passes 2 to R the gates αattn and αff, shown as small boxes after each sublayer, scale that sublayer’s update to the residual stream.

Datasets

The models were trained on a 2.0B-token mixture from three public sources:

  • FineWeb-Edu: General high-quality web text.
  • codeparrot-clean: Python code.
  • FineMath-4+: Mathematical text.

Evaluation was performed on held-out sets from these same domains.

Key Insights and Ideas

  • The $R=1$ Trap: If the training schedule includes $R=1$, the model's gates "collapse" to low values (0.1–0.5). Because the model must produce a valid output after just one pass, it crams all the "knowledge" into that first pass. Extra loops become mere dampers or small corrections.
  • The Power of Two: By simply moving the lower bound of the training range to $R=2$, the gates stay high (0.6–0.9). The model learns that it has "room to breathe" across multiple passes, treating each as a full layer. This version is much more robust when you increase the loop count at inference time.
  • Direction vs. Norm: A fascinating technical find is that in fixed-depth models, the direction of the data in the residual stream actually converges, but the norm (the length of the vector) keeps growing. This "pushes" the data into a space the output head doesn't recognize, which is why loss usually explodes if you loop a fixed-depth model too many times.
  • Static KV is a "Free Lunch": Reusing the first pass's Keys and Values costs a tiny bit of accuracy (0.01–0.03 nats) but halves the inference cache and makes the math more stable.
Figure 2. The learned loop gates at the last checkpoint (step 60k), one value per block, for the three training schedules. The gate is the scalar α that multiplies a loop pass’s update to the residual stream (§2); a value near 1 means the extra pass is used at full strength, a value near 0 means it is nearly skipped. Plotted is the mean of the attention and feed-forward gates of each block, averaged over two seeds, for the 6-block models that recompute keys and values on every pass. Removing R=1 from the sampling range restores the fixed-R profile.

Key Results

  • Best Performance: The $\{2, 3, 4\}$ schedule produced the best looped model, achieving a validation loss of 2.909 nats, outperforming a parameter-matched plain model (2.951 nats).
  • Robustness: The $\{2, 3, 4\}$ model only degraded by 0.038 nats when run at $R=8$ (twice its maximum training depth), whereas the fixed $R=2$ model's performance fell off a cliff.
  • Efficiency: Looping a 3-block model twice recovers about 35% of the performance gap between a 3-block and a 6-block plain model, using the same number of parameters.
Figure 3. Validation loss of the six 6-block looped models as a function of the number of passes R the shared block is applied at inference time. Each curve is one trained model evaluated at every R from 1 to 8 without retraining; the three colours are the three training schedules of §2. Solid lines are models in which attention recomputes its keys and values on every pass from the current state, shown as the mean over two seeds; dashed lines are the static-KV variants, which compute keys and values once on the first pass and reuse them on every later pass, recomputing only the query, each a single run. Horizontal dotted lines are the plain (non-looped) 6-layer model (2.951) and 12-layer model (2.818) for reference. Values above the 3.80 limit of the axis, all at R=1: the fixed-R model is at 4.96 (static KV 5.01) and the R ∼{2, 3, 4} model at 4.60 (static KV 3.94). The best looped value is 2.909, at R=3 for R ∼{2, 3, 4}.

Limitations and Future Work

  • Scale: The study was conducted on relatively small models (up to 110M parameters). While the patterns are consistent, the "nats" (units of information) gains are small, and it's unclear how this scales to multi-billion parameter models.
  • Task Variety: The evaluation focused on language modeling (predicting the next token). The authors didn't test "latent reasoning" tasks (like complex math or logic) where extra loops might show even bigger benefits.
  • Architecture: The blocks didn't use "input injection" (re-adding the original input at every loop), which is a common trick in other looped architectures.
  • Future Direction: The authors suggest exploring "cheaper" loop bodies—perhaps only looping the attention mechanism and using a simpler adapter instead of a full Feed-Forward Network on later passes.

Summary updated

Abstract

Looped transformers apply one block of layers several times with shared weights, trading parameters for repeated computation. We study how the schedule of the loop iteration count R during training determines whether each extra pass acts as a full layer or as a small correction, using a controlled ladder of 46M-110M-parameter models trained on 2B tokens with learned residual gates on every loop pass and three schedules: R fixed to 2, R sampled uniformly from {1,...,6}, and R sampled from {2,3,4}. We find that the lower bound of the sampling range is the decisive choice. If the sampled range includes R=1, so that some training steps run the block only once and compute the loss on that single pass, the gates collapse to 0.1-0.5 and each additional pass becomes a small correction to the first; if the range starts at R=2, so that every training step runs the block at least twice, the gates stay at 0.6-0.9 and each pass keeps the strength of a full layer, while the model can still be run at any R from 2 up to twice the largest trained value with validation loss within a few hundredths of a nat of its best. The {2, 3, 4} schedule gives the best looped model, 2.909 nats against 2.951 for the parameter-matched plain model, and degrades by only 0.038 nats when run at twice its trained depth. We further show that under a fixed R the direction of the residual stream converges geometrically beyond the trained depth while the loss diverges, which refines a recent finding that static-depth training does not converge, and that reusing the first pass's keys and values on later passes costs 0.01-0.03 nats in every regime while making the per-token iteration uniformly contractive and halving the inference cache. The loop recovers about a third of what real depth provides at equal parameters. The code, trained weights, and per-token traces are released.
BibTeX
@misc{kolokolov2026loop,
  author = {Konstantin Kolokolov},
  title = {{Loop-Count Schedules in Looped Transformers: An Empirical Study}},
  year = {2026},
  eprint = {2611.29704},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.29704},
}
Figure