Skip to content

πŸƒ Spam Classifier with Data Preparation and Support Vector Machine (SVM)

Notifications You must be signed in to change notification settings

javascript-machine-learning/svm-spam-classifier-javascript

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Spam Classifier with SVM in JavaScript

Build Status

This example project demonstrates how support vector machine (SVM) may be used to solve a classification problem (spam filter) in JavaScript. The SMS Spam Collection Dataset from kaggle is used for the purpose of training and testing the algorithm. Before training the algorithm, the data set is prepared with common practices to finally extract a feature vector for each SMS. Furthermore, svm.js is used for a ready to go SVM implementation.

As alternative, uncomment the code to use Naive Bayes classifier instead of SVM from the natural library.

Installation

  • git clone git@github.com:javascript-machine-learning/svm-spam-classifier-javascript.git
  • cd svm-spam-classifier-javascript
  • npm install
  • npm start