I just wrote a chinese to pinyin addon, eventually I will add english translation as well, and yeah I used a sizeable lua file (300kb now), that I autogenerated from a chinese dictionary database that I had previously spent a few months making.
I'll make a post about it after I run some more tests on it.