Welcome to the Email Spam Detection repository. This project was developed during an internship at Afame Technologies, where I worked as a Machine Learning Intern. The goal of this project is to create a model that can accurately detect spam emails using a Naive Bayes classifier. The model achieves an impressive 98% accuracy on the spam detection dataset.
Project Description Dataset Installation Usage Project Structure Results Contributing License
Email spam detection is a crucial task in the modern digital era to ensure safe and efficient communication. This project leverages a Naive Bayes classifier to differentiate between spam and legitimate emails. The model has been trained and tested on a spam detection dataset and demonstrates a high level of accuracy.
The dataset used in this project is a well-known spam detection dataset. It contains email messages labeled as either 'spam' or 'ham' (not spam). The dataset has been preprocessed and cleaned to ensure optimal performance of the Naive Bayes model.
To run this project locally, follow these steps:
bash Copy code git clone https://github.com/pushpasri-M/AfameTechnology.git
bash Copy code cd AfameTechnology
bash
Copy code
python -m venv venv
source venv/bin/activate # On Windows use venv\Scripts\activate
bash Copy code pip install numpy pip install pandas pip install -U scikit-learn
To train and test the spam detection model, run the following command:
bash Copy code python main.py This script will load the dataset, preprocess the data, train the Naive Bayes model, and evaluate its performance. The results, including the accuracy score, will be displayed in the console.
The repository is organized as follows:
bash Copy code AfameTechnology/ │ ├── data/ │ └──> spam.csv # The spam detection dataset ├── notebooks/ │ └──> Spam Detection.ipynb # Jupyter notebook for EDA ├── README.md # Project README file └── LICENSE # Project license
The Naive Bayes model achieves a remarkable 98% accuracy on the spam detection dataset. This high accuracy indicates the model's effectiveness in distinguishing between spam and legitimate emails.
Contributions are welcome! If you would like to contribute to this project, please fork the repository and submit a pull request. For major changes, please open an issue to discuss what you would like to change.
This project is licensed under the MIT License. See the LICENSE file for more details.
Thank you for checking out the Email Spam Detection project. If you have any questions or feedback, feel free to reach out!
For any inquiries, please contact Pushpasri M.