The Cold Start Problem
A recommender that learns only from past clicks has nothing to say about a brand-new user or item, so it falls back to popularity lists until clicks arrive.
Why Does This Exist?
Picture a new film that lands on a streaming home page with zero views. Collaborative filtering only knows what to do when it can compare overlapping watch histories, so with no overlap it stays quiet. No views means no recommendation, and no recommendation means no views.
You'll see this as an empty row or an empty column. Think of a table with one row per user and one column per item, where entry means the stars user gave item . Most cells stay blank, and the method learns only from the filled ones. Matrix factorization makes this explicit by fitting small user and item vectors to those filled cells.
This page names the two cold edges, works the math on a 4-by-5 table, and shows the standard fallback. For the behavior method itself, read collaborative filtering. For the factor math, read matrix factorization. For the retrieval fix that leans on side details, read two-tower retrieval.
Think of It Like This
The new student with no library slips
You join a school where the librarian recommends only from borrowing slips. Ana's slips show she loves space operas, and Ben's slips match hers almost exactly, so the librarian hands Ben what Ana loved. Then you walk in with no slips at all, and a brand-new book arrives with no slips either. The librarian can only point you both at the bestseller shelf until slips pile up.
Ana, Ben, and you are users, books are items, slips are ratings, and the bestseller shelf is the popularity fallback. Matching overlapping slips is similarity.
Where it stops: a real librarian chats with you and learns you love maps in two minutes. The algorithm can't chat. Unless you hand it side details like genre or an onboarding pick, it stays on bestsellers longer than any human would.
How It Actually Works
Call the ratings table , with rows for users and columns for items. Entry means the stars user gave item , and means the set of cells you actually observed. User-based prediction for a missing cell starts from your own mean and mixes in neighbors who rated that item:
Here means the mean rating of user , means cosine similarity between and over items both rated, and the sum runs over neighbors who rated item . The factor view writes the same table as , where means the -by- user factors, means the -by- item factors, and means a small count of hidden tastes. Both forms fit only on .
The table and its two cold edges
Our fixture is 4 users by 5 movies. Ana rates M1 5, M2 4, M4 1. Ben rates M1 5, M3 4, M4 1. Cara rates M1 1, M2 1, M4 5. Dan is new and rates nothing. M5 is new and holds no ratings from anyone. The warm core is the 3-by-4 block in the corner. Dan is the empty row. M5 is the empty column. The diagram draws this exact grid.
Why warm math works and cold math goes quiet
Warm pairs share cells, so similarity has something to divide. Cold pairs share none, so the neighbor sum is empty and the denominator is zero. In factor terms, Dan holds no row in , so his vector never moves from its start, and M5 never updates either. The model still returns a number if you ask, but that number reflects the start, not taste. That is why production code must branch before it scores.
Worked example: one warm cosine and one empty row
Ana and Ben overlap on M1 and M4 as and :
Ana and Cara overlap on M1, M2, and M4 as and :
Dan overlaps with no one on any movie, so both sums stay empty and the formula asks for zero divided by zero. There is no score to compute. Popularity fills the gap by counting ratings: M1 holds 3, M4 holds 3, M2 holds 2, M3 holds 1, M5 holds 0, so the fallback order starts M1, M4, M2. Means agree: M1 averages and M4 averages .
The trade is clear. Popularity and onboarding picks work on day one but feel generic, while behavior math feels personal but needs history. Don't trust pure behavior when most traffic is new or the catalog turns over fast. The method assumes past overlap predicts future taste, and that assumption fails for new rows, new columns, and shifting tastes.
Code
The point is the check: recompute the two warm cosines and confirm the cold row routes to fallback.
from math import sqrt
def cosine(a: list[float], b: list[float]) -> float: dot: float = sum(x * y for x, y in zip(a, b)) norm: float = sqrt(sum(x * x for x in a) * sum(y * y for y in b)) return dot / norm
def fallback_for(user: list[float | None], popular: list[str]) -> list[str]: if all(r is None for r in user): return popular return ["personalized"]
ana_ben: float = cosine([5.0, 1.0], [5.0, 1.0])ana_cara: float = cosine([5.0, 4.0, 1.0], [1.0, 1.0, 5.0])print(f"{ana_ben:.2f} {ana_cara:.2f}") # -> 1.00 0.42print(fallback_for([None, None, None, None], ["M1", "M4", "M2"])) # -> ['M1', 'M4', 'M2']The printout matches the hand computation: 1.00 for the identical pair, 0.42 for the partial match, and the empty row returns the popularity list.
Watch Out For
Treating a cold factor score as a real preference
A new user with no entries still gets a number if you score them, because their factor row sits at its random start. Symptom: new movies with zero views show confident highs, yet offline checks look fine because cold rows were left out of the split. Fix: count overlaps first. When the count is zero, skip the model and return the popularity list, and track how often the cold path fires in recommendation evaluation.
Letting popularity hide new items forever
When every slot goes to past winners, new items never collect the clicks that would warm them. Symptom: the same titles top the list for weeks and the new catalog share of impressions sits near zero. Fix: hold a small fixed slice of slots for new items, spread impressions across them, and watch their click share climb before you promote winners.
The Quick Version
- Cold start means a user row or an item column in holds zero observed entries, so neighbor sums stay empty and factor rows never fit.
- In our 4-by-5 table Ana and Ben score cosine 1.00 over and , Ana and Cara score 0.42, and Dan scores nothing because his row is empty.
- New rows and columns get popularity lists or onboarding picks until clicks arrive, because behavior math cannot invent a preference.
- A factor score for a zero-history row reflects its start, not taste, so gate it and route cold cases to the fallback.
- When new items never win impressions, they never warm up, so reserve a small fixed slice of slots for them and track their share.