Manuscript Offprint
arXiv:2610.36703RankFormer: Rethinking Time Series Transformers through Representation Capacity Analysis and Progressive Decoding
Abstract
Multivariate time series forecasting plays a critical role in Web and cyber-physical systems, where large-scale services and IoT infrastructures generate complex temporal data. Transformer-based models have achieved strong empirical performance in this domain, yet the principles governing the expressive capacity of their learned representations remain insufficiently understood. Moreover, many existing models rely on simplified decoding strategies, including channel-independent modeling and direct projection heads, which limit their ability to capture complex multivariate dynamics. To address these challenges, we propose RankFormer, a novel encoder-decoder architecture for multivariate time series forecasting. We establish a rank-based analysis framework to investigate how tokenization, embedding, and attention designs affect the representation capacity of time series Transformers. Our analysis reveals that patchification increases the potential representation capacity by aggregating multiple temporal observations into each token, while subsequent encoding operations determine how much of this capacity is realized. Guided by these insights, we develop a rank-enhancing encoder with Hourglass Attention to improve rank stability during information interaction. Furthermore, we introduce the Interactive Progressive Decoder (IPD), which improves future trajectory modeling through global-guided cross-channel interaction and progressive refinement. Extensive experiments on real-world long-term forecasting benchmarks demonstrate that RankFormer achieves competitive performance against state-of-the-art methods. Code repository: https://github.com/TangPeiwang/Rankformer.
CCS Concepts
• Computing methodologies → Artificial intelligence.
Keywords
Time Series, Representation Capacity, Hourglass Attention, Interactive Progressive Decoder
This limited understanding raises two fundamental questions:
First, how do encoder architectures create and preserve expressive representations? Existing time series Transformers improve representation capability through various encoding designs, including tokenization, embedding, and attention mechanisms, yet how these components jointly shape the capacity of learned temporal representations remains insufficiently understood. Patchification provides a representative example: by aggregating multiple temporal observations into each token, it expands the attainable representation space compared with point-wise tokenization. However, the realized representation capacity is further shaped by subsequent encoding operations. Linear embeddings introduce rank constraints, while bidirectional attention (BiA) may cause excessive token mixing and representation homogenization, leading to rank degeneration [4, 18, 22, 35]. Although unidirectional attention provides stronger rank stability, its restricted receptive field limits global information interaction. Consequently, existing attention designs struggle to simultaneously maintain representation diversity and achieve effective cross-token information exchange, limiting the ability of time series Transformers to fully exploit their representation space.
Second, how can forecasting decoders fully exploit the learned representations? Although modern encoders can produce increasingly expressive latent features, many existing forecasting architectures still rely on simplified decoding strategies. Channel-independent modeling limits cross-variable interaction, while one-shot projection heads such as Flatten-Linear map encoded representations to the entire prediction horizon through a fixed transformation. Such designs overlook the evolving temporal organization and provide limited capability for progressively refining complex future trajectories, which is particularly restrictive for multivariate forecasting with strong cross-channel dependencies.
To address these challenges, we propose RankFormer, a principled encoder-decoder architecture for multivariate time series forecasting. For the encoder, we establish a rank-based analysis framework to analyze how patchification, embedding, and attention
Corresponding author.

(a)
Causal Attention

Hourglass Attention
(b)
Figure 1: Empirical validation of rank stability and Hourglass Attention (HgA). (a) Rapid singular value decay shows bidirectional attention induces deep-layer rank collapse, while causal masking preserves representational diversity. (b) Causal masking restricts early tokens (starvation). In contrast, HgA uses a symmetric prefix as a global hub, enabling efficient context retrieval while maintaining rank stability.
topology shape the effective capacity of learned temporal representations. Based on these observations, we introduce Hourglass Attention (HgA) to improve rank stability during attention-based interaction, preserving diverse representations while enabling effective global information exchange. For the decoder, we develop an Interactive Progressive Decoder (IPD), which enhances future trajectory generation through global-context-guided cross-channel interaction and progressive refinement. Together, RankFormer provides a principled approach to improving representation learning and future trajectory modeling in time series Transformers.
Our main contributions are summarized as follows:
-
We provide a rank-based analysis of time series Transformer encoders, revealing how patchification, embedding, and attention operations affect representation capacity and offering a theoretical explanation for the effectiveness of patch-based modeling.
-
We propose RankFormer, consisting of HgA and IPD. HgA preserves expressive representations through improved attention design, while IPD captures cross-channel dependencies and progressively refines future trajectories.
-
Extensive experiments on widely used long-term forecasting benchmarks validate the theoretical observations and demonstrate consistently strong performance against competitive state-of-the-art methods.
2 Rank Theory Analysis and Key Theorems
In this section, we establish a rank-based theoretical framework to analyze the core components of time series Transformers. We consider the forecasting problem as learning a mapping from historical observations to future sequences . The model first transforms the input sequence into hidden representations , whose structure determines how much independent information can be preserved for subsequent forecasting. We use matrix rank, rank( ), as a quantitative measure to characterize the independent information capacity of hidden representations. A higher rank indicates more independent representation directions and greater potential to preserve diverse information, whereas rank degradation suggests increased redundancy and reduced representation diversity.
2.1 Patching as a Rank Expansion Mechanism
When a univariate sequence is represented through pointwise tokenization, the resulting token matrix has a single feature dimension, and any linear embedding inherits a rank upper bound of one:
PROPOSITION 1 (RANK EXPANSION VIA PATCHING). Partitioning x into patches of length P and arranging them into a patch matrix , where , gives the attainable rank upper bound:
When , patching expands the maximum attainable rank bound from one to , increasing the potential number of independent directions available for subsequent representation learning. This provides a rank-based perspective for understanding the effectiveness of patch-based modeling in time series Transformers.
2.2 Embedding Layer: Breaking Linear Rank Constraints
To map the patched representation into a hidden representation , standard linear projections ( ) preserve the rank constraint of the input representation:
When , linear embeddings remain constrained by the patch-induced rank bound, limiting the number of independent directions that can be represented in the hidden space.
To overcome this linear rank constraint, we consider nonlinear MLP embeddings:
THEOREM 1 (MAXIMUM RANK EMBEDDING). Let be a continuous, non-polynomial activation function. For any distinct input patches , there exist MLP parameters such that the resulting hidden representation achieves the maximum attainable rank:
This theorem shows that nonlinear embeddings overcome the additional rank restriction imposed by linear projections, allowing
RankFormer: Rethinking Time Series Transformers through Representation Capacity Analysis and Progressive Decoding

