Lune

AAAI2022Top-tier venue

Block-Skim: Efficient Question Answering for Transformer

Yue Guan, Zhengyi Li, Zhouhan Lin, Yuhao Zhu, Jingwen Leng, Minyi Guo

Abstract

Transformer models have achieved promising results on natural language processing (NLP) tasks including extractive question answering (QA). Common Transformer encoders used in NLP tasks process the hidden states of all input tokens in the context paragraph throughout all layers. However, different from other tasks such as sequence classification, answering the raised question does not necessarily need all the tokens in the context paragraph. Following this motivation, we propose Block-skim, which learns to skim unnecessary context in higher hidden layers to improve and accelerate the Transformer performance. The key idea of Block-Skim is to identify the context that must be further processed and those that could be safely discarded early on during inference. Critically, we find that such information could be sufficiently derived from the self-attention weights inside the Transformer model. We further prune the hidden states corresponding to the unnecessary positions early in lower layers, achieving significant inference-time speedup. To our surprise, we observe that models pruned in this way outperform their full-size counterparts. Block-Skim improves QA models' accuracy on different datasets and achieves 3 times speedup on BERT-base model.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

9 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • SQuant: On-the-Fly Data-Free Quantization via Diagonal Hessian Approximation cites Accelerating sparse DNN models without hardware-support via tile-wise sparsity
  • A Survey for Efficient Open Domain Question Answering cites ALBERT: A Lite BERT for Self-supervised Learning of Language Representations
  • ANT: Exploiting Adaptive Numerical Data Type for Low-bit Deep Neural Network Quantization cites SQuant: On-the-Fly Data-Free Quantization via Diagonal Hessian Approximation
  • ANT: Exploiting Adaptive Numerical Data Type for Low-bit Deep Neural Network Quantization cites Accelerating sparse DNN models without hardware-support via tile-wise sparsity
  • Nimbus: Secure and Efficient Two-Party Inference for Transformers cites ANT: Exploiting Adaptive Numerical Data Type for Low-bit Deep Neural Network Quantization
  • OliVe: Accelerating Large Language Models via Hardware-friendly Outlier-Victim Pair Quantization cites SQuant: On-the-Fly Data-Free Quantization via Diagonal Hessian Approximation
  • OliVe: Accelerating Large Language Models via Hardware-friendly Outlier-Victim Pair Quantization cites ANT: Exploiting Adaptive Numerical Data Type for Low-bit Deep Neural Network Quantization
  • OliVe: Accelerating Large Language Models via Hardware-friendly Outlier-Victim Pair Quantization cites Accelerating sparse DNN models without hardware-support via tile-wise sparsity
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers9

  1. OliVe: Accelerating Large Language Models via Hardware-friendly Outlier-Victim Pair QuantizationCong Guo, Jiaming Tang, Weiming Hu, Jingwen Leng et al.ISCA 2023 · 151 citations
  2. ANT: Exploiting Adaptive Numerical Data Type for Low-bit Deep Neural Network QuantizationCong Guo, Chen Zhang, Jingwen Leng, Zihan Liu et al.MICRO 2022 · 109 citations
  3. SQuant: On-the-Fly Data-Free Quantization via Diagonal Hessian ApproximationCong Guo, Yuxian Qiu, Jingwen Leng, Xiaotian Gao et al.ICLR 2022 · 92 citations
  4. Nimbus: Secure and Efficient Two-Party Inference for TransformersZhengyi Li, Kang Yang, Jin Tan, Wen-jie Lu et al.NeurIPS 2024 · 34 citations
  5. A Survey for Efficient Open Domain Question AnsweringQin Zhang, Shangsi Chen, Dongkuan Xu, Qingqing Cao et al.ACL 2023 · 28 citations

Builds on8

  1. ALBERT: A Lite BERT for Self-supervised Learning of Language RepresentationsZhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel et al.ICLR 2020 · 7,418 citations
  2. Reformer: The Efficient TransformerNikita Kitaev, Lukasz Kaiser, Anselm LevskayaICLR 2020 · 2,878 citations
  3. Lite Transformer with Long-Short Range AttentionZhanghao Wu, Zhijian Liu, Ji Lin, Yujun Lin et al.ICLR 2020 · 379 citations
  4. SQuant: On-the-Fly Data-Free Quantization via Diagonal Hessian ApproximationCong Guo, Yuxian Qiu, Jingwen Leng, Xiaotian Gao et al.ICLR 2022 · 92 citations
  5. Accelerating sparse DNN models without hardware-support via tile-wise sparsityCong Guo, Bo Yang Hsueh, Jingwen Leng, Yuxian Qiu et al.SC 2020 · 65 citations

Related papers

  1. Transkimmer: Transformer Learns to Layer-wise SkimYue Guan, Zhengyi Li, Jingwen Leng, Zhouhan Lin et al.ACL 2022
  2. DeFormer: Decomposing Pre-trained Transformers for Faster Question AnsweringQingqing Cao, Harsh Trivedi, Aruna Balasubramanian, Niranjan BalasubramanianACL 2020 · 61 citations
  3. SkipBERT: Efficient Inference with Shallow Layer SkippingJue Wang, Ke Chen, Gang Chen, Lidan Shou et al.ACL 2022
  4. Dynamic Context Pruning for Efficient and Interpretable Autoregressive TransformersSotiris Anagnostidis, Dario Pavllo, Luca Biggio, Lorenzo Noci et al.NeurIPS 2023 · 95 citations
  5. Blockwise Self-Attention for Long Document UnderstandingJiezhong Qiu, Hao Ma, Omer Levy, Wen-tau Yih et al.EMNLP Findings 2020 · 165 citations
Dusk over the sea between two cliffs drawn in fine vertical lines