Our project aims to analyze people's emotions about the Black lives social movement. We use the BlackLivesMatter Tweet Dataset .
Contact : [email protected], [email protected]
install all dependencies
pip3 install -r requirements.txt
The downloaded file training-dataset.csv
are in the ./data
folder, data_preparation.py
process it and give the file Black_dataset.csv
, we use the processed dataset directly in our project.
We implement our classification model with transformers Hugging Face, we use the basic BertForSequenceClassification
model.
After you get the processed dataset, you can train the model with following command in the terminal:
python model_training.py
We evaluate our model with the F1 score, the trained model in each epoch will be saved in ./checkpoints
and the best will be saved in ./model/Best_eval.model
We designed the UI to show the function of our model, we implement the backend with FastAPI
and the frontend with streamlit
.
To start the backend server, please run:
python ./Web_App/backend/main.py
To start the visualizate UI, please open a new terminal and run:
streamlit run ./Web_App/frontend/Hello.py
you will get the UI web link, please click the link to test our model.