Copy Suppression: Comprehensively Understanding an Attention Head

Callum McDougall, Arthur Conmy, Cody Rushing, Thomas McGrath, Neel Nanda
10/6/2023
cs.LGcs.AIcs.CL

Official code: callummcdougall/SERI-MATS-2023-Streamlit-pages (9 stars, MIT, last commit 2024-02-27).

Abstract

We present a single attention head in GPT-2 Small that has one main role across the entire training distribution. If components in earlier layers predict a certain token, and this token appears earlier in the context, the head suppresses it: we call this copy suppression. Attention Head 10.7 (L10H7) suppresses naive copying behavior which improves overall model calibration. This explains why multiple prior works studying certain narrow tasks found negative heads that systematically favored the wrong answer. We uncover the mechanism that the Negative Heads use for copy suppression with weights-based evidence and are able to explain 76.9% of the impact of L10H7 in GPT-2 Small. To the best of our knowledge, this is the most comprehensive description of the complete role of a component in a language model to date. One major effect of copy suppression is its role in self-repair. Self-repair refers to how ablating crucial model components results in downstream neural network parts compensating for this ablation. Copy suppression leads to self-repair: if an initial overconfident copier is ablated, then there is nothing to suppress. We show that self-repair is implemented by several mechanisms, one of which is copy suppression, which explains 39% of the behavior in a narrow task. Interactive visualisations of the copy suppression phenomena may be seen at our web app https://copy-suppression.streamlit.app/

View on arXivView PDF

Code Implementations(1)

MIT

Repo for hosting Streamlit pages for my 2023 SERI MATS project with Arthur Conmy (mentored by Neel Nanda).

91TeX, HTMLJul 17, 20232 years agoMIT

Similar Papers

Cite this paper

@article{mcdougall2023copy,
  title  = {Copy Suppression: Comprehensively Understanding an Attention Head},
  author = {Callum McDougall and Arthur Conmy and Cody Rushing and Thomas McGrath and Neel Nanda},
  year   = {2023},
  eprint = {2310.04625},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2310.04625v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2310.04625.svg)](https://codeofpaper.com/paper/2310.04625)

Discussion