RLTF: ユニットテストフィードバックからの強化学習
RLTF: Reinforcement Learning from Unit Test Feedback
July 10, 2023
著者: Jiate Liu, Yiqin Zhu, Kaiwen Xiao, Qiang Fu, Xiao Han, Wei Yang, Deheng Ye
cs.AI
要旨
プログラム合成、またはコード生成の目標は、与えられた記述に基づいて実行可能なコードを生成することです。最近、大規模言語モデル(LLM)のコード生成性能を向上させるために強化学習(RL)を活用する研究が増えています。しかし、これらのRL手法はオフラインフレームワークのみを使用しており、新しいサンプル空間の探索が制限されています。さらに、現在のユニットテスト信号を利用するアプローチは比較的単純で、コード内の特定のエラー位置を考慮していません。これらの問題に対処するため、我々はRLTF、すなわちユニットテストフィードバックからの強化学習を提案しました。これは、コードLLMを洗練するための多粒度のユニットテストフィードバックを備えた新しいオンラインRLフレームワークです。我々のアプローチは、トレーニング中にリアルタイムでデータを生成し、同時に細かい粒度のフィードバック信号を利用して、より高品質なコードを生成するようモデルを導きます。大規模な実験により、RLTFがAPPSおよびMBPPベンチマークで最先端の性能を達成することが示されました。我々のコードは以下で確認できます:https://github.com/Zyq-scut/RLTF。
English
The goal of program synthesis, or code generation, is to generate executable
code based on given descriptions. Recently, there has been an increasing number
of studies employing reinforcement learning (RL) to improve the performance of
large language models (LLMs) for code. However, these RL methods have only used
offline frameworks, limiting their exploration of new sample spaces.
Additionally, current approaches that utilize unit test signals are rather
simple, not accounting for specific error locations within the code. To address
these issues, we proposed RLTF, i.e., Reinforcement Learning from Unit Test
Feedback, a novel online RL framework with unit test feedback of
multi-granularity for refining code LLMs. Our approach generates data in
real-time during training and simultaneously utilizes fine-grained feedback
signals to guide the model towards producing higher-quality code. Extensive
experiments show that RLTF achieves state-of-the-art performance on the APPS
and the MBPP benchmarks. Our code can be found at:
https://github.com/Zyq-scut/RLTF.