paper-with-me

Papers

How transformers learn structured data: insights from hierarchical filtering

2024-08-27 · Jerome Garnier-Brun, Marc Mézard, Emanuele Moscato, Luca Saglietti

Understanding the learning process and the embedded computation in transformers is becoming a central goal for the development of interpretable AI. In the present study, we introduce a hierarchical filtering procedure for data models of sequences on trees, allowing us to hand-tune the range of positional correlations in the data. Leveraging this controlled setting, we provide evidence that vanilla encoder-only transformers can approximate the exact inference algorithm when trained on root classification and masked language modeling tasks, and study how this computation is discovered and implemented. We find that correlations at larger distances, corresponding to increasing layers of the hierarchy, are sequentially included by the network during training. By comparing attention maps from models trained with varying degrees of filtering and by probing the different encoder levels, we find clear evidence of a reconstruction of correlations on successive length scales corresponding to the various levels of the hierarchy, which we relate to a plausible implementation of the exact inference algorithm within the same architecture.

📄 PDF Abstract BibTeX arXiv:2408.15138

Code (1)

emanuele-moscato/tree-language-paper-submission 공식 구현 pytorch

Tasks

Language ModelingLanguage ModellingMasked Language Modeling

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 제목 키워드 기반

Systematic Generalization and Emergent Structures in Transformers Trained on Structured Tasks

2022-10-02 · YuXuan Li, James L. McClelland

Transformer networks have seen great success in natural language processing and machine vision, where task objectives such as next word prediction and image classification benefit from nuanced context sensitivity across …

image-classificationImage ClassificationSystematic Generalization

Semantic Decomposition Improves Learning of Large Language Models on EHR Data

2022-11-14 · David A. Bloore, Romane Gauriau, Anna L. Decker, Jacob Oppenheim

Electronic health records (EHR) are widely believed to hold a profusion of actionable insights, encrypted in an irregular, semi-structured format, amidst a loud noise background. To simplify learning patterns of health a…

Graph AttentionMedical Diagnosis

Grokking of Hierarchical Structure in Vanilla Transformers

2023-05-30 · Shikhar Murty, Pratyusha Sharma, Jacob Andreas, Christopher D. Manning

For humans, language production and comprehension is sensitive to the hierarchical structure of sentences. In natural language processing, past work has questioned how effectively neural sequence models like transformers…

HATSolver: Learning Groebner Bases with Hierarchical Attention Transformers

2025-12-09 · Mohamed Malhou, Ludovic Perret, Kristin Lauter arxiv

At NeurIPS 2024, Kera et al. introduced the use of transformers for computing Groebner bases, a central object in computer algebra with numerous practical applications. In this paper, we improve this approach by applying…

Hierarchical Transformers Are More Efficient Language Models

2021-10-26 · Findings (NAACL) 2022 7 · Piotr Nawrot, Szymon Tworkowski, Michał Tyrolski, Łukasz Kaiser 외

Transformer models yield impressive results on many NLP and sequence modeling tasks. Remarkably, Transformers can handle long sequences which allows them to produce long coherent outputs: full paragraphs produced by GPT-…

Image GenerationLanguage ModelingLanguage Modelling