用于掩码语言建模的流形投影与迭代自动编码器优化

arXiv cs.CL 论文

摘要

本文提出了一种基于自动编码器和迭代优化的无注意力掩码语言建模方法,其性能与BERT相当,且FLOPs更少。

arXiv:2609.30288v1 Announce Type: new Abstract: In Transformer-based masked language models, attention is the primary mechanism for context mixing, but there are other ways to mix data across tokens. Recent attention-free mixers replace attention with fixed or hypernetwork-generated MLPs, alternating their dynamic, content-dependent weighting for computational simplicity. We build an alternative that gets the same property from a low-rank bottleneck autoencoder. We replace attention with a stack of autoencoder-based mixing modules, one operating over local neighborhoods, one over the full sequence, and one across attention heads, each compressing and reconstructing its input through a bottleneck, and its width is a hyperparameter rather than a training effect. In masked positions, we introduce an iterative refinement procedure that has two distinct steps. A pulling step that pulls an embedding representation toward a weighted average of its neighbors, and a correcting step that projects the result back to the learned manifold via an autoencoder. Our architecture achieves a significant portion of attention's performance at about $1.9 \times$ fewer FLOPs when pretrained on C4 and evaluated with parameter-matched BERT baselines. Our model equals parameter-matched BERT and TinyBERT baselines on the rarest-token frequency bucket using a frequency-aware training schedule that samples rare tokens more than uniformly for the masking tasks.
查看原文
查看缓存全文

缓存时间: 2026/09/28 09:32

