ToDi: Token-wise Distillation via Fine-Grained Divergence Control

Fuente: arXiv
Salvato in:
Dettagli Bibliografici
Autori principali: Jung, Seongryong, Yoon, Suwan, Kim, DongGeon, Lee, Hwanhee
Natura: Preprint
Pubblicazione: 2025
Soggetti:
Accesso online:
Tags: Aggiungi Tag
Nessun Tag, puoi essere il primo ad aggiungerne!!
_version_ 1866915518391255040
author Jung, Seongryong
Yoon, Suwan
Kim, DongGeon
Lee, Hwanhee
author_facet Jung, Seongryong
Yoon, Suwan
Kim, DongGeon
Lee, Hwanhee
contents Large language models (LLMs) offer impressive performance but are impractical for resource-constrained deployment due to high latency and energy consumption. Knowledge distillation (KD) addresses this by transferring knowledge from a large teacher to a smaller student model. However, conventional KD, notably approaches like Forward KL (FKL) and Reverse KL (RKL), apply uniform divergence loss across the entire vocabulary, neglecting token-level prediction discrepancies. By investigating these representative divergences via gradient analysis, we reveal that FKL boosts underestimated tokens, while RKL suppresses overestimated ones, showing their complementary roles. Based on this observation, we propose Token-wise Distillation (ToDi), a novel method that adaptively combines FKL and RKL per token using a sigmoid-based weighting function derived from the teacher-student probability log-ratio. ToDi dynamically emphasizes the appropriate divergence for each token, enabling precise distribution alignment. We demonstrate that ToDi consistently outperforms recent distillation baselines using uniform or less granular strategies across instruction-following benchmarks. Extensive ablation studies and efficiency analysis further validate ToDi's effectiveness and practicality.
format Preprint
id arxiv_https___arxiv_org_abs_2505_16297
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle ToDi: Token-wise Distillation via Fine-Grained Divergence Control
Jung, Seongryong
Yoon, Suwan
Kim, DongGeon
Lee, Hwanhee
Computation and Language
Large language models (LLMs) offer impressive performance but are impractical for resource-constrained deployment due to high latency and energy consumption. Knowledge distillation (KD) addresses this by transferring knowledge from a large teacher to a smaller student model. However, conventional KD, notably approaches like Forward KL (FKL) and Reverse KL (RKL), apply uniform divergence loss across the entire vocabulary, neglecting token-level prediction discrepancies. By investigating these representative divergences via gradient analysis, we reveal that FKL boosts underestimated tokens, while RKL suppresses overestimated ones, showing their complementary roles. Based on this observation, we propose Token-wise Distillation (ToDi), a novel method that adaptively combines FKL and RKL per token using a sigmoid-based weighting function derived from the teacher-student probability log-ratio. ToDi dynamically emphasizes the appropriate divergence for each token, enabling precise distribution alignment. We demonstrate that ToDi consistently outperforms recent distillation baselines using uniform or less granular strategies across instruction-following benchmarks. Extensive ablation studies and efficiency analysis further validate ToDi's effectiveness and practicality.
title ToDi: Token-wise Distillation via Fine-Grained Divergence Control
topic Computation and Language
url https://arxiv.org/abs/2505.16297