Skip to content

this is a QASystem implemented with BERT

Notifications You must be signed in to change notification settings

alchemy-studio/QASystem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

1feb8d4 · Aug 11, 2019

History

51 Commits
Aug 4, 2019
Aug 4, 2019
Jul 27, 2019
Aug 11, 2019
Aug 11, 2019
Aug 11, 2019
Aug 11, 2019
Aug 11, 2019
Aug 11, 2019
Aug 4, 2019
Jul 22, 2019
Aug 3, 2019
Aug 11, 2019
Aug 11, 2019

Repository files navigation

QASystem

this is a QASystem implemented with BERT

install prerequisite packages

install with command

pip3 install -U tf-nightly-2.0-preview bert-for-tf2 flask
sudo apt install libboost-all-dev

download pretrained bert model for Chinese language

download with the following command.

bash downloads.sh

collect question and answer pairs

put the questions and answers in format as question_answer.txt's. and execute following command to convert the collected samples into dataset format.

make && make install
./create_dataset -i question_answer.txt -o dataset

finetune bert classifer to predict relavance between question and answer correctly

with directory dataset generated by the above command presented, finetune with the following to start finetune.

python3 Predictor.py

run the QASystem server

run the QA system server by

FLASK_APP=server.py flask run

stop the server by Ctrl+C

test the server

python3 test.py

capture

About

this is a QASystem implemented with BERT

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published