On Policy 和 Offline Policy 区别



OPD
On-Policy Distillation (OPD) trains large language models with teacher guidance on student-generated trajectories, addressing the mismatch between fixed demonstrations and the histories encountered during deployment.
On-Policy 蒸馏(OPD) 在学生自己生成的轨迹上、借助教师指导来训练大语言模型,解决的正是 "固定示范数据 fixed demonstrations" 与 "部署时实际遇到的历史 histories encountered during deployment" 之间的错配。
OPD 解决 "训练时看到的输入分布" 和 "部署时实际遇到的输入分布" 不一致的问题------ 即模型自己走错后,没人教它怎么回来
训练数据的分布 = 当前学生策略的分布(on-policy),而不是一个固定离线数据集(off-policy)
传统做法(SFT / 经典 KD)都在教师走过的轨迹上训练:

在 agent 场景里被放大得最厉害:
轨迹几十步、每步还有工具返回的观测,状态空间几乎无限,教师示范只能覆盖其中极窄一条走廊
OPD 的解法:把 "谁来产生状态" 从教师换成学生自己
学生生成前缀 → 教师在该前缀上给出完整分布 → 学生按这个分布更新

On-Policy Distillation 的历史:

2025 年起 Qwen3、MiMo、GLM-5、DeepSeek-V4 等主流后训练流程普遍采用 OPD------ 学生自生成 rollout、教师逐 token 给分布。这一步更多是 "工业采纳"
背景
On-Policy 蒸馏(OPD)
interplay ˈɪntəpleɪ
n. 相互影响,相互作用,互动
vi. 相互影响,相互作用
examine ɪɡˈzæmɪn v. 检查,调查;考核,测验;(医生)诊察;(尤指在法庭上)审问,查问
As its use expands across language model training, different formulations of supervision and optimization make it difficult to compare methods and understand when they are effective. This survey develops a unified view of OPD through the interplay between student-generated states, teacher information, and policy updates. This framework connects the foundations of distillation with self-distillation, multi-teacher integration, reinforcement learning, and interactive agents. We examine how these settings change the supervision available to the student and relate the resulting design choices to capability transfer, training efficiency, and deployment. Our synthesis centers on the conditions under which guidance remains reliable and learnable as the student evolves, considering both immediate performance and the capacity for subsequent learning. We conclude by discussing open challenges in adapting supervision and allocating computation to support effective learning.
随着 OPD 在语言模型训练的各个环节被广泛使用,各种监督形式和优化方式差异很大,导致方法之间难以比较,也很难说清它们在什么条件下才真正有效。本综述围绕学生生成的状态 student-generated states、教师提供的信息 teacher information、策略更新 policy updates 三者的相互作用,建立了一个统一的 OPD 视角。这一框架把蒸馏的基础(the foundations of distillation)与自蒸馏 self-distillation、多教师整合 multi-teacher integration、强化学习 reinforcement learning、交互式智能体 interactive agents 联系起来。我们考察这些设定如何改变学生可获得的监督信号(supervision available to the student),并把由此产生的设计选择(the resulting design choices)与能力迁移(capability transfer)、训练效率(training efficiency)、部署(deployment)关联起来。我们的归纳聚焦于一个问题(synthesis centers on the conditions):随着学生不断演进,教师指导(guidance)在什么条件下仍然可靠且可学 reliable and learnable,同时兼顾即时表现(immediate performance)与后续学习能力(the capacity for subsequent learning)。最后,我们讨论了在适配监督信号(adapting supervision)与分配算力(allocating computation)方面的开放挑战。
Introduction
imitation ˌɪmɪˈteɪʃn
n. 模仿,仿效;滑稽模仿;仿制品,赝品;乐句重复
adj. 人造的,仿制的,伪造的
underlying ˌʌndəˈlaɪɪŋ
adj. 根本的,潜在的;表面下的,下层的;优先的;(数量或水平)实际的
v. 位于...的下面;构成...的基础(underlie 的现在分词形式)
competence ˈkɒmpɪtəns n. 能力,胜任;权限,管辖权;技能;感受态,反应能力;<旧>足以谋生的收入
Knowledge distillation trains a student model using guidance from a teacher. It can transfer a larger model's capabilities to a smaller one, combine several specialists in one model, or teach behavior that initially requires extra context. Across these uses, the student must continue from its own outputs, which can lead it away from the histories represented in its training examples. Fixed responses and teacher demonstrations provide no direct guidance at many of these unfamiliar histories (Kim & Rush, 2016; Ross et al., 2011). Even close imitation of a teacher's answer style can leave a gap in underlying competence (Gudibande et al., 2023).
知识蒸馏用一个教师的指导(guidance)来训练学生。它可以把大模型的能力迁移到小模型、把多个专家合并进一个模型,或者教会那些最初需要额外上下文才能表现的行为。在这些用途里,学生都必须从自己的输出继续往下走,而这就可能把它带离(away from)训练样本所覆盖的那些历史(the histories represented in its training examples)。在大量这类 "陌生的历史" 上,固定答案(fixed responses)和教师示范(teacher demonstrations)提供不了任何直接指导(Kim & Rush, 2016; Ross et al., 2011)。即便学生把教师的作答风格模仿得很像(close imitation),底层能力(underlying competence)上仍可能留下缺口(Gudibande et al., 2023)。
On-Policy Distillation (OPD) brings teacher guidance to the student's own generation process. The student generates a response, and the teacher supplies guidance along it. For text generation, a state consists of the prompt and the response prefix generated so far. A trajectory is the resulting sequence of states and generated tokens. If the student takes a wrong turn, OPD can provide guidance at that prefix even when a fixed teacher answer would never visit it. MiniLLM and GKD develop complementary realizations through sequence-level optimization and matching next-token distributions (Gu et al., 2024a; Agarwal et al., 2024). Both connect student-generated experience to teacher guidance, whose value depends on the visited state and the student's ability to learn. Figure 2 depicts this learning loop and the design choices examined in the following chapters.
complementary ˌkɒmplɪˈment(ə)ri adj. 相互补充的,相辅相成的;互补色的;(基因序列、核苷酸等)互补的
On-Policy 蒸馏(OPD)把教师指导带进学生自己的生成过程(generation process):学生生成一个回答,教师在沿途提供指导。对于文本生成,一个 state 由 prompt 加上到目前为止 so far 已生成的前缀构成;一条 trajectory 是由这些 state 和生成的 token 组成的序列。如果学生在某一步走错( takes a wrong turn),OPD 可以在那个前缀处给出指导,而固定的教师答案( fixed teacher answer)永远不会走到那个前缀。MiniLLM 与 GKD 通过序列级优化(sequence-level optimization)和匹配下一 token 分布(matching next-token distributions)给出了两种互补的实现(develop complementary realizations)(Gu et al., 2024a; Agarwal et al., 2024)。两者都把学生自生成的经验(student-generated experience)与教师指导(teacher guidance)连起来,而这份指导的价值(教师的指导好不好用)取决于被访问到的状态(visited state,即学生是在哪儿提问的,如果学生走到一个教师没见过的怪状态,教师给的答案本身就不靠谱,no reliable),以及学生的学习能力(value depends on the visited state and the student's ability to learn,即学生有没有足够脑容量学,如果教师说得再对,3B 学生也拟合不了 70B 的分布,no learnable)。图 2 描绘了这个学习闭环以及后续章节所考察的设计选择。

adaptation ˌædæpˈteɪʃn n. 改编本,改写本;适应,改变;适应(性),适应力;适应性变化
第一列:Collect experience 采集经验(学生自己去访问哪些状态)
- Which states are visited?(访问哪些状态)------ 采样策略,决定了 OPD 的覆盖面
- Coverage and selection(覆盖与选择)------ 采多少、留哪些;错误轨迹是丢还是留
- Refresh, reuse and stages(刷新、复用与分阶段)------ 多久重采一次 rollout(学生一直在变),旧样本能复用多久,是否分阶段扩长轨迹
- Computation budget(算力预算)------ 每步都要重跑学生 + 教师,这是 OPD 最贵的环节
第二列:Construct supervision 构造监督(在这些状态上 "目标" 由谁定义)
- What defines the target?(什么定义目标)------ 目标不一定是教师,可以是构造出来的
- Adaptation(目标适配)------ 教师不可靠时先校准,而不是照抄它的分布
- Self-teaching(自教)------ 没有更强模型时,用特权信息 "造" 一个教师(SDFT/OPSD 那一类)
- Rewards and specialists(奖励与专家)------ 引入 RL 结果奖励、或多专家各管一块能力
- Information access(信息可得性)------ 白盒 logits 还是黑盒文本,决定能算 KL 还是只能算序列级奖励
第三列:Update the student 更新学生(这份目标怎么变成梯度)
- Which gradient is used?(用哪个梯度)------ 同一个 token 分数,进不同估计器结果完全不同
- Matching(分布匹配)------ forward KL /reverse KL / JSD 的选择
- Token coverage(token 覆盖)------ 全词表还是 top-k 截断,影响信号是否完整
- Variance(方差)------ 采样估计的噪声控制
- Temporal credit(时序信用分配)------ 多轮任务里,第 10 步的错误该算到第几步头上
The updated student changes the next state distribution 更新后的学生,会改变下一轮的状态分布
这说明优化目标是非平稳的:学生一变,下一轮采样到的状态就变,教师面对的题目也跟着变。所以:
- 旧 rollout 不能无限复用(会和新策略失配)
- 训练 loss 会 "自己动",不代表模型在退化
- 只盯 loss 会误判,必须看行为评测
底部那行就是补这个缺口的:Interaction and memory (§7) · Behavioral evaluation (§9) 交互与记忆・行为评测
前者说明 agent 场景里状态还包含工具观测和记忆;后者说明闭环的验收标准是行为,不是损失值
Figure 2: The OPD learning loop. Student-generated states determine where supervision is requested, a teacher or constructed target supplies guidance, and the update changes subsequent student behavior. Self-distillation, task feedback and specialist integration modify the supervision within this loop. Agentic interaction additionally changes observations and visible memory.
OPD 学习 loop。学生生成的状态决定在哪里请求监督,教师或构造出的目标提供指导,而更新又改变学生的后续行为。自蒸馏、任务反馈和专家整合(specialist integration)都在该 loop 内修改监督信号。Agent 式交互还会额外改变观测与可见 memory
怎么用这张图?把它当12 格的体检表------ 训练不收敛时逐格问自己:
- 状态覆盖够吗?(只在简单样本上采样 → 学生永远学不会处理难状态)
- rollout 还是最新的吗?(复用太旧 → 目标过时)
- 教师在那些状态上可靠吗?(不可靠 → 先做 adaptation 而不是硬学)
- 目标是教师还是构造的?(没有强教师 → 自教 / 奖励)
- 用哪个散度?方向对不对?
- 词表截断了吗?
- 方差压住了吗?
- 多轮任务里 credit 分配对了吗?
这张图画的是 "采样 → 构造监督 → 更新 → 改变下次采样" 的循环
它的三个输入栏是你可调的旋钮,那条回环箭头则提醒你 ------任何一个旋钮的改动,都会连带改变后面所有环节的输入分布
rollout 是 "让当前策略实际跑一遍,产生一条完整的轨迹"。中文常译为 "采样"、"跑轨迹"、"展开"
名字来自强化学习:把策略 "铺开(roll out)" 在实际环境里走一遍看结果。它不是 "推理一次",而是完整的一局
prompt: "查订单 12345 状态,需要就取消"
↓ 学生用当前权重实际生成
step1 调用 query_order(12345)
step2 拿到返回值 {"status":"已发货"}
step3 判断:不需要取消 → 结束
上面这一整条 = 一次 rollout(一条轨迹 trajectory),里面每一步的 "已生成部分" 就是 state

OPD 的核心动作就是 "rollout":
- rollout 学生 → 拿到学生自己会走到的状态(这是 OPD 的数据来源)
- 在这些状态上问教师 → 得到监督
- 更新参数
- 再 rollout 一遍 → 因为学生变了,走出的状态也变了
第 4 步是关键,也是它最贵的地方:每次更新后旧 rollout 就过期了(策略一变,状态分布就变)
所以综述 §8 专门有 "Refresh, reuse and stages(刷新、复用与分阶段)" ------ 就是在权衡 "多久重采一次" 和 "算力烧不烧得起"
erroneous ɪˈrəʊniəs adj. 错误的,不正确的
motivate ˈməʊtɪveɪt v. 成为......的动机,是......的原因;激励,激发
A capable teacher can still be misleading after an erroneous student prefix, motivating target adaptation and reliability checks (Li et al., 2026l; Qiu et al., 2026). Useful supervision depends on what the teacher knows at the student's current state. Conversely, additional information can create a teaching advantage without a separate stronger model. On-policy self-distillation gives a version of the student a solution, demonstration, or feedback, then uses its predictions as supervision. This information is privileged because the deployed student will not normally receive it. OPSD, SDFT, and SDPO use these information sources to construct supervision when a suitable stronger model is unavailable or impractical (Zhao et al., 2026h; Shenfeld et al., 2026; Hübotter et al., 2026).
一个能力很强的教师,在学生走错前缀(erroneous student prefix,)之后依然可能给出误导性的指导 ------ 这正是 "目标适配 target adaptation" 与 "可靠性检查 reliability checks" 的动机(Li et al., 2026l; Qiu et al., 2026)。有用的监督取决于教师对学生当前状态知道什么(Useful supervision depends on what the teacher knows at the student's current state,即教师在这个位置上的知识量,老司机在市区开得很溜,但把他扔到一个从没去过的野路上,他也会犹豫 ------他的驾驶水平没变,只是这条路他不知道)。反过来,额外信息也能在没有单独更强模型的情况下造出教学优势(teaching advantage):on-policy 自蒸馏给学生的另一个版本提供答案、示范或反馈(gives a version of the student a solution, demonstration, or feedback, give sb sth),再用它的预测作为监督。这类信息是特权信息(privileged),因为部署时的学生不会拿到它。OPSD、SDFT、SDPO 都在没有合适(unavailable)更强模型、或不可行时(impractical),用这些信息源来构造监督(Zhao et al., 2026h; Shenfeld et al., 2026; Hübotter et al., 2026)。
intertwine ˌɪntəˈtwaɪn v. 缠绕,编结;交织,纠缠
successive səkˈsesɪv adj. 连续的,依次的;接替的,继承的
consult kənˈsʌlt v. 咨询,请教;商量,商讨;查询,查阅;当顾问
produce prəˈdjuːs
v. 引起,造成;(自然地)生产,产生;(尤指用机器)生产,制造;(运用技巧)制作,造出;(某地、某过程或制度)出产,产出;出示,拿出;监制,制作(电影或戏剧);生育;<旧>使(线段)延长
n. 农产品;(尤指某人工作或努力的)成果,结果
interpret ɪnˈtɜːprət v. 解释,说明;口译;把......理解为;演绎
interleave ˌɪntəˈliːv v. 交错,交织,穿插(常与 with 连用);(书籍)插入空白页;(计算机/通信)交织
The choice of supervisor is intertwined with the task objective. Teacher preferences guide individual predictions, while reinforcement learning (RL) can use outcome rewards to evaluate complete attempts. Joint updates, selective supervision, and successive training stages offer different ways to combine these signals (Xu et al., 2025a; Li et al., 2026b;a). With several teachers, training must also decide which specialist to consult and how to balance learning across capabilities. Individually effective specialists do not automatically produce a student that retains all their strengths (Ma et al., 2026a; Gao et al., 2026). These design choices can operate together. A self-teacher may interpret feedback from several specialists, and reward learning may be interleaved with transfer between evolving models (He et al., 2026b; Gu et al., 2026b).
监督者的选择与任务目标(task objective)交织在一起。教师偏好指导(preferences guide)单个预测,而强化学习(RL)可以用结果奖励(outcome rewards)来评估完整的尝试(详细解读见下面小段)。联合更新(Joint updates)、选择性监督(selective supervision)、分阶段训练(successive training stages),是组合这些信号的不同方式(Xu et al., 2025a; Li et al., 2026b;a)。在多教师场景(several teachers)下,训练还必须决定问哪个专家、以及如何跨能力平衡。分别有效(Individually effective)的专家,并不会自动得到/造出一个保留了它们全部优势的学生(Ma et al., 2026a; Gao et al., 2026)。这些设计选择可以叠加使用:自教师 self-teacher 可以解读来自多个专家的反馈(一个 "自我教师" 可以把来自多个专家的反馈解读并整合起来),奖励学习也可以与演进模型之间的迁移交替进行(transfer迁移,在这篇综述里就是蒸馏、能力传递:"奖励学习" 和 "模型之间的迁移" 不必分先后两个阶段,可以交替着一起往前推)(He et al., 2026b; Gu et al., 2026b)。
Teacher preferences guide individual predictions, while reinforcement learning (RL) can use outcome rewards to evaluate complete attempts
以改作文为例:
- 教师偏好 = 老师逐句批改:每句话都给你打个 "更该这么写" 的倾向
- 结果奖励 = 只告诉你总分:这篇及格了 / 没及格

informɪnˈfɔːm
v. 通知,告知;告发,检举(inform on);赋特征于,渗透;了解,熟悉;影响
论文:给...... 提供依据、反过来影响
intervention ˌɪntəˈvenʃ(ə)n n. 干预,介入;调停,斡旋;(为改善情况尤指病痛采取的)措施,做法
consequences ˈkɒnsɪkwənsɪz n. 后果,结果,影响(consequence 的复数);(英国英语)连环叙事游戏
In interactive agents, the student's actions also change the environment in which later decisions are made. Tools return observations and memory changes the visible history, so the state must include more than the student's generated response prefix. Delayed feedback must inform earlier decisions, and teacher intervention can change the trajectory itself (Wang et al., 2026g; Liu et al., 2026n). In both response generation and interaction, learning changes which states the student reaches next. Deciding what to collect, supervise, and reuse therefore affects both the information available for learning and its computational cost (Rang et al., 2026; Kang et al., 2026). The consequences extend beyond the distillation loss to task behavior, retained capabilities, and the capacity for subsequent learning (Nicoliciou et al., 2026; Dong et al., 2026b).
在交互式智能体里,学生的动作还会改变后续决策所依赖的/所处的环境。工具返回观测、记忆改变可见的历史,因此 state 必须包含比 "已生成前缀" 更多的东西;迟到的反馈,必须反过来为更早的决策提供依据(Delayed feedback must inform earlier decisions),教师干预则可以直接改变轨迹本身(Wang et al., 2026g; Liu et al., 2026n)。在回答生成(response generation)与交互(interaction)这两类场景中,学习都会改变学生接下来能到达哪些状态(learning changes which states the student reaches next)。决定收集什么、监督什么、复用哪些,既影响可用于学习的信息,也影响算力开销(Rang et al., 2026; Kang et al., 2026)。其后果不止体现在蒸馏损失(distillation loss)上,还体现在任务行为、保留的能力,以及继续学习(subsequent learning)的能力上(Nicoliciou et al., 2026; Dong et al., 2026b)。
Delayed feedback must inform earlier decisions
单轮生成里,第 t 步的监督就在第 t 步:写完就知道这句好不好,信号是即时的;agent 里,成败往往在末尾:
step2 选了一个错的接口 ← 真正错的地方
step5 继续基于它推进
step9 提交任务
step10 返回:失败 ← 反馈到这里才出现
反馈 "第 10 步失败",但原因在第 2 步。如果信号只落在第 10 步,前面 8 步学不到任何东西 ------ 下次还会在第 2 步犯同样的错
- 下棋:输棋的反馈在最后一手才到,但你要能回溯出 "第 12 手是败着"
- 装修防水:三个月后漏水才知道当初没做好 ------ 反馈极晚,但必须能指回那一道工序
divergence daɪˈvɜːdʒəns n. 差异,不同;(气流或洋流的)分开处;(数)发散
We organize the survey around the states visited by the student, the information used to construct supervision, and the update that supervision induces. These distinctions explain why similar training procedures can behave differently. The same divergence can be evaluated on different histories, the same model can teach differently with additional context, and the same token score can enter different gradient estimators. Together, these choices connect the mechanisms of OPD to their effects on learning, transfer, and deployment.
把综述组织为"学生访问到的状态、用于构造监督的信息、以及这份监督所诱导的更新 the states visited by the student, the information used to construct supervision, and the update that supervision induces "这三者之上。这些区分解释了为何相似的训练流程(training procedures)会表现不同:同一个散度 divergence 可以在不同历史上求值,同一个模型在额外上下文下可以教得不一样,同一个 token 分数可以进入不同的梯度估计器。它们共同把 OPD 的机制与其对学习、迁移、部署的影响连起来。
Figure 1 provides a reading map organized around these dependencies. Section 2 builds from classical distillation to student-state supervision, capacity constraints, and optimization before Section 3 examines teacher supervision. Sections 4, 5, and 6 develop self-distillation, coordination with reinforcement learning, and multi-teacher integration. Sections 7 and 8 then examine interaction and the allocation and reuse of supervision as policies change. Section 9 synthesizes the evidence, which informs the practical comparisons and open questions in Sections 10 and 11.
图 1 给出按这些依赖关系组织的阅读地图。第 2 节从经典蒸馏(classical distillation)过渡到学生状态监督(student-state supervision)、容量约束与优化;第 3 节考察教师监督(teacher supervision);第 4、5、6 节分别展开自蒸馏(self-distillation)、与强化学习的协同(coordination with reinforcement learning)、多教师整合(multi-teacher integration);第 7、8 节考察交互(interaction),以及策略变化下(policies change)监督的分配与复用;第 9 节综合证据(synthesizes the evidence),并支撑(inform 给...... 提供依据、反过来影响)第 10、11 节的实践对比与开放问题。
representative ˌreprɪˈzentətɪv
adj. 典型的,有代表性的;代表各类人(或事物)的;由代表组成的,代议制的;表现的,体现的;(艺术)具象派的;(哲) (与)表象(有关)的
n. 代表,代理人;代表他人者;销售代表,销售代理;典型人物,有代表性的事物

图 1:OPD 的章节地图与代表性研究。共享的基础(§2)连接了 §3--8 中的各个设计选择;一个方法可能同时处理跨组的(across group)好几个问题。§9 综合证据,§10 讨论实践用法。
第 2 节,基础与优化

第 3 节,教师监督

第 4 节,On-policy 自蒸馏(没有强教师时)

第 5 节,与 RL 结合

第 6 节,多教师 OPD

第 7 节,Agentic OPD(交互式场景)

第 8 节,训练动态与效率

附录
前缀
前缀" 并非指 URL 或字符串前缀匹配;它表示自回归生成里 "已经生成出来的那一段",也就是模型在第 t 步的输入上下文
生成是逐 token 的
第 1 步:输入 [prompt] → 输出 token₁
第 2 步:输入 [prompt][token₁] → 输出 token₂
第 3 步:输入 [prompt][token₁][token₂] → 输出 token₃
└────── 这就是"前缀" ──────┘
第 t 步时的 "前缀" 就是 prompt + 前 t-1 个已生成的 token。综述里把它叫作 state(状态):state = prompt + 已生成的前缀
OPD 示例
① 学生先自己生成,边走边记录每一步的前缀
② 每到一步,就把「当前前缀」喂给教师,让教师输出它在这一步的完整概率分布
③ 学生把自己在这一步的分布,向教师的分布靠拢(算 KL / CE)
④ 继续下一步,直到学生的整条轨迹走完
前缀 P = [prompt][y₁][y₂]
│
├─→ 学生前向 → q = [0.6, 0.3, 0.1, ...] ← 学生自己想怎么选
└─→ 教师前向 → p = [0.2, 0.7, 0.05, ...] ← 教师在同一个位置会怎么选
↓
loss = KL(p ‖ q) 或 CE(p, q)
关键区别:前缀由学生生成(这是 OPD 与传统蒸馏的唯一但决定性差别)

举例 agent :
prompt: "查一下订单 12345 的状态,需要就先取消"
学生生成: "调" → "用" → "取" → "消" ← 第 4 步走错了
此时前缀 = "查一下订单12345的状态,需要就先取消调用取消"
这个前缀在教师的示范数据里永远不会出现(教师不会在 "调用" 后面接 "取消")。
但在 OPD 里,教师会被喂到该错误前缀,然后输出 "接在这个上下文后面,我倾向什么分布"------ 学生据此被纠正
"完整分布" 指教师在那一步对整个词表给出的概率分布,而不是一个 "正确答案":
在错误前缀下:
教师分布 p = { "订单": 0.75, "取": 0.12, "查": 0.06, ... }
学生分布 q = { "取消": 0.40, "订单": 0.35, ... }
→ 训练把 q 往 p 拉
该示例对应两件事:
- 为什么 OPD 比 "只有一个最终对错" 的 RL 信号密------ 每一步都有整条词表的信息
- 为什么会有 "教师不可靠" 问题------ 教师是在学生造出的怪前缀上作答,它可能自己也不确定,甚至给出误导性分布
两个粒度
- token 级(GKD 路线):逐个前缀算 KL,上图画的就是这个
- 序列级(MiniLLM 路线):把整条轨迹当一个整体,算 reverse KL,不逐 token 分解
前缀 = 走到第 t 步时,模型手里已有的全部上下文(prompt + 已生成的部分);OPD 就是让学生自己造出这些前缀,教师在每个前缀上给出 "我会怎么分布",学生照着改
没有教师怎么办
① 自教(self-teaching /self-distillation)
核心想法:同一个模型,在信息更多的条件下会更准,就让 "信息多的它" 去教 "信息少的它"
- 把标准答案塞进上下文,同一个模型立刻变强 → 用这个 "作弊版" 当教师(OPSD 那类)
- 用检索到的文档当特权信息
- 用旧副本 / 高温度采样造出分布差异
- 用 rollout 多样性:同题多采几条,拿一致性当信号
② 奖励(rewards /verifiers)
不需要 "标准答案分布",只要 "这步做得对不对":
- 单元测试、代码执行结果
- 工具调用是否成功、任务是否完成
- 规则校验器、ORM 打分
这时训练就变成 RL 与 OPD 的混合:分布信号负责 "怎么写得像",奖励信号负责 "哪条路是对的"
不是直接复制教师:教师不可靠就校准它,教师不够强就换视角,没有教师就用奖励
为什么会有 "教师不可靠" 问题
① 分布外(OOD)外推
教师的 p_T(·|x, y_{<t}) 是在自己走过的前缀上训练、校准出来的。学生造出的前缀一旦偏离,教师就进入了 OOD 区域
此时它的 logits 是外推结果,置信度本身不可信:可能给出一个看似高概率、实际毫无根据的分布
② 语言模型的 "顺着写下去" 本性
教师是被训练成 "接得通顺" 的,而不是 "发现前面错了就回头"。给它一个错误前缀,它最自然的反应是把这条错路写得合理:
学生: ... 调用 delete_order(订单12345) ← 走错了,应该查状态
教师在该前缀下: "delete_order(订单12345) 已执行,订单已删除,现在为您..."
↑ 概率 0.72
教师不是 "知道正确答案后拒绝回答",它是按文本连贯性给分布。于是它给出的监督信号,是 "如何把错误继续下去",而不是 "如何回到正轨"。
③ 该状态下根本没有标准答案
"接在一个错误的工具调用之后,正确的下一步是什么?"------ 这在数据里没有定义。现实世界的正确做法可能是 "回滚 + 重新查",但在当前的 token 空间和上下文里,回滚不是一个可表达的下一步。所以教师面对的是一道本身无解的题,它只能编一个最像样的答案。
为什么这在 OPD 里更危险

OPD 的设计本意是 "在学生常去的状态上给监督",但它同时意味着把训练算力集中投向学生最不擅长、教师最没经验的那些状态
错误指导被加权、被反复学习,最终固化
这就是为什么综述里反复提到 reliability checks、target adaptation:不是 "教师不够强",而是 "教师在那个位置的知识不适用"
具体会看到什么症状
- 训练 loss 正常下降,但生成质量反而变差(学到了 "错误也要顺下去" 的行为)
- 学生出现 "自信地错":一旦走偏就一路走到底,不会停、不会回退
- 长轨迹任务(WebShop、ALFWorld 这类)上退化最明显,因为错一次后面全错,而教师的每一步 "续写" 都在加深错误
常见的四种缓解手段
- 不确定性门控:教师在该前缀下熵很高(自己也不确定)时,降权甚至丢弃该样本
- 轨迹级筛选:只保留学生 "走歪但可救" 的样本,纯烂尾轨迹不参与训练
- target adaptation:不直接用教师的分布当目标,而是先做校准(如温度调整、置信度重估),或干脆在该状态下换成 "重试 / 回退" 的目标分布
- 混合策略:保持一部分 off-policy 数据(教师自己的完美前缀),用 λ 混合,防止学生一直在 OOD 区自嗨(GKD
λ是该作用)
教师没 "变笨",而是被问它没被训练过回答的问题;再加上语言模型天生 "顺着写",它给出分布很可能是 "把错误写得更像对的"
这正是 OPD 必须配可靠性检查的原因