Its input are stem and answer, and output is candidate set of distractors. It is fine-tuned by
DGen dataset based on
facebook/bart-base model.
For more details, you can see our
paper or
GitHub.
1from transformers import BartTokenizer, BartForConditionalGeneration, pipeline
2
3tokenizer = BartTokenizer.from_pretrained("AndyChiang/cdgp-csg-bart-dgen")
4csg_model = BartForConditionalGeneration.from_pretrained("AndyChiang/cdgp-csg-bart-dgen")
1sent = "The only known planet with large amounts of water is <mask>. </s> earth"
2cs = unmasker(sent)
3print(cs)
This model is fine-tuned by
DGen dataset, which covers multiple domains including science, vocabulary, common sense and trivia. It is compiled from a wide variety of datasets including SciQ, MCQL, AI2 Science Questions, etc. The detail of DGen dataset is shown below.
The evaluations of this model as a Candidate Set Generator in CDGP is as follows: