Comment

Comment by gnramires

This is pretty cool! If I may suggest something, on the explore view, avoid showing most popular (I think it can lead to rote behavior!)

If I may suggest another algorithm, something like picking from most popular to least with probability ~1/(rank+k)^p, where p is any number >1, for example set p=1.5, k=10.

It can be implemented the following way (by computing the integral of the probability distribution):

(1) Have sorted index by popularity with n items

(2) Pick a random (double) r between 0 and 1

(3) The chosen index is (if I did my integrals right;round to nearest integer):

i = ( k^(p-1)*(n-1+k)^(p-1) / ( (r+1)*(n-1+k)^(p-1) - r*k^(p-1) ) ) ^ 1/(p-1) - k

parent gnramires 2 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton