TL;DR
This paper introduces On-policy Verbal Distillation (OVD), a novel knowledge distillation method that significantly reduces memory requirements and improves training efficiency for large language models (LLMs). OVD replaces computationally expensive token-level probability matching with a more efficient trajectory-level matching using discrete verbal scores from a teacher model, enabling better exploration and performance on complex reasoning tasks.
What Problem Does This Paper Address?
Training large language models (LLMs) for complex, multi-step reasoning tasks is computationally intensive and resource-demanding. Knowledge distillation offers a way to transfer reasoning capabilities from large "teacher" models to smaller, more efficient "student" models. However, existing methods for on-policy distillation (where the student learns by interacting with an environment) face significant challenges:
- Memory Bottleneck: Token-level distillation requires storing detailed probability distributions for every token, leading to prohibitive memory usage, especially for long reasoning sequences. This limits the batch size and the ability to train on complex tasks.
- Restricted Exploration: Token-level alignment can constrain the student model's ability to explore different reasoning paths, hindering its learning process.
- Inefficient Feedback: Existing methods struggle to effectively leverage interactive feedback from environments, which is crucial for developing long-horizon reasoning.
Methods
OVD tackles these issues by introducing a memory-efficient, on-policy distillation framework that uses verbal feedback from a teacher model. Instead of matching token-level probabilities, OVD focuses on trajectory matching using discrete verbal scores (0-9) provided by the teacher.
Here's how it works:
- Verbal Scoring: The teacher model (either an environment agent for Q&A or a reasoning model for math tasks) provides discrete verbal scores for each reasoning step or the entire trajectory. These scores indicate the quality, correctness, and relevance of the student's reasoning.
- Verbal Rejection Sampling: This is the core mechanism. The student generates trajectories, and the teacher assigns verbal scores. Trajectories with low scores are rejected and replaced by demonstrations from the teacher. This process is "on-policy" because the student's own generated trajectories are used for training, mitigating distribution shift issues common in off-policy methods.
- Trajectory-Level Optimization: The student model is then trained using these accepted trajectories and teacher demonstrations, optimizing for the overall trajectory quality rather than just token-level accuracy. This allows the student to freely explore the output space.
- Memory Efficiency: By replacing high-dimensional token probabilities with low-dimensional verbal scores, OVD drastically reduces memory consumption, enabling longer trajectories and larger batch sizes.
Datasets
The paper evaluates OVD on two main categories of tasks:
- Web Q&A Tasks: Eight benchmarks are used, including single-hop (NQ, TriviaQA, PopQA) and multi-hop (HotpotQA, 2Wiki, Musique, Bamboogle, GAIA) reasoning.
- Mathematical Reasoning Tasks: Eight benchmarks are used, including SVAMP, ASDiv, MAWPS, TABMWP, Minerva, OlympiadBench, SAT-Math, MMLU, Gaokao, and AIME2024.
The paper also mentions using a simulated search environment for Web Q&A tasks, trained using supervised fine-tuning (SFT) to mimic search engine outputs.
Key Insights and Ideas
- Verbal Scores as a Powerful Signal: Discrete verbal scores from a teacher model are surprisingly effective for guiding student learning, offering a more interpretable and memory-efficient alternative to token-level probabilities.
- On-Policy Exploration with Teacher Guidance: OVD strikes a balance between student exploration and teacher guidance. By using verbal rejection sampling, it allows students to explore freely while ensuring that low-quality explorations are corrected by teacher demonstrations, leading to more stable and efficient learning.
- Curriculum Learning Emerges Naturally: The verbal rejection sampling mechanism implicitly creates a curriculum. Initially, the student relies heavily on teacher demonstrations, but as it improves, more of its own trajectories are accepted, naturally shifting towards self-learning.
- Black-Box Distillation is Achievable: OVD's reliance on discrete scores, rather than full probability distributions, makes it suitable for distilling knowledge from "black-box" teacher models where internal workings are inaccessible.
Key Results
OVD demonstrates significant improvements across various benchmarks:
- Web Q&A: OVD achieves up to +12.9% absolute improvement in average Exact Match (EM) scores on Web Q&A tasks compared to existing methods.
- Mathematical Reasoning: OVD shows substantial gains, with up to +25.7% improvement on math benchmarks, even when trained with only one random sample per problem.
- Training Efficiency: OVD exhibits superior sample efficiency, converging faster and achieving near-optimal performance with fewer training steps and samples.
- Memory Reduction: The paper highlights a dramatic reduction in memory consumption, making it feasible to train on longer sequences and larger batch sizes. For instance, storing logits for a single batch can be reduced from 160 GB to a negligible amount.
Limitations and Future Work
- Teacher Model Dependency: The performance of OVD is inherently tied to the quality of the teacher model's verbal feedback. If the teacher's scoring is inaccurate or biased, it can negatively impact the student's learning.
- Score Granularity: While the paper explores the trade-offs of score granularity (v), finding the optimal balance between expressiveness and interpretability remains an area of interest. The authors suggest that v=10 provides a good balance.
- Future Work: The authors suggest exploring more sophisticated verbal scoring mechanisms and investigating how OVD can be applied to even more complex reasoning tasks and domains. They also highlight the potential for OVD to be used in scenarios where teacher models are only accessible via an API.
Summary updated