def save(self, path=None):
        """
        Saves the policy model to the provided path

        :param path: path to save the model to
        :return:
        """

        # Don't save if not training
        if not self.is_training:
            return

        if not path:
            path = 'models/policies/reinforce.pkl'
            print('No policy file name provided. Using default: {0}'
                  .format(path))

        # If the directory does not exist, create it
        if not os.path.exists(os.path.dirname(path)):
            os.makedirs(os.path.dirname(path), exist_ok=True)

        obj = {'weights': self.weights,
               'alpha': self.alpha,
               'alpha_decay_rate': self.alpha_decay_rate,
               'epsilon': self.epsilon,
               'exploration_decay_rate': self.exploration_decay_rate}

        with open(path, 'wb') as file:
            pickle.dump(obj, file, pickle.HIGHEST_PROTOCOL)

        Saves the policy model to the provided path

        :param path: path to save the model to
        :return:
        
plato/agent/component/dialogue_policy/deep_learning/reinforce_policy.py