Skip to content

SamuelKupferschmid/nbc

Repository files navigation

nbc

Build Status Coverage Status

this Code is still under construction and not ready for use!

Implementation of a simple naive bayes classifier.

This Library was developed for education purpose and was not used yet in production by the author.

This classifier could be used to detect if a text is spam or not or to detect a language of a given text.

For this a large training and validationset is required.

usage

d := []LabelItem{
	LabelItem{
		label:   "test1",
		content: SplitText("example text"),
	},
}

c := &Classifier{}

c.Train(d)
p := c.Validate(d)

if p.Precision < 1 || p.Recall < 1 {
	t.Fail()
}

About

naive bayes (multi-)classifier written in Go

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages