When I decided to build WhatNext., I made one foundational design decision before writing a single line of interface code: the app would not require an account, your data would stay on your own device by default, and every recommendation would be calculated directly on the phone in your hand.
Most recommendation systems on the web work by taking your ratings, sending them across the internet to a server, running heavy queries in a cloud database, and shipping back a list of results. That approach is convenient for developers: you can collect rich behavioral data, train server-side models, and gate features behind logins.
It also means your private taste (every late-night guilty pleasure, every obscure indie documentary, and every niche franchise you rewatch when you're exhausted) ends up indexed on someone else's infrastructure.
I wanted something different: a private, self-contained tool that felt more like a pocket film almanac than a data harvester. Building a genuine recommendation engine that runs entirely on a phone without lag, though, turned out to be a real engineering puzzle.
The Cloud Shortcut I Chose Not to Take
If you build a recommendation app the usual way, you put a database in the cloud, build an API for the app to talk to, and send information back and forth to that server every time it needs an answer.
The app itself stays simple, but the trade-offs are steep:
- Network latency: Every swipe, rating, or filter tweak requires a round trip over the internet. If you're on an airplane or a subway with spotty reception, the app just stops working.
- Infrastructure overhead: Running hosted databases at scale gets expensive fast, and that cost has to come from somewhere.
- Data custody: Once you store people's preferences on a central server, you're responsible for securing them, forever.
By keeping everything on-device, recommendations work completely offline, and I don't have access to your taste profile in the first place.
A Fingerprint for Every Film
To understand how on-device recommendations work, it helps to know how WhatNext. represents films in the first place.
The app doesn't match movies by simple keyword tags like "action" or "comedy." Instead, every film in the catalogue gets a kind of fingerprint: a set of numbers that captures its themes, pacing, tone, and mood all at once. Movies with similar fingerprints sit close together: Interstellar naturally lands near Arrival and Ad Astra, while Whiplash sits alongside other tense, obsession-driven character studies.
When you rate movies you love, WhatNext. blends their fingerprints together into your own personal taste profile. To suggest what to watch next, it simply looks for films whose fingerprints sit closest to yours.
Here's the catch: WhatNext. tracks roughly 16,900 films, and each fingerprint is made up of hundreds of numbers. Add it all up, and the app has to work through several million individual numbers every time it starts fresh.
Converting all of those numbers into a form the phone could actually use, the standard way, millions of times in a row, caused a noticeable hiccup on launch. It was simply too slow to feel smooth.
The fix was to stop redoing that math over and over. I precomputed every possible answer once, ahead of time, into a small lookup table, about the size of a single photo, so instead of recalculating each number from scratch millions of times, the app just looks the answer up instantly.
That one change took the hiccup down to nothing.
Doing the Math in the Background
Even with that fixed, comparing your taste profile against the whole catalogue could still make the interface stutter during fast scrolling or swiping.
So I moved all of that math out of the way entirely, into its own background process that runs independently of whatever's happening on screen. When the app starts up, all of the film fingerprint data gets handed off to that background process directly, so the part of the app drawing your screen doesn't have to touch a single one of those numbers itself.
Whenever you tap a rating, your updated taste profile gets sent to that background process too. It does the comparison, filters out the near-identical sequels so your feed doesn't fill up with four versions of the same franchise, and sends back a fresh, ranked list of what to watch next, all without the screen ever waiting on it.
That leaves the part of the app drawing your screen completely free to handle smooth scrolling and every card animation in between.
Privacy as an Architecture, Not a Policy
Privacy policies are easy to write, but architecture is what actually protects people.
When an app promises your data is safe on their cloud servers, you're trusting their security practices, their future business models, and their database configurations. When an app is built so that your data doesn't need to leave your device to work in the first place, privacy isn't something you have to take on faith. It's built into how the thing runs.
Your movie taste is personal: it reflects your moods, your memories, and how you spend your quietest hours. Keeping that math on the phone means you don't have to trade your privacy just to get thoughtful recommendations about what to watch next.