- Introduction
- Dataset
- Features
- Technologies Used
- Installation
- Usage
- Example Output
- Contributing
- License
- Author
Fake news detection has become a crucial task in the era of digital information. Identifying and mitigating the spread of misinformation is essential for maintaining the integrity of information ecosystems. This project focuses on enhancing the explainability of fake news detection models using SHAP (SHapley Additive exPlanations) to interpret Bidirectional LSTM (BiLSTM) models.
The goal is to provide a transparent and interpretable model that can help in understanding the underlying factors contributing to the classification of news articles as real or fake. By leveraging SHAP values, we aim to highlight the most influential features in the decision-making process, thus aiding in the explainability of the model.
The dataset used in this project includes labeled news articles, containing both fake and real news. Each sample is preprocessed to extract relevant features for model training and evaluation.
- Data preprocessing and feature extraction
- Implementation of Bidirectional LSTM model
- Model interpretability using SHAP
- Visualization of SHAP values for feature importance
- Python 3.x
- Jupyter Notebook
- TensorFlow/Keras
- Scikit-learn
- Pandas
- Numpy
- SHAP
- Matplotlib
- Seaborn
-
Clone the repository:
git clone https://github.com/your-username/Fake-News-Detection-SHAP-BiLSTM.git cd Fake-News-Detection-SHAP-BiLSTM
-
Create a virtual environment:
python -m venv venv
-
Activate the virtual environment:
- On Windows:
venv\Scripts\activate
- On macOS/Linux:
source venv/bin/activate
- On Windows:
-
Install the required packages:
pip install -r requirements.txt
-
Open the Jupyter Notebook:
jupyter notebook SHAP_BiLSTM_Model.ipynb
-
Run the cells in the notebook to preprocess the data, train the BiLSTM model, and evaluate the results.
Here are some example outputs from the project:
- Model Accuracy: 94.5%
- SHAP Summary Plot
Contributions are welcome! Please open an issue or submit a pull request for any improvements or bug fixes.
This project is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
See the LICENSE file for details.
For any questions or suggestions, please contact:
- Harsh Singh: harshjuly12@gmail.com
- GitHub: harshjuly12