AI Product Recommendation Engine
Personalized recommendations without a personalization latency tax
4 months to production, iterated over 1+ year
- P95 response time
- <80ms
- Cold-start coverage
- 100%
- Recompute cadence
- Nightly + real-time
Overview
Static best-seller lists on product pages were leaving conversion on the table. Built a recommendation service that personalizes results per shopper while keeping response times indistinguishable from a static list.
The Problem
Generic best-seller lists produced flat click-through rates. The business needed personalized recommendations, but naive per-request scoring would have added unacceptable latency to product pages.
Architecture
A recommendation service ingests behavioral events (views, add-to-cart, purchases) and computes collaborative-filtering and content-based scores in a nightly batch job. Results are cached in Redis and served through a lightweight API; a real-time re-ranking layer adjusts cached results using the current session's signals without recomputing from scratch.
Challenges and solutions
Challenges
- Cold-start: new users and new products have no behavioral history to score against
- Keeping recommendations fresh without recomputing the full model on every request
- Serving personalized results at the same latency budget as a static list
Solutions
- Hybrid scoring: popularity- and category-based fallback covers cold-start users and products until behavioral data accumulates
- Nightly batch recompute for the heavy collaborative-filtering pass, with a cheap real-time re-ranking step layered on top per session
- Redis-cached results keyed by user/segment so the request path never touches the model directly
Performance Improvements
- Held p95 response time under 80ms — no perceptible cost versus a static list
- Closed the cold-start gap to 100% coverage via the fallback scoring path
- Increased click-through on recommended placements versus the prior static best-seller list
Business Impact
Product pages now surface relevant items per shopper instead of the same list for everyone, lifting engagement on recommended placements without adding infrastructure cost to the request path.
Lessons Learned
The hard part of recommendation systems is rarely the scoring algorithm — it's designing around cold-start and latency budgets from day one instead of patching them in later.
Stack
- Node.js
- Python
- PostgreSQL
- Redis
- AWS