oyiptong / up-headliner

Headliner is a JSON API that returns personalized content obtained from providers
Mozilla Public License 2.0
0 stars 2 forks source link

personalization api: return results sorted by time #13

Closed oyiptong closed 10 years ago

oyiptong commented 10 years ago

Sorting by time would provide a less clumpy distribution of interests amongst article results.

This would provide a better user experience than the solution provided in #10

The sorting criteria can be obtained by calling http://redis.io/commands/zrevrange with the score option.

The optional parameter has to be provided here: https://github.com/oyiptong/up-headliner/blob/master/up/headliner/data.py#L65

And then the score must be applied to the article data.

Later on, when the response is being constructed, the articles can be sorted by score in descending order, then deduped.