i18n icon indicating copy to clipboard operation
i18n copied to clipboard

Translating after Google Translator Toolkit

Open creativecreatorormaybenot opened this issue 6 years ago • 11 comments

Google Translator Toolkit is shutting down and I do not know what other software would translate the files generated by intl_translation.
Having said that, I was not sure where to open the issue, so there is one over there as well: https://github.com/dart-lang/i18n/issues/534

Since Google Translator Toolkit seems to be the only platform supporting ARB files, maybe an alternative for intl would be to produce a JSON format that is supported across major translation services.

In any case, if it helps, at BMW we wrote this CLI utility to transform to/from ARB files to JSON: https://github.com/bmw-tech/arb-converter-cli

jorgecoca avatar Sep 20 '19 20:09 jorgecoca

Thanks. That seems very helpful and gives people an immediate option. How widely is "Hierarchical JSON" supported?

alan-knight avatar Sep 23 '19 18:09 alan-knight

I do not know, to be honest, I just know it works with our vendor of choice, but if you feel like a new format should be supported, you can file a new issue on arb-converter-cli... also, PRs are welcomed ;)

jorgecoca avatar Sep 24 '19 19:09 jorgecoca

Translator Toolkit has a poor suport for use last version translate on a new version (more strings) of the same APP. The Translation Memory sucks.

So, maybe an option is to work on a simple system for those translation, and that just allow to add new strings to translate without the need of create a entire new translation.

eltonmorais avatar Oct 06 '19 11:10 eltonmorais

Hi, our vendor is Lokalise, and here's their supported format list: https://docs.lokalise.com/en/collections/652248-supported-file-formats

Notably, I think "GNU Gettext / PO", "ICU", some kinds of jsons...

truongsinh avatar Nov 26 '19 23:11 truongsinh

Note that the ARB format is essentially ICU message strings in a JSON format. So it ought to be quite simple to emit/consume a different format. The most difficult part is understanding the other format, and if it handles things like "meaning", or how it defines parameters.

I started doing an experiment writing an equivalent to the extract_to_arb/generate_from_arb scripts in a separate package for XLIFF, which is one of the more complex alternatives, and it doesn't seem like there are many obstacles to doing that. If the strings are not ICU then understanding PetitParser enough to write a different grammar for them is an issue, and understanding XLIFF is another.

It requires importing files from lib/src in intl_translation, but that works, and I think we can reasonably move those out of src/re-export them to make it easier for people to do that. The thing I was doing is still pretty rough, doesn't actually have a specific target, and I have to do some paperwork to publish a new package. But if someone has a specific target they want to use/test against and are willing to try writing support for such a format, I'd be happy to help and to make supporting changes to intl_translation.

alan-knight avatar Nov 27 '19 18:11 alan-knight

Localizely supports ARB files.

I hope this helps.

goranluledzija avatar Dec 28 '19 00:12 goranluledzija

Here is something to convert to XLIFF or Gettext and back https://www.npmjs.com/package/arb-convert

mdoelker avatar Dec 29 '19 23:12 mdoelker

BabelEdit has added support for arb files, works like a charm and doesn't cost a fortune.

ChiefWiggum avatar Jan 15 '20 10:01 ChiefWiggum

I wrote the free tool attranslate to compensate for the death of "Google Translator Toolkit": https://github.com/fkirc/attranslate You can give attranslate a try if this is still an issue for you. attranslate supports both JSON-files and ARB-files, and it also supports conversions between file-formats.

fkirc avatar Nov 22 '20 23:11 fkirc

See also this stackoverflow thread.

mosuem avatar Oct 26 '22 13:10 mosuem