NLP-powered misinformation classifier using TF-IDF features and Logistic Regression to distinguish fake from real news.
A machine learning pipeline that combats misinformation by automatically classifying news articles as real or fake. The system combines article titles and body text, applies TF-IDF vectorization, and uses Logistic Regression for binary classification with high accuracy.
News Article (Title + Body)
↓
Text Preprocessing (combine title & text, lowercase, clean)
↓
TF-IDF Vectorization (stop words removal, frequency filtering)
↓
Logistic Regression Classifier (max_iter=1000)
↓
Prediction: REAL / FAKE
- 🔍 Title + Body Fusion — Combines headline and article text for richer features
- 📊 TF-IDF with Smart Filtering —
max_df=0.95,min_df=5to filter noise - 🎯 Stratified Train/Test Split — Ensures balanced class distribution
- 📈 Full Evaluation Suite — Accuracy, Classification Report, Confusion Matrix
- ⚡ Fast Inference — Classify new articles in milliseconds
git clone https://github.com/Izumi6/Fake-News-Detection-System.git
cd Fake-News-Detection-System
pip install pandas scikit-learn
python fake_news_detection.pyPython · Scikit-learn · TF-IDF · Logistic Regression · Pandas
Suyash Vakhariya — suyashvakhariya.com · LinkedIn · GitHub