When using the MinT test instance, pasting contents to the input text often results in extra space characters at the end. These seem to have an effect in the translation, resulting in unexpected content in the translation. An example is shown below:
Translation with some trailing spaces | Translation without extra spaces |
---|---|
Notice in the first example how the selected text in the source (highlighted in green) results in the translation containing the "Other " text at the end as an incomplete sentence. Something that does not happen when the extra spaces are removed.
The text used in the example is this:
Paplitę daugiausiai Afrikos žemyne, tik nedidelė liūtų populiacijos dalis – šiaurinių liūtų porūšio azijinė populiacija gyvena Azijos žemyno Indostano pusiasalio šiaurvakariuose.
This ticket proposes for MinT to trim the input text internally to remove leading and trailing spaces. We can consider whether it is also safe and beneficial to also remove in-between spaces except for a single space character between words (e.g., double spaces).
In this way, translating a message should produce the same result regardless of the number of extra spaces at the beginning or end of it.