Table of Contents
Fetching ...

XRec: Large Language Models for Explainable Recommendation

Qiyao Ma, Xubin Ren, Chao Huang

TL;DR

XRec tackles the challenge of explainable recommendations by unifying graph-based collaborative filtering with large language models. It introduces a collaborative instruction-tuning framework and a lightweight collaborative adaptor to align CF signals with language semantics, enabling LLMs to generate comprehensive, personalized explanations. Key innovations include a LightGCN-based Collaborative Relation Tokenizer, a Mixture-of-Experts–driven Collaborative Information Adapter, and cross-layer embedding injections into LLMs, plus ground-truth explanation generation from user reviews. Evaluations on three datasets show superior explainability and stability, with strong robustness in sparse and zero-shot scenarios, and the approach is released as open-source.

Abstract

Recommender systems help users navigate information overload by providing personalized recommendations aligned with their preferences. Collaborative Filtering (CF) is a widely adopted approach, but while advanced techniques like graph neural networks (GNNs) and self-supervised learning (SSL) have enhanced CF models for better user representations, they often lack the ability to provide explanations for the recommended items. Explainable recommendations aim to address this gap by offering transparency and insights into the recommendation decision-making process, enhancing users' understanding. This work leverages the language capabilities of Large Language Models (LLMs) to push the boundaries of explainable recommender systems. We introduce a model-agnostic framework called XRec, which enables LLMs to provide comprehensive explanations for user behaviors in recommender systems. By integrating collaborative signals and designing a lightweight collaborative adaptor, the framework empowers LLMs to understand complex patterns in user-item interactions and gain a deeper understanding of user preferences. Our extensive experiments demonstrate the effectiveness of XRec, showcasing its ability to generate comprehensive and meaningful explanations that outperform baseline approaches in explainable recommender systems. We open-source our model implementation at https://github.com/HKUDS/XRec.

XRec: Large Language Models for Explainable Recommendation

TL;DR

XRec tackles the challenge of explainable recommendations by unifying graph-based collaborative filtering with large language models. It introduces a collaborative instruction-tuning framework and a lightweight collaborative adaptor to align CF signals with language semantics, enabling LLMs to generate comprehensive, personalized explanations. Key innovations include a LightGCN-based Collaborative Relation Tokenizer, a Mixture-of-Experts–driven Collaborative Information Adapter, and cross-layer embedding injections into LLMs, plus ground-truth explanation generation from user reviews. Evaluations on three datasets show superior explainability and stability, with strong robustness in sparse and zero-shot scenarios, and the approach is released as open-source.

Abstract

Recommender systems help users navigate information overload by providing personalized recommendations aligned with their preferences. Collaborative Filtering (CF) is a widely adopted approach, but while advanced techniques like graph neural networks (GNNs) and self-supervised learning (SSL) have enhanced CF models for better user representations, they often lack the ability to provide explanations for the recommended items. Explainable recommendations aim to address this gap by offering transparency and insights into the recommendation decision-making process, enhancing users' understanding. This work leverages the language capabilities of Large Language Models (LLMs) to push the boundaries of explainable recommender systems. We introduce a model-agnostic framework called XRec, which enables LLMs to provide comprehensive explanations for user behaviors in recommender systems. By integrating collaborative signals and designing a lightweight collaborative adaptor, the framework empowers LLMs to understand complex patterns in user-item interactions and gain a deeper understanding of user preferences. Our extensive experiments demonstrate the effectiveness of XRec, showcasing its ability to generate comprehensive and meaningful explanations that outperform baseline approaches in explainable recommender systems. We open-source our model implementation at https://github.com/HKUDS/XRec.
Paper Structure (24 sections, 14 equations, 7 figures, 2 tables)

This paper contains 24 sections, 14 equations, 7 figures, 2 tables.

Figures (7)

  • Figure 1: The overall architecture of our XRec. (i). Collaborative Relation Tokenizer: Transforms complex user-item relationships into latent embeddings using GNNs; (ii) Collaborative Information Adapter: A lightweight adapter that integrates collaborative signals into LLMs. (iii) Unifying CF with LLM: Integrates collaborative filtering insights directly into large language models, enabling them to generate insightful explanations.
  • Figure 2: A depiction of model prompt instruction.
  • Figure 3: Ablation Study on Variant Models: Higher scores in GPTScore and BERTScore suggest improved explainability, while lower scores in GPT_std and BERT_std indicate enhanced stability.
  • Figure 4: Experiments of different data sparsity.
  • Figure 5: Case study on the generation of ground truth explanations for recommender systems on Yelp dataset.
  • ...and 2 more figures