Figure 2: Overall structure of RankFormer. The model preprocesses multivariate time series via Instance Norm and CI, utilizing Patch Embedding and a Multi-Head Hourglass Attention encoder to generate a base prediction. An Interactive Progressive Decoder then refines these features. It trains via one-step residual learning using randomized partial ground truth, while inference employs a T-step progressive refinement from a zero-residual state, concluding with Instance Denorm.
hidden representations to achieve their maximum attainable rank determined by the sample and hidden dimensions.
2.3 Attention Mechanisms: Rank Preservation via Attention Topology
BiA enables global information aggregation across tokens, but its dense mixing structure does not provide an explicit guarantee for preserving representation rank. Repeated dense token mixing may lead to representation homogenization and rank degradation in deep networks [18, 22].
To analyze how attention topology affects rank stability, we compare BiA with unidirectional (e.g., causal) attention. Let and denote their attention weight matrices, and let and denote the corresponding outputs after value projection and output projection.
THEOREM 2 (RANK PRESERVATION OF CAUSAL ATTENTION). Given identical projection parameters , causal attention preserves the rank of the value representation and guarantees:
Theorem 2 establishes that causal masking provides a structural rank-preservation property during attention aggregation. In contrast, BiA may reduce output rank when its learned aggregation fails to preserve independent information directions in the value representation (as shown in Figure 1(a)). This analysis highlights the importance of attention topology in maintaining diverse representations during token interaction. Rather than favoring a specific topology, it motivates attention designs that preserve rank stability while enabling effective information exchange, leading to our proposed Hourglass Attention.
3 RankFormer
Guided by the rank-based theoretical framework established above, we propose RankFormer, as illustrated in Figure 2. The architecture consists of a rank-guided encoder with HgA, which improves rank stability during attention-based interaction, and an IPD, which captures complex future trajectories through global-context-guided cross-channel interaction and progressive refinement.
3.1 Patch Embedding
To mitigate the adverse effects of magnitude variations across different variables, we first apply standard instance normalization to the input sequence X along the temporal dimension. The normalized time series is then partitioned into patches of length P, transforming the input into , where N is the number of patches. As elucidated in Proposition 1, this patching operation structurally expands the rank capacity of the input representation.
Subsequently, to break the inherent rank bound of linear projections, we map these patches into the hidden space using a two-layer MLP with a ReLU activation [16]:
where and . As mathematically guaranteed by Theorem 1, this nonlinear formulation ensures that the embedding achieves the theoretical maximum rank of , fully utilizing the representational potential of the high-dimensional hidden space.
3.2 Hourglass Attention
BiA enables global information aggregation across tokens, but repeated dense mixing may cause representation homogenization and rank degradation in deep networks. In contrast, causal attention

Figure 3: Internal architecture of the Interactive Progressive Decoder.
provides a structural rank-preservation guarantee through its triangular topology, but its directional information flow limits efficient context exchange across tokens. To combine these complementary properties, we propose HgA, a topology-aware attention mechanism that reorganizes causal connectivity to maintain rank stability while enabling more effective information interaction.
HgA introduces an hourglass-shaped attention topology through three design principles. First, early tokens are assigned broader receptive fields to aggregate global context from the observed sequence. Second, intermediate tokens use restricted receptive fields to reduce excessive token mixing and maintain representation diversity. Third, receptive fields gradually expand toward later tokens, preserving detailed recent information for downstream forecasting. Together, these designs redistribute information access within the sequence while retaining the rank-stability property inherited from causal attention.
HgA is constructed by a topology-preserving reordering of causal attention. For an input sequence of length , we define as the maximum visible key index of query position under this reordering:
This mapping creates an hourglass-shaped receptive field: the visible range contracts toward the sequence center and expands toward the sequence end. The corresponding mask is:
The attention operation is:
Since HgA is obtained through a reordering of causal connectivity, its attention matrix retains the rank-preservation property of causal attention while providing a different receptive field allocation.
3.3 Interactive Progressive Decoder
The IPD (Figure 3) addresses the mapping bottleneck by transforming channel-independent encoder representations into multivariate forecasts. It first generates a channel-wise base prediction, then introduces cross-channel conditioning to incorporate interactions among variables, and finally refines the prediction through progressive residual updates.
Base Prediction. IPD first obtains a channel-independent base prediction from the flattened encoder representations using a shared linear projection. We denote the initial prediction of channel as , where is the forecast horizon. This base prediction provides the initialization for subsequent cross-channel conditioning and progressive residual refinement.
Cross-channel Conditioning. To introduce multivariate interactions while preserving channel-specific information, IPD constructs an interaction-aware conditioning representation for each channel. The base prediction is first projected into a feature space:
A learnable channel embedding is combined with the prediction feature:
where represents the channel-specific conditioning feature.
The cross-channel branch transforms each channel representation into a message feature:
For channel , the received information from other variables is aggregated as:
where denotes the learnable channel interaction matrix.
RankFormer: Rethinking Time Series Transformers through Representation Capacity Analysis and Progressive Decoding
Table 1: Results of the Long-Term Time Series Forecasting. All baseline models were configured consistently with SEER. The reported results represent the average performance over four distinct forecasting horizons: {96, 192, 336, 720}.
| Models | RankFormer (ours) | SEER (2026) | SRSNet (2025) | DUET (2025) | xPatch (2025) | Amplifier (2025) | FredFormer (2024) | iTransformer (2024) | PatchTST (2023) | DLinear (2023) | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | |
| ETTh1 | ||||||||||||||||||||
| ETTh2 | ||||||||||||||||||||
| ETTm1 | ||||||||||||||||||||
| ETTm2 | ||||||||||||||||||||
| Weather | ||||||||||||||||||||
| Solar | ||||||||||||||||||||
| Electricity | ||||||||||||||||||||
| Traffic | ||||||||||||||||||||
| Count | ||||||||||||||||||||
The own-channel feature and cross-channel message jointly generate horizon-wise modulation parameters:
The conditioned prediction is obtained through ReZero modulation:
where is initialized to zero.
Progressive Residual Refinement. Instead of directly mapping encoder representations to the future sequence through a static projection, IPD models forecasting as residual refinement from an intermediate prediction state.
During training, a completion ratio is sampled to construct:
where is the normalized ground-truth sequence and controls the noise magnitude.
The residual correction is predicted as:
The final training prediction is:
Offline-folded Inference. During inference, IPD initializes the prediction state as and performs residual updates:
Since the residual update is affine in the prediction state and remains fixed across iterations, the updates can be analytically combined. Specifically, defining
the final prediction becomes
where and . These equivalent parameters are precomputed after training, allowing IPD to reproduce the progressive refinement through a single affine mapping during inference.
4 Experiments
We evaluate RankFormer on diverse real-world long-term time series forecasting benchmarks spanning Web- and IoT-relevant applications, demonstrating its superior representational capacity and stable progressive decoding against state-of-the-art (SOTA) baselines.
Datasets. We evaluate our model on nine widely adopted real-world benchmarks: Electricity, Traffic, Weather, Exchange-Rate, Solar, and four ETT datasets (ETTh1, ETTh2, ETTm1, ETTm2). These datasets cover diverse applications relevant to Web and IoT systems, including transportation, energy management, and environmental monitoring, alongside financial forecasting.
Baselines. We benchmark RankFormer against 9 recent SOTA forecasting models. To ensure a comprehensive evaluation, these baselines encompass advanced Transformer-based architectures (SEER [20], iTransformer [12], PatchTST [17], Fredformer [19]), linear-centric networks (DLinear [36]), and other highly competitive contemporary approaches (SRSNet [31], DUET [21], xPatch [24], Amplifier [6]).
Experimental Setup. We evaluate all models under standard long-term forecasting settings, . Performance is measured by Mean Squared Error (MSE) and Mean Absolute Error (MAE). Baseline results are taken from original publications or reproduced using official implementations under the same settings.
4.1 Main Results
As shown in Table 1, we evaluate the long-term forecasting performance of RankFormer against SOTA baselines. All models use a fixed input sequence length of 96, with results averaged across four forecasting horizons. RankFormer demonstrates comprehensive superiority, achieving the best MSE and MAE on 7 out of 8 benchmark datasets (securing 14 out of 16 top metrics). While the recent SEER model shows competitive performance and achieves the best results on the Traffic dataset, RankFormer maintains a strong second place with marginal differences. Compared with established baselines such as PatchTST and iTransformer, RankFormer achieves lower forecasting errors across diverse applications relevant to Web and IoT systems, including energy management (Solar) and environmental monitoring (Weather). These results demonstrate the strong and consistent forecasting performance of RankFormer across diverse real-world scenarios.
4.2 Representation Capacity Analysis

(a) Beyond the Rank-5 Bottleneck
(b) Predictive Value of Additional Directions
Figure 4: Predictive benefits of additional embedding rank capacity. Lines show three-seed means, small dots show individual seeds, and dashed curves show the MSE lower bound for rank-at-most-five predictions.
4.2.1 Predictive Value of Embedding Rank Expansion. We construct synthetic targets with controlled rank to evaluate the predictive benefit of nonlinear embeddings. We compare linear, parameter-matched affine, and MLP embeddings using identical attention and prediction heads that preserve the embedding rank constraints. Both affine embeddings have a rank upper bound of five. Figure 4(a) shows comparable performance at target rank 4. At higher target ranks, the MLP achieves MSE below the rank-five lower bound, while affine embeddings remain constrained. In (b), increasing the contribution of higher-rank target components substantially degrades the rank-constrained MLP, whereas the unconstrained MLP maintains stable performance. These results demonstrate that nonlinear embeddings can exploit higher attainable rank to improve prediction when target structures exceed the linear rank constraint.
4.2.2 Impact of Representation Rank Constraints. To investigate the impact of representation rank constraints on forecasting, we impose rank limits of 1, 4, and 8 on position-enriched patch representations in a standard Transformer encoder. The constraints are maintained during training and inference, with all other settings unchanged. Table 2 shows that rank-one and rank-four constraints consistently increase MSE and MAE across datasets, whereas the relaxed rank-eight constraint largely restores performance toward the unconstrained baseline. Notably, this degradation persists despite the presence of FFNs and residual connections. These results demonstrate that restrictive representation rank constraints can impair forecasting performance, supporting the importance of preserving sufficient independent representation directions.
Table 2: Forecasting performance under different rank constraints on position-enriched embeddings. The best results are in bold.
| Dataset | Unconstrained | Rank ≤ 1 | Rank ≤ 4 | Rank ≤ 8 | ||||
|---|---|---|---|---|---|---|---|---|
| MSE | MAE | MSE | MAE | MSE | MAE | MSE | MAE | |
| ETTh1 | 0.503 | 0.469 | 0.549 | 0.511 | 0.509 | 0.473 | 0.504 | 0.472 |
| ETTh2 | 0.380 | 0.414 | 0.385 | 0.417 | 0.398 | 0.421 | 0.383 | 0.414 |
| ETTm1 | 0.369 | 0.390 | 0.385 | 0.402 | 0.372 | 0.393 | 0.372 | 0.392 |
| ETTm2 | 0.271 | 0.326 | 0.273 | 0.327 | 0.274 | 0.327 | 0.270 | 0.324 |
| Weather | 0.228 | 0.263 | 0.231 | 0.266 | 0.231 | 0.266 | 0.229 | 0.265 |
| Exchange | 0.391 | 0.423 | 0.430 | 0.443 | 0.416 | 0.437 | 0.397 | 0.425 |

Figure 5: Effect of Network Depth on Forecasting with Different Pure Attention Mechanisms.
Table 3: Performance comparison of six-layer pure-attention models. The best results are in bold.
| Method | Metric | ETTh1 | ETTh2 | ETTm1 | Weather | Exchange |
|---|---|---|---|---|---|---|
| BiA | MSE | 0.710 | 0.418 | 0.648 | 0.279 | 0.375 |
| MAE | 0.583 | 0.433 | 0.530 | 0.303 | 0.414 | |
| HgA | MSE | 0.510 | 0.407 | 0.421 | 0.273 | 0.371 |
| MAE | 0.480 | 0.428 | 0.422 | 0.293 | 0.412 |
4.2.3 Robustness to Increasing Attention Depth. To evaluate the impact of attention depth, we compare BiA, causal attention, and HgA in pure-attention networks with one to six stacked attention layers. All variants share the same architecture except for the attention mechanism. Figure 5 shows that BiA suffers from substantial performance degradation as attention depth increases, whereas HgA maintains more stable forecasting performance. Causal attention also improves depth robustness, but its performance varies across datasets. Table 3 further demonstrates that HgA achieves consistent improvements over BiA across multiple datasets, especially in deeper attention stacks. These results indicate that HgA improves robustness under increasingly deep attention interactions by preserving more stable representations. This empirical behavior is consistent with the rank-preservation analysis, showing that attention topology plays an important role in maintaining representation diversity during deep information exchange.
4.2.4 Effect of Training-Time Attention Rank Constraints. To investigate how attention rank constraints affect forecasting performance, we impose rank constraints with on every attention head of a six-layer HgA model. The constrained models
RankFormer: Rethinking Time Series Transformers through Representation Capacity Analysis and Progressive Decoding
Table 4: Training-Time Attention Rank Constraints in Six-Layer Pure HgA. For the rank-constrained columns, values are percentage changes relative to the Unconstrained model.
| Dataset | Unconstrained | rank(A) ≤ 1 | rank(A) ≤ 3 | |||
|---|---|---|---|---|---|---|
| MSE | MAE | MSE | MAE | MSE | MAE | |
| ETTh1 | 0.510 | 0.481 | +12.44 | +7.36 | +0.23 | +0.04 |
| ETTh2 | 0.406 | 0.427 | +0.93 | -0.55 | +1.88 | +0.72 |
| ETTm1 | 0.422 | 0.421 | +37.72 | +19.04 | +7.27 | +3.89 |
| ETTm2 | 0.293 | 0.338 | +6.92 | +4.07 | +3.60 | +2.02 |
| Weather | 0.273 | 0.293 | +6.83 | +6.70 | +4.47 | +3.93 |
| Exchange | 0.372 | 0.413 | +8.04 | +5.66 | +3.97 | +2.71 |
| Solar | 0.306 | 0.326 | +50.40 | +40.08 | +8.53 | +7.52 |
| Forward Order | Reverse Order | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| ETTh1 | -0.8 | -0.5 | -0.4 | -0.0 | -19.1 | -17.0 | -17.0 | -10.8 | 40200-20-40 |
| ETTh2 | +0.7 | +0.8 | +2.8 | -4.8 | -10.9 | -22.9 | -25.9 | -5.0 | |
| ETTm1 | -6.7 | -3.8 | -3.0 | -1.6 | -41.1 | -38.9 | -37.6 | -31.6 | |
| ETTm2 | -7.0 | -2.5 | +6.9 | +1.9 | -12.9 | -15.4 | -26.8 | -15.7 | |
| Weather | -2.2 | -0.2 | -1.1 | -0.2 | -35.0 | -21.2 | -17.8 | -15.6 | |
| Solar | -2.5 | -3.2 | -3.3 | -2.4 | -57.9 | -49.9 | -50.9 | -52.2 | |
| 96 | 192 | 336 | 720 | 96 | 192 | 336 | 720 | ||
| Prediction horizon | Prediction horizon | ||||||||
Figure 6: Forecasting Comparison of HgA and Causal Attention under Different Token Orders.
are trained under the same settings as the unconstrained baseline. Table 4 shows that restricting attention rank consistently degrades forecasting performance across datasets. Severe rank constraints () lead to substantial performance drops, while a relaxed constraint () reduces the degradation. These results demonstrate that overly restrictive attention rank constraints can impair the effectiveness of HgA, supporting the role of maintaining sufficient representation diversity during attention interaction.
4.2.5 Predictive Value of Information Pathways. To evaluate the predictive value of HgA's information pathways, we compare HgA with causal attention under forward and reversed token orders, using the same original latest patch as the prediction readout in both settings. Reversing token order changes the information accessible through causal attention, allowing us to assess the contribution of HgA's additional cross-token interactions. Figure 6 shows that HgA outperforms causal attention on most forward-order tasks, with more pronounced improvements under reversed order, where HgA achieves lower MSE on all 24 tasks shown. These results highlight the predictive value of HgA's information pathways, demonstrating its ability to effectively integrate cross-token information while maintaining rank stability.
4.2.6 Empirical Validation of Rank Theory. To empirically validate our theoretical framework, we visualize the rank distributions of intermediate representations in Figure 7 and 8. First, the Figure 7 demonstrate that our nonlinear MLP embedding explicitly breaks

Figure 7: Rank distributions of embedding matrices with patch sizes (ETTm2) and (Weather).

