AI Glossary / AI and machine learning / Intermediate
Candidate generation
Definition
Candidate generation is the fast first stage of a recommendation or search system, which picks a few hundred plausible items out of millions so a slower, smarter stage can rank them properly.
What it means
A large catalog is too big to score item by item for every user. A shop with a million products cannot run its best model a million times per visit, so the problem is split in two.
The first stage, candidate generation, is built for speed and high recall: it must be cheap, and it must not miss items the user would love, even if it picks up plenty of mediocre ones.
The second stage, ranking, takes the shortlist and scores it carefully with the full model, using richer signals such as context, margins and diversity, to produce the final few.
Candidates come from several sources at once: items similar to past purchases, what similar users liked, trending lists, new arrivals and simple business rules such as in stock and shippable to this address.
For a business, the stage matters because it silently bounds quality. If the right item never makes the shortlist, no clever ranker can ever show it, so the candidate stage is where popularity bias and blind spots are born.
The same two-stage pattern appears outside retail: document search retrieves candidate passages before a reader model answers, and hiring tools shortlist before people interview.
How it works
Represent items and users in a shared numerical space, then retrieve the nearest items to the user, a fast lookup even over millions of items.
Merge candidates from several generators: similarity, popularity, trends, newness and rules, each adding a slice the others miss.
Deduplicate, filter on hard constraints such as availability and region, and pass a few hundred survivors to the ranker.
Measure stage one with recall: how often the item the user ultimately wanted was somewhere in the shortlist. If recall is low, fix candidates before tuning the ranker.
Watch the latency and cost budget. The whole point of the split is that stage one stays cheap as the catalog grows.
Freshness matters. Candidates are usually precomputed or served from a fast index, so a system update that ignores the candidate store can leave the shortlist stale even when the ranker is new.
Three practical examples
- An online shop shortlisting 500 products per visitor, then ranking them by predicted interest and margin.
- A music app drawing candidates from similar listeners, recent plays and editorial picks before ordering the home screen.
- A recruitment site shortlisting CVs by skills match before a recruiter reviews the ranked top fifty.
Think of it this way
Think of hiring. A quick screen turns a thousand applications into a shortlist of twenty, and interviews pick from the twenty. Nobody interviews a thousand people.
The limit: whatever the screen wrongly rejects is gone for good. A screen that filters on the wrong thing, such as one employer's name, quietly removes the best candidates before the interviews begin.
Worked example
shortlisting books for the home page
Suppose an online bookshop has 800,000 titles. On each visit it generates candidates from the customer's past purchases, similar readers' favorites and this week's new releases, about 400 titles in tens of milliseconds.
A ranking model then scores those 400 using reading history, stock and margin, and the top twelve appear on the home page. The figures are illustrative.
When a bestseller is missing from recommendations, the team checks recall first: the title was never generated as a candidate, so the ranker never saw it.
They add a rule-based generator for highly rated new titles, and the problem class disappears.
Illustrative case study
A fictional marketplace notices that a handful of big sellers dominate every recommendation slot. Candidate recall is fine, but every generator leans on popularity signals.
The team adds a generator dedicated to relevant small sellers and caps how many slots one seller can take. Revenue per visit holds steady while seller diversity recovers, which stabilizes the marketplace.
The invented lesson: the candidate stage is where fairness and diversity are decided, because the ranker can only choose from what it is given.
Common misconceptions and mistakes
- The recommender is the ranking model. The ranker only orders the shortlist; generation decides what is thinkable at all.
- More candidates always help. Beyond a point they add noise, latency and cost while the ranker ignores the tail.
- It only matters at giant scale. The retrieve-then-rank idea pays off from a few thousand items upward, and the recall lesson applies at any size.
Business use
When buying or reviewing a recommendation system, ask how candidates are generated and how recall is measured, not just how the ranking model works.
Audit the shortlist for blind spots: new products, niche suppliers and unusual customers are the usual casualties of a popularity-driven generator.
If you sell through marketplaces, their candidate generation decides whether your products are even considered, which is why complete attributes and early sales velocity matter so much there.
People also ask
How many candidates should stage one keep?
Enough to give the ranker real choice without slowing it: hundreds is typical, tuned by recall and latency.
What is recall in this context?
The share of ultimately chosen or loved items that made it into the shortlist at all.
Is candidate generation the same as retrieval?
Retrieval is the main technique; generation also includes rules, trends and editorial sources.
Can I inspect the candidate stage as a buyer?
Ask for recall metrics and a sample shortlist; a vendor who cannot show candidates cannot explain misses.
Check your understanding
Why not score every item in the catalog for every user?
Answer: Scoring millions of items per visit is too slow and expensive, so a cheap, high-recall stage shortlists a few hundred for the accurate ranker.
Related terms
- Ranking
- Recall
- Embedding
- Popularity Bias
- recommendation system
- retrieval
- embeddings
Learn next
AI for Business Owners helps you ask the right questions of recommendation and personalization vendors: https://aiforbusinessandlife.com/academy/ai-for-business-owners. [C2]
More in AI and machine learning
- Bucketing - Bucketing groups values into ranges, or buckets, such as ages 18 to 24 and 25 to 34, so a model or report works with a few clear groups instead of thousands...
- C4.5 algorithm - C4.5 is a supervised learning algorithm developed by Ross Quinlan for building classification decision trees from labeled examples.
- Calibration curves - A calibration curve checks whether a model's confidence means what it says: when the model predicts a 70 percent chance for a group of cases, about 70...
- Canonical correspondence analysis - Canonical correspondence analysis is a constrained ordination method that relates a table of species abundances, or similar non-negative response data, to...
- Cascading classifiers - Cascading classifiers are classification stages arranged so that an example's result at one stage determines whether it proceeds to another.
- Case-based reasoning - Case-based reasoning is an approach to problem solving that uses relevant past cases to help address a new situation.
Sources
[S2] Google, Machine Learning Glossary. Full URLs are in the source ledger. Verified 11 October 2026.
Previous: Camera path Next: Candidate key