# Karat Sleuth
## Project By Evan, Tim, Heather


A SPAM Email detection tool that uses various heuristics and continually learns
what is and is not SPAM


We've done _SO, MUCH, WORK_. So amaze

# Karat Sleuth
## Project By Evan, Tim, Heather


A SPAM Email detection tool that uses various heuristics and continually learns
what is and is not SPAM


## Implementation

 * Written as a ruby gem with an intuitive command line interface and library
 * Rake tasks to download and normalize training/testing data
 * Bayesian filtering/training performed on email subject and body
 * Bayesian category-word-tally triplets are stored in SQLite


### Data Normalization

`rake training:normalize`

 * Downloads 10 different archives of spam / ham training data
 * Ensures all messages are in the same raw message format
 * Organizes spam/ham into 'difficulty' categories: Hard, Easy, Unknown -
   Based on original data set organization
 * Renames all email messages to {md5checksum}.eml
 * `training_sets/{hard,easy,unknown}/{spam,ham}/*.eml`


## CLI Usage

 * `karat-sleuth train [data-set|path] [ham|spam]`
   - If a data-set name is passed (`easy`, `hard`, `unknown`) then the messages
    will be loaded from the default training directory
   - If a file / directory path is specified it will learn from all messages
    specified in the path
   - Persists the classifier data

 * `karat-sleuth reclassify [data-set|path]`
   - Can classify one or more messages from a specified path
   - Prints out statistics regarding testing data
   - Accuracy per message, total accuracy, and confusion matrix
 

Add recap and current CLI usage
Add recap and current CLI usage
