Pretraining with Artificial Language: Studying Transferable Knowledge in Language Models

Ryokan Ri, Yoshimasa Tsuruoka

Introduction

Large-scale pretrained models like BERT and GPT exhibit a remarkable "zero-shot" transfer ability, where a model trained on one language can often solve tasks in another with minimal additional training. Intriguingly, this occurs even when the languages share no overlapping vocabulary. This phenomenon suggests that models learn abstract structural properties of language. To investigate this, researchers presented a study at ACL 2022 using the Test for Inductive Bias via Language Model Transfer (TILT) framework. By stripping away the complexity of human speech and using "artificial languages," the authors isolate the specific structural properties that make a pretrained model "smart."

Methodology

The core of the study involves pretraining models on algorithmically generated artificial languages and then transferring the learned encoder to natural language tasks.

The TILT Framework

As illustrated in Figure 1, the process involves two main stages:

  1. Artificial Pretraining: An encoder is trained on an artificial language (L1) with specific properties.
  2. Fine-tuning: The frozen encoder is transferred to a natural language task (L2, e.g., English), where only the word embeddings and the final output layer are trained.
The TILT framework: pretraining on artificial language followed by transfer to natural language.

Artificial Language Design

The authors designed several artificial languages to isolate different linguistic properties:

  • Distributional Properties: These include Uniform (random tokens), Zipf (natural frequency distributions), and Log-linear (topic-based co-occurrence).
  • Structural Properties: "Dependency" languages were created where tokens come in head-tail pairs.
  • Flat Dependency: Pairs are scattered randomly.
  • Nesting Dependency: Pairs are nested hierarchically (e.g., [ { ( ) } ]), mimicking recursive human grammar.

Both LSTM and Transformer architectures were tested. The artificial datasets consisted of 12.8 million sentences for each variant.

Key Results and Insights

The study reveals that the "secret sauce" for effective transfer is the presence of nesting structures and distinct roles for tokens.

Performance Across Structures

As shown in Figure 3, the choice of pretraining data significantly impacts the model's final perplexity on natural language tasks like the Penn Treebank (PTB).

Comparison of model performance (perplexity) across different token distributions, dependency structures, and natural languages.
  • Nesting is Superior: A Transformer pretrained on "Nesting Dependency" achieved a perplexity of 160.6 on English PTB, significantly outperforming the "Flat Dependency" version (175.7) and the random weights baseline (194.7).
  • Token Distributions: Pretraining on Zipf-distributed tokens generally led to higher perplexity than uniform distributions in the absence of structure, but structure (like nesting) mitigated this.
  • Architecture Flexibility: Transformers consistently outperformed LSTMs across most pretraining scenarios, likely due to the self-attention mechanism's ability to aggregate context more effectively.

The "Contextual Memory" Hypothesis

Probing experiments suggested that models trained on structured data learn "position-aware context dependence." Unlike models trained on random data, which learn to ignore context, structured pretraining teaches the encoder to represent a token based on the identity and distance of its specific neighbors.

Conclusion and Future Work

The findings confirm that the hierarchical nature of human language is a fundamental feature that neural networks can leverage for transfer. While "position-aware context" is a strong candidate for what is being transferred, limitations remain. The study used relatively small models (~7M parameters) and focused on syntax-heavy tasks. Future research should explore whether these structural biases hold in billion-parameter models and if they assist in high-level semantic tasks like Natural Language Inference or Question Answering.

Summary updated

BibTeX
@inproceedings{ri2022pretraining,
  author = {Ryokan Ri and Yoshimasa Tsuruoka},
  title = {{Pretraining with Artificial Language: Studying Transferable Knowledge in Language Models}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2022},
  doi = {10.18653/v1/2022.acl-long.504},
}
Figure