Online and Linear-Time Attention by Enforcing Monotonic Alignments
tf.contrib.seq2seq
module.
NOTE - A reference implementation of the monotonic attention mechanism is now built into TensorFlow in the This repository contains an example implementation of the monotonic alignment decoder proposed in "Online and Linear-Time Attention by Enforcing Monotonic Alignments", by Colin Raffel, Minh-Thang Luong, Peter J. Liu, Ron J. Weiss, and Douglas Eck (arXiv:1704.00784).
It also contains (in the benchmark
folder) the synthetic benchmark used to compare the speed of the monotonic attention mechanism and standard softmax-based attention.