Awesome Open Source
Awesome Open Source


knowQA Source Code by RUCIR

Baseline, BERTfine-tuning, F10.35


Before launch the script install these packages in your Python3 environment:

  • pytorch >= 1.4
  • transformers 4.2.0

Conda :)

 conda create -n knowqa -c pytorch python=3.6 pytorch
 conda activate knowqa
 pip install transformers==4.2.0 tqdm -i

Huggingface BERT-base-uncasedpytorch_model.bin, ./models/bert/

git clone knowqa
cd knowqa
wget -O ./models/bert/pytorch_model.bin

Launch the script

. ./output/score.txt,


: ./data/:(

Experimental Results


mode=1: top5termmask

mode=2(): term mask, term1, term

Models F1 on testset
Official baseline 0.172
Ours (mode=1) 0.2574
Ours (mode=2) 0.3536


Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
Python (1,141,333
Machine Learning (31,692
Deep Learning (23,680
Pytorch (11,591
Artificial Intelligence (5,558
Natural Language Processing (4,742
Transformer (1,679
Bert (1,164
Question Answering (587
Knowledge (437
Pretrained Models (324
Huggingface (185
Fine Tuning (137
Pre Training (76
Related Projects