Welcome to FewRel


a Few-shot Relation classification dataset


Paper GitHub

FewRel is a Few-shot Relation classification dataset, which features 70, 000 natural language sentences expressing 100 relations annotated by crowdworkers.

Please refer to our EMNLP 2018 paper to learn more about FewRel.
We add two more challenging settings: few-shot domain adaptation (DA) and few-shot none-of-the-above detection (NOTA) in FewRel 2.0 dataset. Please refer to our EMNLP 2019 paper for more details.
Baseline models and a series of toolkits are released in this repo:


It is fairly easy for you to get started with FewRel. First, you can download a copy of the dataset by the following links. The dataset is distributed under the CC BY-SA 4.0 license:

To evaluate your model, please sample a pair of input and standard output file from the validation set, and compare your output with the standard one. The sampling scripts and evaluations scripts used in official evaluation are also accessible through the following work sheet.


Once you have built a model that works to your expectations on the validation set, you can submit it to get official scores on the hidden test set. To preserve the integrity of test results, we do not release the test set to the public. Instead, we require you to submit your model so that we can run it on the test set for you. Instructions to submit your model is here!


@inproceedings{han-etal-2018-fewrel,
    title = "{F}ew{R}el: A Large-Scale Supervised Few-Shot Relation Classification Dataset with State-of-the-Art Evaluation",
    author = "Han, Xu and Zhu, Hao and Yu, Pengfei and Wang, Ziyun and Yao, Yuan and Liu, Zhiyuan and Sun, Maosong",
    booktitle = "Proceedings of the 2018 Conference on Empirical Methods in Natural Language Processing",
    month = oct # "-" # nov,
    year = "2018",
    address = "Brussels, Belgium",
    publisher = "Association for Computational Linguistics",
    url = "https://www.aclweb.org/anthology/D18-1514",
    doi = "10.18653/v1/D18-1514",
    pages = "4803--4809"
}

@inproceedings{gao-etal-2019-fewrel,
    title = "{F}ew{R}el 2.0: Towards More Challenging Few-Shot Relation Classification",
    author = "Gao, Tianyu and Han, Xu and Zhu, Hao and Liu, Zhiyuan and Li, Peng and Sun, Maosong and Zhou, Jie",
    booktitle = "Proceedings of the 2019 Conference on Empirical Methods in Natural Language Processing and the 9th International Joint Conference on Natural Language Processing (EMNLP-IJCNLP)",
    month = nov,
    year = "2019",
    address = "Hong Kong, China",
    publisher = "Association for Computational Linguistics",
    url = "https://www.aclweb.org/anthology/D19-1649",
    doi = "10.18653/v1/D19-1649",
    pages = "6251--6256"
}
								


# Model NOTA 15%
5-way-1-shot
NOTA 15%
5-way-5-shot
NOTA 50%
5-way-1-shot
NOTA 50%
5-way-5-shot

1

Anonymous Cat

(Aug 7, 2020)
79.0685.5281.6987.74

2

BERT-PAIR[paper][code]
THUNLP, Tsinghua University
(Nov 3, 2019)
77.6784.1980.3186.06

3

Proto (BERT)

(Nov 3, 2019)
70.0283.7945.9475.21

4

Proto (CNN)

(Nov 3, 2019)
60.5977.7940.0061.66