paper-with-me

홈 › Papers

Learning to Attribute with Attention

2025-04-18 · Benjamin Cohen-Wang, Yung-Sung Chuang, Aleksander Madry

Given a sequence of tokens generated by a language model, we may want to identify the preceding tokens that influence the model to generate this sequence. Performing such token attribution is expensive; a common approach is to ablate preceding tokens and directly measure their effects. To reduce the cost of token attribution, we revisit attention weights as a heuristic for how a language model uses previous tokens. Naive approaches to attribute model behavior with attention (e.g., averaging attention weights across attention heads to estimate a token's influence) have been found to be unreliable. To attain faithful attributions, we propose treating the attention weights of different attention heads as features. This way, we can learn how to effectively leverage attention weights for attribution (using signal from ablations). Our resulting method, Attribution with Attention (AT2), reliably performs on par with approaches that involve many ablations, while being significantly more efficient. To showcase the utility of AT2, we use it to prune less important parts of a provided context in a question answering setting, improving answer quality. We provide code for AT2 at https://github.com/MadryLab/AT2 .

📄 PDF Abstract BibTeX arXiv:2504.13752

Code (1)

madrylab/at2 공식 구현 pytorch

Tasks

AttributeLanguage ModelingLanguage ModellingQuestion Answering

Methods 이 논문이 사용한 방법론

Softmax The Softmax output function transforms a previous layer's output into a vector of probabilities. It is commonly used for multiclass classification. Given an input vector $x$…
Attention 설명 없음

Similar Papers 제목 키워드 기반

Pedestrian Attribute Recognition in Video Surveillance Scenarios Based on View-attribute Attention Localization

2021-06-11 · Weichen Chen, Xinyi Yu, Linlin Ou

Pedestrian attribute recognition in surveillance scenarios is still a challenging task due to inaccurate localization of specific attributes. In this paper, we propose a novel view-attribute localization method based on …

AttributePedestrian Attribute Recognition

MU-GAN: Facial Attribute Editing based on Multi-attention Mechanism

2020-09-09 · Ke Zhang, Yukun Su, Xiwang Guo, Liang Qi 외

Facial attribute editing has mainly two objectives: 1) translating image from a source domain to a target one, and 2) only changing the facial regions related to a target attribute and preserving the attribute-excluding …

AttributeDecoderGenerative Adversarial Network

Distantly Supervised Attribute Detection from Reviews

2018-11-01 · WS 2018 11 · Lisheng Fu, Pablo Barrio

This work aims to detect specific attributes of a place (e.g., if it has a romantic atmosphere, or if it offers outdoor seating) from its user reviews via distant supervision: without direct annotation of the review text…

AttributeEntity Extraction using GANSentiment Analysis

A Knowledge-Enhanced Recommendation Model with Attribute-Level Co-Attention

2020-06-18 · Deqing Yang, Zengcun Song, Lvxin Xue, Yanghua Xiao

Deep neural networks (DNNs) have been widely employed in recommender systems including incorporating attention mechanism for performance improvement. However, most of existing attention-based models only apply item-level…

AttributeKnowledge GraphsRecommendation Systems

Attribute-Aware Attention Model for Fine-grained Representation Learning

2019-01-02 · Kai Han, Jianyuan Guo, Chao Zhang, Mingjian Zhu

How to learn a discriminative fine-grained representation is a key point in many computer vision applications, such as person re-identification, fine-grained classification, fine-grained image retrieval, etc. Most of the…

AttributeFine-Grained Image ClassificationImage RetrievalPerson Re-Identification+2