Translation Automation

How can you achieve continuous translation?

Nils Jacobsen


#Translation Automation - with lint and machine translation

A common problem with i18n processes is the presence of manual steps and broken translations. These efforts are continuous instead of being a one-time activity. However, an automation system can help manage this issue. To establish the automation we can use the CLI.

#When does Translation Automation becomes handy?

  • New feature development requires new translations
  • Newly added languages need new translations
  • The new design gives new context that needs to be translated
  • New brand guide line requires updated translations
  • And many more...

#How does Change Control enable your review system?

  • Use machine translations to fully automate or give a starting point
  • Lint your translation content to ensure quality

#Don't want translations to be machine translated?

Sometimes machine translations don't match your quality standards and you want your translations to be done by humans. In this case, you can use the Ninja i18n GitHub action to get lint reports in your pull requests, including links to the relevant messages, and have your team translate the content using the Fink localization editor. You can find more information about Ninja i18n here.

#Hands-on Guide

Because lix is git compatible, you can use the mechanisms of GitHub to build this system.

  1. Create a inlang project image

  2. Install the CLI

npx @inlang/cli [command]
  1. Setup Lint in CI/CD. You can add this to your test step.
"test": npx @inlang/cli lint --project <projectPath>
  1. Setup Machine Translate in CI/CD. You can add this to your build step.
"build": npx @inlang/cli machine translate --project <projectPath>

#How we do it on

"build": "npx @inlang/cli machine translate -f --project ../../../project.inlang --targetLanguageTags fr,it,pt-BR,sk,zh"
"test": "npx @inlang/cli lint --project ../../../project.inlang

Add this to you build and test step to:

  • Machine translate through build step. We want to shift more quality to en and de, that is why we don't machine translate them. We cnsider the other languages comunity languages. When they have weak translations, the community can open a PR through fink.
  • Lint through test step. We let the lint command throw errors when translations are missing. There is not only the missing message lint rule. There are differen lint rules for different use cases, that can be configured as error or warning.

Edit on GitHub