English
Related papers

Related papers: Max-Margin Token Selection in Attention Mechanism

200 papers

Attention mechanism is contributing to the majority of recent advances in machine learning for natural language processing. Additionally, it results in an attention map that shows the proportional influence of each input in its decision.…

Computation and Language · Computer Science 2025-01-23 Duc Hau Nguyen , Cyrielle Mallart , Guillaume Gravier , Pascale Sébillot

We revisit the I/O complexity of attention in large language models. Given query-key-value matrices $Q,K,V\in\mathbb{R}^{n\times d}$, and a machine with fast memory size $M$, the goal is to compute the "attention matrix" $A=\text{softmax}(Q…

Machine Learning · Computer Science 2026-05-25 Pál András Papp , Aleksandros Sobczyk , Anastasios Zouzias

We examine the intrinsic (within the attention head) and extrinsic (amongst the attention heads) structure of the self-attention mechanism in transformers. Theoretical evidence for invariance of the self-attention mechanism to softmax…

Numerical Analysis · Mathematics 2025-06-19 Oluwadamilola Fasina , Ruben V. C. Pohle , Pei-Chun Su , Ronald R. Coifman

Prompt-tuning is an emerging strategy to adapt large language models (LLM) to downstream tasks by learning a (soft-)prompt parameter from data. Despite its success in LLMs, there is limited theoretical understanding of the power of…

Machine Learning · Computer Science 2023-06-07 Samet Oymak , Ankit Singh Rawat , Mahdi Soltanolkotabi , Christos Thrampoulidis

The success of Transformer language models is widely credited to their dot-product attention mechanism, which interweaves a set of key design principles: mixing information across positions (enabling multi-token interactions),…

Computation and Language · Computer Science 2025-10-14 Huiyin Xue , Nafise Sadat Moosavi , Nikolaos Aletras

Large language models (LLMs) have demonstrated remarkable performance across a wide range of tasks. However, the quadratic complexity of softmax attention remains a central bottleneck that limits their scalability. Alman and Song (NeurIPS…

Machine Learning · Computer Science 2026-03-20 Maryam Aliakbarpour , Vladimir Braverman , Junze Yin , Haochen Zhang

We propose the first method to show theoretical limitations for one-layer softmax transformers with arbitrarily many precision bits (even infinite). We establish those limitations for three tasks that require advanced reasoning. The first…

Effective representation learning from text has been an active area of research in the fields of NLP and text mining. Attention mechanisms have been at the forefront in order to learn contextual sentence representations. Current…

Computation and Language · Computer Science 2020-08-11 Sneha Mehta , Huzefa Rangwala , Naren Ramakrishnan

First derived from human intuition, later adapted to machine translation for automatic token alignment, attention mechanism, a simple method that can be used for encoding sequence data based on the importance score each element is assigned,…

Computation and Language · Computer Science 2018-11-15 Dichao Hu

Vision transformers using self-attention or its proposed alternatives have demonstrated promising results in many image related tasks. However, the underpinning inductive bias of attention is not well understood. To address this issue, this…

Machine Learning · Computer Science 2022-05-23 Arda Sahiner , Tolga Ergen , Batu Ozturkler , John Pauly , Morteza Mardani , Mert Pilanci

Attention mechanisms are widely used to dramatically improve deep learning model performance in various fields. However, their general ability to improve the performance of physiological signal deep learning model is immature. In this…

Signal Processing · Electrical Eng. & Systems 2022-07-15 Seong-A Park , Hyung-Chul Lee , Chul-Woo Jung , Hyun-Lim Yang

The attention mechanism has been proven effective on various visual tasks in recent years. In the semantic segmentation task, the attention mechanism is applied in various methods, including the case of both Convolution Neural Networks…

Computer Vision and Pattern Recognition · Computer Science 2024-05-10 Zheng Yuan , Jie Zhang , Yude Wang , Shiguang Shan , Xilin Chen

Softmax self-attention often assigns disproportionate weight to semantically uninformative tokens such as special tokens and punctuation, a phenomenon known as attention noise. While recent methods like Cog Attention and the Differential…

Computation and Language · Computer Science 2025-08-27 Ivan Kobyzev , Abbas Ghaddar , Dingtao Hu , Boxing Chen

Transformer attention is typically implemented using softmax normalization, which enforces attention weights with unit sum normalization. While effective in many settings, this constraint can limit flexibility in controlling attention…

Computation and Language · Computer Science 2026-02-27 Jeongin Bae , Baeseong Park , Gunho Park , Minsub Kim , Joonhyung Lee , Junhee Yoo , Sunghyeon Woo , Jiwon Ryu , Se Jung Kwon , Dongsoo Lee

Neural attention has become central to many state-of-the-art models in natural language processing and related domains. Attention networks are an easy-to-train and effective method for softly simulating alignment; however, the approach does…

Machine Learning · Statistics 2018-11-09 Yuntian Deng , Yoon Kim , Justin Chiu , Demi Guo , Alexander M. Rush

The transformer architecture is central to the success of modern Large Language Models (LLMs), in part due to its surprising ability to perform a wide range of tasks - including mathematical reasoning, memorization, and retrieval - using…

Machine Learning · Computer Science 2025-09-05 Yihe Dong , Lorenzo Noci , Mikhail Khodak , Mufan Li

In the realm of deep learning, the self-attention mechanism has substantiated its pivotal role across a myriad of tasks, encompassing natural language processing and computer vision. Despite achieving success across diverse applications,…

Computation and Language · Computer Science 2023-10-25 Muhan Zhang

Transformers and deep state space models (SSMs) sit at opposite ends of a basic design choice: attention routes each query through a growing key-value (KV) cache by content-based matching at quadratic cost, while deep SSMs compress context…

Machine Learning · Computer Science 2026-05-26 Naoki Kiyohara , Harrison Bo Hua Zhu , Riccardo El Hassanin , Zhuo Sun , Wenlong Chen , Samir Bhatt , Yingzhen Li

Large language models (LLMs) have made transformed changes for human society. One of the key computation in LLMs is the softmax unit. This operation is important in LLMs because it allows the model to generate a distribution over possible…

Machine Learning · Computer Science 2023-04-27 Yichuan Deng , Zhihang Li , Zhao Song

We study two strange phenomena in auto-regressive Transformers: (1) the dominance of the first token in attention heads; (2) the occurrence of large outlier activations in the hidden states. We find that popular large language models, such…

Computation and Language · Computer Science 2024-10-23 Prannay Kaul , Chengcheng Ma , Ismail Elezi , Jiankang Deng