Closed guotong1988 closed 7 years ago
In decoding phase, the attention mechanism is used to compute align scores between encoder outputs and the current target word, which need to use the previous state of decoder as one of the input parameter. Please refer to 《Neural Machine Translation by Jointly Learning to Align and Translate》 for details.
https://github.com/ilivans/tf-rnn-attention/blob/master/attention.py The link project doesn't use prev_state as one of the input parameter. @pemywei Thank you!!!