Translate i18n JSON locale files locally, on CPU, for free with AI
https://www.npmjs.com/package/locale-ai β HEALTH ? 100 / Healthy
Translate i18n JSON locale files locally, on CPU, for free with AI
https://www.npmjs.com/package/locale-ai β// readme
Translate your i18n locale files locally, on CPU, for free. No API keys, no Python, nothing leaves your machine.
npx locale-ai translate --from en --to fr,es,de
locale-ai 0.6.3
Found 3 en files in locales/en/
Models to download (one time, then cached for every project):
en-fr 345 MB khabouss/opus-mt-tc-big-en-fr-onnx
...
Download 577 MB? (Y/n)
β fr 43 strings translated, 3 files written in 2.7s, 1 plural forms added
β es 43 strings translated, 3 files written in 2.5s, 1 plural forms added
β de 43 strings translated, 3 files written in 2.1s
Behind a proxy or in locked-down CI?
npm installpulls inonnxruntime-node, which tries to download a ~260Β MB CUDA provider locale-ai never uses (it only ever runs on CPU) β on a network that canβt reachapi.nuget.org, that download failing takes the whole install down with it. Skip it with:ONNXRUNTIME_NODE_INSTALL=skip npm install locale-aiThatβs also the faster way to install even with a good connection β about 51Β MB and 3 seconds instead of several hundred MB. locale-ai re-checks for (and removes) that CUDA provider onβ¦