SQuAD Model Comparison Jiehan Zhu [email protected] Video: https://www.youtube.com/watch?v=l0rOxMMHOX0 Background Implementation Comparison of Results Recent development in Deep Learning in NLP has reach better than human Largest pretrained contextual embedding model, a BERT based model with performance on multiple NLP tasks. The sequence nature of RNN and LSTM limited Baseline Model: BiDAF without Char Embed additional layers for SQuAD, provides best performance among the models that the neural network model to parallel calculation, and requires long training time for large have been tested., F1 score of 73.77 and 72.95 on development and test sets. The baseline model has five block, Embedding Layer, Encoder Layer, Attention Layer, Model dataset. This leads to application of CNN and Attention layer that enable faster training Median size model QANet provides second best and BiDAF based have lowest Layer and Output Layer. and smaller model with similar or higher preference. The application of BERT has performances. But BERT take very long time to train for each epoch, and reach ● Embedding Layer: The Embedding Layer project the word embedding from GloVe reached new state of art in various tasks, including reading comprehension, and performance cap within 3 epoch. On the other hand, Non-PCE models have lower embedding with a FC layer, and two Highway layers. encourage a multitask model structure. initial performance, but can improve with more train epochs. ● Encoder Layer: The encoder layer uses a bidirectional LSTM without sharing parameters between left-to-right and right-to-left LSTM. Using pretrained character level embedding, regularization improves model ● Attention Layer: The two Attention layer allow in this part allow the attentions flow both way, Problem Statement performance slightly, but not a significant amount. Model size and the depth are Context-to-Question (C2Q) Attention and Question-to-Context(Q2C) Attention. Recent development in Deep Learning in NLP has reach better than human the determination factors of model performance. ● Model Layer: The model layer have same structure as encoder layer, a bidirectional LSTM performance on multiple NLP tasks. The sequence nature of RNN and LSTM limited without sharing weights. the neural network model to parallel calculation, and requires long training time for ● Output Layer: The output layer applies a bidirectional LSTM to the modeling layer outputs, large dataset. This leads to application of CNN and Attention layer that enable faster and Fully Connected layers with softmax to product distribution probability of answer start training and smaller model with similar or higher preference. The application of BERT and end positions. has reached new state of art in various tasks, including reading comprehension, and encourage a multitask model structure. Model 1: BiDAF with Character Level Embedding The best BiDAF based model is using 2nd Data Preprocess & Visualization character level embedding structure. It This paper uses Stanford Question Answering Dataset (SQuAD), which consists reaches F1 score of 62.26 on questions posed by crowd-workers on a set of Wikipedia articles. About half of development dataset with 20 epochs questions are answerable, and the answer to answerable every question is a segment training. of text, or span, from the corresponding reading context. Comparing with the 1st BiDAF with Context: Following the disbandment of Destiny's Child in June 2005, she released her character level embedding models, the second solo album, B'Day (2006), which contained hits "Déjà Vu", "Irreplaceable", and 2nd model has additional CNN layer on "Beautiful Liar". Beyoncé also ventured into acting, with a Golden Globe-nominated character level embedding. performance in Dreamgirls (2006), and starring roles in The Pink Panther (2006) and Obsessed (2009). Comparing with 3rd model, the 2ndmodel Question: After her second solo album, what other entertainment venture did Beyoncé uses Fully Connected layer instead of explore? CNN layer on merged embedding output Answer: acting of word and character level embedding, which have more parameters. Model Epochs Train Time Dev EM Dev F1 The length of context various in the data set, most of the context have 50 to 250 words, while some of the context have more than 600 words. Due to the memory restriction, Model 2: QANet with Pre-trained Char Embed Baseline 30 9 58.58 61.88 the maximum number of word loaded for each context is limited at 400, and this only impact less then one percent of data. And the maximum number of word loaded for Built on Transformer, QANet used only CNN and self-attention layer in order to train parallel on GPU and Baseline with L2 30 7.5 57.47 60.78 each question is limited at 50, which should not impact the model at all. obtain much faster training process. BiDAF with 1st char embed 20 4.5 57.64 60.63 The QANet based model used in this project are slightly different from the implementation in original paper. The original QANet used random initialization 200 dimension character level embedding, while BiDAF with 2nd char embed 20 6 59.23 62.26 this model uses pretrained 300 dimension GloVe character level embedding. Model 3: Bert BiDAF with 3rd char embe 20 5 57.03 60.27 BERT base model is a fine tuning implementation. QANet with GloVe char embed 30 31 64.24 67.84 In addition, BERT with additional layer model, a model with additional layers specific for SQuAD has been Bert Base 3 17 69.84 73.09 trained and compares. A Fully Connected layer, ReLU activation, and dropout layers have been added before question answering output linear layer that calculating start and end position probability Bert with add. layers 3 11 70.32 73.77 distribution. .
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages1 Page
-
File Size-