GiFT: Gibbs Fine-Tuning for Code Generation
Not on the map. Why?
Abstract (arXiv)
Training Large Language Models (LLMs) with synthetic data is a prevalent practice in code generation. A key approach is self-training, where LLMs are iteratively trained on self-generated correct code snippets. In this case, the self-generated codes are drawn from a conditional distribution, conditioned on a specific seed description. However, the seed description is not the only valid representation that aligns with its intended meaning. With all valid descriptions and codes forming a joint space, codes drawn from the conditional distribution would lead to an underrepresentation of the full description-code space. As such, we propose Gibbs Fine-Tuning (GiFT), a novel self-training method inspired by Gibbs sampling. GiFT allows self-generated data to be drawn from the marginal distribution of the joint space, thereby mitigating the biases inherent in conditional sampling. We provide a theoretical analysis demonstrating the potential benefits of fine-tuning LLMs with code derived from the marginal distribution. Furthermore, we propose a perplexity-based code selection method to mitigate the imbalanced long-tail distribution of the self-generated codes. Empirical evaluation of two LLMs across four datasets demonstrates that GiFT achieves superior performance, particularly on more challenging benchmarks. Source code is available at https://github.com/Alex-HaochenLi/GiFT.
Key facts. Cited by 3 papers in the map (data through 14 Oct 2026). Builds on 31 of its 41 references that are in the map. First posted on arXiv 17 Feb 2025.
Builds on
31 of 41 references.
References · 31
- 2023Judging LLM-as-a-Judge with MT-Bench and Chatbot Arenacited by 8,626
- 2021Program Synthesis with Large Language Modelscited by 3,637
- 2022Self-Instruct: Aligning Language Models with Self-Generated Instructionscited by 2,724
- 2023Code Llama: Open Foundation Models for Codecited by 2,139
- 2024A Survey on LLM-as-a-Judgecited by 1,423
- 2023Is Your Code Generated by ChatGPT Really Correct? Rigorous Evaluation of Large Language Models for Code Generationcited by 1,391
- 2024DeepSeek-Coder: When the Large Language Model Meets Programming -- The Rise of Code Intelligencecited by 1,181
- 2024OpenHands: An Open Platform for AI Software Developers as Generalist Agentscited by 1,002
- 2021Measuring Coding Challenge Competence With APPScited by 902
- 2023Large Language Modelscited by 780
- 2023WizardCoder: Empowering Code Large Language Models with Evol-Instructcited by 733
- 2022Large Language Models Can Self-Improvecited by 664
19 more
- 2024A Survey on Large Language Models for Code Generationcited by 658
- 2023Reinforced Self-Training (ReST) for Language Modelingcited by 500
- 2022CodeT: Code Generation with Generated Testscited by 384
- 2023The Curse of Recursion: Training on Generated Data Makes Models Forgetcited by 356
- 2023Beyond Human Data: Scaling Self-Training for Problem-Solving with Language Modelscited by 349
- 2024Large Language Model-Based Agents for Software Engineering: A Surveycited by 178
- 2022Large Language Models Meet NL2Code: A Surveycited by 138
- 2024A Tale of Tails: Model Collapse as a Change of Scaling Lawscited by 130
- 2024StepCoder: Improve Code Generation with Reinforcement Learning from Compiler Feedbackcited by 77
- 2024MathGenie: Generating Synthetic Data with Question Back-translation for Enhancing Mathematical Reasoning of LLMscited by 72
- 2024SelfCodeAlign: Self-Alignment for Code Generationcited by 62
- 2023WaveCoder: Widespread And Versatile Enhancement For Code Large Language Models By Instruction Tuningcited by 42
- 2024Rewriting the Code: A Simple Method for Large Language Model Augmented Code Searchcited by 17
- 2023Rethinking Negative Pairs in Code Searchcited by 14
- 2024Mitigating Tail Narrowing in LLM Self-Improvement via Socratic-Guided Samplingcited by 13
- 2024B4: Towards Optimal Assessment of Plausible Code Solutions with Plausible Testscited by 9
- 2024DSTC: Direct Preference Learning with Only Self-Generated Tests and Code to Improve Code LMscited by 9
- 2022Exploring Representation-Level Augmentation for Code Searchcited by 8
- 2024CodeInsight: A Curated Dataset of Practical Coding Solutions from Stack Overflowcited by 4
Built on by
Citing papers per year: 2025: 2; 2026: 1.
3 papers.