In this job, I collaborated with Ihebeddine RYAHI
In this project, we built an end to end fake news classifier. This starts from training a machine learning classifier to deploying a web app.š
How to do š¤?
First of all, let's have a look how the app looks like š¤:
As you see, this web app allows a user to detect either an article is fake or real news. To do, the user just pastes the article in the text area and clicks on Predict
.
NB : You can add some articles in the test dataset file : server/data/fake_or_real_news_testset.csv
To build this app, we followed this main steps:
ā¢ Training a machine learning classifier (Logistic Regression)
ā¢ Building an interactive web app using React.js
ā¢ Setting a REST API
using Flask
ā¢ Node.js (version 12.13.0)
ā¢ Python (version 3.7.4)
ā¢ Flask : pip install flask
ā¢ Go to server\
directory and run app.py
script in order to start the API
ā¢ You can get the pickle of our trained model from Dropbox: https://www.dropbox.com/s/r2bhfdvzb7rb99k/model.pkl?dl=0
and store it in server\model
directory
NB : Keep in mind that when you first run the app.py
script, the machine learning model (~350MB) will be loaded into your machine RAM
ā¢ Go to client\
directory and run npm install && npm start to start the App