A web application that predicts whether a given message is Spam or Not Spam using Machine Learning (ML) and Natural Language Processing (NLP).
Built with Python, Flask, NLTK, and Scikit-learn.
# Create a new conda environment
conda create -p venv python=3.9 -y
# Activate the environment
conda activate venv/# Install virtualenv if not already installed
pip install virtualenv
# Create a virtual environment
virtualenv venv
# Activate the environment
venv\Scripts\activate # (Windows)
source venv/bin/activate # (Linux/Mac)
⚠️ Note: Do not mix Conda and Virtualenv in the same project. Use only one method.
Once the environment is active, install all required packages:
pip install -r requirements.txtIf you want to explore or train models in Jupyter:
pip install ipykernel
pip install jupyter notebookThen launch the notebook:
jupyter notebookRun the Flask application:
python app.pyNow open your browser and go to: 👉 http://127.0.0.1:5000/
- Go to https://dashboard.render.com/web.
- Click New → Web Service.
- Choose Build and deploy from a Git repository, then click Next.
- Configure your repository settings as shown in the screenshots.
- Click Manual Deploy → Deploy Latest Commit.
- Wait 2–3 minutes for deployment to complete.
This project demonstrates Text Classification using Machine Learning and Natural Language Processing (NLP), integrated into a Flask web application and deployed on Render.
It’s a simple yet effective example of how to turn an ML model into a real-world web service.