implemented caching of languages in translator