Introducing django-bayesianvoting

I'm not one for simple +1/-1, linear growth-based voting systems. For a few projects, both here at work and at home in my secret laboratory (spare bedroom), I wanted something a ranking system that was a little more realistic, and a little less based in reality. After noodling around for a while, I've come up with a Django application that can be dropped in and used fairly easily for voting any which way you'd like: +1/-1, 1-5, 1.0-10.0, and so on. Heres the catch: it ranks results using a Bayesian average.

By using a Bayesian average, content will be ranked by determining its true popularity compared to the rest of the content. To quote Markus Weichselbaum,

  • The more votes an item has, the closer the corrected rating value would be to the uncorrected rating value.
  • The less votes an item has – and this is the main trick here – the closer its rating should be to the average rating value of all items!

My first (publicly available) attempt at solving the issue of probabilistic ranking will soon be online over at Google Code. Ultimately, this project will factor customizable aspects like object lifetime-based decay and user voting weight into popularity ranking -- you'll be able to have Digg-style voting out-of-the-box for any content on your site, with the cream of the crop rising to the top. With its initial release, however, you'll be able use the application to make sure that your ranking speaks to the general consensus of the voters.

django-bayesianvoting will be released as soon as the API is gussied up a bit more and I can "finish" testing it. Im hoping to post by 4/25, and look forward to feedback.

For those curious about Bayes, his probabilistic theorems, and the like, check out these links:

Also, if you're really in the mood for data crunching, ranking, etc:

 

Tags: bayes, django, python, voting

Bookmark Posted by Matt on 4/21/08 Comments (2)

Comments

From Doug Twyman, 2 months ago.

Any good news on this yet ?

From Pete Skomoroch, 2 months ago.

I built something like this in rails a while back, but am primarily a Django guy now. I'll keep an eye out for the code. What datasets were you experimenting with?

Add A Comment

* optional

> Add Your Comment