How transfer learning impacts linguistic knowledge in deep NLP models?

33747

Authors

nan

Abstract

Transfer learning from pre-trained neural lan- guage models towards downstream tasks has been a predominant theme in NLP recently. Several researchers have shown that deep NLP models learn non-trivial amount of linguis- tic knowledge, captured at different layers of the model. We investigate how fine-tuning towards downstream NLP tasks impacts the learned linguistic knowledge. We carry out a study across popular pre-trained models BERT, RoBERTa and XLNet using layer and neuron- level diagnostic classifiers. We found that for some GLUE tasks, the network relies on the core linguistic information and preserve it deeper in the network, while for others it for- gets. Linguistic information is distributed in the pre-trained language models but becomes localized to the lower layers post-fine-tuning, reserving higher layers for the task specific knowledge. The pattern varies across architec- tures, with BERT retaining linguistic informa- tion relatively deeper in the network compared to RoBERTa and XLNet, where it is predomi- nantly delegated to the lower layers. 1

Keywords

nan

Full Content

Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021, pages 4947–4957 August 1–6, 2021. ©2021 Association for Computational Linguistics 4947 How transfer learning impacts linguistic knowledge in deep NLP models? Nadir Durrani Hassan Sajjad Fahim Dalvi {ndurrani,hsajjad,faimaduddin}@hbku.edu.qa Qatar Computing Research Institute, HBKU Research Complex, Doha 5825, Qatar Abstract Transfer learning from pre-trained neural lan- guage models towards downstream tasks has been a predominant theme in NLP recently. Several researchers have shown that deep NLP models learn non-trivial amount of linguis- tic knowledge, captured at different layers of the model. We investigate how fine-tuning towards downstream NLP tasks impacts the learned linguistic knowledge. We carry out a study across popular pre-trained models BERT, RoBERTa and XLNet using layer and neuron- level diagnostic classifiers. We found that for some GLUE tasks, the network relies on the core linguistic information and preserve it deeper in the network, while for others it for- gets. Linguistic information is distributed in the pre-trained language models but becomes localized to the lower layers post-fine-tuning, reserving higher layers for the task specific knowledge. The pattern varies across architec- tures, with BERT retaining linguistic informa- tion relatively deeper in the network compared to RoBERTa and XLNet, where it is predomi- nantly delegated to the lower layers. 1 Introduction Contextualized word representations learned in transformer-based language models capture rich linguistic knowledge, making them ubiquitous for transfer learning towards downstream NLP prob- lems such as Natural Language Understanding tasks e.g. GLUE (Wang et al., 2018). The general idea is to pretrain representations on large scale un- labeled data and adapt these towards a downstream task using supervision. Descriptive methods in neural interpretability investigate what knowledge is learned within the representations through relevant extrinsic phe- nomenon varying from word morphology (Vylo- mova et al., 2016; Belinkov et al., 2017a; Dalvi et al., 2017) to high level concepts such as structure (Shi et al., 2016; Linzen et al., 2016) and seman- tics (Qian et al., 2016; Belinkov et al., 2017b) or more generic properties such as sentence length (Adi et al., 2016; Bau et al., 2019). These studies are carried towards analyzing representations from pre-trained models. However, it is important to investigate how this learned knowledge evolves as the models are adapted towards a specific task from the more generic task of language modeling (Peters et al., 2018) that they are primarily trained on. In this work, we analyze representations of 3 popular pre-trained models (BERT, RoBERTa and XLnet) with respect to morpho-syntactic and se- mantic knowledge, as they are fine-tuned towards GLUE tasks. More specifically we investigate i) if the fine-tuned models retain the same amount of linguistic information, ii) how this information is redistributed across different layers and individual neurons. To this end, we use Diagnostic Classifiers (Hupkes et al., 2018; Conneau et al., 2018), a pop- ular framework for probing knowledge in neural models. The central idea is to extract feature repre- sentations from the network and train an auxiliary classifier to predict the property of interest. The quality of …

Content truncated to 500 words

Labeled Text

Transfer learning from pre-trained neural language models towards downstream tasks has been a predominant theme in NLP recently. Several researchers have shown that deep NLP models learn non-trivial amount of linguistic knowledge, captured at different layers of the model. We investigate how fine-tuning towards downstream NLP tasks impacts the learned linguistic knowledge. We carry out a study across popular pre-trained models BERT, RoBERTa and XLNet using layer and neuronlevel diagnostic classifiers. We found that for some GLUE tasks, the network relies on the core linguistic information and preserve it deeper in the network, while for others it forgets. Linguistic information is distributed in the pre-trained language models but becomes localized to the lower layers post-fine-tuning, reserving higher layers for the task specific knowledge. The pattern varies across architectures, with BERT retaining linguistic information relatively deeper in the network compared to RoBERTa and XLNet, where it is predominantly delegated to the lower layers. 1

Publication Details

Paper ID:
33747
Year:
2021
Publication:
TIPSTER
Publication Type:
conf
DOI:
nan