cs.LGMar 31, 2026

QUEST: A robust attention formulation using query-modulated spherical attention

Authors: Hariprasath Govindarajan, Per Sidén, Jacob Roll, Fredrik Lindsten

Organizations: Linköping University, Sweden · Qualcomm Auto Ltd Sweden Filial

Abstract

The Transformer model architecture has become one of the most widely used in deep learning and the attention mechanism is at its core. The standard attention formulation uses a softmax operation applied to a scaled dot product between query and key vectors. We explore the role played by norms of the queries and keys, which can cause training instabilities when they arbitrarily increase. We demonstrate how this can happen even in simple Transformer models, in the presence of easy-to-learn spurious patterns in the data. We propose a new attention formulation, QUEry-modulated Spherical aTtention (QUEST), that constrains the keys to a hyperspherical latent space, while still allowing individual tokens to flexibly control the sharpness of the attention distribution. QUEST can be easily used as a drop-in replacement for standard attention. We focus on vision applications while also exploring other domains to highlight the method's generality. We show that (1) QUEST trains without instabilities and (2) produces models with improved performance (3) that are robust to data corruptions and adversarial attacks.

Figures & tables

Appendix figures & tables22 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. QSV: Quat-Sphere-Vision for Coupled Quaternion Attention on Spherical Lattices

    Sep 24, 2026Nicholas Foley, Devin Marinelli, Donny Moore +2Attention MechanismsVision Transformer

  2. Query Expansion and Key Specialization in Transformer Attention Geometry

    Sep 28, 2026Vidit Gupta, Siddhesh Nadkarni, Mihik Chaudhari +2Neural Representation GeometryTransformer Attention

  3. Why Attend to Everything? Focus is the Key

    Mar 12, 2026Hengshuai Yao, Xing Chen, Ahmed Murtadha +8Attention MechanismsEfficient Attention