NILE : Natural Language Inference with Faithful Natural Language Explanations

Sawan Kumar, Partha P. TalukdarACL 2020

Introduction

In the field of Natural Language Processing (NLP), deep learning models have achieved remarkable success in predicting labels for complex tasks. However, these models often function as "black boxes," providing little insight into their decision-making processes. In the context of Natural Language Inference (NLI)—determining whether a premise entails, contradicts, or is neutral toward a hypothesis—the need for transparency is paramount for building trust.

Traditional "explainable" AI often relies on post-hoc justifications: a model predicts a label first and then generates a text that sounds like a reasonable explanation. The fundamental flaw is that these justifications may not reflect the model's actual internal logic—a phenomenon known as a lack of faithfulness. In their ACL 2020 paper, Kumar and Talukdar introduce NILE (Natural-language Inference over Label-specific Explanations), a framework designed to ensure that explanations are faithful by making them the primary driver of the final prediction.

The NILE Framework

NILE shifts the paradigm from post-hoc explanation to explanation-driven inference. The architecture consists of a two-step pipeline designed to make the prediction sensitive to the logic of the explanation:

  1. Candidate Explanation Generators ($G$): For any given premise-hypothesis pair, NILE employs three separate generators (finetuned GPT-2 models). Each is tasked with producing a natural language explanation for one of the three possible NLI labels: Entailment, Contradiction, and Neutral.
  2. Explanation Processor ($S$): A RoBERTa-based classifier receives the premise, the hypothesis, and the three generated candidate explanations. Its role is to evaluate which explanation is most logically consistent with the input pair and output the corresponding label.
The NILE framework pipeline: Step I generates label-specific candidates, and Step II processes them to infer the task label.

By forcing the model to select from pre-generated explanations to determine the label, the explanation becomes an integral part of the decision path rather than an afterthought.

Addressing Shortcut Biases

A significant challenge in training such models is the "shortcut" or "Clever Hans" bias. Models may learn to associate specific linguistic patterns in an explanation (e.g., certain keywords or syntactic structures) with a label without actually understanding the underlying logic.

To combat this, the authors introduced negative sampling. During training, the Explanation Processor is presented not only with valid explanations but also with "random" explanations of the same label type that do not apply to the specific input pair. This forces the model to distinguish between the content of the explanation and its form, ensuring that the final prediction is sensitive to the actual reasoning provided.

Experimental Evaluation

The authors evaluated NILE using the Stanford Natural Language Inference (SNLI) dataset and its explanatory extension, e-SNLI. To test generalization, they also utilized the Multi-Genre NLI (MNLI) dataset, which contains text from diverse sources like fiction and government documents.

Performance and Accuracy

NILE demonstrated that faithfulness does not have to come at the cost of performance. On the SNLI test set, NILE achieved an accuracy of 91.29%, outperforming previous explanatory models like ETPA and remaining competitive with state-of-the-art non-explanatory models like SemBERT.

Performance comparison on SNLI: NILE achieves high label accuracy and superior explanation quality metrics compared to baselines.

Generalization and Robustness

One of the most striking results was NILE's performance on out-of-domain data. When tested on MNLI without additional finetuning, NILE maintained an accuracy of approximately 73%, whereas the ETPA baseline dropped to roughly 56%. This suggests that grounding predictions in natural language explanations helps the model capture more generalizable logical principles.

Measuring Faithfulness

To prove that NILE is truly faithful, the authors conducted a "shuffling test." They swapped the explanations between different input pairs. If the model were truly sensitive to the explanation's content, its accuracy should drop significantly. Indeed, NILE's accuracy plummeted to ~35% (near random chance) during this test. In contrast, models trained without the negative sampling "fix" maintained high accuracy (~88%) even with swapped explanations, proving they were ignoring the text and relying on hidden biases.

Conclusion

NILE represents a significant step toward trustworthy AI. By making the explanation the driver of the prediction and implementing rigorous training techniques to ensure sensitivity, Kumar and Talukdar demonstrate that we can build models that are both highly accurate and genuinely transparent. Future work will likely focus on reducing the computational overhead of the multi-model pipeline and developing even more sophisticated probes for faithfulness.

Reference: Kumar, S., & Talukdar, P. (2020). NILE: Natural Language Inference with Faithful Natural Language Explanations. Proceedings of the 58th Annual Meeting of the Association for Computational Linguistics, 8730–8742.

Summary updated

BibTeX
@inproceedings{kumar2020nile,
  author = {Sawan Kumar and Partha P. Talukdar},
  title = {{NILE : Natural Language Inference with Faithful Natural Language Explanations}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2020},
  doi = {10.18653/v1/2020.acl-main.771},
}
Figure