English

Multi-Head Self-Attention with Role-Guided Masks

Computation and Language 2020-12-24 v1

Abstract

The state of the art in learning meaningful semantic representations of words is the Transformer model and its attention mechanisms. Simply put, the attention mechanisms learn to attend to specific parts of the input dispensing recurrence and convolutions. While some of the learned attention heads have been found to play linguistically interpretable roles, they can be redundant or prone to errors. We propose a method to guide the attention heads towards roles identified in prior work as important. We do this by defining role-specific masks to constrain the heads to attend to specific parts of the input, such that different heads are designed to play different roles. Experiments on text classification and machine translation using 7 different datasets show that our method outperforms competitive attention-based, CNN, and RNN baselines.

Keywords

Cite

@article{arxiv.2012.12366,
  title  = {Multi-Head Self-Attention with Role-Guided Masks},
  author = {Dongsheng Wang and Casper Hansen and Lucas Chaves Lima and Christian Hansen and Maria Maistro and Jakob Grue Simonsen and Christina Lioma},
  journal= {arXiv preprint arXiv:2012.12366},
  year   = {2020}
}

Comments

Accepted at ECIR@2021

R2 v1 2026-06-23T21:14:50.605Z