Rex: Medium's Go recommendation microservice for personalized story feeds
Medium's Node.js-based recommendation system was too slow and could only rank around 150 candidate stories per feed request, with homepage feed generation taking up to seconds.
Node.js's single-threaded event loop caused CPU starvation under the heavy I/O and computation load required to build ranked feeds; technical debt also made testing and iterating on recommendation strategies slow.
Rex can rank 10x more candidate stories per feed request, and feed creation now takes less than one second for 95% of requests.
Frequently asked questions
What did this team achieve with this AI workflow?
Rex can rank 10x more candidate stories per feed request, and feed creation now takes less than one second for 95% of requests.
What tools did this team use?
Go, Redis, Scala, Node.js, collaborative filtering.
What results were reported?
Candidate stories ranked per feed: 10x; Feed creation time: less than one second for 95% of requests; Previous candidate stories ranked: 150; Previous homepage feed creation time: up to seconds (source-reported, not independently verified).
What failed first in this deployment?
Node.js's single-threaded event loop caused CPU starvation under the heavy I/O and computation load required to build ranked feeds; technical debt also made testing and iterating on recommendation strategies slow.
How is this back office ops AI workflow structured?
Multi-source story aggregation → Collaborative filtering → Preprocessing filters → Feature annotation → ML feed ranking → Diversity postprocessing → Redis cache storage → Cached feed validation.