NEW 4-5 - AI Localization
AI Localization
Overview
The AI Localization panel translates every FText in your project into any language, using whichever AI provider Yarin is signed into: ChatGPT (Codex) or Claude.
It drives Unreal's own localization pipeline from a single window — gather, export, translate, import, compile — so you never open the Localization Dashboard or run a commandlet by hand. The output is a standard PO file and a standard compiled .locres: nothing proprietary, nothing you can't edit later by hand or hand over to a human translator.
Out of the box, you get:
One button that runs the whole chain: gather → export → translate → import → compile
Translation of the missing strings only, or of everything with Overwrite
Placeholder protection: a line that would lose a
{0}, a{PlayerName}or a<tag>is rejected and kept in the source language instead of shipping brokenEverything stored as
FTextis covered — dialogues, quests, items, abilities, subtitles, UILive activity log, per-batch progress, and Cancel at any time
Blueprint nodes to switch language at runtime and a settings list for your options menu
No magic, no black boxes. The panel only writes into your localization target: every intermediate file stays on disk for you to inspect.
Requirements
1. The module
AscentLocalizationEditor ships with ACF Ultimate and is editor only. Nothing is added to your packaged game: the translations are, the tool is not.
2. Yarin signed in
The panel checks the provider when it opens. The status line under the title tells you where you stand:
Yarin ChatGPT and Claude: ready <- green, you can translate
Yarin is not connected. Open Yarin and sign in. <- orange, nothing will runThere is no API key field: the panel borrows the session Yarin is already using.
3. A localization target
You need at least one Game localization target with its native culture set (the language your FText is actually written in). If you have never created one: Tools > Localization Dashboard > Add New Target, set the native culture, and come back. The panel lists game targets only.
Configuration
1. Open the panel
Either:
Tools > Yarin > AI Localization
the globe button in the Play toolbar, right after the Yarin button
Window > Tools > Yarin AI Localization
2. Pick the localization target
Choose it in the Localization target combo. Refresh re-reads the targets and re-checks the provider — use it if you just created a target.
3. Tell it which folders to scan
In Asset folders to scan, type a project-relative folder and press Add:
Content/MyGame/
Content/MyGame/Dialogues/This writes into the target's Gather from Packages include wildcards and switches package gathering on, so it is the same setting the Localization Dashboard uses — you are not building a parallel configuration.
Add the folders that actually hold your text assets. Scanning all of Content/ works but is slow, because the gather loads every package it is pointed at.
4. Enter the culture code
In Culture code, use an IETF tag:
fr de ja it pt-BR zh-HansIf that culture is not on the target yet, the panel adds it for you. You do not need to prepare it in the dashboard.
5. Decide about existing translations
Leave Overwrite existing translations off to translate only what has no translation yet — the normal case when you add new dialogue to a language you already shipped.
Turn it on to retranslate every string, including the ones already translated. That is also the way to retry lines that were skipped on a previous run.
6. Press Translate
Leave the editor open and the panel visible. The status line walks through the real steps:
WORKING — searching texts... <- the gather commandlet, the slow part
WORKING — writing the text file... <- export of the native PO
WORKING — Reading the exported text file...
WORKING — N strings to send to Yarin. M already translated and skipped.
WORKING — Waiting for Yarin. Batch 3 of 12. Strings 120 / 460...
WORKING — Writing translations, importing, and compiling the culture...
Done. Translated 437 strings, skipped 23. Culture: itStrings go out in batches of 40. Cancel stops the job after the batch currently in flight — it never leaves a half-written PO.
7. Check the files
The run leaves standard Unreal files behind:
Content/Localization/<Target>/<native>/<Target>.po <- source text, exported by the gather
Content/Localization/<Target>/<culture>/<Target>.po <- the translation
Content/Localization/<Target>/<culture>/<Target>.locres <- compiled, this is what the game loadsOpen the culture PO in any text editor or PO tool. If you want a human pass over the AI output, this is the file to send out, and re-importing it from the dashboard is enough.
8. See it in the editor
Call Set Game Language with your culture code, or use the engine's game localization preview.
In the editor the two are the same thing: PIE shares the editor process, so the system switches only the game's text and leaves the editor UI in your own language. The preview is re-applied on every PIE start, so the choice sticks between runs.
9. Put the language in your options menu
The settings menu does not read your localization targets: it reads an explicit list, so you decide what the player is offered.
Project Settings > Ascent UI Settings > Localization > Game Languages — a map of culture code to display name:
en -> English
it -> Italiano
fr -> <- leave empty to use the culture's own native nameThen build the menu with these nodes:
Get Available Game Languages — the codes you configured above, sorted
Get Language Display Name — what to print in the combo
Set Game Language (
CultureCode,bSave) — switches immediately; withbSaveon, the choice is written toGameUserSettings.iniand the next launch starts in that languageGet Game Language — the current one, to preselect the entry
On Game Language Changed — fires after a successful switch, for any widget that has to rebuild itself
Invalid culture codes in the map are ignored, so a typo costs you a missing entry, not a crash.
10. Package it
Two project settings decide whether the translation reaches the player:
Project Settings > Packaging > Localizations to Package must include the culture
the target's localization path must be listed in the game's localization paths
In DefaultGame.ini that is:
[/Script/UnrealEd.ProjectPackagingSettings]
+CulturesToStage=en
+CulturesToStage=it
[Internationalization]
+LocalizationPaths=%GAMEDIR%Content/Localization/MyTargetA language that works in PIE and disappears in the packaged build is almost always a missing CulturesToStage.
How it works
Worth knowing, because it explains the timings and the skipped lines:
The gather is Unreal's, not ours. The panel launches the engine's gather commandlet as a separate process and streams its output into the activity log. On a large project this step takes minutes and is entirely disk and package-load bound — the AI has not been called yet.
Only missing entries are sent. The native PO and the culture PO are compared first; already translated entries are counted as skipped before a single request goes out.
Batches of 40. Each batch is one request, with the target language's English name in the system prompt. A batch that fails does not kill the job: those 40 lines are marked skipped, the reason is logged, and the run continues.
Placeholders are verified after the fact. Every translation is checked against its source for the same placeholders and tags. A translation that drops or renames one is refused and the line stays in the source language — a visibly untranslated string is a bug you can see, a broken
{0}is a crash in a release build.Import and compile are the engine's tasks too, so the result is byte-compatible with a translation produced by hand.
Troubleshooting
Status line is orange, Translate does nothing. Yarin is not signed in. Open Yarin, sign in with ChatGPT or Claude, then press Refresh in the panel.
"Writing the source text file failed. File missing: ..." The gather produced no text: the folders in Asset folders to scan contain no gatherable
FText. Check the paths — they are project-relative (Content/...), not content-browser paths (/Game/...)."Nothing to translate. All strings already have translations." Expected when you re-run on an untouched target. Use Overwrite to force a new pass.
Many strings skipped. Read the activity log:
Already translatedis normal, a placeholder reason means the model broke a token on that line. Re-run with Overwrite to retry.A string is never picked up. It is probably an
FString, not anFText. OnlyFTextis gathered — this is an engine rule, not a tool limitation. Culture-invariant text (INVTEXT, or text built at runtime withFText::FromString) is invisible to the gather as well.Editor UI switched language too. That only happens outside PIE. In PIE the game preview is used and the editor keeps its own language.
Translations work in the editor, not in the build. See step 10:
CulturesToStageand the localization path.