From: Scarlett <63085504+Whayme@users.noreply.github.com> Date: Sat, 28 Nov 2020 06:29:56 +0000 (-0600) Subject: Short intro explanation, reformatted as a table X-Git-Url: http://these/git/%7B%60%24%7BwebArchiveUrl%7D/%22%7B%7D/%22https:/nerdica.net/readmes/README.zh.hant.md?a=commitdiff_plain;h=961fc9d0ce1683e79188d42594ad9a59f59b0426;p=lemmy.git Short intro explanation, reformatted as a table More explanation from someone who understands the benefits of the log scale would be helpful. --- diff --git a/docs/src/about_ranking.md b/docs/src/about_ranking.md index 0f91b7e3..854b4da8 100644 --- a/docs/src/about_ranking.md +++ b/docs/src/about_ranking.md @@ -1,16 +1,17 @@ # Trending / Hot / Best Sorting algorithm -## Goals + +An expected feature in link aggregators is a kind of "Trending" sort which shows users a mixture of new posts / comments and popular ones, making for a display order which highlights the most currently active parts of the site / thread. This keeps the experience fresh and makes sure the site stays moving. Various flaws can be found in the ways that popular link aggregators like Reddit have implemented "Hot" or "Trending" sorts, so Lemmy has its own algorithm. + +## Goals and Considerations - During the day, new posts and comments should be near the top, so they can be voted on. - After a day or so, the time factor should go away. - Use a log scale, since votes tend to snowball, and so the first 10 votes are just as important as the next hundred. -## Reddit Sorting -[Reddit's comment sorting algorithm](https://medium.com/hacking-and-gonzo/how-reddit-ranking-algorithms-work-ef111e33d0d9), the wilson confidence sort, is inadequate, because it completely ignores time. What ends up happening, especially in smaller subreddits, is that the early comments end up getting upvoted, and newer comments stay at the bottom, never to be seen. Research showed that nearly all top comments are just the [first ones posted.](https://minimaxir.com/2016/11/first-comment/) - -## Hacker News Sorting -The [Hacker New's ranking algorithm](https://medium.com/hacking-and-gonzo/how-hacker-news-ranking-algorithm-works-1d9b0cf2c08d) is great, but it doesn't use a log scale for the scores. +| Reddit | Hacker News | Lemmy | +|-|-|-| +| Does not take the lifetime of the thread into account, [giving early comments an overwhelming advantage over later ones,](https://minimaxir.com/2016/11/first-comment/) with the effect being even worse in small communities. New comments pool at the bottom of the thread, effectively killing off discussion and making each thread a race to comment early. This lowers the quality of conversation and rewards comments that are repetitive and spammy. | While far superior to Reddit's implementation for its decay of scores over time, [Hacker News' ranking algorithm](https://medium.com/hacking-and-gonzo/how-hacker-news-ranking-algorithm-works-1d9b0cf2c08d) does not use a logarithmic scale for scores. | Counterbalances the snowballing effect of votes over time with a logarithmic scale. Negates the inherent advantage of early comments while still ensuring that votes still matter in the long-term, not nuking older popular comments. | -## My Algorithm +## Additional Details ``` Rank = ScaleFactor * log(Max(1, 3 + Score)) / (Time + 2)^Gravity