Figure 8: Rank distributions of attention matrices on Weather and ETTm2.
the rank-1 bottleneck inherent to linear projections. It consistently drives the representations toward high-rank states, closely approaching the theoretical maximum (validating Theorem 1). Second, the Figure 8 compare the attention weight matrices. While standard BiA suffers from severe rank collapse, evidenced by a widespread long-tail distribution toward lower ranks, HgA consistently locks at the maximum rank across all test samples. This confirms that HgA effectively preserves representational diversity and circumvents rank-deficient topologies, perfectly aligning with Theorem 2.
4.3 Interactive Progressive Decoder Analysis
4.3.1 Analysis of Progressive Refinement. We investigate the effectiveness of progressive refinement by examining prediction accuracy, error correction, and inference efficiency. Using fixed checkpoints, we evaluate different refinement steps across multiple forecasting horizons. Figure 9 shows that ETTm1 benefits primarily from a few refinement steps, whereas Exchange continues to improve as increases, indicating dataset-dependent sensitivity to refinement depth.
To understand what refinement corrects, we decompose forecasting errors into level, linear-trend, and remaining-shape components. Figure 10 shows that increasing from 1 to 5 improves MSE and MAE across all six evaluated datasets at , with different dominant correction components across datasets.
Finally, we evaluate the efficiency of offline-folded inference. The folded predictions match explicit iterative updates within numerical precision while avoiding online iterations. As shown in Figure 11, at , offline folding achieves median speedups of for the refinement module and for the full model. These results demonstrate that IPD enables effective progressive forecast correction with efficient inference.

Figure 9: Hyperparameter sensitivity of refinement steps .

Figure 10: Reductions in level, trend, and remaining-shape errors from to at .

Figure 11: Online inference latency of iterative refinement and offline-folded inference.
4.3.2 Effectiveness of IPD Components. To evaluate the contributions of IPD components, we compare three prediction heads under the same encoder: a standard linear head, progressive residual refinement without conditioning (Refinement Only), and the complete IPD with interactive conditioning. Table 5 shows that residual refinement alone improves MSE over the linear head on five of six datasets. Introducing interactive conditioning further improves performance, with Full IPD achieving the lowest MSE and MAE across all six datasets. Notably, on Weather, refinement alone slightly underperforms the linear head, whereas Full IPD improves upon both. These results demonstrate the complementary benefits of progressive residual refinement and interactive conditioning for multivariate forecasting.
4.3.3 Effect of Cross-channel Conditioning. To investigate how cross-channel information contributes to forecasting, we analyze the relative-humidity channel on Weather by replacing source channel features with their training-set means. Figure 12(a) illustrates how sample-dependent cross-channel information adjusts the predicted trajectory, particularly around the trough and later forecast positions. The scaling modulation contributes most of the
Table 5: Comparison of IPD component configurations.
| Dataset | Linear Head | Refinement Only | Full IPD | |||
|---|---|---|---|---|---|---|
| MSE | MAE | MSE | MAE | MSE | MAE | |
| ETTh1 | 0.426 | 0.430 | 0.412 | 0.421 | 0.405 | 0.416 |
| ETTh2 | 0.349 | 0.385 | 0.344 | 0.384 | 0.342 | 0.384 |
| ETTm1 | 0.349 | 0.368 | 0.342 | 0.367 | 0.339 | 0.367 |
| ETTm2 | 0.254 | 0.307 | 0.253 | 0.308 | 0.252 | 0.307 |
| Weather | 0.228 | 0.254 | 0.230 | 0.257 | 0.226 | 0.252 |
| Exchange | 0.405 | 0.426 | 0.395 | 0.421 | 0.389 | 0.417 |

