Skip to main content
QUICK REVIEW

[Paper Review] Can recursive neural tensor networks learn logical reasoning?

Samuel R. Bowman|arXiv (Cornell University)|Dec 21, 2013
Topic ModelingComputer Science18 references29 citations
TL;DR

This paper investigates whether recursive neural tensor networks (RNTNs) can learn logical reasoning through a custom dataset of unambiguous natural language inference examples. The model successfully learns monotonicity-based reasoning patterns with high accuracy and generalizes to unseen inference types in most cases, demonstrating that learned vector representations can support structured logical inference.

ABSTRACT

Recursive neural network models and their accompanying vector representations for words have seen success in an array of increasingly semantically sophisticated tasks, but almost nothing is known about their ability to accurately capture the aspects of linguistic meaning that are necessary for interpretation or reasoning. To evaluate this, I train a recursive model on a new corpus of constructed examples of logical reasoning in short sentences, like the inference of "some animal walks" from "some dog walks" or "some cat walks," given that dogs and cats are animals. This model learns representations that generalize well to new types of reasoning pattern in all but a few cases, a result which is promising for the ability of learned representation models to capture logical reasoning.

Motivation & Objective

  • To evaluate whether recursive neural tensor networks (RNTNs) can learn and generalize logical reasoning from supervised training on natural language inference.
  • To isolate reasoning capacity from other NLP challenges like coreference resolution and parsing by using hand-constructed, unambiguous inference examples.
  • To test whether learned vector representations capture general-purpose quantifier semantics enabling inference beyond memorization.
  • To investigate the limits of RNTNs in learning logical relations, particularly involving quantifiers like 'some' and 'no'.
  • To assess whether monotonicity-based inference patterns can be effectively learned and generalized by deep learning models using only distributional representations.

Proposed method

  • The study uses a recursive neural tensor network (RNTN) architecture, closely modeled after Socher et al., to learn phrase and sentence representations from tree-structured parse trees.
  • The model computes vector representations for phrases and sentences via recursive composition using tensor-based nonlinear transformations.
  • A custom dataset of 1,000 unambiguous natural language inference examples is constructed, focusing on quantifier-based monotonicity reasoning (e.g., 'all dogs bark' entails 'all puppies bark').
  • The training data includes various quantifier pairs (e.g., some, all, most, no) and their logical relations (entailment, contradiction, etc.), with sentences carefully constructed to avoid ambiguity.
  • Experiments are conducted with multiple train/test splits: one where entire quantifier pairs are held out, and others where subclasses or sentence types are excluded to test generalization.
  • The model is trained to predict the logical relation (entailment, contradiction, etc.) between sentence pairs using a softmax classifier over the output representation.

Experimental results

Research questions

  • RQ1Can recursive neural tensor networks learn and generalize logical reasoning patterns from a small, curated dataset of unambiguous natural language inference examples?
  • RQ2To what extent can the model generalize to unseen quantifier pairs or inference types not present in the training data?
  • RQ3Does the model learn general-purpose representations of quantifiers that support inference beyond memorization of fixed patterns?
  • RQ4Why does the model fail consistently on the 'some'–'no' quantifier pair, and what does this reveal about the representational capacity of RNTNs?
  • RQ5Can the model’s behavior be explained by formal natural logic systems, such as MacCartney’s monotonicity framework?

Key findings

  • The model achieves perfect accuracy in learning and generalizing monotonicity-based inference patterns across most training configurations, demonstrating strong inductive bias toward logical reasoning.
  • In the 'pair-out' setting, where entire quantifier pairs are held out, the model generalizes successfully to unseen relations in 90% of cases, indicating robust learning of quantifier semantics.
  • The model learns lexical hierarchies (e.g., dog ⊏ animal) from training data and applies them to infer relations like (some dog) bark ⊏ (all animal) bark.
  • The model fails consistently on the 'some'–'no' pair, predicting the weaker relation '|' instead of the strict contradiction '∧' in 100% of cases in set- and subclass-out settings, suggesting a representational limitation.
  • The failure on 'some'–'no' is consistent with formal logic: the relation cannot be derived from other seen examples under MacCartney’s natural logic, implying the model may be learning a consistent but incomplete subset of logical relations.
  • The results suggest that RNTNs can learn general-purpose representations supporting logical inference, but optimization and representational capacity may need improvement for certain quantifier combinations.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.