Skip to content

Statistical Limits in Learning Multi-Head Attention Interactions

Shai Zucker, Fei Lu, Inbar Seroussi

stat.ML

Abstract

Multi-head attention aggregates pairwise token interactions, making recovery of the underlying token interaction a statistical inverse problem. We study this problem through an interacting particle system formulation, asking how smoothness and head sparsity determine recovery accuracy and the number of heads needed for estimation. Each head has unknown query-key and value matrices and a ββ-Hölder activation, with head strengths constrained by an ℓq\ell^q budget, 0<q≤10<q\le1. Under suitable assumptions on the token distribution and interaction class, we establish finite-sample minimax lower bounds and upper bounds for empirical risk minimization that avoid the nonparametric curse of dimensionality. As the sample size increases, the lower bound distinguishes three regimes: a saturation regime, a balanced regime in which a sample-dependent number of heads is selected, and a dense regime. In the dense regime, the dependence on the available head count HH changes at qc=2/(2β+1)q_c=2/(2β+1): the nonparametric term is independent of HH under stronger sparsity, q≤qcq\le q_c, but increases with HH under weaker sparsity, q>qcq> q_c. The upper bound exhibits the same transition and, for fixed sequence length, matches the lower bound up to logarithmic factors once both bounds are in the dense regime and the matrix-estimation term does not dominate. Balancing approximation and estimation errors in the upper bound yields a sample-dependent choice of the number of heads, which can be substantially smaller than HH.

Create a lesson

Metadata

Categories
stat.ML, cs.LG