(a)
(b)
Figure 12: Cross-channel conditioning analysis on Weather.
adjustment in this example, while the shifting modulation provides smaller corrections. Figure 12(b) further reveals varying contributions from different source channels. The raining channel shows the largest positive contribution. These findings demonstrate that IPD can exploit informative cross-channel relationships to produce adaptive temporal corrections, supporting the effectiveness of interactive conditioning.
5 Conclusion
In this paper, we present RankFormer, a principled encoder-decoder architecture for multivariate time series forecasting. Through a rank-based analytical framework, we revisit how tokenization, embedding, and attention designs influence the capacity of learned representations. Our analysis reveals that patchification expands the attainable rank bound, nonlinear embeddings overcome the additional constraints of linear projections, and attention topology plays an important role in preserving representation diversity during information interaction. Guided by these insights, we develop a rank-enhancing encoder with HgA and an IPD, which respectively improve representation preservation and future trajectory modeling through effective information exchange and progressive refinement. Extensive experiments on real-world forecasting benchmarks validate the effectiveness of RankFormer and demonstrate consistent improvements over competitive methods.
References
[1] Srinadh Bhojanapalli, Chulhee Yun, Ankit Singh Rawat, Sashank Reddi, and Sanjiv Kumar. 2020. Low-rank bottleneck in multi-head attention models. In International conference on machine learning. PMLR, 864–873.
[2] Jiezhu Cheng, Kaizhu Huang, and Zibin Zheng. 2020. Towards better forecasting by fusing near and distant future visions. In Proceedings of the AAAI Conference on Artificial Intelligence. 3593–3600.
RankFormer: Rethinking Time Series Transformers through Representation Capacity Analysis and Progressive Decoding
[3] Krzysztof Marcin Choromanski, Valerii Likhosherstov, David Dohan, Xingyou Song, Andreea Gane, Tamas Sarlos, Peter Hawkins, Jared Quincy Davis, Afroz Mohiuddin, Lukasz Kaiser, et al. 2021. Rethinking Attention with Performers. In International Conference on Learning Representations.
[4] Yihe Dong, Jean-Baptiste Cordonnier, and Andreas Loukas. 2021. Attention is not all you need: Pure attention loses rank doubly exponentially with depth. In International conference on machine learning. PMLR, 2793–2803.
[5] Yuchen Fang, Yuxuan Liang, Bo Hui, Zezhi Shao, Liwei Deng, Xu Liu, Xinke Jiang, and Kai Zheng. 2025. Efficient large-scale traffic forecasting with transformers: A spatial data management perspective. In Proceedings of the 31st ACM SIGKDD Conference on Knowledge Discovery and Data Mining V. 1. 307–317.
[6] Jingru Fei, Kun Yi, Wei Fan, Qi Zhang, and Zhendong Niu. 2025. Amplifier: Bringing attention to neglected low-energy components in time series forecasting. In Proceedings of the AAAI conference on artificial intelligence. 11645–11653.
[7] Soufiane Hayou, Nikhil Ghosh, and Bin Yu. 2024. LoRA+ efficient low rank adaptation of large models. In Proceedings of the 41st International Conference on Machine Learning. 17783–17806.
[8] Edward J Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu, Yuanzhi Li, Shean Wang, Lu Wang, Weizhu Chen, et al. 2022. Lora: Low-rank adaptation of large language models. ICLR 1, 2 (2022), 3.
[9] Jiajia Li, Ling Dai, Feng Tan, Hui Shen, Zikai Wang, Bin Sheng, and Pengwei Hu. 2022. CDX-NET: cross-domain multi-feature fusion modeling via deep neural networks for multivariate time series forecasting in AIOps. In ICASSP 2022-2022 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP). IEEE, 4073–4077.
[10] Shizhan Liu, Hang Yu, Cong Liao, Jianguo Li, Weiyao Lin, Alex X Liu, and Schahram Dustdar. 2022. Pyraformer: Low-Complexity Pyramidal Attention for Long-Range Time Series Modeling and Forecasting. In International Conference on Learning Representations.
[11] Shih-Yang Liu, Chien-Yi Wang, Hongxu Yin, Pavlo Molchanov, Yu-Chiang Frank Wang, Kwang-Ting Cheng, and Min-Hung Chen. 2024. Dora: Weight-decomposed low-rank adaptation. In Forty-first International Conference on Machine Learning.
[12] Yong Liu, Tengge Hu, Haoran Zhang, Haixu Wu, Shiyu Wang, Lintao Ma, and Mingsheng Long. 2023. itransformer: Inverted transformers are effective for time series forecasting. arXiv preprint arXiv:2310.06625 (2023).
[13] Yong Liu, Guo Qin, Xiangdong Huang, Jianmin Wang, and Mingsheng Long. 2025. Timer-XL: Long-Context Transformers for Unified Time Series Forecasting. In The Thirteenth International Conference on Learning Representations.
[14] Yong Liu, Haoran Zhang, Chenyu Li, Xiangdong Huang, Jianmin Wang, and Mingsheng Long. 2024. Timer: generative pre-trained transformers are large time series models. In Proceedings of the 41st International Conference on Machine Learning. 32369–32399.
[15] Md Mahmuddin Nabi Murad, Mehmet Aktukmak, and Yasin Yilmaz. 2025. Wp-mixer: Efficient multi-resolution mixing for long-term time series forecasting. In Proceedings of the AAAI Conference on Artificial Intelligence. 19581–19588.
[16] Vinod Nair and Geoffrey E Hinton. 2010. Rectified linear units improve restricted boltzmann machines. In Proceedings of the 27th international conference on machine learning (ICML-10). 807–814.
[17] Yuqi Nie, Nam H Nguyen, Phanwadee Sinthong, and Jayant Kalagnanam. 2023. A Time Series is Worth 64 Words: Long-term Forecasting with Transformers. In The Eleventh International Conference on Learning Representations.
[18] Lorenzo Noci, Sotiris Anagnostidis, Luca Biggio, Antonio Orvieto, Sidak Pal Singh, and Aurelien Lucchi. 2022. Signal propagation in transformers: Theoretical perspectives and the role of rank collapse. Advances in Neural Information Processing Systems 35 (2022), 27198–27211.
[19] Xihao Piao, Zheng Chen, Taichi Murayama, Yasuko Matsubara, and Yasushi Sakurai. 2024. Fredformer: Frequency debiased transformer for time series forecasting. In Proceedings of the 30th ACM SIGKDD conference on knowledge discovery and data mining. 2400–2410.
[20] Xiangfei Qiu, Xvyuan Liu, Tianen Shen, Xingjian Wu, Hanyin Cheng, Bin Yang, and Jilin Hu. 2026. SEER: Transformer-based Robust Time Series Forecasting via Automated Patch Enhancement and Replacement. arXiv preprint arXiv:2602.00589 (2026).
[21] Xiangfei Qiu, Xingjian Wu, Yan Lin, Chenjuan Guo, Jilin Hu, and Bin Yang. 2025. Duet: Dual clustering enhanced multivariate time series forecasting. In Proceedings of the 31st ACM SIGKDD Conference on Knowledge Discovery and Data Mining V. 1. 1185–1196.
[22] Thiziri Nait Saada, Alireza Naderi, and Jared Tanner. 2025. Mind the Gap: a Spectral Analysis of Rank Collapse and Signal Propagation in Attention Layers. In Forty-second International Conference on Machine Learning.
[23] David Salinas, Valentin Flunkert, Jan Gasthaus, and Tim Januschowski. 2020. DeepAR: Probabilistic forecasting with autoregressive recurrent networks. International journal of forecasting (2020), 1181–1191.
[24] Artyom Sitsyuk and Jaesik Choi. 2025. xpatch: Dual-stream time series forecasting with exponential seasonal-trend decomposition. In Proceedings of the AAAI Conference on Artificial Intelligence, Vol. 39. 20601–20609.
[25] Hua Wang, Jinghao Lu, and Fan Zhang. 2026. Eeo-tfv: Escape-explore optimizer for web-scale time-series forecasting and vision analysis. In Proceedings of the ACM Web Conference 2026. 7271–7282.
[26] Sinong Wang, Belinda Z Li, Madian Khabsa, Han Fang, and Hao Ma. 2020. Linformer: Self-attention with linear complexity. arXiv preprint arXiv:2006.04768 (2020).
[27] Shiyu Wang, Jiawei Li, Xiaoming Shi, Zhou Ye, Baichuan Mo, Wenzé Lin, Ju Shengtong, Zhixuan Chu, and Ming Jin. 2025. TimeMixer++: A General Time Series Pattern Machine for Universal Predictive Analysis. In ICLR 2025: The Thirteenth International Conference on Learning Representations. International Conference on Learning Representations.
[28] Haixu Wu, Tengge Hu, Yong Liu, Hang Zhou, Jianmin Wang, and Mingsheng Long. 2023. TimesNet: Temporal 2D-Variation Modeling for General Time Series Analysis. In The Eleventh International Conference on Learning Representations.
[29] Haixu Wu, Jiehui Xu, Jianmin Wang, and Mingsheng Long. 2021. Autoformer: Decomposition transformers with auto-correlation for long-term series forecasting. Advances in neural information processing systems 34 (2021), 22419–22430.
[30] Xinyi Wu, Amir Ajorlou, Yifei Wang, Stefanie Jegelka, and Ali Jadbabaie. 2024. On the role of attention masks and layernorm in transformers. Advances in Neural Information Processing Systems 37 (2024), 14774–14809.
[31] Xingjian Wu, Xiangfei Qiu, Hanyin Cheng, Zhengyu Li, Jilin Hu, Chenjuan Guo, and Bin Yang. 2025. Enhancing Time Series Forecasting through Selective Representation Spaces: A Patch Perspective. In Advances in Neural Information Processing Systems, Vol. 38. 23328–23354.
[32] Yunyang Xiong, Zhanpeng Zeng, Rudrasis Chakraborty, Mingxing Tan, Glenn Fung, Yin Li, and Vikas Singh. 2021. Nyströmformer: A nyström-based algorithm for approximating self-attention. In Proceedings of the AAAI conference on artificial intelligence. 14138–14148.
[33] Zhijian Xu, Ailing Zeng, and Qiang Xu. 2024. FITS: Modeling Time Series with 10k Parameters. In The Twelfth International Conference on Learning Representations.
[34] Kun Yi, Qi Zhang, Wei Fan, Shoujin Wang, Pengyang Wang, Hui He, Ning An, Defu Lian, Longbing Cao, and Zhendong Niu. 2023. Frequency-domain MLPs are more effective learners in time series forecasting. Advances in Neural Information Processing Systems 36 (2023), 76656–76679.
[35] Annan Yu, Danielle C Maddix, Boran Han, Xiyuan Zhang, Abdul Fatir Ansari, Oleksandr Shchur, Christos Faloutsos, Andrew Gordon Wilson, Michael W Mahoney, and Yuyang Wang. 2025. Understanding Transformers for Time Series: Rank Structure, Flow-of-ranks, and Compressibility. arXiv preprint arXiv:2510.03358 (2025).
[36] Ailing Zeng, Muxi Chen, Lei Zhang, and Qiang Xu. 2023. Are transformers effective for time series forecasting?. In Proceedings of the AAAI conference on artificial intelligence. 11121–11128.
[37] Boning Zhang, Haishuai Wang, Zehong Hu, Jiajun Wang, Hongyi Zhang, and Jia Jia. 2026. Re-Diffusion: Modeling Latent Residuals with Diffusion for Time-Series Forecasting. In Proceedings of the ACM Web Conference 2026. 7390–7400.
[38] Fan Zhang, Shiming Fan, and Hua Wang. 2026. Time-tk: A multi-offset temporal interaction framework combining transformer and kolmogorov-arnold networks for time series forecasting. In Proceedings of the ACM Web Conference 2026. 7495–7506.
[39] Jianqi Zhang, Jingyao Wang, Wenwen Qiang, Fanjiang Xu, and Changwen Zheng. 2026. Enhancing large language models for time-series forecasting via vector-injected in-context learning. In Proceedings of the ACM Web Conference 2026. 7211–7222.
[40] Xu Zhang, Peng Wang, Yichen Li, and Wei Wang. 2026. Amortized predictability-aware training framework for time series forecasting and classification. In Proceedings of the ACM Web Conference 2026. 5624–5635.
[41] Xu Zhang, Qitong Wang, Peng Wang, and Wei Wang. 2026. Semixer: Semantics enhanced mlp-mixer for multiscale mixing and long-term time series forecasting. In Proceedings of the ACM Web Conference 2026. 5636–5647.
[42] Haoyi Zhou, Shanghang Zhang, Jieqi Peng, Shuai Zhang, Jianxin Li, Hui Xiong, and Wancai Zhang. 2021. Informer: Beyond efficient transformer for long sequence time-series forecasting. In Proceedings of the AAAI conference on artificial intelligence. 11106–11115.
[43] Tian Zhou, Ziqing Ma, Qingsong Wen, Xue Wang, Liang Sun, and Rong Jin. 2022. Fedformer: Frequency enhanced decomposed transformer for long-term series forecasting. In International conference on machine learning. PMLR, 27268–27286.
A Related Work
A.1 Time Series Forecasting
Time series forecasting faces challenges in modeling long-term dependencies and complex dynamics. Traditional RNNs and CNNs suffer from scalability bottlenecks and difficulties in handling long sequences [2, 23]. In contrast, Transformers have achieved superior

