Skip to content

Naive Bayes spamfilter implementation in python 3.6 and its command line interface for Linux system

Notifications You must be signed in to change notification settings

ZhouYuxuanYX/Naive-Bayes-Spamfilter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Naive Bayes spamfilter implementation in python 3.6 and its command line interface for Linux system

Main Files:

  • spamfilter.py
  • NBclassifier.py

Usage:

spamfilter train -m -c

spamfilter classify -m

Options:

-c , --corpuspath #Path to the corpus that should be used to train the spamfilter. The path should contain two directories, ham and spam, which contain the ham and spam emails in individual files.

-m , --modelpath #Path to the model. In training mode this is where the model will be written to, in classification mode this is where the model will be read from.

Assumptions:

• Bag of words Model: assume position of words doesn’t matter

• Conditional Independence: Assume the feature probabilities are independent given the class c

About

Naive Bayes spamfilter implementation in python 3.6 and its command line interface for Linux system

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages