Add a /public/langs.json file that maps between Wikimedia language codes (ISO 639-1 or BCP 47?) to the different engine's codes (which will also indicate engine support for a language, and so we'll be able to switch the multiselect widget to only show the correct ones).
For example:
{ "en": { "tesseract": "eng", "google": "en" }, "bn": { "tesseract": "ben", "google": "bn" }, "uz": { "tesseract": "uzb", "google": "uz" }, "uz-cyrl": { "tesseract": "uzb_cyrl", "google": "uz-Cyrl" }, "he": { "tesseract": "heb", "google": "iw" }, "it_old ??": { "tesseract": "ita_old", } }
This way, we'll be able to display a localized list of available languages in the wiki UI.
Outstanding question: how do we deal with language codes such as ita_old which don't have direct mappings in ISO639-1?
We also need to include localized language names in user's current interface depending on the engine