InfeRE: Step-by-Step Regex Generation via Chain of Inference

要約

自然言語記述 (NL2RE) から正規表現 (略称 regexes) を自動的に生成することは、新たな研究分野となっています。
以前の研究では、正規表現をトークンの線形シーケンスとして扱い、最終的な式を 1 回のパスで自己回帰的に生成しました。
最終結果の背後にある段階的な内部テキストマッチングプロセスは考慮されていませんでした。
これは、ニューラル言語モデルによる正規表現生成の有効性と解釈可能性を著しく妨げます。
この論文では、正規表現の生成を段階的な推論のチェーンに分解する、InfeRE と呼ばれる新しいパラダイムを提案します。
堅牢性を強化するために、異なるモデルからサンプリングされた複数の出力をアンサンブルする自己一貫性デコード メカニズムを導入します。
NL-RX-Turk と KB13 という 2 つの公的に利用可能なデータセットで InfeRE を評価し、その結果を最先端のアプローチおよび人気のあるツリーベースの生成アプローチ TRANX と比較します。
実験結果は、InfeRE が以前のベースラインを大幅に上回り、2 つのデータセットで DFA@5 精度がそれぞれ 16.3% および 14.7% 向上したことを示しています。
特に、InfeRE は、DFA@5 の精度の点で、両方のデータセットで一般的なツリーベースの生成アプローチをそれぞれ 18.1% および 11.3% 上回っています。

要約(オリジナル)

Automatically generating regular expressions (abbrev. regexes) from natural language description (NL2RE) has been an emerging research area. Prior studies treat regex as a linear sequence of tokens and generate the final expressions autoregressively in a single pass. They did not take into account the step-by-step internal text-matching processes behind the final results. This significantly hinders the efficacy and interpretability of regex generation by neural language models. In this paper, we propose a new paradigm called InfeRE, which decomposes the generation of regexes into chains of step-by-step inference. To enhance the robustness, we introduce a self-consistency decoding mechanism that ensembles multiple outputs sampled from different models. We evaluate InfeRE on two publicly available datasets, NL-RX-Turk and KB13, and compare the results with state-of-the-art approaches and the popular tree-based generation approach TRANX. Experimental results show that InfeRE substantially outperforms previous baselines, yielding 16.3% and 14.7% improvement in DFA@5 accuracy on two datasets, respectively. Particularly, InfeRE outperforms the popular tree-based generation approach by 18.1% and 11.3% on both datasets, respectively, in terms of DFA@5 accuracy.

arxiv情報

著者 Shuai Zhang,Xiaodong Gu,Yuting Chen,Beijun Shen
発行日 2023-08-08 04:37:41+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

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