module NBayes
NBayes::Base
¶ ↑
Robust implementation of NaiveBayes:
-
using log probabilities to avoid floating point issues
-
Laplacian smoothing for unseen tokens
-
allows binarized or standard NB
-
allows Prior distribution on category to be assumed uniform (optional)
-
generic to work with all types of tokens, not just text