Introduction
Modern sequential recommendation systems have long been dominated by the "learning-to-classify" paradigm. In this framework, models like SASRec or GRU4Rec are trained to predict the next item in a sequence by treating the entire item catalog as a set of discrete classes. However, this approach faces inherent limitations in capturing the nuance of human preference. This paper introduces DreamRec, a novel framework that shifts the task from classification to conditional generation. By utilizing guided diffusion models, DreamRec generates an "oracle item"—a continuous, idealized representation of a user’s next preference—thereby bypassing the traditional pitfalls of negative sampling and discrete label prediction.
The Pitfalls of Learning-to-Classify
Traditional recommenders typically rely on a binary or multi-class objective: given a user's history, the model must distinguish a "positive" item (the actual interaction) from a set of "negative" items (randomly sampled non-interactions). The authors identify two primary flaws in this methodology:
- The Negative Sampling Bottleneck: Selecting effective negative samples is notoriously difficult. "Easy" negatives provide little signal, while "hard" negatives are often noisy. In many cases, a negative sample might actually be a "false negative"—an item the user would enjoy but simply hasn't encountered yet. This ambiguity coarsens the decision boundary and limits the model's ability to map the true distribution of user interests.
- The "Oracle" Mismatch: Humans do not typically choose items by scanning a fixed list and performing a classification task. Instead, they often have an "oracle item" in mind—a mental image of the perfect product or content—and then select the real-world item that most closely matches that ideal. Classification models struggle to represent these "in-between" preferences that don't align perfectly with existing item IDs.
DreamRec: Recommendation as Guided Diffusion
DreamRec re-imagines recommendation as a conditional generation task. Instead of calculating probabilities over a fixed vocabulary, it learns to construct an embedding in a continuous preference space.
The Diffusion Process
Inspired by Denoising Diffusion Probabilistic Models (DDPM), DreamRec employs a two-stage process:
- Forward (Noising): The model gradually adds Gaussian noise to the target item's embedding until it reaches a state of pure noise.
- Reverse (Denoising): Guided by the user’s historical context, the model learns to reverse this process. Unlike standard DDPMs that predict the added noise, DreamRec is optimized to predict the original "oracle" item embedding directly. This direct reconstruction provides a cleaner training signal for recommendation tasks.
Contextual Guidance
To inform the generation process, DreamRec uses a Transformer encoder to process the user's historical interactions into a guidance representation ($c_{n-1}$). To ensure the model balances specific user history with general item popularity, the authors implement classifier-free guidance. During training, the history signal is occasionally dropped, forcing the model to learn a more robust and generalized understanding of the item space.
Inference and Retrieval
At test time, the model starts with pure Gaussian noise and iteratively denoises it to generate an "oracle" embedding. Because this generated vector exists in a continuous space, the final recommendation is made by performing a K-nearest neighbor (KNN) search (using inner product) to find the real-world items that best approximate the generated ideal.
Experimental Evaluation
The authors evaluated DreamRec against competitive baselines (including SASRec, CL4SRec, and the diffusion-based DiffRec) across three diverse datasets:
- YooChoose: E-commerce purchase sequences.
- KuaiRec: Short-video interaction logs.
- Zhihu: Knowledge-sharing community reading sequences.
Key Results
DreamRec consistently outperformed all baselines. The most dramatic improvements were seen in the KuaiRec dataset, where DreamRec nearly doubled the performance of traditional models, increasing the NDCG@20 from approximately 2.01 to 4.11. These results suggest that the generative approach is particularly effective at capturing the "long tail" of user preferences where classification models often fail due to sparse data.
Discussion: Why Generation Wins
The success of DreamRec stems from its ability to explore the item space more effectively. While classification-based models tend to "clump" item embeddings into tight, discrete zones, t-SNE visualizations indicate that DreamRec spreads embeddings across a much richer, continuous distribution. By moving away from discrete IDs, the model can represent nuanced preferences that sit between existing items, effectively modeling the "oracle" intent of the user. Furthermore, by eliminating the need for negative sampling, the training process remains focused entirely on the positive signal, leading to a more precise representation of user intent.
Limitations and Future Work
While DreamRec represents a significant step forward, it introduces new challenges:
- Efficiency: The iterative nature of diffusion makes inference slower than single-pass models. Future iterations may utilize "consistency models" to achieve one-step generation.
- Complexity: The training overhead is higher than standard cross-entropy losses.
- Privacy: The explicit generation of a "preference vector" could potentially be decoded to reveal sensitive user information, necessitating future research into privacy-preserving generative recommendation.
Conclusion
DreamRec demonstrates that shifting from classification to guided diffusion allows recommendation models to better capture the underlying distribution of user preferences. By generating an idealized "oracle" item rather than choosing from a list, DreamRec achieves state-of-the-art performance and provides a more robust framework for understanding complex, sequential user behavior.
Summary updated