From 6 Hours to 20 Minutes: How We Sped Up the Collaborative Model in Avito Recommendations

Salavat Dinmukhametov24 Sep 2026

Problem

Avito's home-page recommendations bring about half of all views and about 30% of contacts to sellers. One of the main candidate sources, the collaborative model avitofm, was retrained every 6 hours. Good listings sell fast and their CTR peaks in the first hours, so new items missed the peak. Training was also split into thousands of category-by-region models.

Example from the article: a new listing now reaches the home page in 25 minutes instead of 6 hours.

Solution in brief

Keep the batch model as a daily starting point and fine-tune a single near-real-time model per category on 20-minute clickstream windows. One model per category (52 instead of thousands) replaces the category-by-region split, and a geo mask at inference restores locality. SparseAdam, snapshots and a worker queue make the pipeline fit in memory and survive crashes.

Questions this case answers
  • How to keep a batch-trained embedding recommender fresh for short-lived items when a full retrain takes hours
  • How to consolidate thousands of per-segment models into one model per category while keeping segment-level locality at inference
  • How to make a batch-trained collaborative recommender pick up fresh listings within minutes instead of hours?
  • How to replace thousands of per-segment recommendation models with one model per category without losing quality?

Tools and methods

  • Collaborative filtering on embeddings — user and item tables in one space, score by dot product, top-K retrieval
  • Incremental fine-tuning on time windows — updates only the rows touched by fresh events
  • SparseAdam — updates only touched embedding rows, cutting memory on large categories
  • Geo mask at inference — keeps only items from the user's region
  • Apache Kafka, Redis, Kubeflow — event stream, serving of top-K, orchestration through the in-house Avitoflow platform built on Kubeflow
Continue reading — it's free

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