How to Configure Locale Context for Better AI Output
Add per-locale cultural notes so AI translations feel natural for each region — not just grammatically correct.
Locale context is a short note about a specific locale that the AI receives on every translation for that locale. It supplements the general product context with region-specific preferences — formality, idioms, regional vocabulary.
Where to add it
- Open Project Settings (⌘,)
- Click the AI tab
- Scroll to Locale Context
- Click + Add next to the locale you want to configure
Project Settings AI tab showing the Locale Context section with an entry for pt-BR
What to write
Write 1–3 sentences of cultural guidance. Focus on things that distinguish this locale from the generic translation:
Good locale context examples:
pt-BR: "Use informal 'você' form consistently. Prefer Brazilian Portuguese idioms over European Portuguese. Avoid translating brand names or technical terms."ja: "Use polite ます/です form throughout. Avoid katakana loanwords where a natural Japanese term exists. Keep UI text short — Japanese characters are wider."de: "Use formal Sie form for user-facing UI. Compound nouns are acceptable but avoid ambiguous ones. UI text should be concise."ar: "Write right-to-left. Use modern standard Arabic, not dialect. Ensure plural forms cover all six Arabic plural categories."es-ES: "Use vosotros for second person plural (not ustedes). Prefer European Spanish terms over Latin American variants."
When locale presets include context
When you add a locale from the presets list, StringLane pre-fills the locale context with common guidance for that region. Review and edit it — the preset is a starting point, not a complete description of your product's needs.
Effect on translations
Locale context is appended to the system prompt after the product context. It tells the model how to adapt the translation for that specific audience. The context is included every time a key is translated for that locale — for single-key ✨ translation and for bulk runs.
Without locale context: ¡Hola, mundo! (generic Spanish)
With pt-BR locale context: Olá, mundo! (Brazilian Portuguese)
The difference matters most for:
- Formality level (tu vs. vous in French, du vs. Sie in German)
- Regional vocabulary (different words for "cell phone" in Spain vs Mexico vs Brazil)
- Character constraints (Japanese and Chinese are more space-efficient — shorter strings needed)