You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We want to make sure that the best daily content shows up on top anytime someone checks in. The links with the best score will show up on top. This means we have to assign a computed score to each link item that is posted.
So how do we score the best links?
The latest links - sorted by time posted
The most upvoted links - sorted by number of votes accumulated
In effect we can say that links decay over time - they have a certain freshness to them. Adding votes adds to their score but only incrementally.
We want to make sure that the best daily content shows up on top anytime someone checks in. The links with the best score will show up on top. This means we have to assign a computed score to each link item that is posted.
So how do we score the best links?
In effect we can say that links decay over time - they have a certain freshness to them. Adding votes adds to their score but only incrementally.
Worth adding this excerpt:
Effects of gravity (G) and time (T)
Gravity and time have a significant impact on the score of an item. Generally these things hold true:
For reference I am also adding the ranking algorithm at the heart of Hacker News:
In Python
In PHP
From the excerpt again:
Score = (P-1) / (T+2)^G
where,
P = points of an item (and -1 is to negate submitters vote)
T = time since submission (in hours)
G = Gravity, defaults to 1.8 in news.arc
more on the HN algo here: https://medium.com/hacking-and-gonzo/how-reddit-ranking-algorithms-work-ef111e33d0d9
The text was updated successfully, but these errors were encountered: