Automatic Retranslation

Updated: last quarter · 1 min read

Deprecated

These docs cover the legacy CLI (v0). The current CLI is v1. See the current CLI docs

The Lingo.dev CLI automatically retranslates content when you modify the source text. The lockfile stores fingerprints for every source string - when a fingerprint changes, the CLI sends the updated content through the translation pipeline and replaces the old translation in all target files.

How it works#

json
// locales/en.json (original)
{ "button.save": "Save changes" }

// locales/es.json (generated)
{ "button.save": "Guardar cambios" }

After editing the source:

json
// locales/en.json (updated)
{ "button.save": "Save all changes" }

Running npx lingo.dev@latest run detects the new fingerprint and retranslates:

json
// locales/es.json (updated automatically)
{ "button.save": "Guardar todos los cambios" }

Unchanged keys are skipped entirely - only the modified key is sent to the translation backend.

What triggers retranslation#

ChangeRetranslated?
Source text modifiedYes
Source text unchangedNo
Key renamed, content unchangedNo - translation is carried forward
Key deleted from sourceTranslation removed from targets
New key added to sourceTranslated as new content

Overrides and automatic retranslation#

If you've manually overridden a translation, automatic retranslation replaces your override when the source changes. This is by design - a source change signals that the meaning has shifted and a fresh translation is needed.

To retranslate content for other reasons (model change, prompt update), see Retranslation.

Next Steps#