Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use Context

By Urvashi Khandelwal, He He, Peng Qi, Dan Jurafsky. 2018

323 citations recorded by the source corpus.

We know very little about how neural language models (LM) use prior linguistic context. In this paper, we investigate the role of context in an LSTM LM, through ablation studies. Specifically, we analyze the increase in perplexity when prior context words are shuffled, replaced, or dropped. On two standard datasets, Penn Treebank and WikiText-2, we find that the model is capable of using about 200 tokens of context on average, but sharply distinguishes nearby context (recent 50 tokens) from the distant history. The model is highly sensitive to the order of words within the most recent sentence, but ignores word order in the long-range context (beyond 50 tokens), suggesting the distant past is modeled only as a rough semantic field or topic. We further find that the neural caching model (Grave et al., 2017b) especially helps the LSTM to copy words from within this distant context. Overall, our analysis not only provides a better understanding of how neural LMs use their context, but also sheds light on recent success from cache-based models.

Subfields: Artificial Intelligence, Computer Vision and Pattern Recognition, Large Language Models, Natural Language Processing

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. Mohit Bansal
  2. Percy Liang
  3. Luke S. Zettlemoyer
  4. Yonatan Belinkov
  5. Noah A. Smith
  6. Yejin Choi
  7. Jianfeng Gao
  8. Hannaneh Hajishirzi

In Computer Vision and Pattern Recognition

  1. Luc Van Gool
  2. Mohit Bansal
  3. Dacheng Tao
  4. Trevor Darrell
  5. Xiaogang Wang
  6. Jitendra Malik
  7. Ming-Hsuan Yang
  8. Quoc V. Le

In Large Language Models

  1. Luke S. Zettlemoyer
  2. Noah A. Smith
  3. Jonathan Berant
  4. Hinrich Schütze
  5. Yejin Choi
  6. Mohit Bansal
  7. Michael Lewis
  8. Yonatan Belinkov

In Natural Language Processing

  1. Yonatan Belinkov
  2. Mohit Bansal
  3. Percy Liang
  4. Luke S. Zettlemoyer
  5. Yoav Goldberg
  6. Jonathan Berant
  7. Christopher D. Manning
  8. Graham Neubig

Citations in the corpus