q = apply_rope(q, positions) k = apply_rope(k, positions) scores = q @ k.T