During training the model uses dynamic programming to marginalize over permutations of the null symbols, while beam search is employed during decoding.
our model defines a separate latent alignment variable, which adds flexibility to the way the alignment distribution can be defined (as a geometric distribution or parameterised by a neural network) and how the alignments can be constrained, without redefining the dynamic program.