Efficient Semiring-Weighted Earley Parsing

要約

この論文は、さまざまな高速化を備えた Earley (1970) のコンテキストフリー解析アルゴリズムの参考説明を演繹システムの形式で提供します。
私たちのプレゼンテーションには、自然言語処理で発生する大規模な文法では実行不可能な Earley の $O (N^3|G||R|)$ から $O (N^3|G) への既知のワーストケースのランタイム改善が含まれています。
|)$、文法 $G$ のバイナリ化バージョンでの CKY のランタイムと一致します。
ここで、$N$ は文の長さ、$|R|$ は $G$ 内の作品の数、$|G|$ はそれらの作品の合計の長さです。
$|M| で $O (N^3|M|)$ の実行時間を実現するバージョンも提供しています。
\leq |G|$ は、文法が単一の有限状態オートマトン $M$ としてコンパクトに表現される場合です (これは部分的に斬新です)。
セミリング重み付き演繹への一般化を慎重に扱い、Stolcke (1995) のように文法を前処理して演繹サイクルを排除し、文接頭語の重みを計算する Stolcke の方法をさらに一般化します。
また、効率的な実行のための実装の詳細も提供します。これにより、前処理された文法では、メソッドのセミリング重み付けバージョンが、一部の文法でのサブキュービック ランタイムを含め、非重み付けメソッドと同じ漸近的なランタイムおよびスペース要件を持つことが保証されます。

要約(オリジナル)

This paper provides a reference description, in the form of a deduction system, of Earley’s (1970) context-free parsing algorithm with various speed-ups. Our presentation includes a known worst-case runtime improvement from Earley’s $O (N^3|G||R|)$, which is unworkable for the large grammars that arise in natural language processing, to $O (N^3|G|)$, which matches the runtime of CKY on a binarized version of the grammar $G$. Here $N$ is the length of the sentence, $|R|$ is the number of productions in $G$, and $|G|$ is the total length of those productions. We also provide a version that achieves runtime of $O (N^3|M|)$ with $|M| \leq |G|$ when the grammar is represented compactly as a single finite-state automaton $M$ (this is partly novel). We carefully treat the generalization to semiring-weighted deduction, preprocessing the grammar like Stolcke (1995) to eliminate deduction cycles, and further generalize Stolcke’s method to compute the weights of sentence prefixes. We also provide implementation details for efficient execution, ensuring that on a preprocessed grammar, the semiring-weighted versions of our methods have the same asymptotic runtime and space requirements as the unweighted methods, including sub-cubic runtime on some grammars.

arxiv情報

著者 Andreas Opedal,Ran Zmigrod,Tim Vieira,Ryan Cotterell,Jason Eisner
発行日 2023-07-06 13:33:59+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.CL, cs.DS, cs.FL パーマリンク