Improving Item Recommendation Accuracy Using Collaborative Filtering and Vector Search Engine

Naotaka Uchida12 Jun 2023

Problem

Mercari is a Japanese marketplace with hundreds of millions of items for sale and over 3 billion listed in total. Its item details page shows a block of similar items on every view. The old recommendation logic could not keep up with fast trends in the toys category, so items about a new TV-show character got unrelated recommendations. The block must also work for sold-out items, which therefore need embeddings too.

Example from the article: a user viewing a pouch from the "ちいかわ ワクワクゆうえんち" series got mostly unrelated items (a Haikyu coaster pack, a Doraemon wallet). After the change, the top 10 were all from that series.

Solution in brief

Item vectors come from collaborative filtering on browsing logs. A small neural network learns to reproduce them from item text and categories, which covers items with little history. Recommendations are an approximate nearest-neighbor search over on-sale items, and the first A/B test showed that freshness also had to be considered.

Questions this case answers
  • How to recommend similar items for a given item in a fast-changing catalog when behavioral embeddings do not exist for new items
  • How to keep an approximate nearest-neighbor index current when items are added and removed continuously
  • How to recommend similar items on an item details page when the catalog holds hundreds of millions of items and trends change fast?
  • How to get embeddings for new items that have no browsing history yet?

Tools and methods

  • Collaborative filtering — item factors from browsing logs with implicit, trained on a GPU
  • Neural network on item text and categories — reproduces the factors for items without enough views
  • Vertex AI Matching Engine — approximate nearest-neighbor search over on-sale items
  • Bigtable — vectors of all items, including sold ones
  • MRR (mean reciprocal rank) on browsing logs — offline model selection before the A/B test
Continue reading — it's free

Google or a one-time email code. No password.