Figure 13: Rank expansion via patchification.
performance by leveraging self-attention mechanisms, spurring the development of efficient and interpretable temporal models [10, 28] such as Informer [42], Autoformer [29], and PatchTST [17]. Meanwhile, frequency-domain methods effectively capture periodic and spectral patterns in time series through Fourier or wavelet transforms [15]. Representative works, including Fredformer [19], FreTS [34], and FITS [33], demonstrate competitive advantages in extracting global features. Recent studies further integrate temporal and frequency-domain information, proposing hybrid modeling approaches. For example, CDX-Net combines multiple network structures for feature fusion [9], FEDformer unifies decomposition and frequency analysis [43], and TimeMixer++ enhances temporal representation through multi-scale sampling and attention mechanisms, advancing the field [27].
A.2 Rank Analysis in Transformer
Low-rank attention research aims to improve Transformer efficiency through low-rank approximations or parameterization. Low-rank approximation methods, such as Linformer [26], Nystromformer [32], and Performer [3], utilize low-dimensional projections, anchor tokens, or random feature mappings to reduce attention computational complexity to linear. Low-rank parameterization methods [7, 8, 11], directly learn low-rank update matrices for efficient fine-tuning but lack theoretical guidance on the underlying causes of low-rank behavior. Theoretical analysis reveals that pure attention networks suffer from a double-exponential collapse in representation rank as depth increases, a phenomenon known as rank collapse [18, 22]. Studies indicate that residual connections, layer normalization, and feed-forward networks can effectively mitigate this issue and maintain representational diversity [4, 30]. Additionally, the relationship between attention head dimension and sequence length influences the rank of attention matrices, thereby constraining model expressiveness [1].
In time series forecasting, sequence embeddings exhibit rapidly decaying singular value spectra, naturally concentrating in low-rank subspaces and endowing attention layers with inherent compressibility [35]. However, existing work still lacks a unified theoretical framework to systematically guide the overall design and optimization of time series Transformers from a rank perspective.
B Visualization of Rank Expansion via Patching
Figure 13 illustrates the rank expansion effect discussed in Section 2. Point-wise tokenization (P = 1) limits the representation to a rank-1 structure, while patchification enlarges the attainable rank bound to as stated in Proposition 1, providing additional independent directions for subsequent representation learning.
C Proof of Theorem 1
We consider the two-layer MLP embedding:
where denotes the input patch matrix and is a continuous non-polynomial activation function. We show that there exist MLP parameters such that
C.1 Spanning Property of Non-polynomial Activations
We first establish a property of non-polynomial activations. For any distinct input points , define
LEMMA 1. The set of vectors spans .
PROOF. Assume that the image of does not span . Then there exists a non-zero vector satisfying
for all w and b.
Since the input points are distinct, there exists a direction such that the projected values are pairwise distinct. Setting gives
for all t, b. This contradicts the discriminatory property of continuous non-polynomial activations, which states that no non-trivial linear combination of their translated and scaled functions can vanish identically. Therefore, the vectors span .
C.2 Maximum Rank Achievability
Let
By Lemma 1, the activation outputs span , and therefore there exist linearly independent vectors
generated by suitable parameters , where
Construct the first MLP layer using
The hidden representation becomes
which satisfies
RankFormer: Rethinking Time Series Transformers through Representation Capacity Analysis and Progressive Decoding
Finally, choosing the output projection to map these independent hidden directions into the output space yields
Therefore, nonlinear MLP embeddings can achieve the maximum attainable rank under the given sample and hidden dimensions.
D Attention Rank Analysis
We analyze how attention topology affects the rank preservation of value representations during token interaction. Given query, key, and value projections:
the attention output after output projection can be written as
where
and A denotes the corresponding attention aggregation matrix.
The following analysis focuses on whether the attention aggregation matrix A preserves the rank of the value representation.
D.1 Full-rank Potential of Bidirectional Attention
BiA is not inherently rank deficient. We show that its attention matrix can achieve full rank under suitable projection parameters.
Given an input matrix X with distinct rows, there exists a projection direction v such that
contains pairwise distinct values. Choosing one-dimensional query and key projections as
produces the attention score matrix
Although S is rank one, the element-wise exponential matrix generated by the softmax operation,
is full rank for distinct . Since the softmax normalization only introduces an invertible diagonal scaling, the resulting bidirectional attention matrix can achieve
Therefore, BiA itself does not suffer from an intrinsic rank limitation. Its limitation is the absence of a structural guarantee for preserving rank during repeated token interaction.
D.2 Rank Preservation of Causal Attention
LEMMA 2 (INVERTIBILITY OF CAUSAL ATTENTION). The causal attention matrix is invertible:
PROOF. Due to the causal mask, is a lower triangular matrix. Its diagonal entries are:
where .
Since all exponential terms are strictly positive,
Therefore,
which proves that is invertible.
D.2.1 Proof of Theorem 2.
PROOF. Let
From Lemma 2, is invertible. Therefore,
For bidirectional attention, the rank of
is determined by whether the null space of intersects with the column space of .
By the rank-nullity theorem restricted to :
Hence,
Therefore,
Equality holds exactly when
D
E Additional Experimental Results
Different Patch Sizes. As shown in Figure 14, we systematically evaluated the singular value distribution of embedding matrices under different patch sizes (1, 4, 8, 16) across 7 datasets. The experimental results show that for most datasets, the singular value decay curves of their embedding representations generally exhibit full-rank or near-full-rank characteristics, even under the smallest patch size (1). This indicates that the model can learn highly diverse and linearly independent representations for these datasets, with their effective rank significantly surpassing the inherent bottleneck of the original univariate input (which has an upper rank bound of 1).

