A residual connection adds a layer’s input to its transformed output: Output = LayerNorm(x + SubLayer(x)). The layer adds to the existing representation instead of replacing it. section 9.6
This addition preserves the original information and lets gradients flow directly through the skip connection, making deep networks easier to train. section 9.6
Transformer encoder
In a Transformer encoder, residual connections wrap both self-attention and feedforward sub-layers that process zone representations. section 9.6
Figure 9.8 Transformer architecture.
The Transformer architecture diagram provides context for where residual connections fit in the encoder. section 9.6

















