I assume you are referring to Lambertus’ maps? AFAIK the conversion is whatever the underlying program mkgmap uses. You need to take that up with the programmers of that.

Thai is even worse, it turns into gibberish.

Cheers,
Peter.