Singular value index
Singular value index
Singular value index
Singular value index
ETTh1
ETTh2
ETTm1
ETTm2
Electricity
Exchange
Weather
Figure 14: Rank Distribution of Embedding Matrices (Patch Size = 16).
(a) Bidirectional Attention

Layer 1 (Input)
Layer 2
Layer 3
Layer 4
Layer 5
Layer 6 (Final)
(b) Hourglass Attention
Layer 1 (Input)
Layer 2
Layer 3
Layer 4
Layer 5
Layer 6 (Final)
Figure 15: PCA visualization of token representation evolution across deep layers in a pure attention network. The color gradient indicates the token index within the sequence.
Visualization of Representation Collapse. As illustrated in Figure 15, the evolutionary trajectories of the token representations differ drastically depending on the chosen attention mechanism: BiA: The top panel (Figure 15a) demonstrates that while tokens are initially scattered in the input space, they rapidly assimilate during forward propagation. By Layer 4, the representations of all tokens completely collapse into a single indistinguishable point. This visualizes the extreme over-smoothing and severe rank collapse inherent to deep unmasked attention. HgA: The bottom panel (Figure 15b) shows that HgA successfully preserves representational diversity. Even at the final layer (Layer 6), the tokens maintain a distinct and structured spread. This provides direct and compelling visual evidence of HgA's structural superiority in circumventing rank collapse and preserving full-rank capacity.