LeTI: Learning to Generate from Textual Interactions

要約

事前トレーニングされた言語モデル (LM) を微調整すると、モデルの機能が強化されます。
従来の技術は、入出力ペア(例えば、命令の微調整)、またはその出力の品質を評価する数値的報酬(例えば、人間のフィードバックからの強化学習)によって、事前に訓練されたLMを微調整します。
私たちは、LM がテキスト インタラクション (LeTI) から学習する可能性を探ります。LeTI は、バイナリ ラベルで正しさをチェックするだけでなく、テキスト フィードバックを通じて出力のエラーを特定して説明します。
私たちの調査は、モデルが自然言語命令に応じてコード部分を生成するコード生成タスクに焦点を当てています。
この設定により、テキスト フィードバック (Python インタープリターを使用したコード実行からのエラー メッセージとスタック トレース) を取得する自然かつスケーラブルな方法が実現します。
LeTI は、自然言語命令、LM で生成されたプログラム、および生成されたプログラムがタスクの解決に失敗した場合にのみ提供されるテキスト フィードバックを連結した LM 目標を使用して、モデルを繰り返し微調整します。
この微調整テキストの前にバイナリ報酬トークンが追加され、正しいソリューションとバグのあるソリューションを区別するために使用されます。
コード生成データセットである MBPP では、LeTI はスケールの異なる 2 つのベース LM のパフォーマンスを大幅に向上させます。
LeTI はトレーニングにグラウンドトゥルース出力を必要とせず、必要とする微調整されたベースラインよりも優れたパフォーマンスを発揮します。
LeTI の優れたパフォーマンスは他のデータセットにも一般化されます。
MBPP でトレーニングされているため、HumanEval の目に見えない問題に関して、ベース LM と同等以上のパフォーマンスを達成します。
さらに、バイナリ フィードバックと比較して、テキスト フィードバックは生成品質とサンプル効率の向上につながり、半分未満のグラジエント ステップで同じパフォーマンスを達成できることがわかりました。
LeTI は、自然言語タスクがコード生成として定式化できる場合には、自然言語タスクにも同様に適用できます。これは、イベント引数の抽出で経験的に検証されました。

要約(オリジナル)

Finetuning pre-trained language models (LMs) enhances the models’ capabilities. Prior techniques fine-tune a pre-trained LM on input-output pairs (e.g., instruction fine-tuning), or with numerical rewards that gauge the quality of its outputs (e.g., reinforcement learning from human feedback). We explore LMs’ potential to learn from textual interactions (LeTI) that not only check their correctness with binary labels, but also pinpoint and explain errors in their outputs through textual feedback. Our investigation focuses on the code generation task, where the model produces code pieces in response to natural language instructions. This setting invites a natural and scalable way to acquire the textual feedback: the error messages and stack traces from code execution using a Python interpreter. LeTI iteratively fine-tunes the model, using the LM objective, on a concatenation of natural language instructions, LM-generated programs, and textual feedback, which is only provided when the generated program fails to solve the task. Prepended to this fine-tuning text, a binary reward token is used to differentiate correct and buggy solutions. On MBPP, a code generation dataset, LeTI substantially improves the performance of two base LMs of different scales. LeTI requires no ground-truth outputs for training and even outperforms a fine-tuned baseline that does. LeTI’s strong performance generalizes to other datasets. Trained on MBPP, it achieves comparable or better performance than the base LMs on unseen problems in HumanEval. Furthermore, compared to binary feedback, we observe that textual feedback leads to improved generation quality and sample efficiency, achieving the same performance with fewer than half of the gradient steps. LeTI is equally applicable in natural language tasks when they can be formulated as code generation, which we empirically verified on event argument extraction.

arxiv情報

著者 Xingyao Wang,Hao Peng,Reyhaneh Jabbarvand,Heng Ji
発行日 2023-05-17 15:53:31+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

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