Skip to main content
QUICK REVIEW

[Paper Review] What they do when in doubt: a study of inductive biases in seq2seq learners

Eugene Kharitonov, Rahma Chaabouni|arXiv (Cornell University)|Jun 26, 2020
Domain Adaptation and Few-Shot LearningComputer Science41 references13 citations
TL;DR

This paper investigates inductive biases in sequence-to-sequence models using four synthetic tasks probing memorization, arithmetic, hierarchical, and compositional reasoning. It introduces description length as a principled, sensitive measure of inductive bias and finds that LSTM and Transformer models favor hierarchical generalization, while CNN-based models prefer linear and compositional patterns, with Transformers showing strong memorization bias.

ABSTRACT

Sequence-to-sequence (seq2seq) learners are widely used, but we still have only limited knowledge about what inductive biases shape the way they generalize. We address that by investigating how popular seq2seq learners generalize in tasks that have high ambiguity in the training data. We use SCAN and three new tasks to study learners' preferences for memorization, arithmetic, hierarchical, and compositional reasoning. Further, we connect to Solomonoff's theory of induction and propose to use description length as a principled and sensitive measure of inductive biases. In our experimental study, we find that LSTM-based learners can learn to perform counting, addition, and multiplication by a constant from a single training example. Furthermore, Transformer and LSTM-based learners show a bias toward the hierarchical induction over the linear one, while CNN-based learners prefer the opposite. On the SCAN dataset, we find that CNN-based, and, to a lesser degree, Transformer- and LSTM-based learners have a preference for compositional generalization over memorization. Finally, across all our experiments, description length proved to be a sensitive measure of inductive biases.

Motivation & Objective

  • To understand how sequence-to-sequence models generalize under data scarcity, especially when multiple explanations are consistent with limited training data.
  • To identify and quantify inductive biases—such as preferences for memorization, arithmetic, hierarchy, or compositionality—in popular seq2seq architectures.
  • To develop and validate a principled, sensitive measure of inductive bias using description length, grounded in Solomonoff’s theory of induction.
  • To compare the generalization behavior of LSTM, Transformer, and CNN-based seq2seq models across diverse reasoning patterns.

Proposed method

  • Design four new synthetic tasks: Count-or-Memorization, Add-or-Multiply, Hierarchical-or-Linear, and Composition-or-Memorization, each with ambiguous training data and distinct generalization patterns.
  • Use fraction of perfect agreement (FPA) to measure how often models generalize according to a specific rule, with higher FPA indicating stronger bias toward that rule.
  • Propose description length (L) as a principled measure of inductive bias, defined as the description length of a model’s predictions under a given rule, with lower values indicating stronger bias.
  • Normalize description length by number of examples to track learning speed and bias acquisition over training, enabling analysis of bias evolution.
  • Train multiple models (LSTM, Transformer, CNN) on each task with 20 random seeds, and compare FPA and description length across architectures and settings.
  • Apply paired t-tests to assess statistical significance of differences in description length between candidate rules.

Experimental results

Research questions

  • RQ1How do seq2seq models generalize when trained on a single example in tasks with high ambiguity?
  • RQ2Which inductive biases—memorization, arithmetic, hierarchical, or compositional reasoning—do LSTM, Transformer, and CNN-based seq2seq models exhibit?
  • RQ3Can description length serve as a sensitive and principled measure of inductive bias in sequence models?
  • RQ4How quickly do different architectures learn to prefer one type of generalization over another?

Key findings

  • LSTM-based models can learn non-trivial arithmetic rules—such as counting, addition, and multiplication by a constant—from as few as one training example.
  • Transformer and LSTM-based models show a strong preference for hierarchical generalization over linear generalization, while CNN-based models prefer the opposite.
  • CNN-based models exhibit a bias toward compositional generalization over memorization when given sufficient composite examples, as indicated by lower description length.
  • Transformers show a pronounced bias toward memorization, with description length significantly lower for memorization than for compositional rules.
  • Description length proved to be a sensitive and reliable measure of inductive bias, with statistically significant differences across model types and generalization rules.
  • The inductive biases of joint source-target self-attention models closely resemble those of standard Transformers, suggesting consistency across attention mechanisms.

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.