Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Step 1, background for making the /about page friendlier is trying to surface recent discussions from the instance. first i wanted to make the discover page usable at all, and then i'll add a filter to only include posts from the instance.
Currently the discovery page is sort of sad, doesn't really work for smaller instances because the values are all tuned for mastodon social.
beginning_of_day
rather thandays_ago(1)
So this PR
descendents_count
method to Status that counts all replies in a tree, rather than immediate repliesused
key in redis but i'm assuming it's last time it's accessed)interaction_exponent
out of the function into the options - i feel like this should be an exponent <1 where there is some ceiling for interaction counts mattering rather than making them matter more at higher values, but i didn't want to change too much without simulatinglocal_weight
value that amplifies posts from within the instanceHere's the worst matplotlib plot you've ever seen showing some values of favorites, replies, and boosts over a week and how those scores decay with time. i split it out into 3 subplots for number of favorites bc there were too many lines in a single plot, and the legends say how many boosts or replies for each post. another way of reading this is to "slide each line across time" to see when a post with a smaller number of interactions would have a higher rank than an older post with more interactions, and that's sort of a proxy for the discovery churn. The vertical black bars indicate when a post (with the matching initial y-value) would fall below the consideration threshold. So a post with 25 likes, 25 boosts, and 5 replies would fall out of consideration in about a week (but would probably be very low in the list at that point), and all the higher values follow shortly after
@thesamovar wdyt
edit: looks like i'll need to adjust some values in the tests, but nothing seems fundamentally broken. this is a pretty simple pr after all