On-policy agent distillation lands in TRL: Qwen3.5-9B distilled to 2B agent
SergioPaniego · x · 2026-12-01
Hugging Face TRL now ships an on-policy distillation example for agents: a small student agent practices in the same environments used for RL, while a larger self-hosted model scores every step it takes.
The example distills Qwen3.5-9B into Qwen3.5-2B as a data-analysis agent: the student works over up to 10 turns on real CSV/TSV/JSON files in a live Python session, and the teacher scores every token. On 61 checked tasks, accuracy rises from 0.19 to 0.29 with first-turn-only distillation and 0.35 with whole-episode distillation, consistent across three seeds.
Motivation: most distillation recipes target single answers, but an agent's answer is an episode—what it writes on turn three depends on the session history—hence on-policy scoring over full trajectories.
More from coding & agent
- Voice AI latency: median 1400-1700ms, 5-6x slower than the 300ms users expect — JiaZhihao · 2026-12-03
- Open-source Glowline puts AI agent status in a glowing macOS screen-edge bar — Daniel_Farinax · 2026-12-03
- Sergey Karayev jokes about a future pipeline: Opus 5.5 codes, Astra 6.2 does QA — sergeykarayev · 2026-12-03
- Designers need to learn evals now — your eval sets will define the product experience — round · 2026-12-03
- Use Copilot as a proofreader to find gaps in your instructions — RichardW_Dev · 2026-12-03
- skeeto's Prospero: a single-executable C++/ImGui AI coding harness, public domain — JeremyCMorgan · 2026-12-03