def _predict(self, message: Message) -> Optional[Dict[(Text, Union[(tf.Tensor, Dict[(Text, tf.Tensor)])])]]:
    if (self.model is None):
        logger.debug(f"There is no trained model for '{self.__class__.__name__}': The component is either not trained or didn't receive enough training data.")
        return None
    model_data = self._create_model_data([message], training=False)
    if model_data.is_empty():
        return None
    return self.model.run_inference(model_data)
def _predict(self, message: Message) -> Optional[Dict[(Text, Union[(tf.Tensor, Dict[(Text, tf.Tensor)])])]]:
    if (self.model is None):
        logger.debug(f"There is no trained model for '{self.__class__.__name__}': The component is either not trained or didn't receive enough training data.")
        return None
    model_data = self._create_model_data([message], training=False)
    if model_data.is_empty():
        return None
    return self.model.run_inference(model_data)