i18n-guide — Claude Code rule for response language
The i18n-guide rule sets how agents choose a response language and which project text gets localized. It fits workflows that need consistent language handling across user-facing output and code.
MIT ★ 1,472 updated 2026-10-29
/plugin marketplace add first-fluke/oh-my-agent
/plugin install oma@oh-my-agentWhat i18n-guide does
The rule checks the language of the user’s prompt first, then the language value in .agents/oma-config.yaml; when neither determines a language, it uses English. The translation_voice setting controls the style of translated user-facing content. For translation work, workflows are directed to the oma-translator skill. The rule is marked to apply automatically.
User-facing explanations, errors and progress reports are localized, while code, configuration keys and CLAUDE.md or SKILL.md content stay in English. When a project has packages/i18n/, ARB files are the source for UI strings. After changing them, run dart run build_runner build from that directory; otherwise generated localization code will not reflect the edits.
What it helps with
- choose a response language from the prompt or project settings
- set the tone for translated user-facing content
- keep code and system identifiers in English
- update ARB strings and regenerate localization code
- write subagent result files in the user's language
Example prompts for the agent
- Reply in the language of my request and keep technical terms unchanged.
- Translate these user-facing messages using the tone configured in
.agents/oma-config.yaml. - Update the UI text in its ARB file, then rebuild localization code in
packages/i18n/.
How to install i18n-guide
1Plugin marketplace
/plugin marketplace add first-fluke/oh-my-agent/plugin install oma@oh-my-agent2Manually: put the files in place
.claude/rules/i18n-guide.mdThe paths frontmatter field limits the files
AGENTS.md
Codex reads AGENTS.md: paste the rule text there
Manually: put the files in place
.cursor/rules/i18n-guide.mdcFrontmatter: description, globs, alwaysApply
Manually: put the files in place
.github/instructions/i18n-guide.instructions.mdThe applyTo field sets which files it applies to
Manually: put the files in place
.devin/rules/i18n-guide.mdManually: put the files in place
.clinerules/i18n-guide.mdStep by step, with commands for each platform: AGENTS.md vs CLAUDE.md: what they are and which one to use
Questions about i18n-guide
How do I install i18n-guide in Claude Code?
Run /plugin marketplace add first-fluke/oh-my-agent, followed by /plugin install oma@oh-my-agent. The rule file is listed at .claude/rules/i18n-guide.md.
What does i18n-guide do?
It defines how agents select response language, handle translation tone and distinguish localized content from English identifiers. It also sets rules for ARB-based UI strings and subagent communication.
What does the rule require when packages/i18n/ exists?
Use ARB files as the source for user-visible strings. After editing them, run dart run build_runner build inside packages/i18n/ to regenerate localization code.
Source text
i18n-guide.md · MIT
---
description: Response language rules for agents and workflows
globs:
alwaysApply: true
---
# i18n Guide — Response Language Rules
Rules for determining and applying response language across agents and workflows.
## Language Resolution
Response language is determined by the following priority:
1. **User prompt language** — if the user writes in a specific language, respond in that language
2. **`oma-config.yaml`** — `language` field in `.agents/oma-config.yaml`
3. **Fallback** — English (en) if neither of the above is set
```yaml
# .agents/oma-config.yaml
language: ko # ko, en, ja, zh, ...
```
## Translation Voice
When translating user-facing content, the `translation_voice` field in `.agents/oma-config.yaml` controls global rhythm and formality. It is applied on top of `oma-translator` content-type persona routing.
| Value | Effect |
|---|---|
| `formal` | strict complete sentences, no fragments, formal register only |
| `balanced` (default) | content-type defaults — fragments only in label/cell positions |
| `interpreter` | punchy, audience-first, spoken cadence; fragments allowed when natural |
Workflows that translate user-facing content should respect this setting via the `oma-translator` skill rather than hardcoding a tone.
## What to Localize
| Category | Localize? | Example |
|----------|-----------|---------|
| Natural language responses | Yes | User-facing explanations and descriptions |
| Error messages (user-facing) | Yes | Authentication failure messages |
| Status updates / progress reports | Yes | "Phase 2 complete, starting Phase 3" |
| Charter Preflight output | Yes | Descriptive text localized, keywords stay in English |
| Result files (result-*.md) | Yes | User-readable text |
## What Stays in English
| Category | Why | Example |
|----------|-----|---------|
| Code (variables, functions, classes) | Codebase consistency | `getUserProfile()` |
| Git commit messages | Conventional commits standard | `feat: add user auth` |
| PR titles/body | GitHub collaboration standard | `fix: resolve race condition` |
| Technical / domain terms | Meaning loss when translated | API, JWT, middleware, scaffold |
| File paths / config keys | System identifiers | `.agents/config/` |
| Log levels / status keywords | Parsing compatibility | `Status: completed`, `BLOCKED` |
| CLAUDE.md / SKILL.md content | System prompts | Keep English originals |
## Mixed-Language Rules
1. **Keep technical terms in original language** — don't force-translate
- Good: "Validates the JWT token"
- Bad: "Validates the JSON Web Token"
2. **Code blocks are always in English** — including comments
3. **Inline code (`backtick`) is never translated**
4. **Parenthetical supplement allowed** — for unfamiliar terms, use `translated(original)` format once
5. **Register consistency** — match the target language's appropriate register for the context
6. **Translation tasks** — for translating UI strings, docs, or marketing copy, use the `/oma-translator` skill
## Workflow Integration
All workflows follow these rules. The following line in existing workflows references this guide:
```
- **Response language follows `language` setting in `.agents/oma-config.yaml` if configured.**
```
## ARB-Based Localization (`packages/i18n/`)
If `packages/i18n/` exists in the project, ARB files are the **single source of truth** for all user-facing strings.
1. **Never hardcode UI strings** — all user-visible text must come from ARB files (`*.arb`)
2. **Edit ARB first** — when adding or changing UI text, update the ARB file, then run the build in `packages/i18n/`
3. **Build after changes** — run `dart run build_runner build` (or equivalent) inside `packages/i18n/` to regenerate localization code
4. **Base locale** — the primary ARB file (e.g., `app_en.arb`) is the reference; other locales derive from it
5. **Key naming** — use `camelCase` keys describing the purpose, not the content: `loginButton` not `clickHere`
6. **Placeholders** — use ICU message syntax for interpolation: `"greeting": "Hello, {name}!"`
7. **Do not translate keys** — ARB keys are identifiers, always in English
## Subagent Behavior
- Subagent **result files** (`result-*.md`) are written in the user's language
- **Internal communication** between subagents (charter, status keywords) stays in English
- Agent definition files (`.agents/agents/*.md`) stay in English
© First Fluke · MIT · first-fluke/oh-my-agent