01 · The idea
A weekly ranking rewards the wrong venues.
A frozen weekly leaderboard has two problems. It rewards whoever banked views early and coasts, and it resets on a cliff, so every Monday the standings lurch in a way that has nothing to do with where the night is actually moving. For a product whose entire promise is real-time, a stale ranking undercuts the pitch.
I wanted a ranking that reflects momentum right now, gives every venue a live reason to stay active, and turns that competition into something the business can monetize.
02 · The work
Score demand with decay, rank the city, show everyone their place.
Instead of counting views in a fixed window, each venue's score is a sum of its view events where every view is weighted by how recently it happened. The weight follows an exponential decay with a 48-hour half-life, so a view from a day ago still carries most of its value and an old view fades smoothly. There is no reset and no cliff, just a score that always reflects current momentum. The whole computation runs at query time in the database aggregation, so the ranking is live.
On top of the raw signal I built a richer demand layer that dedupes noisy events and weights them by intent, so a strong action counts for more than an idle glance. The city-wide ranking surfaces the top rooms, and every owner sees their own position, their exact rank out of the full field, with an up or down delta against the previous window so they can feel movement.
Then I closed the loop to revenue. The leaderboard is where a venue feels competitive, so that is exactly where the promote-your-venue path lives, turning the ranking into the top of the ads funnel.
03 · Outcome
A ranking that's alive, fair, and monetized.
04 · Behind the work
How I think about it.
Decay over snapshots is a small modeling choice with a big behavioral payoff. A half-life means the ranking can never go stale and never resets unfairly, so the incentive it creates, stay active to stay visible, is on all the time instead of once a week. The math is in service of the behavior.
The part I care about is that the same surface does three jobs at once: it tells users where the night is, it gives venues a competitive scoreboard, and it opens the ads funnel. One ranking, three sides of the marketplace pulling in the same direction.