Pruning a BERT-based Question Answering Model

By J. Scott McCarley. 2019

54 citations recorded by the source corpus.

We investigate compressing a BERT-based question answering system by pruning parameters from the underlying BERT model. We start from models trained for SQuAD 2.0 and introduce gates that allow selected parts of transformers to be individually eliminated. Specifically, we investigate (1) reducing the number of attention heads in each transformer, (2) reducing the intermediate width of the feed-forward sublayer of each transformer, and (3) reducing the embedding dimension. We compare several approaches for determining the values of these gates. We find that a combination of pruning attention heads and the feed-forward layer almost doubles the decoding speed, with only a 1.5 f-point loss in accuracy.

Subfields: Artificial Intelligence

How researchers see this paper

The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.

In Artificial Intelligence

  1. Yonatan Belinkov
  2. Zhiyuan Liu
  3. Maosong Sun
  4. Hassan Sajjad
  5. Fahim Dalvi
  6. Nadir Durrani
  7. Qun Liu
  8. Xin Jiang

Citations in the corpus