RefineCoder: Iterative Improving of Large Language Models via Adaptive Critique Refinement for Code Generation

Changzhi Zhou, Xinyu Zhang, Dandan Song, Xiancai Chen, Wanli Gu +4 more
2/13/2025
cs.CLcs.AI

No confident code implementation found for this paper.

Abstract

Code generation has attracted increasing attention with the rise of Large Language Models (LLMs). Many studies have developed powerful code LLMs by synthesizing code-related instruction data and applying supervised fine-tuning. However, these methods are limited by teacher model distillation and ignore the potential of iterative refinement by self-generated code. In this paper, we propose Adaptive Critique Refinement (ACR), which enables the model to refine itself by self-generated code and external critique, rather than directly imitating the code responses of the teacher model. Concretely, ACR includes a composite scoring system with LLM-as-a-Judge to evaluate the quality of code responses and a selective critique strategy with LLM-as-a-Critic to critique self-generated low-quality code responses. We develop the RefineCoder series by iteratively applying ACR, achieving continuous performance improvement on multiple code generation benchmarks. Compared to the baselines of the same size, our proposed RefineCoder series can achieve comparable or even superior performance using less data.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{zhou2025refinecoder,
  title  = {RefineCoder: Iterative Improving of Large Language Models via Adaptive Critique Refinement for Code Generation},
  author = {Changzhi Zhou and Xinyu Zhang and Dandan Song and Xiancai Chen and Wanli Gu and Huipeng Ma and Yuhang Tian and Mengdi Zhang and Linmei Hu},
  year   = {2025},
  eprint = {2502.09183},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.09183v2}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2502.09183.svg)](https://codeofpaper.com/paper/2502.09183)

Discussion