Initial implementation of Naive Bayes classifier.