PHP Bayesian Classifier

I am looking for a naive Bayes classifier for PHP, ideally this is equivalent to the Python version of Reverend Bayes. Does anyone know about such a library?

Basically, I need to be able to train him with a set of labels and words, i.e. GOOD = good, happy, fun; Bad = wrong, garbage, terrible, etc., then pass it a string value and return the best guess to it. The reverend does this fine, but unfortunately the application that you now need to use is not Python based and makes the bridge between them unfeasible.

Any suggestions would be highly appreciated, as most of the classes that I found seem to be focused on medicine with only a few cases or setting up spam filtering.

+3
source share
1 answer

It looks like a good set of guides on this. A similar question was asked earlier , and the only real answer pointed to the same resource.

Bayesian filtering - a general approach. Even if the examples you find are medical, the methods are almost the same and can be applied anywhere.

+3
source

Source: https://habr.com/ru/post/1727506/


All Articles