1
$\begingroup$

Why in the attention mechanism do they apply multihead? It's been said that it would lift the amplitude of vector dot production from word that at the moment is analysed, which can be correct, but dividing the embedding vector to 8 arbitrary vectors may cause the next most important word also to be the same head as the word we are analysing right now not to shine properly again. It's better than previous procedure but still.... There may be some misunderstandings by me if so correct me please. And what are other reasons to use multiheads.

$\endgroup$

1 Answer 1

2
$\begingroup$

The different words in a sentence can relate to each other in many different ways simultaneously. For example, distinct syntactic, semantic, and discourse relationships can hold between verbs and their arguments in a sentence. It would be difficult for a single transformer block to learn to capture all of the different kinds of parallel relations among its inputs. Transformers address this issue with multihead self-attention layers. These are sets of self-attention layers, called heads, that reside in parallel layers at the same depth in a model, each with its own set of parameters. Given these distinct sets of parameters, each head can learn different aspects of the relationships that exist among inputs at the same level of abstraction.

Reference:
Speech and Language Processing: An introduction to natural language processing

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.