Exercise

# Building the inference models

You're now ready to produce autocompleted text for your input data. So far, you have created an encoder-decoder model and trained it using the preprocessed email dataset. Throughout this lesson, you'll use the trained model to generate a sequence of next characters given an incomplete sentence as input.

As a first step, you'll create the encoder and the decoder inference models in this exercise. The variables `encoder_input`

, `encoder_states`

, `decoder_input`

are available for use and contains the input tensor to the encoder, internal states of the encoder and the input tensor to the decoder.

Instructions 1/2

**undefined XP**

- Use the
`Model()`

function from`keras`

to build the Encoder inference model. - Use
`Input()`

to define Decoder initial states of dimension 256. - Combine the states into a single vector.