Explicit Knowledge Transfer for Weakly-Supervised Code Generation
Zhangir Azerbayev, Ansong Ni, Hailey Schoelkopf, Dragomir Radev

TL;DR
This paper introduces explicit knowledge transfer (EKT), a method for transferring code generation skills from large language models to smaller models using weakly-supervised data, improving performance on math problem solving tasks.
Contribution
The paper proposes EKT, a novel approach that leverages few-shot capabilities of LLMs to generate and filter training data for smaller models, outperforming existing knowledge transfer methods.
Findings
EKT improves code generation performance on GSM8k.
EKT outperforms knowledge distillation in experiments.
A smaller model can outperform its teacher using EKT.
Abstract
Large language models (LLMs) can acquire strong code-generation capabilities through few-shot learning. In contrast, supervised fine-tuning is still needed for smaller models to achieve good performance. Such fine-tuning demands a large number of task-specific NL-code pairs, which are expensive to obtain. In this paper, we attempt to transfer the code generation ability of an LLM to a smaller model with the aid of weakly-supervised data. More specifically, we propose explicit knowledge transfer (EKT), which uses the few-shot capabilities of a teacher LLM to create NL-code pairs that we then filter for correctness and fine-tune the student on. We evaluate EKT on the task of generating code solutions to math word problems from the GSM8k dataset. We find that EKT not only yields better performance than training with expert iteration, but also outperforms knowledge distillation, another…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsTopic Modeling · Natural Language Processing Techniques · Speech Recognition and Synthesis
MethodsKnowledge Distillation · GPT-Neo
