The system is trained on a labeled dataset containing both spam and non-spam messages. It analyzes the text content, learns common patterns used in spam messages, and then predicts whether a new message is spam or not.
This project focuses on the core concepts of Natural Language Processing (NLP) and supervised learning rather than complex models.
1.The input text is cleaned and converted into numerical form using text vectorization. 2.A machine learning algorithm is trained on the processed data. 3.When a new message is entered, the trained model predicts its category based on learned patterns.
- Python
- pandas
- scikit-learn
- Install dependencies: pip install -r requirements.txt
- Run the program: python model.py
Enter a message: Win a free prize now
Prediction: SPAM