How Q, K and V are computed from the input tokens
Single-head attention with N = 4 tokens and model size d = 4. The same input matrix X is multiplied by three different d × d weight matrices. Each output cell is a dot product of one token row with one weight column.