Skip to content

Latest commit

 

History

History
33 lines (23 loc) · 1.43 KB

README.md

File metadata and controls

33 lines (23 loc) · 1.43 KB

SAIS

Code for SAIS: Supervising and Augmenting Intermediate Steps for Document-Level Relation Extraction (NAACL 2022).

Requirements

PyTorch = 1.9.0
HuggingFace Transformers = 4.8.1

Run

Given an input dataset (e.g., DocRED):

  1. The Data/{dataset}/Original folder contains the original files provided by the corresponding dataset that are necessary for our experiments.
  2. The command bash Code/prepare.sh transforms the original data structure into the structure acceptable to our model and stores the output files in the Data/{dataset}/Processed folder.
  3. The command bash Code/main.sh trains the model, writes the standard output in the Data/{dataset}/Stdout folder, and delivers the set of predicted relations and corresponding evidence for the develop and test sets in the Data/{dataset}/Processed folder.

The set of hyperparameters for Step 2 and 3 are specified in prepare.sh and main.sh, respectively.

Our model trained on DocRED can be downloaded here.

Citation

@inproceedings{xiao2022sais,
  title={SAIS: Supervising and Augmenting Intermediate Steps for Document-Level Relation Extraction},
  author={Xiao, Yuxin and Zhang, Zecheng and Mao, Yuning and Yang, Carl and Han, Jiawei},
  booktitle={NAACL},
  year={2022}
}