Check info.py for the training and testing code. A demo of the tool is available here

Refer this paper for more information about the algorithms used.

http://arxiv.org/abs/1305.6143

This tool works by examining individual words and short sequences of words (n-grams) and comparing them with a probability model. The probability model is built on a prelabeled test set of IMDb movie reviews. It can also detect negations in phrases, i.e, the phrase “not bad” will be classified as positive despite having two individual words with a negative sentiment.