Skip to content

Repository files navigation

Create a virtual environment (Linux/Mac)

python -m venv venv source venv/bin/activate

On Windows:

python -m venv venv venv\Scripts\activate

(ensure using correct interpreter)

install depedencies inside venv

pip install --upgrade pip
pip install -r requirements.txt

install NLTK stock words & tokenizers from script

python NLTKscript.py

May need to install lxml html clean

pip install lxml[html_clean]

or explicitly

pip install lxml_html_clean

after installing run streamlit app

streamlit run app.py

Fake news articles can be found here: https://www.bbc.com/news/topics/cjxv13v27dyt

Example 1: https://www.bbc.com/news/articles/cy890gpqw1po

Image

Example 2 real news: https://www.cnn.com/2025/01/26/politics/colombia-tariffs-trump-deportation-flights/index.html

Image

FakeNewsDetector/

├── app.py # Streamlit app (main interface)
├── train.py # Script to train the model
├── evaluate.py # Evaluate the trained model
├── model.py # Model architecture or pipeline definition
├── utils.py # Helper functions (e.g., preprocessing, loading data)
├── requirements.txt # Dependencies (streamlit, pandas, transformers, etc.)
├── data/ # Data directory
│ ├── Fake.csv
│ └── True.csv
└── models/ # Directory to save trained models
└── fake_news_model.pkl

dataset
https://www.kaggle.com/datasets/emineyetm/fake-news-detection-datasets

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages