A middle path between Feed and Explore

Instagram’s Home Feed ranks content from accounts you follow. Explore does the opposite, surfacing public content from across the platform. In August 2020 the company launched Suggested Posts as a middle ground: recommendations that appear at the end of your feed, from accounts you don't follow, but that are meant to feel like a natural extension of the feed you built yourself.

The system behind that product follows the standard two-stage information retrieval pattern — candidate generation followed by candidate selection — with a few Instagram-specific twists. There’s also a "cold start" problem to solve for users without an established interest graph.

The design principle behind recommendations

The guiding product principle for Suggested Posts is "Feels Like Home." Scrolling through recommendations should feel like continuing down the Home Feed, not being dropped into a new, unrelated discovery surface. That principle influences both what gets recommended and how the system handles freshness, media mix, and source distribution.

Recommended posts come from accounts you don't follow, which makes this an "unconnected" recommendation system. Traditional connected systems — like the Home Feed itself — have an explicit set of sources defined by the user. Ranking those is comparatively straightforward: score posts from known sources on engagement, relevance, user interest, content quality, and freshness. Suggested Posts starts instead with an implicit graph of what the user has engaged with, derives a set of potential source accounts, and then ranks their content with similar criteria.

How candidates are generated

The candidate generation pipeline turns user activity into a virtual graph of interests. Each node in that graph — an account or media item the user has shown explicit interest in — is a potential "seed." Seeds feed into K-nearest-neighbor (KNN) pipelines built on two classic ML principles.

Embeddings-based similarity. Engagement data is used to build account embeddings, formed similarly to word embeddings: accounts and media the user interacts with are treated as sequences of "words," and similar accounts end up close to each other in the learned vector space. Given a seed account, the pipeline finds the nearest accounts in that space.

Co-occurrence-based similarity. This is frequent-pattern mining on user-media interaction data. When a user likes a spaceship post and a science-fiction post, the pair's co-occurrence frequency increments. Aggregating those frequencies yields the top N co-occurring media for a given seed.

The team built a query language to rapidly prototype and test candidate-sourcing queries, similar to one used earlier in Explore's recommender. That enables quick iteration on candidate sources without rebuilding the pipeline.

user
.let(seed_id=user_id)
.liked(max_num_to_retrieve=30)
.account_nn(embedding_config=default)
.posted_media(max_media_per_account=10)
.filter(non_recommendable_model_threshold=0.2)
.rank(ranking_model=default)
.diversify_by(seed_id, method=round_robin)

Handling the cold start

Users with insufficient recent engagement won't yield enough seed candidates. Suggested Posts handles that in two ways:

  • Fallback graph exploration. For a user with a sparse engagement graph, the system looks at one-hop and two-hop connections. If user A hasn't liked many accounts, the system can look at accounts followed by the accounts A has liked, and treat those as candidate seeds: A → Account Liked by A → Accounts following those accounts.
  • Popular media. Brand-new users get popular content initially, then the system adapts parameters based on their early engagement.

Ranking the candidates

Candidate selection trains on multiple engagement labels — positive ones like like, comment, and save, plus negative feedback signals like "not interested." The individual label probabilities are combined with weights in a log-linear user-value model, tuned via offline replay over historical sessions and online Bayesian optimization.

Value(Post) = (probability_like)^weight_like * (1- probability_not_interested)^weight_see_less

The ranking models themselves vary by task:

  • MTML (multi-task, multi-label sparse neural nets) trained with cross-entropy loss on engagement-classification labels.
  • GBDT (gradient-boosted decision trees) on a point-wise basis.
  • LambdaRank for list-wise, session-based ranking that optimizes NDCG directly.

Architecture and hyperparameters are tuned continuously using offline replay and A/B tests. The feature set feeding these models spans engagement history, author-viewer interactions, content counters and trend signals, image/video understanding, and knowledge-based attributes, as well as various precomputed embeddings and taxonomy features. Models are recalibrated regularly to keep their output distributions robust against drift.

Making recommendations feel like Home

"Feels Like Home" requires engineering choices beyond a ranking model. Several measures enforce that feel:

  1. Source prioritization. Seed accounts come potentially from Home, Explore, Reels, and other surfaces. If Home seeds are H, other-surface seeds R, and graph-fallback seeds F, the merge order is H >> R > F. Account embeddings help tune how close a recommended account is to Home accounts.
  2. Training distribution. Ranking models are trained and evaluated so the output distribution isn't skewed away from Home-based sources.
  3. Freshness. The same time-sensitivity heuristics used on the Home Feed apply to make sure suggestions feel current.
  4. Media-type mix. The proportions of photos, videos, and albums in suggested posts are kept roughy similar to the Home Feed.
  5. Qualitative guidance. User experience research and survey results feed back into how "Home-like" the product feels.

The system was ultimately judged not only on metrics like ROC-AUC and NDCG, but on whether it delivers a feed users would choose to curate themselves — relevance and long-term quality over short-term engagement optimization.