# Manifold Projection and Iterative Autoencoder Refinement for Masked Language Modeling
Source: [https://arxiv.org/html/2609.30288](https://arxiv.org/html/2609.30288)
Farzan Haddadi\*Ebrahim Rezaii††thanks:\*Corresponding author \(Email: farzanhaddadi@iust\.ac\.ir\)\. School of Electrical Engineering, Iran University of Science & Technology, Tehran, Iran\. This work has been submitted to the IEEE for possible publication\. Copyright may be transferred without notice, after which this version may no longer be accessible\.

###### Abstract

In Transformer\-based masked language models, attention is the primary mechanism for context mixing, but there are other ways to mix data across tokens\. Recent attention\-free mixers replace attention with fixed or hypernetwork\-generated MLPs, alternating their dynamic, content\-dependent weighting for computational simplicity\. We build an alternative that gets the same property from a low\-rank bottleneck autoencoder\. We replace attention with a stack of autoencoder\-based mixing modules, one operating over local neighborhoods, one over the full sequence, and one across attention heads, each compressing and reconstructing its input through a bottleneck, and its width is a hyperparameter rather than a training effect\. In masked positions, we introduce an iterative refinement procedure that has two distinct steps\. A pulling step that pulls an embedding representation toward a weighted average of its neighbors, and a correcting step that projects the result back to the learned manifold via an autoencoder\. Our architecture achieves a significant portion of attention’s performance at about1\.9×1\.9\\timesfewer FLOPs when pretrained on C4 and evaluated with parameter\-matched BERT baselines\. Our model equals parameter\-matched BERT and TinyBERT baselines on the rarest\-token frequency bucket using a frequency\-aware training schedule that samples rare tokens more than uniformly for the masking tasks\.

###### Index Terms:

Masked Language Modeling, Attention\-Free Architectures, Autoencoders, Iterative Refinement, Low\-Rank Bottleneck

## IIntroduction

Since Vaswani in 2017\[[1](https://arxiv.org/html/2609.30288#bib.bib1)\]introduced self\-attention as the Transformer’s central context\-mixing mechanism, the idea that combining data across tokens necessitates a dynamic, content\-dependent weighting calculated from pairwise query\-key comparisons has become standard in language modeling\. The majority of advances in bidirectional text encoding are derived from masked language models based on this mechanism, such as BERT\[[2](https://arxiv.org/html/2609.30288#bib.bib2)\]\. Almost all of these models maintain self\-attention even when they modify the pretraining objective, the parameter budget, or the training recipe around it\.

There is a line of research that asks whether an attention mechanism is necessary at all\. The MLP\-Mixer\[[3](https://arxiv.org/html/2609.30288#bib.bib3)\], gMLP\[[4](https://arxiv.org/html/2609.30288#bib.bib4)\], FNet\[[5](https://arxiv.org/html/2609.30288#bib.bib5)\], and Synthesizer\[[6](https://arxiv.org/html/2609.30288#bib.bib6)\]each replace self\-attention with a fixed input\-independent mixing operator\. HyperMixer\[[7](https://arxiv.org/html/2609.30288#bib.bib16)\]partially reintroduces input\-dependence by generating mixing weights through a hypernetwork\. These architectures demonstrate that attention is not strictly required for competitive performance\.

Recent theoretical work shows that MLP\-based mixers are already implicitly biased toward low\-rank behavior, either through weight decay\[[8](https://arxiv.org/html/2609.30288#bib.bib7)\], the dynamics of deep linear compositions\[[9](https://arxiv.org/html/2609.30288#bib.bib8)\], or through depth\[[10](https://arxiv.org/html/2609.30288#bib.bib22)\]\. If this compression is happening regardless of architecture, leaving it implicit only makes it uncontrollable\. Now we ask a question: if content\-dependent mixing does not require attention’s query\-key comparison, can it instead be built out of an explicit, controllable low\-rank operation, whose compression ratio is a visible hyperparameter? This motivates us to use an autoencoder\.

On the other hand, the dot product itself is known as Nadaraya–Watson kernel regression, a classical, similarity\-weighted average\[[11](https://arxiv.org/html/2609.30288#bib.bib18),[12](https://arxiv.org/html/2609.30288#bib.bib19),[13](https://arxiv.org/html/2609.30288#bib.bib20)\]\. Separately, assuming a query as a noisy version of the true key and using Bayes’ rule for the reconstruction shows that similarity\-weighted averaging is the optimal estimator under that noise model, and simplifying that optimal estimator reproduces the softmax attention formula exactly\[[14](https://arxiv.org/html/2609.30288#bib.bib23),[15](https://arxiv.org/html/2609.30288#bib.bib24)\]\. We present our own second derivation based on our work notation in Section[III\-D](https://arxiv.org/html/2609.30288#S3.SS4)\.

\[[16](https://arxiv.org/html/2609.30288#bib.bib27)\]show that in attention, when only thekknearest keys are effective under a small noise scale, the squared query–key distance splits, via the Pythagorean theorem, into a component along the local affine hull spanned by the neighboring keys and a component orthogonal to it; the orthogonal component cancels between the numerator and denominator of the softmax, so the attention output depends only on the query’s orthogonal projection onto that affine hull, after which it returns a convex combination of the nearby keys, exactly the projection\-then\-reconstruction shape of an autoencoder\. They show the same projection behavior on the autoencoder side directly, with no noise assumption: a bottlenecked encoder’s local null space, the directions along which the input can move without changing the code, and hence the output, has dimensionm−km\-kfor anmm\-dimensional input andkk\-dimensional code, so its orthogonal complement is exactly akk\-dimensional locally estimated manifold, and any nearby off\-manifold point is decoded by moving along this null space until it meets that manifold orthogonally\. As a result, attention and autoencoders can, in theory, be substituted\. This is the approach we pursue here, creating an explicit autoencoder to replace attention\.

We replace attention with a stack of autoencoders that perform the same similarity\-weighted mixing role, but through a tunable bottleneck\. We implement this principle at three levels: local neighborhoods \(WindowMixAE\), the full sequence \(GlobalMixAE\), and across attention heads \(ChannelMixAE\)\. We then extend it to masked\-position prediction through an iterative refinement procedure\. Each refinement step has two steps: a similarity\-weighted pulling step, which pulls an embedding toward a weighted average of its neighbors, and a correcting step, which pulls the result back toward the manifold of probable embeddings using the same autoencoder\. Because this autoencoder is trained only on real, unmasked embeddings, we expect an off\-manifold estimate projected back toward that same manifold \(Section[III\-D](https://arxiv.org/html/2609.30288#S3.SS4)\)\.

## IIpreliminaries

This section reviews the background on which our architecture is built on\. Section[II\-A](https://arxiv.org/html/2609.30288#S2.SS1)summarizes the masked language modeling paradigm, and Section[II\-B](https://arxiv.org/html/2609.30288#S2.SS2)reviews the existing attention\-free mixing mechanisms, which establish that self\-attention can be replaced with an MLP network\. In Section[II\-C](https://arxiv.org/html/2609.30288#S2.SS3), we demonstrate, based on recent theoretical results, that ordinary MLP\-based mixers are implicitly biased toward low effective rank, regardless of whether their architecture makes the bottleneck explicit\.

### II\-AMasked Language Models

Masked language modeling \(MLM\) has been the dominant pretraining paradigm for bidirectional text encoders since BERT\[[2](https://arxiv.org/html/2609.30288#bib.bib2)\]\. BERT masks 15% of input tokens and predicts them from bidirectional context\. Given a sequence𝐱=\[x1,…,xn\]\\mathbf\{x\}=\[x\_\{1\},\\dots,x\_\{n\}\], a random subset of positions is replaced with a\[MASK\]token, and the model is trained to minimize

ℒMLM\(θ\)=𝔼𝐱∑i∈ℳ−logpθ\(xi∣𝐱masked\),\\mathcal\{L\}\_\{\\text\{MLM\}\}\(\\theta\)=\\mathbb\{E\}\_\{\\mathbf\{x\}\}\\sum\_\{i\\in\\mathcal\{M\}\}\-\\log p\_\{\\theta\}\(x\_\{i\}\\mid\\mathbf\{x\}\_\{\\text\{masked\}\}\),\(1\)wherepθ\(⋅∣𝐱masked\)p\_\{\\theta\}\(\\cdot\\mid\\mathbf\{x\}\_\{\\text\{masked\}\}\)is the model’s output distribution at positioniiconditioned on the masked sequence\. BERT is also trained with a Next Sentence Prediction \(NSP\) objective for sentence\-pair understanding\.

After BERT, RoBERTa\[[17](https://arxiv.org/html/2609.30288#bib.bib10)\]was trained without any architectural changes on 10×\\timesmore data with larger batches, removing NSP, dynamically remasking each epoch\. ALBERT\[[18](https://arxiv.org/html/2609.30288#bib.bib11)\]instead targets the parameter count, factorizing theV×HV\\times Hembedding matrix intoV×EV\\times EandE×HE\\times H\(E≪HE\\ll H\) and sharing Transformer block weights across layers, while replacing NSP with the harder Sentence\-Order Prediction\. ELECTRA\[[19](https://arxiv.org/html/2609.30288#bib.bib12)\]targets the efficiency of samples\. ELECTRA trains a small generator to propose token replacements and a discriminator to classify every position as original or replaced\.

BART\[[20](https://arxiv.org/html/2609.30288#bib.bib13)\]extends the denoising method to a full encoder\-decoder structure to generate rather than predict at masked positions\. A bidirectional encoder reads text corrupted in different ways, such as individual tokens deleted, whole spans collapsed into a single mask, or sentences shuffled out of order\. Then the autoregressive decoder is trained to reconstruct the original text\.

Despite differences in the training objective, every model mentioned above has one structural property\. The token\-level hidden representation is passed through the network at constant width and constant sequence length, from the first layer to the last\. ALBERT’s factorized embedding is a low\-rank decomposition of the vocabulary lookup table\. Once a token’s embedding is projected to the model’s hidden sizeHH, every subsequent layer operates at that same full width, exactly as in BERT\.

The first to explicitly decrease and then restore dimensions were Funnel\-Transformer\[[21](https://arxiv.org/html/2609.30288#bib.bib14)\]and Hourglass\[[22](https://arxiv.org/html/2609.30288#bib.bib15)\]\. Funnel\-Transformer pools the hidden sequence to a shorter one as depth increases, such as spatial downsampling in a convolutional network, and then recovers the full length with a decoder stage for token\-level objectives like MLM\. Hourglass generalizes this into a symmetric, U\-Net\-style architecture\. A contracting path downsamples the sequence, a matching expanding path restores it, and skip connections preserve fine\-grained information that pooling would otherwise lose\.

The key difference is which axis gets compressed\. Funnel\-Transformer and Hourglass compress along the sequence dimension, using pooling and Transformer sub\-layers\. Our mixing modules instead compress along the channel dimension \(and, for GlobalMixAE, jointly across the sequence\) using an autoencoder with a controllable bottleneck ratio, replacing self\-attention entirely\.

### II\-BAttention\-Free Mixing Mechanisms

A line of research replaces the self\-attention layer with an ordinary, gradient\-trained mixing operator, removing the dynamic, content\-dependent weighting that attention provides\. MLP\-Mixer\[[3](https://arxiv.org/html/2609.30288#bib.bib3)\]and gMLP\[[4](https://arxiv.org/html/2609.30288#bib.bib4)\], both introduced in 2021, replace self\-attention with a token\-mixing MLP applied along the sequence dimension, whose weights are fixed after training rather than computed dynamically from the input\. gMLP reports that its spatial gating unit matches Transformer perplexity on masked language modeling but underperforms on GLUE tasks that require cross\-sentence relational reasoning \(like MNLI\), a gap the authors close by adding a small, single\-head self\-attention module \(aMLP\)\. FNet\[[5](https://arxiv.org/html/2609.30288#bib.bib5)\]replaces the token\-mixing operation with an unparameterized 2D Fourier transform, eliminating learned mixing weights entirely\. The Synthesizer\[[6](https://arxiv.org/html/2609.30288#bib.bib6)\]explores both dense and factorized input\-independent attention weight matrices as drop\-in replacements for self\-attention, likewise fixing the mixing pattern after training\.

The above methods fix their mixing weights once training is complete, but HyperMixer\[[7](https://arxiv.org/html/2609.30288#bib.bib16)\]generates the token\-mixing MLP’s weights dynamically via a hypernetwork applied to the input\. The authors describe it as similar to the attention mechanism, because it reintroduces input\-dependence into the mixing weights\.

All of the methods above replace attention with a different single\-pass mixing operator, computed once per layer\. A separate line of work keeps the prediction itself iterative\. Masked diffusion language models such as MDLM\[[23](https://arxiv.org/html/2609.30288#bib.bib25)\]recover masked tokens through repeated denoising steps rather than a single forward pass\. MDLM’s diffusion process operates over the discrete token distribution with a learned noise schedule, generating one masking level at a time\. Our refinement loop operates directly in continuous embedding space with a fixed, deterministic predictor\-corrector update and no noise schedule\.

Our GlobalMixAE module applies a transform along the token dimension with weights shared across channels\. It imposes an explicit low\-rank bottleneck rather than an unconstrainedn×nn\\times nmixing matrix\. Also, it is one stage of a local\-then\-global\-then\-cross\-head hierarchy \(WindowMixAE, GlobalMixAE, ChannelMixAE\) followed by an iterative refinement stage, rather than the sole mixing operation applied once per layer\.

### II\-CLow\-Rank Structure in MLPs

In an autoencoder, the encoder compresses its input to a fractionr<1r<1of its original width before the decoder expands it back\. MLPs have no such bottleneck, and their weight matrices are numerically full\-rank, but their effective rank in practice is less than algebraic rank\. Three independent lines of evidence support this observation, and each has the same consequence for mixing\-based architectures\.

#### II\-C1Measuring effective rank

The algebraic rank is not informative for a trained matrix, since noise can cause the weight matrix to be full rank\. Following\[[8](https://arxiv.org/html/2609.30288#bib.bib7)\]\(building on\[[24](https://arxiv.org/html/2609.30288#bib.bib17)\]\), we instead use the stable rank\.

###### Definition 1\(Stable rank\)\.

ForW∈ℝm×nW\\in\\mathbb\{R\}^\{m\\times n\}with singular valuesσ1≥⋯≥σr≥0\\sigma\_\{1\}\\geq\\cdots\\geq\\sigma\_\{r\}\\geq 0,r=min⁡\(m,n\)r=\\min\(m,n\),

srank⁡\(W\)=‖W‖F2‖W‖22=∑iσi2σ12∈\[1,r\]\.\\operatorname\{srank\}\(W\)\\;=\\;\\frac\{\\\|W\\\|\_\{F\}^\{2\}\}\{\\\|W\\\|\_\{2\}^\{2\}\}\\;=\\;\\frac\{\\sum\_\{i\}\\sigma\_\{i\}^\{2\}\}\{\\sigma\_\{1\}^\{2\}\}\\;\\in\\;\[1,r\]\.\(2\)Here‖W‖F\\\|W\\\|\_\{F\}is the Frobenius norm, the square root of the sum of all squared entries ofWW, and‖W‖2\\\|W\\\|\_\{2\}is the spectral norm, simply the largest singular valueσ1\\sigma\_\{1\}\.

A uniform singular spectrum givessrank⁡\(W\)=r\\operatorname\{srank\}\(W\)=r\. A spectrum dominated by one direction drives it towards11, regardless of how many singular values are technically nonzero\.

\[[8](https://arxiv.org/html/2609.30288#bib.bib7)\]show thatL2L\_\{2\}weight decay provably forces the stable rank downward\. At any stationary point of the regularized loss, every layer’s Frobenius norm is equal regardless of width, so a wide layer does not get an extra energy budget to spread across its extra directions\.

###### Theorem 1\(Low\-rank bias under weight decay,\[[8](https://arxiv.org/html/2609.30288#bib.bib7)\]\)\.

Letθ\\thetabe a stationary point of theL2L\_\{2\}\-regularized lossLλL\_\{\\lambda\}for aKK\-layer network\. Then

1K∑k=1Ksrank\(Wk\)−1/2≥\(λL​\(θ\)1/2−1/K\)1/2\.\\frac\{1\}\{K\}\\sum\_\{k=1\}^\{K\}\\operatorname\{srank\}\(W\_\{k\}\)^\{\-1/2\}\\;\\geq\\;\\left\(\\frac\{\\lambda\}\{L\(\\theta\)^\{1/2\-1/K\}\}\\right\)^\{1/2\}\.\(3\)The stronger the weight decay \(the largerλ\\lambda\), the lower the layers’ stable ranks\. For deep linear networks, this pressure is strong enough that every single weight matrix eventually converges to exactly rank one\.

#### II\-C2Rank\-Minimizing Autoencoder

\[[9](https://arxiv.org/html/2609.30288#bib.bib8)\]designed an experiment\. It inserted a stack ofKKextra fully linear layersW=WKWK−1⋯W1W=W\_\{K\}W\_\{K\-1\}\\cdots W\_\{1\}between the encoder and the decoder, without a bottleneck, without a rank penalty, and without a change in reconstruction loss\. Trained by gradient flow under a balanced initialization, the end\-to\-end matrixW⁡\(t\)W\(t\)is known to evolve as

W˙\(t\)=−∑k=1K\(W\(t\)W\(t\)⊤\)k−1K∇L1\(W\(t\)\)\(W\(t\)⊤W\(t\)\)K−kK\\displaystyle\\dot\{W\}\(t\)=\-\\sum\_\{k=1\}^\{K\}\\big\(W\(t\)W\(t\)^\{\\top\}\\big\)^\{\\frac\{k\-1\}\{K\}\}\\,\\nabla L^\{1\}\(W\(t\)\)\\,\\big\(W\(t\)^\{\\top\}W\(t\)\\big\)^\{\\frac\{K\-k\}\{K\}\}

\(4\)whereL1L^\{1\}is the reconstruction loss as a function of the end\-to\-end matrix\. WritingW⁡\(t\)=U⁡\(t\)​Σ​\(t\)​V​\(t\)⊤W\(t\)=U\(t\)\\Sigma\(t\)V\(t\)^\{\\top\}for its SVD, Equation \([4](https://arxiv.org/html/2609.30288#S2.E4)\) determines the dynamics of each singular value\.

###### Theorem 2\(Rich\-get\-richer singular value dynamics;\[[9](https://arxiv.org/html/2609.30288#bib.bib8)\], building on\[[25](https://arxiv.org/html/2609.30288#bib.bib9)\]\)\.

Under gradient flow with balanced initialization, for a stack ofKKextra linear layers, each singular valueσi​\(t\)\\sigma\_\{i\}\(t\)of the end\-to\-end map evolves with relative growth rateσ˙i/σi∝σi1−2/K\\dot\{\\sigma\}\_\{i\}/\\sigma\_\{i\}\\propto\\sigma\_\{i\}^\{1\-2/K\}\. Since1−2/K\>01\-2/K\>0forK\>2K\>2, larger singular values grow relatively faster than smaller ones, concentrating the spectrum on a few directions\.

Once one direction is even slightly larger, it grows faster than the rest during training \(a fact that\[[9](https://arxiv.org/html/2609.30288#bib.bib8)\]confirm experimentally\)\.

#### II\-C3Regardless of training mechanism

The third research is independent of the training process\[[10](https://arxiv.org/html/2609.30288#bib.bib22)\]\. The bias toward low effective rank exists in the parameterization itself, before any training\. Sincerank⁡\(A​B\)≤min⁡\(rank⁡\(A\),rank⁡\(B\)\)\\operatorname\{rank\}\(AB\)\\leq\\min\(\\operatorname\{rank\}\(A\),\\operatorname\{rank\}\(B\)\), depth by itself can only lower rank and never raise it\. They used a second metric to formalize this\.

###### Definition 2\(Effective rank;\[[26](https://arxiv.org/html/2609.30288#bib.bib21)\]\)\.

ForA∈ℝm×nA\\in\\mathbb\{R\}^\{m\\times n\}with normalized singular valuesσ¯i=σi/∑jσj\\bar\{\\sigma\}\_\{i\}=\\sigma\_\{i\}/\\sum\_\{j\}\\sigma\_\{j\},

ρ\(A\)=−∑i=1rσ¯ilog\(σ¯i\)\.\\rho\(A\)\\;=\\;\-\\sum\_\{i=1\}^\{r\}\\bar\{\\sigma\}\_\{i\}\\log\(\\bar\{\\sigma\}\_\{i\}\)\.\(5\)

This is similar to stable rank in practice, both are maximized when singular values are all equal\.

###### Theorem 3\(Rank contraction with depth,\[[10](https://arxiv.org/html/2609.30288#bib.bib22)\]\)\.

For add\-layer linear network with i\.i\.d\. Gaussian weight matrices, in the limitdim\(W\)→∞\\dim\(W\)\\to\\infty,

ρ\(WdWd−1⋯W1\)≤ρ\(Wd−1⋯W1\)\.\\rho\\big\(W\_\{d\}W\_\{d\-1\}\\cdots W\_\{1\}\\big\)\\;\\leq\\;\\rho\\big\(W\_\{d\-1\}\\cdots W\_\{1\}\\big\)\.\(6\)Stacking one more Gaussian layer never increases effective rank, and generically decreases it\.

As a result, MLPs are biased toward low effective rank whether or not their architecture makes a bottleneck explicit\. Every attention\-free mixer introduced in Section[II\-B](https://arxiv.org/html/2609.30288#S2.SS2), MLP\-Mixer’s token\-mixing MLP, gMLP’s spatial gating unit, and FNet’s linear token mixer, is already being pushed toward low effective rank\. Given this, if MLP\-based mixing is already compressing to low rank regardless of architecture, leaving that compression implicit only makes it uncontrolled\. We instead build the mixing operation directly out of an autoencoder with an explicit bottleneck Section[III](https://arxiv.org/html/2609.30288#S3)\), whose compression ratiorris a visible, tunable hyperparameter\.

## IIIMethod

Our model follows the standard three\-stage encoder pipeline of a Transformer\-based masked language model, an embedding stage, a context mixing stage, and a task\-specific output stage \(a masked\-token prediction head during pretraining and a pooled classification head during GLUE fine\-tuning\), but replaces the self\-attention layers with a hierarchy of autoencoder\-based mixing modules, followed by an iterative refinement stage applied only at masked positions\. Fig\.[1](https://arxiv.org/html/2609.30288#S3.F1)and Fig\.[2](https://arxiv.org/html/2609.30288#S3.F2)demonstrate the model architecture and internal structure of the mixing module, respectively\. The token embeddings are processed by a stack of local mixing layers \(WindowMixAE\), a global mixing layer \(GlobalMixAE\), and then a ChannelMixAE layer, which mixes information across independent heads\. The resulting per\-position representations at masked positions are taken as an initial embedding and iteratively refined by a distance\-weighted average of unmasked token embeddings and projected through a manifold autoencoder \(ManifoldAE\)\.

Fig\. 1:The model architectureFig\. 2:Internal structure of the mixing modules\.### III\-ALocal mixing stage: WindowMixAE

The model uses a multihead AE structure, which means that the Autoencoders processd=D/Hd=D/H\(H=4H=4heads\) of each embedding dimension\. For a token at positioniiwith embeddingxi∈ℝDx\_\{i\}\\in\\mathbb\{R\}^\{D\}, a window ofw=5w=5neighboring embeddings, positionsi−2,…,i\+2i\-2,\\dots,i\+2, is concatenated per head and passed through an encoder to a bottleneck of dimensionb=d/2b=d/2, then decoded back todddimensions and added as a residual to the center token’s embedding:

x~i\(h\)=xi\(h\)\+Dec\(h\)​\(Enc\(h\)​\(\[xi−2\(h\);…;xi\+2\(h\)\]\)\),\\tilde\{x\}\_\{i\}^\{\(h\)\}=x\_\{i\}^\{\(h\)\}\+\\mathrm\{Dec\}^\{\(h\)\}\\\!\\left\(\\mathrm\{Enc\}^\{\(h\)\}\\\!\\left\(\\left\[x\_\{i\-2\}^\{\(h\)\};\\dots;x\_\{i\+2\}^\{\(h\)\}\\right\]\\right\)\\right\),\(7\)where superscript\(h\)\(h\)denotes the per\-head slice\. Three such layers are stacked, giving an effective local receptive field of±6\\pm 6tokens\.

### III\-BGlobal mixing stage: GlobalMixAE

Following the local mixing stack, a single GlobalMixAE layer mixes information across the entire sequence\. For channelc∈\{1,…,d\}c\\in\\\{1,\\dots,d\\\}within headhh, let

vc\(h\)=\(x1,c\(h\),…,xL,c\(h\)\)∈ℝLv\_\{c\}^\{\(h\)\}=\\big\(x\_\{1,c\}^\{\(h\)\},\\dots,x\_\{L,c\}^\{\(h\)\}\\big\)\\in\\mathbb\{R\}^\{L\}\(8\)denote the sequence of values that the channel takes across allLLpositions\. This vector is passed through an encoder/decoder pair, with weights shared across allddchannels of a head, to a bottleneck of dimensionbG=L/4b\_\{G\}=L/4, and added back as a residual:

v~c\(h\)=vc\(h\)\+DecG\(h\)​\(EncG\(h\)​\(vc\(h\)\)\),\\tilde\{v\}\_\{c\}^\{\(h\)\}=v\_\{c\}^\{\(h\)\}\+\\mathrm\{Dec\}\_\{G\}^\{\(h\)\}\\\!\\left\(\\mathrm\{Enc\}\_\{G\}^\{\(h\)\}\\\!\\left\(v\_\{c\}^\{\(h\)\}\\right\)\\right\),\(9\)

### III\-CChannel mixing stage: ChannelMixAE

Since each head operated on an independentd=D/Hd=D/Hdimensional slice of the model dimension, only the final dense layer sees the full concatenatedDD\-dimensional vector\. We introduce an additional ChannelMixAE module, applied after GlobalMixAE, that uses the full embeddingxi∈ℝDx\_\{i\}\\in\\mathbb\{R\}^\{D\}of each token as a single vector, not split across heads, and passes it through an encoder/decoder pair to a bottleneck of dimensionbC=D/2b\_\{C\}=D/2, added back as a residual delta:

x~i=xi\+DecC​\(EncC​\(xi\)\),\\tilde\{x\}\_\{i\}=x\_\{i\}\+\\mathrm\{Dec\}\_\{C\}\\\!\\left\(\\mathrm\{Enc\}\_\{C\}\(x\_\{i\}\)\\right\),\(10\)whereEncC\\mathrm\{Enc\}\_\{C\}andDecC\\mathrm\{Dec\}\_\{C\}are MLPs whose intermediate widths follow the same geometric taper used by WindowMixAE\. This is the only point in the mixing pipeline where information from different heads is combined before the final classification/output layer\. Like all other modules in this architecture, ChannelMixAE performs no dot product and remains fully attention\-free\.

### III\-DIterative refinement

The mixing modules combine information across tokens and channels\. Our model goes further by adding a refinement stage that operates on the embeddings produced by the mixing modules\. The refinement stage relies on a network trained on the unmasked tokens separately, which is ManifoldAE\. At every training step, we take the embeddings of all unmasked tokens in the batch and train this autoencoder, with its own reconstruction loss\. Once trained, the iterative refinement loop reuses this same encoder\-decoder, with weights frozen \(no gradients flow into it from this second use\) and has two steps:

1. 1\.Pulling Step: The masked position embedding produced by the mixing module moves one step toward a distance\-weighted average of neighboring \(unmasked\) embeddings\. Because this average is a combination of points on a curved manifold, it generally lands off that manifold\. So by moving one step toward it, the embedding gets off the manifold\.
2. 2\.Correcting step: Because the autoencoder was trained on unmasked embeddings and knows the embedding manifolds, we expect that by passing the off\-manifold vector through an autoencoder, it will be projected back to the manifold of real embeddings\. As discussed earlier,\[[16](https://arxiv.org/html/2609.30288#bib.bib27)\]give this expectation a structural, noise\-free grounding: a bottlenecked autoencoder’s local null space around each training point is exactly what defines this pull toward the manifold it was trained to represent\.

Fig\.[3](https://arxiv.org/html/2609.30288#S3.F3)demonstrates this process\. By iteratively repeating this pulling step and correcting step, we refine the embedding of masked positions\. We state this observation empirically in ablation\. The refinement loop performs the following update formula per iteration:

p^\\displaystyle\\hat\{p\}=α​p\(t\)\+\(1−α\)​μ,\\displaystyle=\\alpha\\,p^\{\(t\)\}\+\(1\-\\alpha\)\\,\\mu,Pulling Step\(11\)p\(t\+1\)\\displaystyle p^\{\(t\+1\)\}=p\(t\)\+γ⁡\(AEproj​\(p^\)−p\(t\)\),\\displaystyle=p^\{\(t\)\}\+\\gamma\\big\(\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}\(\\hat\{p\}\)\-p^\{\(t\)\}\\big\),Correcting Step\(12\)whereγ\\gammacontrols the step size, andμ∈ℝD\\mu\\in\\mathbb\{R\}^\{D\}is the distance\-weighted mean over unmasked token embeddings,

μ=∑j∈𝒦softmaxj​\(−\|i−j\|τ\)​xj,\\mu=\\sum\_\{j\\in\\mathcal\{K\}\}\\mathrm\{softmax\}\_\{j\}\\\!\\left\(\-\\frac\{\|i\-j\|\}\{\\tau\}\\right\)x\_\{j\},\(13\)
with𝒦\\mathcal\{K\}the set of unmasked positions andτ\\tauthe temperature of this softmax\. For largeτ\\tau, the weights become nearly uniform, causingμ\\muto approach the global mean\. In contrast, smallτ\\tauplaces most of the weight on the nearest token, while intermediate values ofτ\\taulead to stable states, whereμ\\muconverges toward a small cluster of similar tokens\. During training,τ\\tauis annealed fromτmin=0\.5\\tau\_\{\\min\}=0\.5toτmax=12\\tau\_\{\\max\}=12according to an inverse\-cosine schedule\.

Leta∈ℝDa\\in\\mathbb\{R\}^\{D\}be the initial embedding of the masked position \(the output of the local, global, and channel mixing stages\)\. Starting fromp\(0\)=ap^\{\(0\)\}=a, the refinement loop applies the pulling\-correcting update of Equation \([11](https://arxiv.org/html/2609.30288#S3.E11)–[12](https://arxiv.org/html/2609.30288#S3.E12)\) forT=6T=6fixed iterations, withα=0\.7\\alpha=0\.7and step sizeγ=0\.4\\gamma=0\.4\. HereAEproj\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}is a forward pass through the ManifoldAE with its weights detached from the refinement loop’s gradient\.

Only the ManifoldAE’s own parameters are detached, so no gradient updates flow into them from the refinement loop\. The forward computation itself is not detached from its input\.AEproj\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}is used as an ordinary differentiable function ofp^\\hat\{p\}, with its weights treated as constants inside that computation\. Gradients therefore do flow back throughAEproj\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}’s layers top^\\hat\{p\}, and from there to earlier refinement iterations and the mixing modules; this is exactly what makes the vanishing\-gradient failure mode described above possible, and what the damped residual update was designed to fix\.

The residual form of this update, withγ<1\\gamma<1, turned out to be essential\. We first tried the more direct updatep\(t\+1\)←AEproj​\(p^\)p^\{\(t\+1\)\}\\leftarrow\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}\(\\hat\{p\}\), replacingp\(t\)p^\{\(t\)\}outright at every step\. Because this replacement is applied six times in a row, and each pass through the ManifoldAE is itself several layers deep, the effective path from the last refinement step back to the first is comparable to an unusually deep network with no skip connections\. In practice, this caused the gradient to vanish: by the time it reached the first iteration, its norm was effectively zero\. Switching to the damped residual update above fixed this\. With everything else held fixed, the ratio between the gradient norm at the first iteration and at the last rose from≈0\\approx 0to≈0\.446\\approx 0\.446\. The earliest refinement steps started receiving a meaningful learning signal again\.

Token Manifoldp\(t\)p^\{\(t\)\}μ\\mup^\\hat\{p\}Pulling:p^=α​p\(t\)\+\(1−α\)​μ\\hat\{p\}=\\alpha p^\{\(t\)\}\+\(1\-\\alpha\)\\mup\(t\+1\)p^\{\(t\+1\)\}Correcting:AEproj​\(p^\)\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}\(\\hat\{p\}\)p^′\\hat\{p\}^\{\\prime\}p\(t\+2\)p^\{\(t\+2\)\}Fig\. 3:The iterative refinement procedure consists of two steps: pulling and correcting\. Starting fromp\(t\)p^\{\(t\)\}, the pulling step moves the embedding toward the neighbor meanμ\\mu, landing off the manifold atp^\\hat\{p\}\. Then in the correcting stepAEproj​\(p^\)\\mathrm\{AE\}\_\{\\mathrm\{proj\}\}\(\\hat\{p\}\)project this back onto the manifold, givingp\(t\+1\)p^\{\(t\+1\)\}\.
### III\-ERetrieval as Bayesian Denoising

Considering attention as the result of Bayesian denoising under Gaussian corruption is not a new observation\.\[[14](https://arxiv.org/html/2609.30288#bib.bib23)\]showed, in the context of ordinary classification rather than attention, that if a set of classes has Gaussian feature distributions with equal covariance, the posterior class probabilities computed via Bayes’ rule take the exact form of a softmax over linear discriminants, reached by asking a completely different question \(which class does this point belong to, not which key does this query match\)\.\[[15](https://arxiv.org/html/2609.30288#bib.bib24)\]treat a query as a Gaussian\-corrupted copy of the key to be retrieved, and show that applying Bayes’ rule to recover the most likely key reconstructs softmax attention exactly\.

We follow this derivation ourselves in our own notation, because the same reasoning that a noisy input needs to be projected back toward the known manifold motivates what the ManifoldAE is doing in Section[III\-D](https://arxiv.org/html/2609.30288#S3.SS4)\.

Attention compares a query against a set of keys and returns a weighted blend of the associated values\. Suppose each keykik\_\{i\}is clean, and a queryqjq\_\{j\}is a noisy probe of one of them,

qj=ki\+η,η∼𝒩⁡\(0,σ2​I\)\.q\_\{j\}=k\_\{i\}\+\\eta,\\qquad\\eta\\sim\\mathcal\{N\}\(0,\\sigma^\{2\}I\)\.\(14\)We wantP⁡\(ki∣qj\)P\(k\_\{i\}\\mid q\_\{j\}\), but can only compute the reverse,P⁡\(qj∣ki\)P\(q\_\{j\}\\mid k\_\{i\}\), directly from this noise model\. Bayes’ rule bridges the two:

P⁡\(ki∣qj\)⏟want this=P⁡\(qj∣ki\)⏞can compute this​P​\(ki\)P⁡\(qj\)\.\\underbrace\{P\(k\_\{i\}\\mid q\_\{j\}\)\}\_\{\\text\{want this\}\}=\\frac\{\\overbrace\{P\(q\_\{j\}\\mid k\_\{i\}\)\}^\{\\text\{can compute this\}\}\\,P\(k\_\{i\}\)\}\{P\(q\_\{j\}\)\}\.\(15\)With GaussianP\(qj∣ki\)∝exp\(−∥qj−ki∥2/2σ2\)P\(q\_\{j\}\\mid k\_\{i\}\)\\propto\\exp\(\-\\lVert q\_\{j\}\-k\_\{i\}\\rVert^\{2\}/2\\sigma^\{2\}\)and a uniform priorP⁡\(ki\)=1/NP\(k\_\{i\}\)=1/N, every other factor is constant inii\(fixed onceqjq\_\{j\}is observed\), so

P⁡\(ki∣qj\)∝exp⁡\(−∥qj−ki∥22​σ2\)\.P\(k\_\{i\}\\mid q\_\{j\}\)\\;\\propto\\;\\exp\\\!\\left\(\-\\frac\{\\lVert q\_\{j\}\-k\_\{i\}\\rVert^\{2\}\}\{2\\sigma^\{2\}\}\\right\)\.\(16\)The best single valuezzto report is the one minimizing expected squared error,∑iP⁡\(ki∣qj\)​∥z−vi∥2\\sum\_\{i\}P\(k\_\{i\}\\mid q\_\{j\}\)\\lVert z\-v\_\{i\}\\rVert^\{2\}; setting its gradient to zero gives the weighted mean

z∗=∑iP⁡\(ki∣qj\)​vi∑iP⁡\(ki∣qj\),z^\{\\ast\}=\\frac\{\\sum\_\{i\}P\(k\_\{i\}\\mid q\_\{j\}\)\\,v\_\{i\}\}\{\\sum\_\{i\}P\(k\_\{i\}\\mid q\_\{j\}\)\},\(17\)the Nadaraya–Watson estimator\. Expanding∥qj−ki∥2=∥qj∥2−2​⟨qj,ki⟩\+∥ki∥2\\lVert q\_\{j\}\-k\_\{i\}\\rVert^\{2\}=\\lVert q\_\{j\}\\rVert^\{2\}\-2\\langle q\_\{j\},k\_\{i\}\\rangle\+\\lVert k\_\{i\}\\rVert^\{2\}, the first term is constant iniiand cancels; the last term also cancels once keys have approximately equal norm,∥ki∥≈c\\lVert k\_\{i\}\\rVert\\approx c\(after normalization\)\. What remains is exactly the softmax attention,

z∗=softmax⁡\(qj​K⊤σ2\)​V,z^\{\\ast\}=\\mathrm\{softmax\}\\\!\\Big\(\\tfrac\{q\_\{j\}K^\{\\top\}\}\{\\sigma^\{2\}\}\\Big\)V,\(18\)which matches the standardsoftmax⁡\(q⊤​k/dk\)\\mathrm\{softmax\}\(q^\{\\top\}k/\\sqrt\{d\_\{k\}\}\)scaling of\[[1](https://arxiv.org/html/2609.30288#bib.bib1)\]whenσ2=dk\\sigma^\{2\}=\\sqrt\{d\_\{k\}\}\. A largeσ\\sigmamakes the weights in Equation \([16](https://arxiv.org/html/2609.30288#S3.E16)nearly uniform, averaging over most keys, while a smallσ\\sigmaconcentrates almost all the weight on the single nearest key, the same bandwidth trade\-off that governs the temperatureτ\\tauin our own neighbor meanμ\\mu\.\[[16](https://arxiv.org/html/2609.30288#bib.bib27)\]study this convergence pattern for the same closed\-form estimator: they show, and confirm with their own simulation, that asσ\\sigmais gradually decreased the estimator moves from an average over nearby signals toward a sparse solution concentrated on the single nearest one\. The same qualitative behavior is expected to hold for our ownτ\\tau\.

TABLE I:Comparison across AE\-mixing configurations, all on C4, 100k steps\. Bucket columns report masked\-token accuracy \(%\) for frequency ranges\[100,2​k\)\[100,2\\mathrm\{k\}\),\[2​k,5​k\)\[2\\mathrm\{k\},5\\mathrm\{k\}\), and\[5k\)\[5\\mathrm\{k\}\)\.
### III\-FExperimental Setup & Configuration

The model is trained with a masked language modeling objective using 15% masked tokens\. It is applied in two phases that differ in how the masked\-token target distribution and the loss are weighted with respect to token frequency\. Phase 1 \(steps 1–40k\) was standard, frequency\-uniform MLM, matching the original BERT masking procedure\[[2](https://arxiv.org/html/2609.30288#bib.bib2)\]\. For the first 40k steps, the masked targets are uniformly at random from the tokens in each sequence, and the cross\-entropy loss on every masked token is weighted equally\. Phase 2 \(steps 40k–100k\) was frequency\-aware masking and loss weighting\. Instead of uniform sampling, masking targets are drawn with a probability that increases with token rarity, so that rare tokens are selected as masking targets more often than common tokens\. Moreover, independently of how a masked token was selected, its contribution to the cross\-entropy loss is scaled by a factor that depends on its frequency bucket\. This mechanism controls how much a prediction error on the selected token matters to the gradient\. Independent of this two\-phase schedule, validation always uses the uniform masking distribution with unweighted loss, so that the reported validation metric remains comparable with different architectural configurations evaluated throughout this work\.

Training configuration and number of tokens used during training are important factors in determining whether the attention\-free architecture becomes competitive with self\-attention mechanisms\. We evaluate the performance of our model using different system configurations\. For the base configuration \(A\) described in Section[III](https://arxiv.org/html/2609.30288#S3), we evaluate the performance of our model using the 10B\-token C4 corpus\[[27](https://arxiv.org/html/2609.30288#bib.bib26)\]\. The base configuration is four stacked WindowMixAE layers, a single GlobalMixAE layer, and a ChannelMixAE layer, and then the iterative refinement loop with six iterations\. The model has a hidden dimensionD=680D=680, sequence lengthL=512L=512, and 4 mixing heads, for a total of 32M parameters\. Training uses a batch size of 128 for 100,000 steps with the AdamW optimizer, a cosine learning\-rate schedule and mixed\-precision \(fp16\) training, using the NVIDIA L40S GPU with 48 GB of GDDR6 memory\.

Motivated by HyperMixer\[[7](https://arxiv.org/html/2609.30288#bib.bib16)\], Configuration B designed a Content\-aware neighbor bias\. The neighbor\-averaging termμ\\muin the refinement loop weights known tokens solely by their distance to the masked position, independent of token content\. ChunkedContentBias computes a content\-dependent bias between each masked position’s mixing\-derived embedding and the chunked mean of the sequence, which is then added to the distance\-based logits before the softmax that producesμ\\mu\. The sequence is partitioned into fixed\-size windows ofCONTENT\_CHUNK\_SIZE=8\\texttt\{CONTENT\\\_CHUNK\\\_SIZE\}=8\. Each chunk is summarized by the mean embedding of its known tokens, and scored against the masked position’s own embedding via cosine similarity, giving a content\-dependent bias added to the distance\-based logits for every token in that chunk\.

In Configuration C, the two mixing/refinement coefficientsα\\alphaandγ\\gamma, previously fixed, were instead made learnable\. In addition, an exponential moving average \(EMA\) of the model weights was tracked and used during evaluation\. The training procedure was also modified to incorporate gradient accumulation\.

The ManifoldAE is a multi\-head autoencoder: theDD\-dimensional embedding is split intoH=4H=4independent heads of widthdhead=D/Hd\_\{\\mathrm\{head\}\}=D/H, and each head has its own 3\-hidden\-layer encoder\-decoder stack with a bottleneck ratio ofr=0\.5r=0\.5\(bottleneck width=0\.5⋅dhead=0\.5\\cdot d\_\{\\mathrm\{head\}\}\), GELU\-activated, with intermediate widths following a geometric taper – the same hourglass template used by WindowMixAE and GlobalMixAE\. All models are trained with AdamW \(β1=0\.9\\beta\_\{1\}\{=\}0\.9,β2=0\.98\\beta\_\{2\}\{=\}0\.98,ϵ=10−6\\epsilon\{=\}10^\{\-6\}, weight decay0\.010\.01applied to all two\-or\-more\-dimensional parameters except embeddings, layer norms, and biases\), a cosine learning\-rate schedule with linear warmup, and mixed\-precision \(fp16\) training\.

The ManifoldAE’s reconstruction loss is combined with the main MLM loss at a weight that is itself annealed over training, from0\.30\.3at initialization down to0\.090\.09\(30% of the initial value\) by the end of training, following a cosine schedule\. We found this necessary: holding the weight fixed at0\.30\.3throughout let the ManifoldAE’s reconstruction loss begin rising again partway through training, most likely because the MLM loss increasingly competes for optimization budget as training progresses; annealing the AE weight down gives the MLM objective more room in the second half of training without destabilizing the ManifoldAE early on, when it most needs to learn the embedding manifold\.

TABLE II:Our AE base configuration versus three BERT\-based baselines, matched in parameter count\.\*BERT here is standard self\-attention Transformer encoders trained from scratch under our own setup \(same optimizer, masking scheme, and steps as our model\)\.TABLE III:GLUE validation results over 3 seeds: our best AE configuration \(base\+\+ChunkedContentBias\) versus the three attention\-based baselines of Table[II](https://arxiv.org/html/2609.30288#S3.T2)\.

## IVResults

We report Score, top\-1 masked\-token prediction accuracy averaged over all masked positions in the validation set, regardless of token frequency\. The bucket columns \(\[100,2k\), \[2k,5k\), \[5k\)\) report the same accuracy restricted to masked tokens whose frequency rank is in this range\.

All four configurations, pretrained under the same circumstances on C4 for 100k steps, are compared in Table[I](https://arxiv.org/html/2609.30288#S3.T1)\. It is confirmed that allowing the neighbor\-averaging term to depend on content rather than simply distance is worth the additional parameters by adding ChunkedContentBias \(Configuration B\), which causes the best overall result in both accuracy and perplexity\.

Our base AE configuration is compared to BERT and TinyBERT Transformer baselines with comparable parameter counts in Table[II](https://arxiv.org/html/2609.30288#S3.T2)\. The attention baselines are standard Transformer encoders matched in hidden dimensionDDand parameter count to our configuration: theD=680,L=512D\{=\}680,L\{=\}512baseline uses 2 layers and 4 attention heads, and theD=680,L=128D\{=\}680,L\{=\}128baseline uses 4 layers and 8 attention heads\. Full configuration details for all baselines are available in the released code \(GitHub\)\.

Table[III](https://arxiv.org/html/2609.30288#S3.T3)fine\-tunes our model configuration \(base\+\+ChunkedContentBias\) and all BERT baselines on GLUE\. The AE model outperforms three attention baselines on CoLA and SST\-2\. In tasks that require relating two input segments to each other, such as MRPC, the mixing modules perform poorly\. CoLA and SST\-2 are both single\-sentence tasks, solvable from one segment’s surface\-level or lexical properties, whereas the tasks where the AE model falls behind require judging a relationship between two separate spans of text\. The token\-to\-token alignment mechanism missing from our architecture is exactly what self\-attention computes, a pairwise, content\-dependent weighting between every pair of tokens, at a substantial computational cost\. In contrast, our own approach, especially in its base configuration, just considers the physical distance between neighboring tokens rather than their semantic content\. Nevertheless, by this simple positional average, could fill a masked token semantically correctly\.

TABLE IV:FLOPs per forward pass, base \+ ChunkedContentBias configuration \(batch size 32\)\.Beyond the accuracy comparison above, the two architectures are different structurally in how their cost scales with sequence lengthLL\. Self\-attention costsO⁡\(L2​D\)O\(L^\{2\}D\)per layer, dominated by theQ​K⊤QK^\{\\top\}and softmax\-weighted\-value calculation terms\. Our mixing modules instead use fixed\-size autoencoder bottlenecks, so most of them cost onlyO⁡\(L​D\)O\(LD\), linear, not quadratic, in sequence lengthLL\. The one exception is GlobalMixAE, whose bottleneck width scales withLLand so keeps a \(smaller\-constant\)O⁡\(L2\)O\(L^\{2\}\)term\. Table[IV](https://arxiv.org/html/2609.30288#S4.T4)presents FLOPs at the two lengths we trained and evaluated\. At bothL=128L=128andL=512L=512, our strongest configuration, which uses a content\-dependent mean, needs1\.9×1\.9\\timesfewer FLOPs than a matched attention model, even though it utilizes an architecture that is by design less capable of modeling paired token interaction than attention\.

TABLE V:Ablations over the refinement loop’s three hyperparameters: number of iterationsTT, mixing ratioα\\alpha, and step sizeγ\\gamma\.The results mentioned above do not support the idea that self\-attention should be completely replaced by all attention\-free mixing\. We believe the evidence in this section actually supports the claim that this architecture achieves a large fraction of attention’s performance at a fraction of its cost with a much simpler mixing mechanism, no query\-key comparison, no dot\-product attention, and a bottleneck width that is a visible hyperparameter rather than an emergent property of training\.

### IV\-AAblation Studies

The three ablations mentioned in this section describe the design choices we made in our work\. This section’s ablations are all inference\-time on the held\-out C4 validation set using hyperparameters that are changed one at a time while keeping the others fixed\. Table[V](https://arxiv.org/html/2609.30288#S4.T5)tests whether the iterative refinement loop itself is doing real work by varying the number of refinement iterationsTTfrom 1 to 6\. Accuracy improves from 6\.4% atT=1T=1to 38% atT=6T=6\. This indicates that a single feed\-forward mixing pass, of the kind used in prior attention\-free architectures, should be completed with an iterative, autoencoder\-based refinement component\.

Table[V](https://arxiv.org/html/2609.30288#S4.T5)tests, by changingα\\alphain each refinement step, the weight given to the mixing\-derived embedding and the distance\-weighted neighbor\. Inα→0\\alpha\\to 0, pure neighbor\-mean and no mixing signal, loss 5\.4, accuracy 25\.8%, confirming that the mixing\-derived embedding is an essential signal\. The trained value ofα\\alpha, sits inside the good region rather than at an accidental amount\.

Table[V](https://arxiv.org/html/2609.30288#S4.T5)tests whether the residual connection is necessary by varying the step sizeγ\\gamma\. Both a smaller step \(γ=0\.2\\gamma=0\.2: loss 11\) and a larger one \(γ=0\.8\\gamma=0\.8: loss 9\.8\) degrade the performance of the model\. The trained valueγ=0\.4\\gamma=0\.4is a clear optimum\. This demonstrates that the residual formulation of the refinement update represents a specific operating point the model has adapted to, rather than just a training\-stability convenience\. Perplexity formulation iselosse^\{\\text\{loss\}\}, so it grows extremely fast\. Moving away from the configuration we identified as optimal, a step size far from the trainedγ=0\.4\\gamma=0\.4drives it very high\. We report these numbers as they are\. Rather than a computation error, they confirm how sharply performance depends on the operating point we found, and how poorly the model does once it is moved away from it\.

As a result, the three ablation tests demonstrate that none ofTT,α\\alpha, orγ\\gammais a free parameter, each is an optimum at its trained value, and moving away from it causes the model to fail\. This is evidence that the pulling\-correcting mechanism is functioning as designed, not as an incidental architectural choice\.

## VConclusion

In our work, we investigated whether context mixing requires self\-attention’s pairwise query\-key comparison, or whether an autoencoder with a bottleneck and an iterative refinement process could replace it\. This question has a theoretical basis: under a shared Gaussian noise model, a noise\-augmented autoencoder and self\-attention reduce to the same closed\-form estimator, a connection\[[16](https://arxiv.org/html/2609.30288#bib.bib27)\]establish directly and extend to denoising diffusion models as well\.

In our work, we replace attention with a hierarchy of autoencoders \(WindowMixAE, GlobalMixAE, and ChannelMixAE\), each compressing and reconstructing its input through a bottleneck whose width is a hyperparameter\. Then, with an initial embedding produced via our mixing module, we iterate a refinement loop which consists of pulling\-correcting steps\.

We believe that our results are comparable to attention mechanisms while requiring significantly lower computational cost\. Our model exceeds attention on single\-sentence tasks \(CoLA, SST\-2\) that can be solved from one segment’s surface\-level or lexical properties, but falls behind the attention performance on tasks that require relating two separate parts of text \(Table[III](https://arxiv.org/html/2609.30288#S3.T3)\)\. It is the pairwise, content\-dependent comparison that attention computes, and our architecture decreases this computational cost\.

The gap is narrower on rare tokens specifically\. Accuracy on the rarest frequency bucket \(\[5k\), Table[I](https://arxiv.org/html/2609.30288#S3.T1)\) matches or slightly exceeds all three attention baselines\. It required both the frequency\-aware training schedule and ChunkedContentBias together\. This is because of the frequency\-aware masking and loss\-weighting schedule described in Section[III](https://arxiv.org/html/2609.30288#S3), underscoring that training procedure matters here just as much as architectural design\.

Our model architecture has1\.9×1\.9\\timesfewer FLOPs at the sequence lengths we test in Table[IV](https://arxiv.org/html/2609.30288#S4.T4)\. Our ablations show that the refinement loop’s three central hyperparameters,TT,α\\alpha, andγ\\gamma, each sit at an optimum point, and removing them causes the model to fail \(Section[IV\-A](https://arxiv.org/html/2609.30288#S4.SS1)\), evidence that the pulling\-correcting mechanism is doing the work we designed it to do\. We leave the larger\-scale evaluation and flexibility of length in the mixing modules with pooling, or dynamically produced weights, to future work\.

## References

- \[1\]A\. Vaswani, N\. Shazeer, N\. Parmar, J\. Uszkoreit, L\. Jones, A\. N\. Gomez, Ł\. Kaiser, and I\. Polosukhin\(2017\)Attention is all you need\.InAdvances in Neural Information Processing Systems \(NeurIPS\),Vol\.30\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p1.1),[§III\-E](https://arxiv.org/html/2609.30288#S3.SS5.p3.6)\.
- \[2\]J\. Devlin, M\. Chang, K\. Lee, and K\. Toutanova\(2019\)BERT: pre\-training of deep bidirectional transformers for language understanding\.InProceedings of NAACL\-HLT,pp\. 4171–4186\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p1.1),[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p1.1),[§III\-F](https://arxiv.org/html/2609.30288#S3.SS6.p1.1)\.
- \[3\]I\. O\. Tolstikhin, N\. Houlsby, A\. Kolesnikov, L\. Beyer, X\. Zhai, T\. Unterthiner, J\. Yung, A\. Steiner, D\. Keysers, J\. Uszkoreit, M\. Lucic, and A\. Dosovitskiy\(2021\)MLP\-Mixer: an all\-MLP architecture for vision\.InAdvances in Neural Information Processing Systems \(NeurIPS\),Vol\.34\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p2.1),[§II\-B](https://arxiv.org/html/2609.30288#S2.SS2.p1.1)\.
- \[4\]H\. Liu, Z\. Dai, D\. So, and Q\. V\. Le\(2021\)Pay attention to MLPs\.InAdvances in Neural Information Processing Systems \(NeurIPS\),Vol\.34\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p2.1),[§II\-B](https://arxiv.org/html/2609.30288#S2.SS2.p1.1)\.
- \[5\]J\. Lee\-Thorp, J\. Ainslie, I\. Eckstein, and S\. Ontanon\(2022\)FNet: mixing tokens with Fourier transforms\.InProceedings of NAACL\-HLT,pp\. 4296–4313\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p2.1),[§II\-B](https://arxiv.org/html/2609.30288#S2.SS2.p1.1)\.
- \[6\]Y\. Tay, D\. Bahri, D\. Metzler, D\. Juan, Z\. Zhao, and C\. Zheng\(2021\)Synthesizer: rethinking self\-attention for transformer models\.InProceedings of ICML,pp\. 10183–10192\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p2.1),[§II\-B](https://arxiv.org/html/2609.30288#S2.SS2.p1.1)\.
- \[7\]F\. Mai, A\. Pannatier, F\. Fehr, H\. Chen, F\. Marelli, F\. Fleuret, and J\. Henderson\(2023\)HyperMixer: an MLP\-based low cost alternative to transformers\.InProceedings of the 61st Annual Meeting of the ACL \(Volume 1: Long Papers\),Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p2.1),[§II\-B](https://arxiv.org/html/2609.30288#S2.SS2.p2.1),[§III\-F](https://arxiv.org/html/2609.30288#S3.SS6.p3.1)\.
- \[8\]I\. Kuzborskij and Y\. Abbasi Yadkori\(2025\)Low\-rank bias, weight decay, and model merging in neural networks\.arXiv preprint arXiv:2502\.17340\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p3.1),[§II\-C1](https://arxiv.org/html/2609.30288#S2.SS3.SSS1.p1.1),[§II\-C1](https://arxiv.org/html/2609.30288#S2.SS3.SSS1.p3.1),[Theorem 1](https://arxiv.org/html/2609.30288#Thmtheorem1)\.
- \[9\]L\. Jing, J\. Zbontar, and Y\. LeCun\(2020\)Implicit rank\-minimizing autoencoder\.InAdvances in Neural Information Processing Systems \(NeurIPS\),Vol\.33\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p3.1),[§II\-C2](https://arxiv.org/html/2609.30288#S2.SS3.SSS2.p1.1),[§II\-C2](https://arxiv.org/html/2609.30288#S2.SS3.SSS2.p2.1),[Theorem 2](https://arxiv.org/html/2609.30288#Thmtheorem2)\.
- \[10\]M\. Huh, H\. Mobahi, R\. Zhang, B\. Cheung, P\. Agrawal, and P\. Isola\(2022\)The low\-rank simplicity bias in deep networks\.Transactions on Machine Learning Research\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p3.1),[§II\-C3](https://arxiv.org/html/2609.30288#S2.SS3.SSS3.p1.1),[Theorem 3](https://arxiv.org/html/2609.30288#Thmtheorem3)\.
- \[11\]E\. A\. Nadaraya\(1964\)On estimating regression\.Theory of Probability & Its Applications9\(1\),pp\. 141–142\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p4.1)\.
- \[12\]G\. S\. Watson\(1964\)Smooth regression analysis\.Sankhyā: The Indian Journal of Statistics, Series A26\(4\),pp\. 359–372\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p4.1)\.
- \[13\]Y\. H\. Tsai, S\. Bai, M\. Yamada, L\. Morency, and R\. Salakhutdinov\(2019\)Transformer dissection: an unified understanding for transformer’s attention via the lens of kernel\.InProceedings of EMNLP\-IJCNLP,Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p4.1)\.
- \[14\]C\. M\. Bishop\(1995\)Neural networks for pattern recognition\.Oxford University Press\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p4.1),[§III\-E](https://arxiv.org/html/2609.30288#S3.SS5.p1.1)\.
- \[15\]J\. Henderson and F\. Fehr\(2022\)A variational autoencoder for transformers with nonparametric variational information bottleneck\.arXiv preprint arXiv:2207\.13529\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p4.1),[§III\-E](https://arxiv.org/html/2609.30288#S3.SS5.p1.1)\.
- \[16\]F\. Haddadi, L\. Monfared, E\. Rezaii, M\. Malek\-Mohammadi, P\. Zakalvand, and N\. Mokhtari\(2026\)Denoising diffusion generative models secretly calculate attentions\.arXiv preprint arXiv:2609\.00885\.Cited by:[§I](https://arxiv.org/html/2609.30288#S1.p5.1),[item 2](https://arxiv.org/html/2609.30288#S3.I1.i2.p1.1),[§III\-E](https://arxiv.org/html/2609.30288#S3.SS5.p3.6),[§V](https://arxiv.org/html/2609.30288#S5.p1.1)\.
- \[17\]Y\. Liu, M\. Ott, N\. Goyal, J\. Du, M\. Joshi, D\. Chen, O\. Levy, M\. Lewis, L\. Zettlemoyer, and V\. Stoyanov\(2019\)RoBERTa: a robustly optimized BERT pretraining approach\.arXiv preprint arXiv:1907\.11692\.Cited by:[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p2.1)\.
- \[18\]Z\. Lan, M\. Chen, S\. Goodman, K\. Gimpel, P\. Sharma, and R\. Soricut\(2020\)ALBERT: a lite BERT for self\-supervised learning of language representations\.InInternational Conference on Learning Representations \(ICLR\),Cited by:[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p2.1)\.
- \[19\]K\. Clark, M\. Luong, Q\. V\. Le, and C\. D\. Manning\(2020\)ELECTRA: pre\-training text encoders as discriminators rather than generators\.InInternational Conference on Learning Representations \(ICLR\),Cited by:[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p2.1)\.
- \[20\]M\. Lewis, Y\. Liu, N\. Goyal, M\. Ghazvininejad, A\. Mohamed, O\. Levy, V\. Stoyanov, and L\. Zettlemoyer\(2020\)BART: denoising sequence\-to\-sequence pre\-training for natural language generation, translation, and comprehension\.InProceedings of the 58th Annual Meeting of the ACL,pp\. 7871–7880\.Cited by:[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p3.1)\.
- \[21\]Z\. Dai, G\. Lai, Y\. Yang, and Q\. Le\(2020\)Funnel\-transformer: filtering out sequential redundancy for efficient language processing\.InAdvances in Neural Information Processing Systems \(NeurIPS\),Vol\.33\.Cited by:[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p5.1)\.
- \[22\]P\. Nawrot, S\. Tworkowski, M\. Tyrolski, L\. Kaiser, Y\. Wu, C\. Szegedy, and H\. Michalewski\(2022\)Hierarchical transformers are more efficient language models\.InFindings of the Association for Computational Linguistics: NAACL 2022,pp\. 1559–1571\.Cited by:[§II\-A](https://arxiv.org/html/2609.30288#S2.SS1.p5.1)\.
- \[23\]S\. S\. Sahoo, M\. Arriola, A\. Gokaslan, E\. M\. Marroquin, A\. M\. Rush, Y\. Schiff, J\. T\. Chiu, and V\. Kuleshov\(2024\)Simple and effective masked diffusion language models\.InAdvances in Neural Information Processing Systems \(NeurIPS\),Vol\.38\.Cited by:[§II\-B](https://arxiv.org/html/2609.30288#S2.SS2.p3.1)\.
- \[24\]N\. Timor, G\. Vardi, and O\. Shamir\(2023\)Implicit regularization towards rank minimization in relu networks\.InProceedings of the 34th International Conference on Algorithmic Learning Theory,Proceedings of Machine Learning Research, Vol\.201\.Cited by:[§II\-C1](https://arxiv.org/html/2609.30288#S2.SS3.SSS1.p1.1)\.
- \[25\]S\. Arora, N\. Cohen, and E\. Hazan\(2018\)On the optimization of deep networks: implicit acceleration by overparameterization\.InProceedings of ICML,pp\. 244–253\.Cited by:[Theorem 2](https://arxiv.org/html/2609.30288#Thmtheorem2)\.
- \[26\]O\. Roy and M\. Vetterli\(2007\)The effective rank: a measure of effective dimensionality\.In15th European Signal Processing Conference \(EUSIPCO\),pp\. 606–610\.Cited by:[Definition 2](https://arxiv.org/html/2609.30288#Thmdefinition2)\.
- \[27\]C\. Raffel, N\. Shazeer, A\. Roberts, K\. Lee, S\. Narang, M\. Matena, Y\. Zhou, W\. Li, and P\. J\. Liu\(2020\)Exploring the limits of transfer learning with a unified text\-to\-text transformer\.Journal of Machine Learning Research21\(140\),pp\. 1–67\.Cited by:[§III\-F](https://arxiv.org/html/2609.30288#S3.SS6.p2.1)\.

相似文章

Intern-Decision:基于自回归掩码语言建模的高效多模态决策

Hugging Face Daily Papers

Intern-Decision 引入了一系列紧凑型(0.8B/2B/4B)多模态决策模型,采用自回归掩码语言建模目标,在单次因果前向传播中输出带概率的结构化选择,在七个基准上达到 90.02% 的平均准确率,并具有低延迟,适用于交互式智能体。

PreDiff-LM: 预训练离散掩码扩散语言建模与混合注意力

arXiv cs.AI

PreDiff-LM 提出了一种混合注意力机制,该机制对提示令牌保持因果注意力,对掩码目标令牌使用双向注意力,从而使得预训练自回归模型能够适应离散掩码扩散语言建模,在困惑度和下游任务上相较于先前的扩散基线取得了改进。