input: Write a function to construct a neural network model in Python using Keras to classify the MNIST dataset correctly. The model should include an input layer, a hidden layer, and an output layer. The input layer should take vectors of size 784, the hidden layer should have 128 units with ReLU activation, and the output layer should have 10 units with softmax activation. The model should be compiled using the Adam optimizer, sparse categorical crossentropy loss, and accuracy as the metric.
  assert construct_mnist_classifier().summary() == keras.models.Model(inputs=keras.layers.Input(shape=(784,)), outputs=keras.layers.Dense(10, activation='softmax')(keras.layers.Dense(128, activation='relu')(keras.layers.Input(shape=(784,))))).summary()
  assert isinstance(construct_mnist_classifier(), keras.models.Model)
  construct_mnist_classifier().compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy'])
output: def construct_mnist_classifier():
      model = keras.models.Sequential([
          keras.layers.Input(shape=(784,)),
          keras.layers.Dense(128, activation='relu'),
          keras.layers.Dense(10, activation='softmax')
      ])
      model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy'])
      return model