Build trending hashtags in to left nav

I (and probably others) would love to see trending hashtags be listed in the left nav like this example:

I would like to discuss the best / most preferred method of doing this in order to build a spec for Github issue #6012.

There are various ways to do it and there is no right or wrong way, it merely depends on ones definition of the word ‘trending’. I might be over-complicating this so please chip in with your ideas!

What it should not be, is simply a list of ‘popular’ tags.

I recommend 3x podmin level options in diaspora.yml to allow the podmin to turn on or off: Local Trending Tags, Worldwide Trending Tags, Popular Tags.

(where ‘popular’ is a list of popular (by count))

The ability to exclude certain words is also a requirement (bots, spam, offensive, etc. Also a requirement is the ability to exclude certain users too (again, bots, spammers, etc). These ignored tags and ignored users should be stored in a simple db table.

Users should also have an option in their profile settings to choose (if the podmin has enabled it) to display trending tags in their left nav menu.

The reason to allow or differentiate between “local” and “worldwide” trending tags is due to the size of the pod. A pod with a small amount users (less than 1000) will struggle to find true trending tags.

Be aware, the current tags table contains tags used in PRIVATE posts so should be approached with caution.

Both myself and Brian õ have put in countless hours on this elsewhere so can happily provide core logic / flow process examples where required but to start this spec-discussion off I would recommend:

Create two db tables called:

  1. tags_ignore_words
  2. tags_ignore_handles

These will be used for reference so the script(s) know what to include or exclude.

Create a script (or whatever the Ruby equivalent is) that once per hour scans all public posts for the last 30 days, excludes reshares, and captures all #hashtag words in to a new table, attaching a counter to each tag. This will be your rolling average / baseline / past frequency.

Create another script which runs more frequently, perhaps every 15mins or so, which a scans all posts in the last one hour and drops those tags in to a different table. This will be your present frequency.

Compare present frequency tags against the past frequency baseline tags for reoccurrence and score them accordingly. Pull the top ten and display in the left nav.

This (long) video goes a great way to explaining what I mean: https://www.youtube.com/watch?v=duHxpSTmwW0&t=9m52s (the relevant part starts at 9mins 52mins)

My work in progress (which is NOT coded in Ruby but please see the logic principals as a good starting point) is at https://github.com/RichKavanagh/diaspora_trending_tags/blob/master/README.md

Thoughts?


Note: This discussion was imported from Loomio. Click here to view the original discussion.

I have conflicting thoughts about that in occasions can be a useful tool but can also occur as in twitter that only becomes a jerk competition.

I’d love a trending tags list - preferably split into local/all sections.

@juansantiago No problem, if done correctly you can switch it off on your profile settings :slight_smile:

@rich1 My problem is that if I see a bunch of idiots running for an irrelevance, at times I become one more of them :frowning:

Hi Rich

could you please email at ed@tridentnet.net would like to talk to you with regards to a project

Thanks

Possible duplicate of https://www.loomio.org/d/YlO5RF3q/top-twenty-tags-section-in-left-sidebar?

Edit: And this is really interesting! I’m not sure if I’d like it in the main interface or just on like the welcome/sign in page for each pod though…

Not a duplicate - this is for ‘trending’ tags, not popular ones.