I think the interpretation of N depends on the paper, and I just had a discussion with @dwf and Yann D, it seems that in NLL when we say N, it means conditioned on the past N words. But me and @dwf suggest using something like sequence_length instead of n_gram to eliminate the confusion. You can clarify sequence_len in the docstring that it's the sequence length conditioned on.