Lune

NeurIPS2023顶会

A Logic for Expressing Log-Precision Transformers

William Merrill, Ashish Sabharwal

摘要

One way to interpret the reasoning power of transformer-based language models is to describe the types of logical rules they can resolve over some input text. Recently, Chiang et al. (2023) showed that finite-precision transformer classifiers can be equivalently expressed in a generalization of first-order logic. However, finite-precision transformers are a weak transformer variant because, as we show, a single head can only attend to a constant number of tokens and, in particular, cannot represent uniform attention. Since attending broadly is a core capability for transformers, we ask whether a minimally more expressive model that can attend universally can also be characterized in logic. To this end, we analyze transformers whose forward pass is computed in log n precision on contexts of length n. We prove any log-precision transformer classifier can be equivalently expressed as a first-order logic sentence that, in addition to standard universal and existential quantifiers, may also contain majority-vote quantifiers. This is the tightest known upper bound and first logical characterization of log-precision transformers. Any log-precision transformer can be re-expressed as a sentence in FO(M) logic, e.g.: Mi. a(i) ∧ Mj. b(j) ∧ ¬∃k, ℓ. (a(k) ∧ b(ℓ) ∧ ℓ < k) (m a's followed by m b's, i.e., a m b m ) aaaabbbb ✓ aaabbbbb ✗ baaaabbb ✗ Figure 1: A first-order logic with majority (FO(M)) sentence for a m b m . In addition to standard ∀ and ∃ quantifiers over string indices, FO(M) allows majority quantifiers (M) that take a majority-vote across indices. a(i) indicates whether token i is a (and analogously for b). We prove FO(M) can express any function computed by a log-precision transformer.

问 Lune

几分钟读透这篇 Paper,不用再花一下午。

Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。

已有 37 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。

可以从这些问题问起

Lune 可以查阅

全文 · 引用它的顶会 Paper · 相关的 Paper

获取答案

免费开始,无需绑卡

脉络

  • The Expressive Power of Transformers with Chain of Thought 引用了 Transformers Learn Shortcuts to Automata
  • The Expressive Power of Transformers with Chain of Thought 引用了 Tighter Bounds on the Expressivity of Transformer Encoders
  • The Expressive Power of Transformers with Chain of Thought 引用了 On Layer Normalization in the Transformer Architecture
  • The Expressive Power of Transformers with Chain of Thought 引用了 Faith and Fate: Limits of Transformers on Compositionality
  • Chain of Thought Empowers Transformers to Solve Inherently Serial Problems 引用了 Transformers Learn Shortcuts to Automata
  • Chain of Thought Empowers Transformers to Solve Inherently Serial Problems 引用了 Tighter Bounds on the Expressivity of Transformer Encoders
  • Chain of Thought Empowers Transformers to Solve Inherently Serial Problems 引用了 On Layer Normalization in the Transformer Architecture
  • Transformers Learn Shortcuts to Automata 引用了 On the Ability and Limitations of Transformers to Recognize Formal Languages
  • The Illusion of State in State-Space Models 引用了 The Expressive Power of Transformers with Chain of Thought
  • The Illusion of State in State-Space Models 引用了 Transformers Learn Shortcuts to Automata
  • The Illusion of State in State-Space Models 引用了 Tighter Bounds on the Expressivity of Transformer Encoders
  • Understanding Transformer Reasoning Capabilities via Graph Algorithms 引用了 The Expressive Power of Transformers with Chain of Thought
  • Understanding Transformer Reasoning Capabilities via Graph Algorithms 引用了 Transformers Learn Shortcuts to Automata
  • Understanding Transformer Reasoning Capabilities via Graph Algorithms 引用了 Language Models are Few-Shot Learners
  • Tighter Bounds on the Expressivity of Transformer Encoders 引用了 On the Ability and Limitations of Transformers to Recognize Formal Languages
  • Faith and Fate: Limits of Transformers on Compositionality 引用了 Transformers Learn Shortcuts to Automata
  • Faith and Fate: Limits of Transformers on Compositionality 引用了 Language Models are Few-Shot Learners
  • Faith and Fate: Limits of Transformers on Compositionality 引用了 Tighter Bounds on the Expressivity of Transformer Encoders
它引用的引用它的从左到右按年份排列,引用越多,位置越高。

引用它的顶会 Paper37

  1. Faith and Fate: Limits of Transformers on CompositionalityNouha Dziri, Ximing Lu, Melanie Sclar, Xiang Lorraine Li 等NeurIPS 2023 · 728 次引用
  2. Chain of Thought Empowers Transformers to Solve Inherently Serial ProblemsZhiyuan Liu, Hong Liu, Denny Zhou, Tengyu MaICLR 2024 · 259 次引用
  3. The Expressive Power of Transformers with Chain of ThoughtWilliam Merrill, Ashish SabharwalICLR 2024 · 243 次引用
  4. The Illusion of State in State-Space ModelsWilliam Merrill, Jackson Petty, Ashish SabharwalICML 2024 · 157 次引用
  5. Understanding Transformer Reasoning Capabilities via Graph AlgorithmsClayton Sanford, Bahare Fatemi, Ethan Hall, Anton Tsitsulin 等NeurIPS 2024 · 84 次引用

它引用的 Paper6

  1. Language Models are Few-Shot LearnersTom B. Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah 等NeurIPS 2020 · 64,255 次引用
  2. On Layer Normalization in the Transformer ArchitectureRuibin Xiong, Yunchang Yang, Di He, Kai Zheng 等ICML 2020 · 1,388 次引用
  3. Tighter Bounds on the Expressivity of Transformer EncodersDavid Chiang, Peter Cholak, Anand PillayICML 2023 · 80 次引用
  4. Transformers Learn Shortcuts to AutomataBingbin Liu, Jordan T. Ash, Surbhi Goel, Akshay Krishnamurthy 等ICLR 2023 · 11 次引用
  5. On the Ability and Limitations of Transformers to Recognize Formal LanguagesSatwik Bhattamishra, Kabir Ahuja, Navin GoyalEMNLP 2020 · 7 次引用

相关 Paper

  1. Characterizing the Expressivity of Fixed-Precision Transformer Language ModelsJiaoda Li, Ryan CotterellNeurIPS 2025 · 18 次引用
  2. Characterizing the Expressivity of Local Attention in TransformersJiaoda Li, Ryan CotterellACL 2026 · 2 次引用
  3. Revisiting Padded Transformer Expressivity: Which Architectural Choices Matter and Which Don'tAnej Svete, William Merrill, Ryan Cotterell, Ashish SabharwalICML 2026 · 3 次引用
  4. Expressive Power of Graph Transformers via LogicVeeti Ahvonen, Maurice Funk, Damian Heiman, Antti Kuusisto 等AAAI 2026
  5. Not all quantifiers are equal: Probing Transformer-based language models' understanding of generalised quantifiersTharindu Madusanka, Iqra Zahid, Hao Li, Ian Pratt-Hartmann 等EMNLP 2023 · 2 次引用
黄昏的海面,两侧是细线勾勒的悬崖