On the Interpolation Error of Nonlinear Attention versus Linear Regression

Fuente: arXiv
Salvato in:
Dettagli Bibliografici
Autori principali: Liao, Zhenyu, Liu, Jiaqing, Hou, TianQi, Zou, Difan, Ling, Zenan
Natura: Preprint
Pubblicazione: 2025
Soggetti:
Accesso online:
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866917294563655680
author Liao, Zhenyu
Liu, Jiaqing
Hou, TianQi
Zou, Difan
Ling, Zenan
author_facet Liao, Zhenyu
Liu, Jiaqing
Hou, TianQi
Zou, Difan
Ling, Zenan
contents Attention has become the core building block of modern machine learning (ML) by efficiently capturing the long-range dependencies among input tokens. Its inherently parallelizable structure allows for efficient performance scaling with the rapidly increasing size of both data and model parameters. Despite its central role, the theoretical understanding of Attention, especially in the nonlinear setting, is progressing at a more modest pace. This paper provides a precise characterization of the interpolation error for a nonlinear Attention, in the high-dimensional regime where the number of input tokens $n$ and the embedding dimension $p$ are both large and comparable. Under a signal-plus-noise data model and for fixed Attention weights, we derive explicit (limiting) expressions for the mean-squared interpolation error. Leveraging recent advances in random matrix theory, we show that nonlinear Attention generally incurs a larger interpolation error than linear regression on random inputs. However, this gap vanishes, and can even be reversed, when the input contains a structured signal, particularly if the Attention weights align with the signal direction. Our theoretical insights are supported by numerical experiments.
format Preprint
id arxiv_https___arxiv_org_abs_2506_18656
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle On the Interpolation Error of Nonlinear Attention versus Linear Regression
Liao, Zhenyu
Liu, Jiaqing
Hou, TianQi
Zou, Difan
Ling, Zenan
Machine Learning
Statistics Theory
Attention has become the core building block of modern machine learning (ML) by efficiently capturing the long-range dependencies among input tokens. Its inherently parallelizable structure allows for efficient performance scaling with the rapidly increasing size of both data and model parameters. Despite its central role, the theoretical understanding of Attention, especially in the nonlinear setting, is progressing at a more modest pace. This paper provides a precise characterization of the interpolation error for a nonlinear Attention, in the high-dimensional regime where the number of input tokens $n$ and the embedding dimension $p$ are both large and comparable. Under a signal-plus-noise data model and for fixed Attention weights, we derive explicit (limiting) expressions for the mean-squared interpolation error. Leveraging recent advances in random matrix theory, we show that nonlinear Attention generally incurs a larger interpolation error than linear regression on random inputs. However, this gap vanishes, and can even be reversed, when the input contains a structured signal, particularly if the Attention weights align with the signal direction. Our theoretical insights are supported by numerical experiments.
title On the Interpolation Error of Nonlinear Attention versus Linear Regression
topic Machine Learning
Statistics Theory
url https://arxiv.org/abs/2506.18656