Tensor_Devourer_56

joined 11 months ago
[–] Tensor_Devourer_56@alien.top 1 points 11 months ago (2 children)

If I'm understanding your question correctly, it probably doesn't make any differences computation wise. But if we have query dot key as one single input, then the attention layer would just have two inputs: 1.query dot key matrix; 2. value matrix. I think this would be a worse formulation thant the original paper altough they are the same computation wise. By allowing separate key and value matrices, the data flow is clearer. For example the Encoder-Decoder attention layer takes the result of Encoder block as key and value but the processed target sequence as value. This idea is very clear with the original attention layer formation.