Converting Transformers into DGNNs Form

Jie Zhang, Kuan-Chieh Wang, Bo-Wei Chiu, Min-Te SunarXiv 2025 · DOI

Abstract

Standard Transformers suffer from quadratic scaling, limiting their utility for long-sequence tasks. We present Converter, an architecture that reinterprets self-attention as a directed graph convolution. By utilizing unitary matrices and the Kernel Polynomial Method (KPM), Converter achieves $O(N \log N)$ complexity while maintaining full-rank expressivity. Our evaluation on the Long-Range Arena (LRA) benchmark demonstrates a significant performance leap, with Converter reaching an average accuracy of 75.94%, outperforming existing efficient Transformer variants.

Introduction

The core "self-attention" mechanism in standard Transformers scales quadratically ($O(N^2)$) with sequence length. This computational bottleneck makes processing long documents or high-resolution data prohibitively expensive. While many "Efficient Transformers" have been proposed, they often rely on low-rank approximations that lead to "rank collapse," where the model loses the ability to distinguish complex relationships between tokens. The Converter model addresses this by reimagining attention as a directed graph operation that is both faster and more expressive.

Methodology: From Attention to Directed Graphs

The Converter model transforms the Transformer architecture into a Directed Graph Neural Network (DGNN). This shift allows the use of tools from Digraph Signal Processing (DGSP) to optimize computation.

Synvolution and Kernelution

Instead of calculating a massive similarity matrix between all pairs of words, Converter employs Synvolution (Synthetic Digraph Convolution). It treats the sequence as a directed graph and synthesizes a learnable unitary matrix to represent the graph's structure. This is implemented via Givens rotations and LQ factorization, achieving linearithmic time complexity ($O(N \log N)$).

Furthermore, the model replaces standard Multi-Head Attention with Kernelution. This uses the Kernel Polynomial Method (KPM) and Chebyshev polynomials to approximate complex filters in the spectral domain, providing a more rigorous theoretical foundation for feature extraction than traditional heuristics.

The Converter architecture replaces standard attention with Kernelution and utilizes a Gated Feed-Forward Network.

Gated Feed-Forward and Loss Functions

Because spectral operations involve complex numbers, a specific Gated Feed-Forward Network (GFFN) maps these signals back into real-valued labels. To ensure stability and prevent overfitting, the authors introduce the Kernel Polynomial Loss (KPL), which penalizes high-order polynomial coefficients to encourage smooth, meaningful filters.

Experimental Results

Converter was evaluated against 14 popular Transformer variants across several challenging long-range dependency tasks.

Long-Range Arena (LRA)

On the LRA benchmark, Converter achieved an average accuracy of 75.94%, a substantial improvement over the previous state-of-the-art variant, Luna-256 (61.95%). Notably, on the difficult ListOps task involving nested logical operations, Converter scored 60.38%, nearly doubling the performance of many competitors.

Comparison of Converter against various efficient Transformer models on the LRA benchmark.

Long Document and DNA Classification

The model's efficiency was further proven on sequences up to 32,768 tokens (arXiv papers) and biological DNA sequences. On 32K-length documents, Converter reached 82.34% accuracy, significantly outperforming the vanilla Transformer's 70.84%.

Discussion

The success of Converter stems from its "full-rank" nature. Unlike models that "thin out" the attention matrix through low-rank approximations, Converter keeps the matrix dense and unitary, preserving information capacity even as sequences grow. By working in the spectral domain, the model captures global patterns more efficiently than spatial-domain attention.

Conclusion

Converter demonstrates that self-attention can be mathematically reformulated as a digraph convolution to achieve both speed and expressivity. While currently focused on encoder-style classification tasks, future work aims to expand the architecture into decoder components for generative tasks and explore broader graph topologies.

Summary updated

BibTeX
@misc{zhang2025converting,
  author = {Jie Zhang and Kuan-Chieh Wang and Bo-Wei Chiu and Min-Te Sun},
  title = {{Converting Transformers into DGNNs Form}},
  year = {2025},
  eprint = {2502.00585},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2502.00585},
}
Figure