XFT: Unlocking the Power of Code Instruction Tuning by Simply Merging Upcycled Mixture-of-Experts
Yifeng Ding, Jiawei Liu, Yuxiang Wei, Lingming Zhang
Abstract
We introduce X FT, a simple yet powerful training scheme, by simply merging upcycled Mixture-of-Experts (MoE) to unleash the performance limit of instruction-tuned code Large Language Models (LLMs). While vanilla sparse upcycling fails to improve instruction tuning, X FT introduces a shared expert mechanism with a novel routing weight normalization strategy into sparse upcycling, which significantly boosts instruction tuning. After finetuning the upcycled MoE model, X FT introduces a learnable model merging mechanism to compile the upcycled MoE model back to a dense model, achieving upcycled MoE-level performance with only dense-model compute. By applying X FT to a 1.3B model, we create a new state-of-the-art tiny code LLM (<3B) with 67.1 and 64.6 pass@1 on HumanEval and Hu-manEval+ respectively. With the same data and model architecture, X FT improves supervised fine-tuning (SFT) by 13% on HumanEval+, along with consistent improvements from 2% to 13% on MBPP+, MultiPL-E, and DS-1000, demonstrating its generalizability. X FT is fully orthogonal to existing techniques such as Evol-Instruct and OSS-INSTRUCT, opening a new dimension for improving code instruction tuning. Codes are available at https: //github.com/ise-uiuc/xft .
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext d9998e77-6e61-4bed-ac2a-6b003c202d84Cited by top-tier papers5
- SelfCodeAlign: Self-Alignment for Code GenerationYuxiang Wei, Federico Cassano, Jiawei Liu, Yifeng Ding et al.NeurIPS 2024 · 79 citations
- Advancing SMoE for Continuous Domain Adaptation of MLLMs: Adaptive Router and Domain-Specific LossLiang Zhang, Ziyao Lu, Fandong Meng, Hui Li et al.ACL 2025 · 3 citations
- DeRS: Towards Extremely Efficient Upcycled Mixture-of-Experts ModelsYongqi Huang, Peng Ye, Chenyu Huang, Jianjian Cao et al.CVPR 2025
- Layerwise Recurrent Router for Mixture-of-ExpertsZihan Qiu, Zeyu Huang, Shuang Cheng, Yizhi Zhou et al.ICLR 2025
- CoVFT: Context-aware Visual Fine-tuning for Multimodal Large Language ModelsNan Zhou, Huiqun Wang, Yaoyan Zheng, Di HuangCVPR 2026
Builds on12
- Measuring Massive Multitask Language UnderstandingDan Hendrycks, Collin Burns, Steven Basart, Andy Zou et al.ICLR 2021 · 7,905 citations
- Is Your Code Generated by ChatGPT Really Correct? Rigorous Evaluation of Large Language Models for Code GenerationJiawei Liu, Chunqiu Steven Xia, Yuyao Wang, Lingming ZhangNeurIPS 2023 · 2,317 citations
- GShard: Scaling Giant Models with Conditional Computation and Automatic ShardingDmitry Lepikhin, HyoukJoong Lee, Yuanzhong Xu, Dehao Chen et al.ICLR 2021 · 1,954 citations
- Model soups: averaging weights of multiple fine-tuned models improves accuracy without increasing inference timeMitchell Wortsman, Gabriel Ilharco, Samir Yitzhak Gadre, Rebecca Roelofs et al.ICML 2022 · 1,464 citations
- WizardCoder: Empowering Code Large Language Models with Evol-InstructZiyang Luo, Can Xu, Pu Zhao, Qingfeng Sun et al.ICLR 2024 · 945 citations
Related papers
- Upcycling Instruction Tuning from Dense to Mixture-of-Experts via Parameter MergingTingfeng Hui, Zhenyu Zhang, Shuohuan Wang, Yu Sun et al.ACL 2025
- Automatic Expert Discovery in LLM Upcycling via Sparse Interpolated Mixture-of-ExpertsShengzhuang Chen, Ying Wei, Jonathan Richard SchwarzACL 2025
- Mixture-of-Experts Meets Instruction Tuning: A Winning Combination for Large Language ModelsSheng Shen, Le Hou, Yanqi Zhou, Nan Du et al.ICLR 2024 · 87 citations
- Drop-Upcycling: Training Sparse Mixture of Experts with Partial Re-initializationTaishi Nakamura, Takuya Akiba, Kazuki Fujii, Yusuke Oda et al.ICLR 2025
- Let the Expert Stick to His Last: Expert-Specialized Fine-Tuning for Sparse Architectural Large Language ModelsZihan Wang, Deli Chen, Damai Dai, Runxin Xu et al.EMNLP 2024 · 2 citations
