Large Language Model Distillation and Refusal Behavior Tuning: A Practical Breakdown
This article breaks down a real-world pipeline for building a lightweight reasoning model: a larger teacher model generates worked solutions, an open 9B base model is fine-tuned on them, a light reinforcement learning pass is applied, and refusal behavior is then adjusted through activation-level intervention. It explains what distillation actually transfers, how to structure teacher samples, key SFT and reward design choices, which layers to target when tuning refusals, and how to evaluate the result across capability, safety, and cost. Readers will find a reproducible checklist and a three-layer evaluation dashboard approach.
1. Background and Problem Definition
A derivative model with roughly 9 billion parameters recently topped the trending list on a model aggregation community. Its origin is not mysterious: a much larger teacher model with about 1.6 trillion total parameters was used to batch-generate problem-solving samples, those samples were used to run supervised fine-tuning on an open-source 9B base model, a light round of reinforcement learning was added afterward, and finally another publisher adjusted the refusal behavior on the completed weights. In other words, this 9B checkpoint went through two rounds of modification: one aimed at “being able to solve problems,” and one aimed at “being willing to answer.”
A common misconception is worth clearing up here: distillation does not compress a large model’s parameters into a small model. It transfers the large model’s behavior distribution to the small model. The small model does not learn weights; it learns solution paths and output distributions. As a result, the ceiling on distillation quality is largely determined by the structure and coverage of the samples produced by the teacher model.
2. Pipeline Breakdown: From Teacher Samples to a Usable Small Model
2.1 Teacher Stage: Constructing Solution Samples
According to the original material, the teacher model generated about 250,000 math and STEM samples in a high-effort mode. The value of these samples lies not in the answers themselves but in being “process-visible”: where to start, how to decompose the problem, how each step is derived, and what conclusion is reached. In engineering practice, samples are usually expected to have four elements:
- Complete reproduction of the problem statement and constraints, avoiding ambiguity;
- A clear entry point and the reasoning behind the chosen approach;
- Step-by-step derivation with verifiable key steps;
- A final answer and a self-check conclusion.
Sample construction should follow a three-dimensional grid of difficulty tiers, subject tiers, and problem-type tiers, with deduplication and filtering for repeated problems, extremely short problems, and unsolvable problems. More is not always better; 250,000 samples is already a substantial volume, and what truly determines the outcome is whether the difficulty distribution matches the target scenario.
2.2 Student Stage: Supervised Fine-Tuning (SFT)
The student model is an open-source 9B base. The goal of SFT is to make the model imitate the teacher’s problem-solving process, not merely memorize answers. Practical points include:
- Data cleaning: remove samples with broken formatting, skipped derivation steps, or answers that contradict the process;
- Length control: overly long samples dilute attention, so truncate or bucket by percentile;
- Learning rate and epochs: small-model SFT usually needs only 1–3 epochs, and overfitting will damage general capability;
- Retaining a general-purpose corpus ratio: if the data is entirely STEM, general conversational ability drops noticeably.
Illustrative training configuration (pseudocode, structure only):
# Illustrative flow only; not tied to any specific framework APIfor epoch in range(3):for batch in dedup(science_math_samples):loss = sft_loss(student_9b, batch) # supervise "process + answer" onlyloss.backward()optimizer.step()
2.3 Reinforcement Stage: Lightweight Post-Training with GSPO
The material mentions a subsequent lightweight round of reinforcement learning using GSPO. GSPO follows a sequence-level importance sampling policy optimization approach and is characterized by more stable training and better tolerance for length and variance. The key to keeping it lightweight is to give rewards only around math and STEM reasoning, without using coding data, to avoid capability drift. The reward design can use a composite signal of answer correctness, process verifiability, and format compliance, with a penalty for excessively long outputs.
3. The Second Modification: Activation-Level Tuning of Refusal Behavior
3.1 Method Principle
The publisher of the derivative version used the ARA method from Heretic: compare the model’s internal activations when handling different types of prompts, locate the signal direction associated with refusal, then modify the weights of some layers to weaken that signal’s influence on the output. It is essentially a hybrid of representation engineering and weight fine-tuning; it does not rely on large amounts of labeled data, and it is low-cost and fast to take effect.
3.2 Choosing the Layer Range
The published configuration set the adjustment range to layers 9 through 24. This choice matches an empirical rule: layers that are too shallow carry general syntax and vocabulary, and modifying them easily damages language ability; layers that are too deep are strongly coupled with the final logits, and modifying them easily causes output collapse. Middle layers (roughly one-third to two-thirds of the depth) are usually the dense region for “intent and safety representations,” making them suitable for targeted weakening.
3.3 Risks and Boundaries
Refusal behavior often carries both safety alignment and compliance constraints. Weakening the refusal signal may bring two kinds of risk: first, reduced resistance to genuinely harmful requests; second, output distribution shift that causes factual fluctuations. Therefore, KL divergence must be used to monitor distribution drift, and a safety evaluation set must be retained for regression.
4. Evaluation: Metric Definitions and Interpreting Results
4.1 Distillation Stage Metrics
- STEM accuracy: a small improvement, indicating that process distillation has a positive effect on reasoning, though the magnitude is bounded by the base model’s capability ceiling;
- Format compliance rate: the proportion of outputs that follow the required format is close to 97%, showing that SFT shapes instruction following significantly;
- Inference cost: both first-token latency and total generation length must be recorded, to avoid “accuracy improves but cost explodes.”
4.2 Refusal Adjustment Stage Metrics
- Refusal comparison: on the same set of 100 prompts, the distilled version refused all of them, while the adjusted version refused only 3;
- Distribution drift: KL divergence of 0.0422, a relatively small magnitude, indicating the change was concentrated in the middle-to-late layers and did not broadly break the original distribution;
- Regression items: safety and general-capability sets must be added; looking only at the drop in refusals leads to a one-sided conclusion.
The evaluation is best organized as a “three-layer dashboard”: capability layer (accuracy / compliance rate), safety layer (refusal and harmful rate), and cost layer (latency / length / GPU memory).
5. Reproducible Practice Checklist
- Define the target capability boundary: if you only want STEM reasoning, do not mix in coding data;
- Apply three-dimensional tiering and deduplication to teacher samples, ensuring the process is verifiable;
- Keep a general-purpose ratio in SFT and limit epochs to 1–3;
- Use a composite reward for reinforcement learning; the length penalty cannot be skipped;
- For refusal tuning, prefer middle layers and keep the range from being too wide;
- Before going live, run KL divergence and safety regression, and set up the three-layer dashboard;
- If using cloud training and inference resources, you can combine a container platform, object storage, logging service, and monitoring alerts to build a pipeline that enables sample versioning, traceable training, and alertable metrics.
6. Conclusion
This pipeline — a large model produces samples, a small model runs SFT, light reinforcement follows, and refusal behavior is tuned in a targeted way — is a typical paradigm for landing lightweight inference models today. Its core is not any single technique, but closing the loop across four things: process data, training stages, representation intervention, and evaluation definitions. For developers, the truly reusable asset is this methodology and evaluation system, not a single leaderboard placement.
