paper-with-me

홈 › Papers

Identifying Semantic Induction Heads to Understand In-Context Learning

2024-02-20 · Jie Ren, Qipeng Guo, Hang Yan, Dongrui Liu, Quanshi Zhang, Xipeng Qiu, Dahua Lin

Although large language models (LLMs) have demonstrated remarkable performance, the lack of transparency in their inference logic raises concerns about their trustworthiness. To gain a better understanding of LLMs, we conduct a detailed analysis of the operations of attention heads and aim to better understand the in-context learning of LLMs. Specifically, we investigate whether attention heads encode two types of relationships between tokens present in natural languages: the syntactic dependency parsed from sentences and the relation within knowledge graphs. We find that certain attention heads exhibit a pattern where, when attending to head tokens, they recall tail tokens and increase the output logits of those tail tokens. More crucially, the formulation of such semantic induction heads has a close correlation with the emergence of the in-context learning ability of language models. The study of semantic attention heads advances our understanding of the intricate operations of attention heads in transformers, and further provides new insights into the in-context learning of LLMs.

📄 PDF Abstract BibTeX arXiv:2402.13055

Code (0)

등록된 구현이 없습니다.

Tasks

In-Context LearningKnowledge Graphs

Similar Papers 제목 키워드 기반

The Dual-Route Model of Induction

2025-04-03 · Sheridan Feucht, Eric Todd, Byron Wallace, David Bau

Prior work on in-context copying has shown the existence of induction heads, which attend to and promote individual tokens during copying. In this work we introduce a new type of induction head: concept-level induction h…

In-Context Learningmodel

Selective Induction Heads: How Transformers Select Causal Structures In Context

2025-09-09 · Francesco D'Angelo, Francesco Croce, Nicolas Flammarion arxiv

Transformers have exhibited exceptional capabilities in sequence modeling tasks, leveraging self-attention and in-context learning. Critical to this success are induction heads, attention circuits that enable copying tok…

Which Attention Heads Matter for In-Context Learning?

2025-02-19 · Kayo Yin, Jacob Steinhardt

Large language models (LLMs) exhibit impressive in-context learning (ICL) capability, enabling them to perform new tasks using only a few demonstrations in the prompt. Two different mechanisms have been proposed to expla…

In-Context Learning

Induction Head Toxicity Mechanistically Explains Repetition Curse in Large Language Models

2025-05-17 · Shuxun Wang, Qingyu Yin, Chak Tou Leong, Qiang Zhang 외

Repetition curse is a phenomenon where Large Language Models (LLMs) generate repetitive sequences of tokens or cyclic sequences. While the repetition curse has been widely observed, its underlying mechanisms remain poorl…

In-Context Learning

Induction Heads as an Essential Mechanism for Pattern Matching in In-context Learning

2024-07-09 · Joy Crosbie, Ekaterina Shutova

Large language models (LLMs) have shown a remarkable ability to learn and perform complex tasks through in-context learning (ICL). However, a comprehensive understanding of its internal mechanisms is still lacking. This …

In-Context Learning