This project is an email spam detection system built with Streamlit and a Multinomial Naive Bayes classifier.
It analyzes the textual content of emails to determine whether a message is SPAM or HAM (legitimate) using probabilistic natural language processing (NLP) techniques.
The model is trained on a labeled dataset of real email messages to classify incoming text accurately and efficiently.
- Real-time spam detection directly from the browser
- Machine learning model (Multinomial Naive Bayes) trained on SMS/Email text data
- Automatic text preprocessing and vectorization using CountVectorizer
- Confidence-based probability output for each classification
- Simple, clean Streamlit web interface for user interaction
- Python 3
- Streamlit for the web interface
- Pandas and NumPy for data processing
- Scikit-learn for model building and text vectorization
- The system loads and preprocesses the email dataset (spam vs ham).
- Each message is converted into numerical features using CountVectorizer.
- A Multinomial Naive Bayes classifier learns the statistical patterns of spam and ham messages.
- When a user inputs a new email, the model predicts whether it is spam or legitimate.
- The output includes a clear classification and a confidence score representing prediction certainty.
This project demonstrates how machine learning and NLP can effectively detect unwanted or malicious messages.
Using a lightweight Naive Bayes model, the app provides fast, accurate, and interpretable results suitable for practical spam filtering applications.
Explore the Email Spam Detection App yourself! The app is deployed on Streamlit. Click the link below to get started: Email Spam Detection App