Adjust rankings to squash lingering popular stuff (#1982)

This commit is contained in:
Ben Halpern 2019-03-05 10:43:40 -08:00 committed by GitHub
parent 14beb68fd3
commit 3f25d52aba
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -10,9 +10,10 @@ class BlackBox
recency_bonus = usable_date > 12.hours.ago ? 80 : 0
today_bonus = usable_date > 26.hours.ago ? 395 : 0
two_day_bonus = usable_date > 48.hours.ago ? 330 : 0
four_day_bonus = usable_date > 96.hours.ago ? 330 : 0
FunctionCaller.new("blackbox-production-articleHotness",
{ article: article, user: article.user }.to_json).call +
reaction_points + recency_bonus + super_recent_bonus + super_super_recent_bonus + today_bonus + two_day_bonus
reaction_points + recency_bonus + super_recent_bonus + super_super_recent_bonus + today_bonus + two_day_bonus + four_day_bonus
end
def comment_quality_score(comment)