Beyond Neural Incompatibility: Easing Cross-Scale Knowledge Transfer in Large Language Models through Latent Semantic Alignment
Jian Gu, Aldeida Aleti, Chunyang Chen, Hongyu Zhang
TL;DR
This work addresses cross-scale parametric knowledge transfer for large language models by proposing SemAlign, a semantics-first framework that uses layer activations as the transfer medium. The method consists of three stages: layer attribution and pairing to identify counterpart layers, latent semantic alignment to project teacher semantics into the student space, and cosine-based representation steering to align both intermediate representations and final outputs. Across four benchmarks and multiple LLM pairs, SemAlign consistently outperforms prior PKT baselines and remains closer to larger teachers than alternative transfer methods, with notable gains on MMLU and code-related tasks. The approach reduces neural incompatibility, is computation-efficient, and demonstrates the value of preserving semantic content in latent space for robust cross-scale knowledge transfer.
Abstract
Large Language Models (LLMs) encode vast amounts of knowledge in their massive parameters, which is accessible to locate, trace, and analyze. Despite advances in neural interpretability, it is still not clear how to transfer knowledge in a fine-grained manner, namely parametric knowledge transfer (PKT). A key problem is enabling effective and efficient knowledge transfer across LLMs of different scales, which is essential for achieving greater flexibility and broader applicability in transferring knowledge between LLMs. Due to neural incompatibility, referring to the architectural and parametric differences between LLMs of varying scales, existing methods that directly reuse layer parameters are severely limited. In this paper, we identify the semantic alignment in latent space as the fundamental prerequisite for LLM cross-scale knowledge transfer. Instead of directly using the layer parameters, our approach takes activations as the medium of layer-wise knowledge transfer. Leveraging the semantics in latent space, our approach is simple and outperforms prior work, better aligning model behaviors across varying scales. Evaluations on four benchmarks demonstrate the efficacy of our method. Further analysis reveals the key factors easing cross-scale knowledge transfer and provides insights into the nature of latent semantic alignment.
