Elamur Research
☰
home / papers / 2021 / Factual Probing Is [MASK]: Learning vs. Learning to Recall

Factual Probing Is [MASK]: Learning vs. Learning to Recall

Written for the Research library (claude-opus-5-5) from the paper text. Original — aclanthology.org/2021.naacl-main.398.pdf

Summary

Factual probing tries to measure how much world knowledge a pre-trained language model like BERT stores, usually by having it fill cloze-style templates from the LAMA benchmark. Earlier studies read the resulting accuracy as a lower bound and tried to raise it by tuning prompts on additional Wikidata triples. Zhong, Friedman and Chen make two contributions.

First, they introduce OptiPrompt. Rather than searching over discrete vocabulary tokens, it learns real-valued input vectors for each relation and can start from the embeddings of a hand-written template. The method is cheap to train and beats AutoPrompt and LPAQA on the T-REx part of LAMA.

Second, they challenge the lower-bound reading. Wikidata training facts do not overlap with the test set, but they still contain distributional regularities such as dominant object classes and lexical cues. Prompt-search methods can exploit these, and optimized prompts even recover "facts" from a BERT with random weights. Using such controls, the authors split test items into easy and hard subsets. OptiPrompt leads on both.

The work shows that probing scores mix knowledge stored in the model with patterns learned from the probe's training data.

Key points

  • With BERT-base-cased, OptiPrompt initialized from manual prompts reaches 48.6% top-1 accuracy on LAMA, compared with 42.2% for AutoPrompt (+6.4 points), 34.1% for LPAQA and 31.1% for the original manual LAMA prompts. On LAMA-UHN it rises from 31.3% to 38.4%.
  • The evaluation uses the T-REx split: 41 Wikidata relation types with up to 1000 triples each, grouped into 1-1, N-1 and N-M relations. Objects are restricted to single tokens.
  • Always predicting the majority class already gives 22.0% overall accuracy (23.8% on UHN), which shows how skewed the fact distribution is.
  • The control experiments include a randomly initialized model. All data-driven prompt methods, OptiPrompt among them, learn from training-set regularities.
  • OptiPrompt needs white-box gradient access to the model. The authors frame it as a tool for diagnosis rather than as a means of turning BERT into a knowledge base. Code is available at github.com/princeton-nlp/OptiPrompt.

Our summary of the paper, in our own words — not its text. The work belongs to its authors; read it at the links above.

Fields: Natural language processing

Cited by

151 papers of our library cite it (of the 140673 whose bibliographies we read); 12 of them have a page here, 139 not yet.

Cite

The paper itself, not this page. BibTeX from the library's record of the work. DOI 10.18653/v1/2021.naacl-main.398

