MCP
arXivarXiv
Preprint
Published: August 3, 2026
cs.LG

Feed-Forward Steering in Transformer Residual Dynamics

Abstract
Attention-only dynamical theories model Transformer residual directions as particles aggregating on a sphere. We extend this framework by incorporating the feed-forward network (FFN) term as a local steering field acting on each token state. The resulting theory predicts that the tangential component of the FFN field is necessary for motion in residual-direction space, that critical residual directions correspond to nonlinear projective equilibria, and that a commutator defect determines when a finite attention--FFN block can be accurately approximated by a parallel, additive flow. Across GPT-2, Pythia, Mistral, and Llama models, the extended theory improves one-step angular prediction relative to an attention-only baseline, with the contribution of the FFN increasing from GPT-2 to Llama-3-8B. Intervention experiments show that retaining only the tangential FFN component preserves most model quality, whereas retaining only the radial component causes performance to collapse. The tangential component also preserves output diversity under aggregation pressure. As a practical application, layers with small commutator defects can be approximately parallelized with only a modest increase in loss, whereas layers with large defects degrade rapidly. These findings support the interpretation of FFN layers as directional steering fields that shape Transformer residual geometry and govern the feasibility of block-level interventions.
0
AI overview
Reviews
Citation graph
References · 17
Structured
This preview uses generator v1; v2 is available

Overview

Addressing the problem that Transformer residual dynamics cannot be fully described by attention aggregation alone, this paper proposes an extended theory that models the feedforward network (FFN) as a tangential steering field of residual directions. Experiments across multiple models verify the FFN's role in maintaining residual geometry and counteracting over-aggregation, and the paper provides a practical low-loss layer-parallelization scheme based on commutator defect diagnostics.

Background and Empirical Gap in Transformer Residual Dynamics Research

Existing continuous studies of Transformer dynamics typically take the commutative mean-field limit under bidirectional full attention as the baseline, whereas decoder-only causal large models correspond to a Volterra flow with prefix indexing. Prior related work has continued the analysis perspective of continuous attention dynamics and has not yet incorporated the FFN as an independent local steering field into a complete dynamics modeling framework.

On all mainstream models tested, keeping only the tangential component of the FFN consistently performs closest to the full model. In stark contrast, keeping only the radial component is catastrophic, performing essentially on par with removing the FFN entirely.

The Core Theoretical Claim of the FFN as a Tangential Steering Field of Residual Directions

The paper argues that Transformer residual dynamics cannot be fully described by attention aggregation alone. In all core experiments, the FFN is consistently present as a tangential steering field and is a necessary component for explaining, preserving, and controlling the geometric properties of residual directions. Please refer to the figure immediately following to intuitively understand the division of labor among different components in residual dynamics and the overall logic of geometric evolution.

Fig. 1: Schematic diagram of residual direction dynamics, illustrating the mechanism by which the non-local aggregation field of attention and the local guidance field of the FFN jointly shape the residual flow

Operating Logic and Validation Scheme of the Tangential Steering Mechanism

Building on the tangential steering field claim above, empirical observations show that attention steps typically decrease D(µ), meaning aggregation pulls residual directions toward more concentrated configurations, while the FFN often increases feature diversity after the attention step, counteracting over-aggregation in the angular variables. This is the core pathway by which the tangential steering field geometrically adjusts residual directions. In all tested models, the deviation between attention-only predictions and actual block updates is positive, ranging from 0.41 for GPT-2 to 0.63 for Llama-3-8B, indicating that within the tested model scale range, the misalignment between attention-only predictions and actual block updates worsens as model scale increases.

To verify the effectiveness of this mechanism, the study conducted multiple controlled-variable sweep experiments, using the trained (βA,αF)=(1,1)(\beta_A, \alpha_F)=(1, 1) as the reference baseline; this baseline is not a specially tuned choice. The swept variables include the attention gain βA\beta_A, the FFN gain αF\alpha_F, the edit scale ss, the ablation set size kk, the number of neurons involved per edit nn, and the intervention depth fraction ℓ/L\ell/L, with the softmax temperature kept at each model's default value.

