Skip to content
LATW AI Translation for WPML

Glossary

On this page

Available in LATW AI Translator for WPML PRO.

#What it does

The glossary pins chosen terms to a fixed translation: brand names, product names, industry
vocabulary, anything the AI keeps translating in a way you don’t want. You enter a term once, give
it a translation for each language, and from then on every translation into that language is told
to use your wording.

You’ll find it under AI Translator → Glossary.

#Adding an entry

Click Add Entry and fill in:

  • Term: the word or phrase as it appears in your content.
  • Source Language: the language the term is written in. It defaults to your WPML default
    language.
  • Description: optional. It is a note for you and your team only and is not sent to the
    AI
    .
  • Translations: one field per language. Type the translation the AI should use for that
    language.

A translation field left empty means “no rule for this language”. That language gets nothing
for this term, and the AI translates it however it sees fit. This is the most common surprise, and
it matters most for terms you want to leave untranslated (see below).

You can also move entries in bulk with Import CSV and Export CSV. They use the same format
as the WPML glossary.

#How the glossary reaches the AI

The glossary isn’t applied to the text after translation. It goes into the prompt as an
instruction. When a job is sent from English to German, the plugin collects every entry that has a
German translation and adds a block like this to the prompt:

Glossary (use these exact translations for the listed terms):
Aeropress: Aeropress
cold brew: Kaltextraktion
pour-over: Handfilter

A few things follow from that:

  • The block goes in through the {{glossary}} variable in the translation prompt. The default
    prompt already has it. If you edit the prompt and remove it, the glossary is no longer sent, and
    nothing in the translations tells you so. The settings screen warns you when the variable is
    missing. How the Translation Prompt Works shows where the block sits in the prompt.
  • Only the current language pair is sent. An English → German job gets the German
    translations, not the French ones.
  • Entries also work in reverse. An entry written in English with a German translation is used
    for German → English jobs too, with the pair flipped. If two languages are both linked to a term
    in a third language, the plugin uses that term to connect them.
  • Every matching entry is sent with every job, whether or not the term appears in the text.
    A glossary of a few dozen terms costs next to nothing. A glossary of thousands of terms adds
    tokens to every request, and you pay for those tokens.
  • It is an instruction, not a guarantee. A capable model follows it very reliably, and higher
    Reasoning effort helps. Still, nothing checks the result afterwards. If a term must never be
    wrong, also check it before saving (Checking Translations Before They Are Saved).

#Keeping a term untranslated (“do not translate”)

The glossary has no separate “do not translate” checkbox. To keep a term as it is, enter the
same term as its translation in every language
.

Example: you want the brand name Aeropress to stay Aeropress in German, French and Polish.

Field Value
Term Aeropress
Source Language English
German Aeropress
French Aeropress
Polish Aeropress

The AI then gets Aeropress: Aeropress in the prompt for every one of those languages, which
tells it to leave the term unchanged.

Why fill in every language rather than leaving the fields empty: an empty field sends nothing (see
Adding an entry), so for that language the AI gets no instruction at all and may well translate
or adapt the name. When you add a new language to the site later, open your “do not translate”
entries and fill in the new language too.

To set up many such terms at once, use Import CSV with one row per term and language, where
translated_term is the same as original_term:

"original_language_code","target_language_code","original_term","translated_term","description"
"en","de","Aeropress","Aeropress","Brand name - never translate"
"en","fr","Aeropress","Aeropress","Brand name - never translate"
"en","pl","Aeropress","Aeropress","Brand name - never translate"

For a whole kind of text rather than individual terms (for example “never translate product
codes”), add a sentence to the translation prompt instead. The glossary works term by term.

#When the glossary does not apply

  • No active licence. Your entries stay saved, but they are no longer sent to the AI, and the
    Glossary screen is locked until a licence key is active again.
  • LATW Cloud. A site connected to LATW Cloud translates with the glossary set in its LATW Cloud
    site settings. The local glossary can’t be edited while the site is connected and isn’t used.
    Export CSV still works, and LATW Cloud can import that file.
  • DeepL doesn’t read prompts, but it does honour the glossary: the plugin uploads your entries
    to DeepL as a native glossary, so “do not translate” entries work there too.
  • Google Translate ignores the glossary entirely.

#Developer reference

  • Entries are stored in the {prefix}latwaitrp_glossary table: one row per term with
    target_language_code = 'undefined' (the term and its description), plus one row per
    translation.
  • The text for {{glossary}} is built by the latwaitr_prompt_glossary filter
    ($text, $source_lang, $target_lang). The add-on hooks it to return the block shown above, or
    an empty string when the language pair has no entries.
  • The exact prompt each job sent, glossary included, is stored in the queue row’s request_data
    column. That is the quickest way to check whether a term was actually sent.