HackerPapers

arXiv:2305.02386cs.CL

Approximating CKY with Transformers

Ghazal Khalighinejad, Ollie Liu, Sam Wiseman

Early discovery. Linked by one identifiable commenter. This paper is outside the main ranking; a mention is not an endorsement.

Abstract

We investigate the ability of transformer models to approximate the CKY algorithm, using them to directly predict a sentence's parse and thus avoid the CKY algorithm's cubic dependence on sentence length. We find that on standard constituency parsing benchmarks this approach achieves competitive or better performance than comparable parsers that make use of CKY, while being faster. We also evaluate the viability of this approach for parsing under \textit{random} PCFGs. Here we find that performance declines as the grammar becomes more ambiguous, suggesting that the transformer is not fully capturing the CKY computation. However, we also find that incorporating additional inductive bias is helpful, and we propose a novel approach that makes use of gradients with respect to chart representations in predicting the parse, in analogy with the CKY algorithm being a subgradient of a partition function variant with respect to the chart.

arXiv comments
EMNLP 2023
Journal reference
DOI
Subjects
cs.CLComputation and Language cs.LGMachine Learning

On Hacker News

Linked by 1 identifiable commenter in 1 comment across 1 thread, from Jun 2023 to Jun 2023.

Comments linking this paper, per year.

Discussed in comments1 thread

    • > LLM's don't actually understand anything (as greater concepts), but rather operate as complex probability machines? What does it mean to "operate as a probability machine"? And what does it mean to understand anything? One recent example of understanding is that…

      thomasahleView on HNParent context

Submitted to Hacker News

Connected through shared HN threads, not inferred similarity or a recommendation.