--- # edu-hufe title: 'Write §7: Exercise 2 — implement self-attention in Rust' status: todo type: task created_at: 2026-03-13T22:01:56Z updated_at: 2026-03-13T22:01:56Z parent: edu-u2w7 --- Implement scaled dot-product attention using candle tensors. Single head, causal mask, softmax, output projection. Reader writes the core attention function.