@inproceedings{zhong2021factual,
  title = {{Factual Probing Is [MASK]: Learning vs. Learning to Recall}},
  author = {Zhong, Zexuan and Friedman, Dan and Chen, Danqi},
  booktitle = {Proceedings of the 2021 Conference of the North American Chapter of the Association for Computational Linguistics: Human Language Technologies},
  year = {2021},
  doi = {10.18653/v1/2021.naacl-main.398},
  url = {https://doi.org/10.18653/v1/2021.naacl-main.398}
}

References

31 references, 16 of them with a card of ours. ↗ leads to the work, «find» searches for one we have no id for yet.

  1. Yonatan Belinkov, Nadir Durrani, Fahim Dalvi, Hassan Sajjad, and James Glass. 2017. What do neural machine translation models learn about morphology? In Association for Computational Linguistics (ACL), pages 861–872. find our card
  2. Tom B Brown, Benjamin Mann, Nick Ryder, Melanie Subbiah, Jared Kaplan, Prafulla Dhariwal, Arvind Neelakantan, Pranav Shyam, Girish Sastry, Amanda Askell, et al. 2020. Language models are few-shot learners. arXiv preprint arXiv:2005.14165. find
  3. Jacob Devlin, Ming-Wei Chang, Kenton Lee, and Kristina Toutanova. 2019. BERT: Pre-training of deep bidirectional transformers for language understanding. In North American Chapter of the Association for Computational Linguistics (NAACL), pages 4171–4186. find
  4. Hady Elsahar, Pavlos Vougiouklis, Arslen Remaci, Christophe Gravier, Jonathon Hare, Frederique Laforest, and Elena Simperl. 2018. T-REx: A large scale alignment of natural language with knowledge base triples. In Eleventh International Conference on Language Resources and Evaluation (LREC). find
  5. Tianyu Gao, Adam Fisch, and Danqi Chen. 2020. Making pre-trained language models better few-shot learners. arXiv preprint arXiv:2012.15723. find our card
  6. Samuel Gehman, Suchin Gururangan, Maarten Sap, Yejin Choi, and Noah A Smith. 2020. Realtoxicityprompts: Evaluating neural toxic degeneration in language models. In Proceedings of the 2020 Conference on Empirical Methods in Natural Language Processing: Findings, pages 3356–3369. find our card
  7. Robert Geirhos, Jörn-Henrik Jacobsen, Claudio Michaelis, Richard Zemel, Wieland Brendel, Matthias Bethge, and Felix A Wichmann. 2020. Shortcut learning in deep neural networks. arXiv preprint arXiv:2004.07780. find
  8. Adi Haviv, Jonathan Berant, and Amir Globerson. 2021. BERTese: Learning to speak to BERT. In European Chapter of the Association for Computational Linguistics (EACL). find
  9. John Hewitt and Percy Liang. 2019. Designing and interpreting probes with control tasks. In Empirical Methods in Natural Language Processing (EMNLP), pages 2733–2743. find
  10. Zhengbao Jiang, Frank F Xu, Jun Araki, and Graham Neubig. 2020. How can we know what language models know? Transactions of the Association of Computational Linguistics (TACL). find our card
  11. Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma, and Radu Soricut. 2019. ALBERT: A lite BERT for self-supervised learning of language representations. In International Conference on Learning Representations (ICLR). find
  12. Xiang Lisa Li and Percy Liang. 2021. Prefix-tuning: Optimizing continuous prompts for generation. arXiv preprint arXiv:2101.00190. find
  13. Yongjie Lin, Yi Chern Tan, and Robert Frank. 2019. Open sesame: Getting inside bert’s linguistic knowledge. In Proceedings of the 2019 ACL Workshop BlackboxNLP: Analyzing and Interpreting Neural Networks for NLP, pages 241–253. find our card
  14. Xiao Liu, Yanan Zheng, Zhengxiao Du, Ming Ding, Yujie Qian, Zhilin Yang, and Jie Tang. 2021. GPT understands, too. arXiv preprint arXiv:2103.10385. find our card
  15. Yinhan Liu, Myle Ott, Naman Goyal, Jingfei Du, Mandar Joshi, Danqi Chen, Omer Levy, Mike Lewis, Luke Zettlemoyer, and Veselin Stoyanov. 2019. RoBERTa: A robustly optimized BERT pretraining approach. arXiv preprint arXiv:1907.11692. find
  16. Tom McCoy, Ellie Pavlick, and Tal Linzen. 2019. Right for the wrong reasons: Diagnosing syntactic heuristics in natural language inference. In Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics, pages 3428–3448. find our card
  17. Moin Nadeem, Anna Bethke, and Siva Reddy. 2020. StereoSet: Measuring stereotypical bias in pre-trained language models. ArXiv, abs/2004.09456. find our card
  18. Fabio Petroni, Tim Rocktäschel, Sebastian Riedel, Patrick Lewis, Anton Bakhtin, Yuxiang Wu, and Alexander Miller. 2019. Language models as knowledge bases? In Empirical Methods in Natural Language Processing (EMNLP), pages 2463–2473. find our card
  19. Eric Wallace, Shi Feng, Nikhil Kandpal, Matt Gardner, and Sameer Singh. 2019. Universal adversarial triggers for attacking and analyzing NLP. In Empirical Methods in Natural Language Processing and International Joint Conference on Natural Language Processing (EMNLP-IJCNLP), page 2153–2162. find
  20. Tiago Pimentel, Josef Valvoda, Rowan Hall Maudslay, Ran Zmigrod, Adina Williams, and Ryan Cotterell. 2020. Information-theoretic probing for linguistic structure. In Association for Computational Linguistics (ACL), pages 4609–4622. find our card
  21. Thomas Wolf, Julien Chaumond, Lysandre Debut, Victor Sanh, Clement Delangue, Anthony Moi, Pier-ric Cistac, Morgan Funtowicz, Joe Davison, Sam Shleifer, et al. 2020. Transformers: State-of-the-art natural language processing. In Proceedings of the 2020 Conference on Empirical Methods in Natural Langu… find our card
  22. Nina Poerner, Ulli Waltinger, and Hinrich Schütze. 2019. BERT is not a knowledge base (yet): Factual knowledge vs. name-based reasoning in unsupervised qa. arXiv preprint arXiv:1911.03681. find
  23. Zining Zhu and Frank Rudzicz. 2020. An information theoretic view on selecting linguistic probes. In Empirical Methods in Natural Language Processing (EMNLP), pages 9251–9262. find
  24. Pranav Rajpurkar, Jian Zhang, Konstantin Lopyrev, and Percy Liang. 2016. Squad: 100,000+ questions for machine comprehension of text. In Empirical Methods in Natural Language Processing (EMNLP), pages 2383–2392. find our card
  25. Anna Rogers, Olga Kovaleva, and Anna Rumshisky. 2020. A primer in bertology: What we know about how bert works. Transactions of the Association of Computational Linguistics (TACL), 8:842–866. find our card
  26. Timo Schick and Hinrich Schütze. 2020. It’s not just size that matters: Small language models are also few-shot learners. arXiv preprint arXiv:2009.07118. find our card
  27. Taylor Shin, Yasaman Razeghi, Robert L. Logan IV, Eric Wallace, and Sameer Singh. 2020. AutoPrompt: Automatic prompt construction for masked language models. In Empirical Methods in Natural Language Processing (EMNLP), pages 4222–4235. find
  28. Robyn Speer and Catherine Havasi. 2012. Representing general relational knowledge in conceptnet 5. In LREC, pages 3679–3686. find
  29. Saku Sugawara, Kentaro Inui, Satoshi Sekine, and Akiko Aizawa. 2018. What makes reading comprehension questions easier? In Empirical Methods in Natural Language Processing (EMNLP), pages 4208–4219. find
  30. Ian Tenney, Patrick Xia, Berlin Chen, Alex Wang, Adam Poliak, R Thomas McCoy, Najoung Kim, Benjamin Van Durme, Samuel Bowman, Dipanjan Das, et al. 2019. What do you learn from context? probing for sentence structure in contextualized word representations. In International Conference on Learning Repr… find our card
  31. Elena Voita and Ivan Titov. 2020. Information-theoretic probing with minimum description length. In Empirical Methods in Natural Language Processing (EMNLP), pages 183–196. find our card