The study defines three core evaluation metrics corresponding to different validation objectives. The first is one-step faithfulness: the difference between the cosine of the full attention-plus-FFN prediction against the true angular update and the cosine of the attention-only prediction against the true angular update, used to measure whether the FFN reaction term is a necessary component for explaining layer motion. The second is the edit transfer metric: the R2R^2 and slope sign of the induced target logit change relative to the edit scale ss, verifying the linear relationship and direction of action predicted by the steering law. The third comprises edit efficiency and locality metrics: the target logit change per unit edit norm, and the KL divergence on held-out next tokens, used for comparison with properties of the FFN value path.

Multi-Model Intervention Experiments and Engineering Application Results

Measured results of the defect-diagnosis-based layer-parallelization scheme show that the direct defect score effectively predicts a layer's actual replaceability: the low-CℓC_\ell strategy far outperforms random selection or high-CℓC_\ell selection in preserving model quality on GPT-2, GPT-2-large, and Mistral. For GPT-2-large, parallelizing 18 low-CℓC_\ell layers yields about a 1.24x speedup with only a 0.02 loss increase, whereas parallelizing just 4 high-CℓC_\ell layers introduces a 0.29 loss increase. For Mistral, parallelizing 8 low-CℓC_\ell layers yields about a 1.10x speedup with only a 0.009 loss increase, while parallelizing 4 high-CℓC_\ell layers introduces a 0.71 loss increase. This result demonstrates that CℓC_\ell is not only a diagnostic for ODE validity but also a directly actionable quantitative basis for layer selection.

Scaling interventions on FFN outputs verified that pretrained checkpoints operate near a stable aggregation-adjustment corridor. The experiments used the update form xℓ+1=xℓ+βAAℓ(xℓ)+αFΦℓ(xℓ)x_{\ell+1} = x_{\ell}+ \beta_{A}A_{\ell}(x_{\ell}) + \alpha_{F} \Phi_\ell(x_{\ell}), with gain sweeps conducted at fixed βA=1\beta_A=1. Results show that removing the FFN sharply increases loss, and the optimal operating point is very close to the pretrained FFN output scaling factor αF=1\alpha_F=1. The experiments also observed that the balance between inter-layer aggregation and FFN steering strength differs markedly across model families and is not arbitrary: pretraining has already calibrated the FFN's steering scale to a near-optimal operating region.

Critical residual geometry statistics across four models (GPT-2, GPT-2-large, Pythia-410M, Pythia-1.4B) show that the candidate set of the FFN-only dynamical field already exhibits strong saddle-point dominance: under the aggregation statistics, 118 of 140 FFN-only candidates are of the saddle type, and the full dynamical field's candidate set maintains a similar saddle proportion, with 116 of 140 candidates being saddles. Under the original full dynamical field with recovery criticality at α=1\alpha=1, saddle-type residual directions also dominate: 91 of 111 candidates are saddles, 11 are repellers, and only 9 are residual attractors. This indicates that the FFN's adjustment cannot be simply explained as creating stable residual attractors; rather, it reorganizes the local phase portrait through saddle-like/transport geometric structures.

Scope of Applicability and Key Takeaways

The paper's theoretical mean-field results describe only the full-attention setting; causal decoder-type models require adapting to a dynamics form with prefix indexing and cannot directly apply that mean-field conclusion. The anti-collapse claim holds conditionally: the research team performed the corresponding verification by constructing aggregation pressure, and does not claim that this conclusion provides universal guarantees. The phase portrait and critical point analyses used in the study are reduced local diagnostic tools, not a global description of the entire residual space.

The simplified FFN notation used in the theoretical derivations serves only the analysis; all empirical experiments were run directly using the actual MLP/SwiGLU modules from the checkpoints. The near-zero labels in the relevant tables are results of local spectral diagnostics and, without completed numerical root refinement, must not be directly interpreted as conclusions about equilibrium stability. All engineering measurements are positioned as mechanism diagnostics, not complete production-ready deployment solutions.

Rating
No ratings yet
Rate
Community rating
—
/ 5
No ratings yet
Rating
—
Soundness
—
Presentation
—
Contribution
—
Confidence
—
Discussion
Top
Newest
Questions
Replication
Author
No comments yet — be the first