Resources · Tools
Translate
Translate text into any language using an LLM, preserving formatting and context
The Translate block sends text to an LLM with an instruction to translate it into a target language, and returns only the translated text — no commentary or explanation is included in the output.
Configuration
- Text to Translate — the source text.
- Translate To — required. The target language, entered as free text (for example
Spanish,French,Japanese) or as a reference to an upstream value such as<start.language>. The language is put into the translation instruction on every run. Leading and trailing spaces are ignored in typed text; a reference is inserted exactly as it resolves, spaces included. The name is passed to the model exactly as written, so spell it the way the model will understand. A run is blocked until this field is filled in. - Model — the LLM used to perform the translation. Optional; leave blank to use your organization's default LLM. If the organization has no default LLM, the run fails with a message pointing to Settings → Platform → Extensions → Models & defaults, where you can choose one.
Inputs and outputs
| Field | Type | Description |
|---|---|---|
context (input) | string | Text to translate. |
targetLanguage (input) | string | Target language. |
content (output) | string | Translated text. |
model (output) | string | Model used to perform the translation. |
tokens (output) | json | Token usage for the translation call. |
Example
Translate a customer support ticket's body into English before routing it to an agent block for triage, then translate the agent's reply back into the customer's original language before sending it. To do this, set Translate To on the second Translate block to a reference to the language you captured earlier, for example <start.language>.