arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2210.05709cs.CLcs.LG
收藏

Shapley Head Pruning:识别并消除多语言Transformer中的干扰

Shapley Head Pruning: Identifying and Removing Interference in Multilingual Transformers

William Held, Diyi Yang

AI总结:

针对多语言Transformer模型随适配语言增多性能下降的干扰问题,提出用Shapley值识别引发干扰的注意力头并剪枝的方法,最高可提升目标语言任务性能24.7%,并通过可视化提供了相关洞见。

摘要:

基于Transformer的多语言模型通过学习并复用语言无关特征,展现出出色的跨语言零样本和少样本迁移能力。然而,当固定规模的模型适配更多语言时,其在所有语言上的性能都会下降,这种现象被称为干扰。干扰通常被归因于模型容量有限,常用的解决方法是增加额外参数,尽管已有证据表明基于Transformer的模型存在参数过剩的问题。在本研究中,我们证明可以通过识别并剪枝语言特定参数来减少干扰。首先,我们使用沙普利值(Shapley Values,一种来自合作博弈论的贡献分配指标)来识别会引入干扰的注意力头。随后我们发现,从固定模型中移除这些识别出的注意力头,能够提升目标语言在句子分类和结构预测任务上的性能,提升幅度最高可达24.7%。最后,我们通过注意力可视化,对语言无关和语言特定的注意力头提供了相关见解。

英文摘要:

Multilingual transformer-based models demonstrate remarkable zero and few-shot transfer across languages by learning and reusing language-agnostic features. However, as a fixed-size model acquires more languages, its performance across all languages degrades, a phenomenon termed interference. Often attributed to limited model capacity, interference is commonly addressed by adding additional parameters despite evidence that transformer-based models are overparameterized. In this work, we show that it is possible to reduce interference by instead identifying and pruning language-specific parameters. First, we use Shapley Values, a credit allocation metric from coalitional game theory, to identify attention heads that introduce interference. Then, we show that removing identified attention heads from a fixed model improves performance for a target language on both sentence classification and structural prediction, seeing gains as large as 24.7\%. Finally, we provide insights on language-agnostic and language-specific attention heads using attention visualization.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