Abstract
Generative Flow Networks (GFlowNets) offer a novel approach to listwise recommendation by modeling list construction as a sequential decision process. This paper introduces GFN4Rec, a framework that learns to sample recommendation lists with probabilities proportional to their predicted rewards. By aligning log-probabilities with log-rewards, GFN4Rec effectively addresses the combinatorial explosion of list spaces and mitigates mode collapse, a common issue in standard softmax-based models. Experimental results on ML1M and KR1K datasets demonstrate that GFN4Rec achieves superior rewards and significantly higher item coverage compared to state-of-the-art baselines, particularly in online exploration scenarios.
Introduction
Most recommendation engines operate on a pointwise basis, scoring items individually and ranking them. This approach ignores "listwise" effects—the complex interactions between items in a list. For instance, a list of three identical action movies might be individually "accurate" but provides a poor user experience due to lack of variety.
While listwise and generative models exist, they face two major hurdles: the combinatorial explosion of possible lists and the "diversity trap." Standard training often leads to mode collapse, where models become over-confident in a few high-scoring items, hindering the exploration necessary for effective online learning. GFN4Rec addresses these by treating list generation as a "flow" through a generation tree.
Methods
The GFN4Rec framework adapts GFlowNets to the recommendation task by modeling the construction of a $K$-item list as a path in a tree. Starting from an empty set, the model adds items sequentially until a full list is formed.
Log-Scale Reward Matching
The core innovation of GFN4Rec is its training objective: aligning the log-probability of a list with its log-reward. Unlike the typical softmax approach, which makes high-scoring items exponentially more likely, GFN4Rec ensures that $P(List) \propto Reward(List)$. This linear relationship maintains diversity by giving lower-reward (but still good) lists a fair chance of being sampled.
Architecture and Training
The model employs a Transformer-based encoder to capture mutual influences between items and user preferences. It explores two GFlowNet-specific losses: Trajectory Balance (TB), which optimizes the entire path, and Detailed Balance (DB), which focuses on step-by-step transitions. To handle the massive search space, bias terms are introduced to normalize the flow and ensure numerical stability.
Experimental Evaluation
The researchers evaluated GFN4Rec using the ML1M (MovieLens 1M) and KR1K (KuaiRand-1K) datasets. To test online learning, they utilized a simulated environment where a stochastic user model responds to generated lists.
Key Results
- Superior Rewards: GFN4Rec consistently achieved higher average rewards than strong baselines like ListCVAE and PRM. On the KR1K dataset, it outperformed the strongest baseline by 10%.
- Diversity Gains: In "Explore" mode, GFN4Rec improved item coverage by 4x compared to standard pointwise models without a significant drop in recommendation quality.
- Consistency: The authors demonstrated that models trained on static offline data performed predictably in online simulations, validating the robustness of the GFlowNet approach.
Conclusion and Future Work
GFN4Rec provides a principled way to balance exploration and exploitation in listwise recommendation. By matching generation probability to reward, it avoids mode collapse and naturally promotes diversity. Future research will focus on incorporating intermediate rewards and refining sampling strategies to further accelerate online learning.
Summary updated