Browse Source

update trend statuses threshold

closed-social-glitch-2
欧醚 1 year ago
parent
commit
cd61d74274
1 changed files with 5 additions and 5 deletions
  1. +5
    -5
      app/models/trends/statuses.rb

+ 5
- 5
app/models/trends/statuses.rb View File

@ -7,12 +7,12 @@ class Trends::Statuses < Trends::Base
threshold: 10,
review_threshold: 10,
score_halflife: 12.hours.freeze,
decay_threshold: 1.8,
decay_threshold: 0.007,
expected: 5.0,
# (11 - 5)^2 / 5 * 0.5^2 = 1.8
# so a status with 11 favourites can stay 24hours
# 17 favourites, 2 days
# 29 favourites, 3 days
# (11 - 5)^2 / 5 * 0.5^10 = 0.00703125
# so a status with 11 favourites can stay 5 days
# 17 favourites, 6 days
# 29 favourites, 1 week
}
class Query < Trends::Query

Loading…
Cancel
Save