Skip to main content

crowdin pre-translate

Description

Pre-translate files via Machine Translation (MT) or Translation Memory (TM)

Synopsis

crowdin pre-translate [CONFIG OPTIONS] [OPTIONS]

Options

-l, --language=
Languages to which pre-translation should be applied. Default: ALL

--method=
Defines pre-translation method. Supported values: mt, tm

--engine-id=
Machine Translation engine Identifier

-b, --branch=
Specify branch name. Default: none

--auto-approve-option=
Defines which translations added by TM pre-translation should be auto-approved. Supported values: all, except-auto-substituted, perfect-match-only. Default: none

--[no-]duplicate-translations
Adds translations even if the same translation already exists

--[no-]translate-untranslated-only
Applies pre-translation for untranslated strings only

--[no-]translate-with-perfect-match-only
Applies pre-translation only for the strings with perfect match

--label=
Label identifier. Could be specified multiple times

-V, --version
Display version information and exit

-h, --help
Display help message and exit

--no-progress
Disable progress on executed command

-v, --verbose
Provide more information about the command execution

--no-colors
Disable colors and styles

-c, --config=
Specify a path to the configuration file. Default: crowdin.yml or crowdin.yaml

--identity=
Specify a path to user-specific credentials

--plain
Provide plain, processable output

Config Options

-T, --token=
Personal access token required for authentication

--base-url=
Base URL of Crowdin server for API requests execution

--base-path=
Path to your project directory on a local machine

-i, --project-id=
Numeric ID of the project

-s, --source=
Path to the source files

-t, --translation=
Path to the translation files

--dest=
Specify file name in Crowdin

--[no-]preserve-hierarchy
Choose whether to save the directory hierarchy in the Crowdin project

Notes

Crowdin CLI uses the crowdin.yml configuration to Pre-Translate files.

  • At first, it finds local source files that match the source configuration pattern. Then CLI tries to find the corresponding files in the crowdin project. After that, CLI will request Pre-translation for the found file IDs (matching these files to local sources and configuration file).

  • -l, --language=language_code - defines the language to which pre-translation should be applied. By default, pre-translation is applied for all project’s target languages. Crowdin Language Codes.

  • The --engine-id value you can find in the MT engine details (Profile > Machine translation for crowdin.com and Dashboard > Machine translation for Crowdin Enterprise)

Examples

crowdin pre-translate -l fr -l uk --method tm
crowdin pre-translate -l fr --method mt --engine-id 5
crowdin pre-translate -l fr --method mt --engine-id 5 --branch main