A real-time, interactive web application that detects fake news using a deep learning model and natural language processing techniques. Users can input any news article or headline and instantly find out whether it’s likely to be REAL or FAKE, along with sentiment analysis, visual confidence plots, and the option to export prediction history.
Kaggle Dataset: Fake News Detection Dataset
Contains labeled examples of real and fake news for supervised learning.
- 🔍 Real-time fake news classification with confidence scores
- 😊 Sentiment analysis of the news content
- 📈 Interactive visualization: Confidence vs. Sentiment scatter plot
- 📸 Downloadable plot image and session data (CSV)
- 📊 Histogram of model confidence (optional analytics)
- 💾 Built with TensorFlow, Scikit-learn, Streamlit, and Plotly
├── app-fakenews.py # Main Streamlit app
├── fake_news_model.keras # Trained deep learning model
├── vectorizer.pkl # Pickled text vectorizer
├── requirements.txt # Dependencies
└── README.md # You're here!
🧠 Model Overview
- Model Type: Binary Classifier (Real vs Fake)
- Architecture: Deep Neural Network (can be extended to BERT or LSTM)
- Input: News headline or article
- Preprocessing: Tokenization, stopword removal, stemming
- Vectorization: TF-IDF or custom tokenizer
- Output: Binary class + probability score
- Clone the repository
git clone https://github.com/yourusername/fake-news-detector.git
cd fake-news-detector
- Create a virtual environment and install dependencies
pip install -r requirements.txt
- Run the app
streamlit run app-fakenews.py
-
Fine-tune a transformer model (e.g., BERT)
-
Explain predictions with LIME or SHAP
-
Add support for CSV or RSS feed inputs
-
Deploy via Hugging Face Spaces or Streamlit Cloud
-
Add multilingual support with XLM-R
-
Paste a news article or headline into the text box.
-
Click Analyze to get:
-
Real/Fake classification
-
Confidence score
-
Sentiment analysis
-
-
Click Show Visual to:
-
Plot confidence vs sentiment
-
Export the results as CSV or PNG
-
- Alekhya Vittalam
- Ananya Agrawal
- Ananya Chembai
- Chehak Arora
- Sophia Kurz