TransRev: Modeling Reviews as Translations from Users to Items

Alberto García-Durán, Roberto Gonzalez, Daniel Oñoro-Rubio, Mathias Niepert, Hui Li

TL;DR

TransRev is a novel recommendation framework that treats product reviews as "translations" in a latent vector space, moving a user's embedding toward an item's embedding. By jointly learning to predict ratings and model this geometric relationship, the system can approximate what a review would say for a product a user hasn't bought yet, significantly improving recommendation accuracy and explainability.

What Problem Does This Paper Address?

Traditional recommender systems usually fall into two camps: collaborative filtering (which looks at who bought what) and sentiment analysis (which looks at what people said). The challenge lies in the "cold start" or predictive scenario: sentiment analysis is powerful, but you can't use it to predict a rating for a product a user hasn't purchased because the review doesn't exist yet.

Existing hybrid models often use review text as a regularization term during training but struggle to leverage that textual richness effectively at test time. The authors of TransRev sought a way to bridge this gap, creating a model that treats the text of a review not just as a label, but as the functional link between a user's preferences and an item's characteristics.

Methods

The core innovation of TransRev is its use of translation-based modeling, a concept borrowed from knowledge graph completion (specifically the TransE algorithm).

  1. The Translation Assumption: The model embeds users ($e_u$), items ($e_i$), and reviews ($h_{rev}$) into the same $k$-dimensional latent space. It assumes that a review is a vector that translates a user to an item: $e_u + h_{rev} \approx e_i$.
  2. Review Embedding: A review's embedding is calculated as the average of its word embeddings plus a bias term. This allows the model to capture the "sentiment" of the text geometrically.
  3. Joint Learning Objective: The model optimizes two things simultaneously:
  4. Sentiment Regression: A regression model $g$ is trained to predict the actual numerical rating from the review embedding.
  5. Translation Distance: The model minimizes the distance between the translated user ($e_u + h_{rev}$) and the target item ($e_i$).
  6. Inference (Test Time): To predict a rating for a new user-item pair, the model approximates the "missing" review embedding as the difference between the item and user vectors: $\hat{h}_{rev} = e_i - e_u$. This approximation is then fed into the regression model to predict the rating.
Fig. 2: At training time, a function’s parameters are learned to compute the review embedding from the word token embeddings such that the embedding of the user translated by the review embedding is similar to the product embedding. At the same time, a regression model g is trained to perform well on predicting ratings.

Datasets

The authors evaluated TransRev on two massive, standard benchmarks:

  • Yelp Business Rating Prediction Challenge: Reviews of restaurants in Phoenix.
  • Amazon Product Data: 18 different product categories (e.g., "Instant Video," "Automotive," "Musical Instruments"). The researchers used "5-core" versions of these datasets, ensuring every user and item in the set had at least five associated reviews to maintain data density.

Key Insights and Ideas

  • Reviews as Bridges: Instead of seeing a review as a byproduct of a transaction, TransRev sees it as the reason for the transaction's score. It captures the specific "delta" that explains why a specific user gave a specific item a specific score.
  • The "Phantom" Review: The ability to calculate $\hat{h}_{rev} = e_i - e_u$ is a powerful trick. It essentially asks the model, "Given this user's history and this item's features, what is the most likely sentiment that would bridge them?"
  • Explainability via Retrieval: Because the model maps reviews to a vector space, it can perform "review retrieval." By taking the approximated vector $\hat{h}_{rev}$ and finding the closest real review in the training set, the system can provide a human-readable explanation for its recommendation (e.g., "We recommend this bike because it's 'really nice,' similar to this other review...").
Fig. 3: At test time, the review embedding is approximated as the difference between the product and user embeddings. The approximated review embedding is used to predict the rating and to retrieve similar reviews.

Key Results

  • State-of-the-Art Performance: TransRev outperformed competitive baselines (including SVD, HFT, and DeepCoNN) on 15 out of 19 datasets tested, measured by Mean Squared Error (MSE).
  • Semantic Clustering: Visualization of the learned word embeddings using t-SNE showed clear clusters: negative words (horrible, useless), neutral words (products, others), and positive words (awesome, fantastic) grouped together naturally based on their role in the translation space.
  • Efficiency: The model achieved these results with a relatively small embedding dimension ($k=16$), proving that the translation assumption is a very efficient way to capture user-item interactions.

Limitations and Future Work

  • Word Order: The current implementation uses a simple average of word embeddings (bag-of-words), meaning it can't distinguish between "good" and "not good." The authors suggest that using CNNs or RNNs for the review embedding function $f$ could solve this.
  • Aspect Specificity: While the model captures overall sentiment well, it sometimes retrieves reviews that focus on different product aspects (e.g., one review mentions "clumping" while the retrieved one mentions "headaches").
  • Product-Agnostic Retrieval: Currently, the model might retrieve a review for a different product if the sentiment vector is similar. Future iterations could constrain retrieval to reviews of the specific product being recommended.

Summary updated

Abstract

The text of a review expresses the sentiment a customer has towards a particular product. This is exploited in sentiment analysis where machine learning models are used to predict the review score from the text of the review. Furthermore, the products costumers have purchased in the past are indicative of the products they will purchase in the future. This is what recommender systems exploit by learning models from purchase information to predict the items a customer might be interested in. We propose TransRev, an approach to the product recommendation problem that integrates ideas from recommender systems, sentiment analysis, and multi-relational learning into a joint learning objective. TransRev learns vector representations for users, items, and reviews. The embedding of a review is learned such that (a) it performs well as input feature of a regression model for sentiment prediction; and (b) it always translates the reviewer embedding to the embedding of the reviewed items. This allows TransRev to approximate a review embedding at test time as the difference of the embedding of each item and the user embedding. The approximated review embedding is then used with the regression model to predict the review score for each item. TransRev outperforms state of the art recommender systems on a large number of benchmark data sets. Moreover, it is able to retrieve, for each user and item, the review text from the training set whose embedding is most similar to the approximated review embedding.
BibTeX
@misc{garciaduran2018transrev,
  author = {Alberto García-Durán and Roberto Gonzalez and Daniel Oñoro-Rubio and Mathias Niepert and Hui Li},
  title = {{TransRev: Modeling Reviews as Translations from Users to Items}},
  year = {2018},
  eprint = {1801.10095},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1801.10095},
}
Figure