Does Pre-training Induce Systematic Inference? How Masked Language Models Acquire Commonsense Knowledge

Ian Porada, Alessandro Sordoni, Jackie Chi Kit Cheung

Abstract

Masked Language Models (MLMs) like BERT demonstrate significant commonsense knowledge, but the mechanism of this acquisition—whether through systematic logical inference or surface-level statistical patterns—is debated. We investigate BERT's pre-training trajectory using a novel intervention strategy to test for the induction of general reasoning rules, specifically downward monotonicity. Our results show that while BERT's prior knowledge of facts increases, its ability to perform systematic inference from premises does not improve over time and peaks early. This suggests that MLMs primarily acquire knowledge through high-dimensional co-occurrence patterns rather than logical deduction.

Introduction

The ability of pre-trained Transformers to encode commonsense knowledge is well-documented. However, whether this knowledge is acquired through "Systematic Inference" (learning general semantic rules) or "Surface-level Patterns" (learning word co-occurrences) remains a central question in NLP. If models induce reasoning, scaling data and compute may suffice for general intelligence. If they rely on patterns, they may never master implicit commonsense. This paper tracks BERT's million-step pre-training journey to determine which path it actually takes.

Methodology

We performed periodic interventions during the pre-training of BERT-base from scratch. Every 50,000 steps, we injected a specific logical premise (e.g., "A boat has a hull") into the training stream via a single gradient update. We then measured the model's posterior likelihood of predicting logically supported inferences (e.g., "A canoe has a hull") against its prior knowledge.

We focused on downward monotonicity, a core logical property where a property of a general category applies to its specific members. Performance was measured using Pointwise Mutual Information (PMI) and Mean Reciprocal Rank (MRR), with control entities (e.g., using "fish" instead of "bird") used to ensure the model wasn't simply getting better at predicting any related word.

Results and Analysis

The evolution of BERT's knowledge reveals a disconnect between memorization and reasoning.

Prior Knowledge Acquisition

Throughout pre-training, BERT's prior log-probability for target statements increased steadily, reflecting the model's capacity to memorize facts from the training corpus. However, this growth in prior knowledge did not translate into improved inferential capabilities.

Prior log-probabilities for sub-statements, super-statements, and class relations across 1M training iterations.

Stagnation of Systematic Reasoning

The "boost" in prediction probability provided by a premise—measured by PMI—remained stagnant throughout the majority of the pre-training process. Explicit reasoning performance (using a provided premise) hit its maximum around 150,000 steps and didn't improve for the remaining 850,000 steps. Crucially, the PMI for correct logical inferences often became indistinguishable from control answers by the end of training.

PMI for Class-Relation vs. Control, illustrating the lack of significant divergence in reasoning performance over time.

Surface-Level Dominance

The intervention results suggest that BERT updates its internal "association map" for broad categories rather than following specific logical links. In many instances, updating on a premise increased the probability of incorrect control predicates as much as, or more than, the correct ones. This behavior aligns with the hypothesis that commonsense in these models is driven by high-dimensional co-occurrence patterns rather than induced semantic reasoning.

Conclusion

Our findings suggest that standard pre-training objectives do not naturally induce systematic logical inference in masked language models. While BERT becomes an expert at retrieving memorized patterns, its capacity for explicit reasoning remains limited and static throughout the later stages of training. This suggests that achieving "true" commonsense may require architectural innovations that incorporate explicit reasoning mechanisms rather than relying solely on scale.

Summary updated

BibTeX
@inproceedings{porada2022does,
  author = {Ian Porada and Alessandro Sordoni and Jackie Chi Kit Cheung},
  title = {{Does Pre-training Induce Systematic Inference? How Masked Language Models Acquire Commonsense Knowledge}},
  booktitle = {Conference of the North American Chapter of the Association for Computational Linguistics},
  year = {2022},
  doi = {10.18653/v1/2022.naacl-main.337},
}
Figure