arXiv:2610.32943cs.IROct 2026

Manuscript Offprint

arXiv:2610.32943

Knowledge Distillation across Item and Code Spaces for Parallel Generative Recommendation

Yixuan Xu, Hailin Liu, Linxiang Peng, Can Yang

Abstract

Generative recommendation with semantic IDs represents each item as a sequence of discrete codes derived from its semantic representation and predicts these codes to generate recommendations. Existing semantic-ID recommenders are typically trained with hard labels for the observed next item. Although such supervision identifies the target, it provides no explicit distributional information about alternative items conditioned on the same user history. Sequential recommenders can supply this item-level predictive knowledge, but transferring it to semantic-ID generation is challenging because the teacher and student operate in item and code spaces, respectively. We propose two complementary knowledge-distillation objectives for parallel semantic-ID recommenders, which predict all code positions simultaneously without autoregressive prefix conditioning. Item Distribution Matching (IDM) reconstructs a catalogue-level item distribution from the student's parallel code predictions and aligns it with the teacher's item distribution. Code Marginal Matching (CMM) projects the teacher's item probabilities onto each code position using fixed item-to-code assignments, then matches the resulting code marginals to the corresponding student heads. Both objectives transfer the teacher's soft distributional knowledge while preserving the student's parallel prediction structure. Experiments on benchmark datasets show that both methods consistently outperform existing state-of-the-art approaches. On average, IDM improves Recall@10 by 15.39%, while CMM improves NDCG@10 by 8.28%. These results demonstrate that distillation in either reconstructed item space or code-marginal space can substantially strengthen hard-label supervision for parallel generative recommendation.

CCS Concepts

• Information systems → Recommender systems.

Keywords

Generative Recommendation, Semantic ID

1 Introduction

Sequential recommendation aims to predict a user's next interaction from their historical behavior. Conventional item-level methods, such as SASRec [14], learn representations of interaction histories and assign scores to individual candidate items [7, 29, 38]. Semantic-ID (SID) generative recommenders adopt a different paradigm: each item is represented by a sequence of discrete codes derived from its semantic representation, and recommendation is performed by predicting this code sequence [4, 19, 28, 32, 36]. Different items may Linxiang Peng

plx@mail.ustc.edu.cn

University of Science and

Technology of China

Hefei, China

Can Yang

macyang@ust.hk

The Hong Kong University

of Science and Technology

Hong Kong, China

share the same code at a given position, while their complete SID sequences distinguish them. This structured representation provides a natural target for generative recommendation [26, 27]. Early approaches such as TIGER [24] predict SID positions autoregressively, conditioning each position on previously generated codes. More recent parallel approaches, including RPG [10], predict all positions simultaneously and remove this sequential dependency [16, 20]. Despite this architectural difference, parallel SID recommenders are still commonly trained with the hard code sequence of a single observed next item.

For a given interaction history, the observed next item induces a one-hot target over the vocabulary of each code position. This target identifies the codes assigned to the observed item, but does not specify how probability mass should be distributed among alternative items or code values. In particular, the fixed item-to-code mapping partitions the catalogue into groups of items that share the same code at each position. A hard target only identifies the group containing the observed item; it provides no graded, history-dependent information about the relative likelihoods of the remaining groups. Consequently, hard-label training does not directly expose the student to the predictive uncertainty encoded in alternative candidates.

A pretrained sequential recommender can provide such complementary supervision through its history-dependent item scores [15, 31]. Applying a softmax over the candidate catalogue converts these scores into a teacher distribution that assigns different probabilities to alternative items, including items not observed as the next interaction. Existing studies have transferred collaborative or sequential knowledge to generative recommenders through prefix-conditioned token alignment or distillation with learnable identifiers [17, 18]. However, these settings differ from a fixed-SID parallel predictor. The teacher produces a distribution over items, whereas the student produces categorical distributions over code values at multiple positions without autoregressive prefix conditioning. The central challenge is therefore how to transfer item-level predictive knowledge into the code distributions of a parallel SID recommender.

The fixed item-to-code mapping provides two natural spaces for this transfer. By combining the student predictions corresponding to an item's complete SID and normalizing the resulting scores over valid catalogue items, the parallel student can induce a catalogue-level item distribution. Alternatively, the teacher's item distribution can be projected onto each code position by summing the probabilities of items that share the same code value. These aggregated probabilities form code-level marginals that can be directly matched to the categorical distributions produced by the corresponding student heads. The two spaces preserve different aspects of the teacher's information: catalogue-level matching retains item-level distinctions, whereas code-level marginal matching provides direct supervision for each parallel prediction head.

Based on these two spaces, we propose two complementary knowledge-distillation objectives, as illustrated in Figure 1. Item Distribution Matching (IDM) combines the student predictions associated with each item's SID, normalizes the resulting scores over the catalogue, and aligns the induced item distribution with the teacher distribution using soft cross-entropy. Code Marginal Matching (CMM) instead uses the fixed item-to-code mapping to aggregate teacher item probabilities into a marginal distribution for each code position, and matches these marginals to the corresponding student heads through KL divergence. IDM therefore transfers knowledge through a reconstructed item space, whereas CMM transfers knowledge through a code-marginal space. Both objectives enrich hard-label supervision with history-dependent soft targets while preserving parallel prediction and inference. Our analysis further shows that, under the proposed parameterization, both objectives are driven by teacher-induced code marginals but differ in their student-side normalization: IDM normalizes over catalogue items, whereas CMM normalizes independently within each code head. Empirically, IDM provides stronger improvements in Recall, while CMM yields stronger improvements in NDCG across the evaluated datasets.

Our main contributions are summarized as follows:

  • We formulate knowledge distillation from item-level teacher distributions to parallel semantic-ID recommenders, addressing the lack of explicit distributional supervision over alternative code values in conventional hard-label training.

  • We propose two complementary objectives for cross-space distillation. IDM matches the teacher distribution in a catalogue-level item space reconstructed from the student’s parallel code predictions, whereas CMM projects the teacher distribution into code-position marginals using the fixed item-to-code mapping.

  • We conduct experiments on three benchmark datasets and compare both objectives with state-of-the-art recommendation methods. The proposed methods consistently outperform existing approaches, with IDM achieving an average improvement of 15.39% in Recall@10 and CMM improving NDCG@10 by 8.28%.

References (26)