The reviewed record of science sign in
Pith

arxiv: 2410.03001 · v1 · pith:Q2SVGR4Y · submitted 2024-10-03 · cs.CL

Can Transformers Learn n-gram Language Models?

Reviewed by Pith T0 review T1 audit T2 compute T3 formal T4 kernel pith:Q2SVGR4Yrecord.jsonopen to challenge →

classification cs.CL
keywords transformersgramlearntheoreticalabilityformallanguagelanguages
0
0 comments X
read the original abstract

Much theoretical work has described the ability of transformers to represent formal languages. However, linking theoretical results to empirical performance is not straightforward due to the complex interplay between the architecture, the learning algorithm, and training data. To test whether theoretical lower bounds imply \emph{learnability} of formal languages, we turn to recent work relating transformers to $n$-gram language models (LMs). We study transformers' ability to learn random $n$-gram LMs of two kinds: ones with arbitrary next-symbol probabilities and ones where those are defined with shared parameters. We find that classic estimation techniques for $n$-gram LMs such as add-$\lambda$ smoothing outperform transformers on the former, while transformers perform better on the latter, outperforming methods specifically designed to learn $n$-gram LMs.

This paper has not been read by Pith yet.

discussion (0)

Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.