Skip to content

Latest commit

 

History

History

MTL-SLI

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

Task 3:Symptom Label Inference (SLI)

This dir contains the code of BERT-MTL model for SLI task.

The model utilizes the BIO labels and contains three training objectives:

  • BIO tag prediction
  • Symptom name classification
  • Symptom label classification

The model is only valid for SLI-IMP task since it requires the annotated BIO tags. DialoAMC do not provide BIO tags for self-reports.

Requirements

  • python>=3.5
  • torch>=1.4.0
  • transformers==2.7.0
  • seqeval==1.2.2
  • pytorch-crf==0.7.2
  • tqdm==4.42.1
  • pandas>=1.0.3
pip install -r requirements.txt

Preprocess

python preprocess.py

Training

python train.py --cuda_num 0

Inference

python inference.py --dataset test --cuda_num 0 

Evaluation

cd .. || exit
python eval_sli.py --target imp --gold ../../dataset/test.json --pred MTL-SLI/test_imp_pred.json