(1) could you clarify what is the rationale behind these assertions?
(2) The naming of the variables *_max_target_length make it seem like they specify a bound on the target (output), but it seems like (according to their description) they’re limits on the input (source). What do you think we rename them to something more descriptive?
The assertions basically suggest that there is no reason you would want to truncate validation target sequences more aggressively than you are truncating train sequences. So if you passed those parameters, you probably made a mistake.