← 05 Deep architecturesunit 5.3 / theory testTheory test: Attention and transformers6 questions. Pass with 5 correct.01 Why are attention scores divided by dk?To make attention fasterDot products grow with dimension; scaling keeps their variance near 1 so the softmax doesn't saturateTo make the weights sum to 1To hide future tokens02 What does a causal mask do?Removes padding tokensLets each position attend only to itself and earlier positionsRandomly drops attention weightsMakes attention bidirectional03 The attention score table for a sequence of n tokens costs:O(n)O(nlogn)O(n2)O(1)04 A model has dmodel=512 and 8 attention heads. Each head works in:512 dimensions64 dimensions8 dimensions4,096 dimensions05 Without any position information, self-attention:Works the same on any sentence order: it can't tell word order apartOnly sees the first tokenBecomes an RNNCan't be trained06 In a pre-norm transformer block, the attention sub-layer computes:x←Attention(x)x←x+Attention(LayerNorm(x))x←LayerNorm(x)⋅Attention(x)x←x−Attention(x)Answer all 6 to submit (0 done)