def is_dialog_complete(handler_input):
    """
    Checks whether the dialog is complete according to the dialog model

    :param handler_input: (HandlerInput)
    :return: (boolean)
    """

    if not hasattr(handler_input.get_request(), "dialogState"):
        return False

    return handler_input.get_request().dialogState == "COMPLETE"