Evaluate Confidence Instead of Perplexity for Zero-shot Commonsense Reasoning

Letian Peng, Zuchao Li, Hai ZhaoarXiv 2022 · DOI · arXiv

Abstract

Current language models often fail at zero-shot commonsense reasoning because they rely on perplexity (PPL), a metric heavily biased toward high-frequency words. This paper introduces Non-Replacement Confidence (NRC), a new metric based on discriminative pre-training (like ELECTRA) that evaluates the "contextual integrity" of a statement rather than its statistical probability. NRC achieves state-of-the-art performance across nine commonsense benchmarks by mitigating frequency bias and focusing on logical fit over word probability.

The Problem with Perplexity

When performing zero-shot commonsense tasks, Pre-trained Language Models (PLMs) typically use perplexity to rank candidate answers. PPL measures the probability of a sequence; however, because it is derived from word frequency, it is inherently biased toward common words. This creates a zero-sum game where common words "steal" probability mass from rarer, more accurate ones.

Figure 1: Comparison of generative metrics (CLM, MLM) vs. discriminative metrics (RTD) for a commonsense task. Generative models often favor high-frequency but incorrect words like "warm" over logical but rarer choices like "chilly."

As shown in Figure 1, in the sentence "I saw my breath because the weather is ____," a model might assign a higher probability to "warm" than "chilly" simply because "warm" appears more frequently in training data. This "frequency bias" prevents models from selecting the only logical answer in many zero-shot scenarios.

Methods: Non-Replacement Confidence (NRC)

The authors propose shifting from a generative perspective (predicting the next word) to a discriminative one (detecting if a word fits). They leverage the Replaced Token Detection (RTD) objective from the ELECTRA model. In RTD, a discriminator is trained to predict whether each token in a sentence is original or has been replaced by a plausible alternative.

The core contribution is the Non-Replacement Confidence (NRC) metric:

  1. The Formula: NRC calculates the average negative log-likelihood that the discriminator believes each token is original (not replaced).
  2. Contextual Integrity: Unlike PPL, NRC does not force candidate words to share a total probability of 1.0. Each word is evaluated individually for its "integrity" within the context, allowing the model to recognize that a low-frequency word like "chilly" fits perfectly without being penalized for its rarity.
  3. Efficiency: NRC is computationally efficient, matching the speed of GPT-style inference while providing better logical discrimination.

Key Results and Insights

The researchers evaluated NRC across a wide array of benchmarks, including ConceptNet, CommonsenseQA (CSQA), COPA, and ARC. Using ELECTRA-Large with the NRC metric, the authors outperformed larger models using PPL:

  • CSQA: NRC achieved 51.8% accuracy, significantly beating GPT2-XL (42.2%) and RoBERTa-Large (40.0%).
  • COPA: NRC reached 82.6%, a massive jump over RoBERTa's 75.2%.
  • ARC-Challenge: NRC (38.4%) outperformed RoBERTa (31.9%) and GPT2-XL (28.8%).

The Low-Frequency Advantage

A critical insight is NRC's robustness to word frequency. While PPL metrics struggle when the correct answer involves rare words, NRC maintains high confidence.

Figure 5: Performance comparison across word frequencies. NRC (red) provides more stable and positive support for correct answers involving rare words compared to PPL-based metrics.

As illustrated in Figure 5, NRC provides much more stable support for the correct answer when that answer involves rare words (frequency < 10), where PPL-based models (BERT, RoBERTa) often fail. Additionally, NRC focuses more on "non-trivial" components of a sentence—the nouns and verbs that carry commonsense weight—rather than stop words like "the" or "is."

Limitations and Future Work

While NRC is excellent at ranking provided answers, it cannot generate commonsense facts from scratch because it is a discriminator, not a generator. Future work may involve hybrid approaches: using a generator (like GPT) to sample potential candidates and then using an RTD-based discriminator with NRC to re-rank and select the most confident, logical choice.

Summary updated

Abstract

Commonsense reasoning is an appealing topic in natural language processing (NLP) as it plays a fundamental role in supporting the human-like actions of NLP systems. With large-scale language models as the backbone, unsupervised pre-training on numerous corpora shows the potential to capture commonsense knowledge. Current pre-trained language model (PLM)-based reasoning follows the traditional practice using perplexity metric. However, commonsense reasoning is more than existing probability evaluation, which is biased by word frequency. This paper reconsiders the nature of commonsense reasoning and proposes a novel commonsense reasoning metric, Non-Replacement Confidence (NRC). In detail, it works on PLMs according to the Replaced Token Detection (RTD) pre-training objective in ELECTRA, in which the corruption detection objective reflects the confidence on contextual integrity that is more relevant to commonsense reasoning than existing probability. Our proposed novel method boosts zero-shot performance on two commonsense reasoning benchmark datasets and further seven commonsense question-answering datasets. Our analysis shows that pre-endowed commonsense knowledge, especially for RTD-based PLMs, is essential in downstream reasoning.
BibTeX
@misc{peng2022evaluate,
  author = {Letian Peng and Zuchao Li and Hai Zhao},
  title = {{Evaluate Confidence Instead of Perplexity for Zero-shot Commonsense Reasoning}},
  year = {2022},
  eprint = {2208.11007},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2208.11007},
}
Figure