ChatPaper.aiChatPaper

強化学習によるLLMコーダーとユニットテスターの共進化

Co-Evolving LLM Coder and Unit Tester via Reinforcement Learning

June 3, 2025
著者: Yinjie Wang, Ling Yang, Ye Tian, Ke Shen, Mengdi Wang
cs.AI

要旨

我々はCUREを提案する。これは、コーディングとユニットテスト生成能力をその相互作用の結果に基づいて共進化させる専用の報酬設計を備えた新しい強化学習フレームワークであり、教師データとしての正解コードを一切必要としない。このアプローチにより、柔軟でスケーラブルな学習が可能となり、ユニットテスターがコーダーのミスから直接学ぶことを可能にする。我々が開発したReasonFlux-Coder-7Bおよび14Bモデルは、Qwen2.5-Instructモデル上で最適化を行った結果、コード生成精度を5.3%、Best-of-N精度を9.0%向上させ、同規模のQwen-Coder、DeepSeek-Coder、Seed-Coderを上回った。これらのモデルは、テスト時のスケーリングやエージェント型コーディングといった下流タスクにも自然に拡張可能で、ベースモデルに対して8.1%の改善を達成した。long-CoTモデルにおいては、ReasonFlux-Coder-4BがQwen3-4Bを一貫して上回りつつ、ユニットテスト生成において64.8%の推論効率を達成した。特に注目すべきは、我々のモデルがベースモデルに対する強化学習の効果的な報酬モデルとしても機能し得る点である。プロジェクト: https://github.com/Gen-Verse/CURE
English
We propose CURE, a novel reinforcement learning framework with a dedicated reward design that co-evolves coding and unit test generation capabilities based on their interaction outcomes, without any ground-truth code as supervision. This approach enables flexible and scalable training and allows the unit tester to learn directly from the coder's mistakes. Our derived ReasonFlux-Coder-7B and 14B models improve code generation accuracy by 5.3% and Best-of-N accuracy by 9.0% after optimization on Qwen2.5-Instruct models, outperforming similarly sized Qwen-Coder, DeepSeek-Coder, and Seed-Coder. They naturally extend to downstream tasks such as test-time scaling and agentic coding-achieving a 8.1% improvement over the base model. For the long-CoT model, our ReasonFlux-Coder-4B consistently outperforms Qwen3-4B while achieving 64.8% inference efficiency in unit test generation. Notably, we also find that our model can serve as an effective reward model for reinforcement learning on base models. Project: https://github.com/Gen-Verse/CURE
PDF244June 4, 2025