From Credit Assignment to Entropy Regularization: Two New Algorithms for Neural Sequence Prediction