Popular tags - personal ranking

* A fancier - perhaps mildly baffling - algorithm for calculating a user's favourite tags. Takes into account "habit", a rough calculation of how consistent their pattern of visits is across 30 days.

* Separates logging of history from logging of tags; only logs history for video views (to support the requirement that autoplay only happens on a user's first visit to a video // @rich-nguyen )

@crifmulholland 

This should be passed in, sourced from capi. Will do this in another PR.