Sentiment word masking bert for valence and arousal
This repository contains the code for replicating results from
- Sentiment-based masked language modeling for improving sentence-level valence–arousal prediction
- Jheng-Long Wu; Wei-Yi Chung
- Applied Intelligence, 2022
- Build a new virtual environment
- Install python3 requirements:
pip install -r requirements.txt
- Run
cd ./Models
to the model folder - Choose the parameter you want to run in the sh files to train different models
- Train your own models
- Experiment configurations are found in
./Models/*.sh
- Results model and logs are stored in the corresponding
output
directory underVA_BERT_mask_sentiment*
.
- Under the
sense_data
folder, that is negative sentiment word and positive sentiment word, you can add the sentiment word to mask it
result_statistic
can grep all the prediction result and indicator to the csv fileGraph
stores the visul of experimental result from the paperdata
contains the experimental data which already split to five fold, the split code and the statistic of masking coverage code is here toonotebooks
stores the multilabel regression model and the visulization code