On Surgical Fine-tuning for Language Encoders

Abhilasha Lodha, Gayatri Belapurkar, Saloni Chalkapurkar, Yuanming Tao, Reshmi Ghosh +3 more
10/25/2023
cs.CLcs.AIcs.IR

No official code found. Best implementation: alexta0/surgical_fine_tuning (5 stars, last commit 2023-11-09).

Abstract

Fine-tuning all the layers of a pre-trained neural language encoder (either using all the parameters or using parameter-efficient methods) is often the de-facto way of adapting it to a new task. We show evidence that for different downstream language tasks, fine-tuning only a subset of layers is sufficient to obtain performance that is close to and often better than fine-tuning all the layers in the language encoder. We propose an efficient metric based on the diagonal of the Fisher information matrix (FIM score), to select the candidate layers for selective fine-tuning. We show, empirically on GLUE and SuperGLUE tasks and across distinct language encoders, that this metric can effectively select layers leading to a strong downstream performance. Our work highlights that task-specific information corresponding to a given downstream task is often localized within a few layers, and tuning only those is sufficient for strong performance. Additionally, we demonstrate the robustness of the FIM score to rank layers in a manner that remains constant during the optimization process.

View on arXivView PDF

Code Implementations(1)

Official code for the paper "On Surgical Fine-tuning for Language Encoders" published at EMNLP 2023

50PythonOct 23, 20232 years ago

Similar Papers

Cite this paper

@article{lodha2023surgical,
  title  = {On Surgical Fine-tuning for Language Encoders},
  author = {Abhilasha Lodha and Gayatri Belapurkar and Saloni Chalkapurkar and Yuanming Tao and Reshmi Ghosh and Samyadeep Basu and Dmitrii Petrov and Soundararajan Srinivasan},
  year   = {2023},
  eprint = {2310.17041},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2310.17041v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2310.17041.svg)](https://codeofpaper.com/paper/2310.17041)

Discussion