Understanding the Decoder of the Transformer

Learn about the structure and components of the decoder of the tranformer.

Suppose we want to translate the English sentence (source sentence) 'I am good' to the French sentence (target sentence) 'Je vais bien'. To perform this translation, we feed the source sentence 'I am good' to the encoder. The encoder learns the representation of the source sentence. We've learned how exactly the encoder learns the representation of the source sentence. Now, we take this encoder's representation and feed it to the decoder. The decoder takes the encoder representation as input and generates the target sentence 'Je vais bien', as shown in the following figure:

Get hands-on with 1200+ tech skills courses.