Yes! I tried again to edit the strange characters in vscode and I succeeded. Only this time I used the html file extracted by KindleUnpack, not the gls file generated by your script. Then I took the edited html and converted it to xml using your script and then to Stardict using pyglossary. My mistake was trying to convert gls to bgl by Babylon Glossary Builder and it always gave an error. Anyway, I think converting a file multiple times wouldn't be cool haha. Using mobitool is better and faster.