Skip to content

feat(i18n): add Russian (ru) locale for desktop app#41677

Open
DrawusMas wants to merge 1 commit into
NousResearch:mainfrom
DrawusMas:add-russian-locale
Open

feat(i18n): add Russian (ru) locale for desktop app#41677
DrawusMas wants to merge 1 commit into
NousResearch:mainfrom
DrawusMas:add-russian-locale

Conversation

@DrawusMas

Copy link
Copy Markdown

Summary

Adds full Russian (ru) locale support to the Hermes Desktop app.

Changes

  • New file: apps/desktop/src/i18n/ru.ts — Complete Russian translation covering ~850 strings across all 29 UI sections
  • Modified: apps/desktop/src/i18n/types.ts — Added 'ru' to the Locale union type
  • Modified: apps/desktop/src/i18n/languages.ts — Added Russian to LOCALE_OPTIONS (name: Русский, englishName: Russian) and LOCALE_ALIASES (ru, ru-ru, ru_ru)
  • Modified: apps/desktop/src/i18n/catalog.ts — Registered ru translation module

Coverage

All UI sections translated:

  • Common, Boot, Notifications, Titlebar, Keybinds, Language
  • Settings (Providers, Gateway, MCP, Model, Sessions, Toolsets)
  • Skills, Agents, Command Center, Messaging (all platforms)
  • Profiles, Cron, Artifacts, Sidebar, Composer
  • Updates, Install, Onboarding, Model Picker, Shell
  • Right Sidebar, Preview, Assistant, Prompts, Desktop, Errors, UI

Testing

npx tsc --noEmit passes with no errors.

Closes #40347

- Add ru.ts with full Russian translation (~850 strings, 29 sections)
- Add 'ru' to Locale type in types.ts
- Add Russian to LOCALE_OPTIONS and LOCALE_ALIASES in languages.ts
- Register ru translation in catalog.ts

Covers all UI sections: common, boot, notifications, titlebar, keybinds,
language, settings, skills, agents, commandCenter, messaging, profiles,
cron, artifacts, sidebar, composer, updates, install, onboarding,
modelPicker, modelVisibility, shell, rightSidebar, preview, assistant,
prompts, desktop, errors, ui.

Related: NousResearch#40347

@tonydwb tonydwb left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review Summary

Verdict: Approved

Pure documentation addition, no code changes. Large locale catalog is appropriate for an i18n data file; no security, naming, or correctness concerns.


Reviewed by Hermes Agent

@alt-glitch alt-glitch added type/feature New feature or request P3 Low — cosmetic, nice to have labels Jun 8, 2026
@Anatoly17

Copy link
Copy Markdown

Hi! I independently submitted a Russian locale PR (#46634, marked as duplicate of this one).

My translation was done on the latest main (commit 6cb88a0, June 14 2026), so it covers new strings added after this PR was opened — particularly in messaging, updates, install, and shell sections. It also has more complete pluralization for Russian (which has 3 plural forms: 1, 2-4, 5+).

If it would help, feel free to cherry-pick any missing strings from my ru.ts:
https://github.com/Anatoly17/hermes-agent/blob/feat/i18n-russian-locale/apps/desktop/src/i18n/ru.ts

Happy to consolidate into this PR if that's preferred. Thanks for the work on this!

@DrMaks22

Copy link
Copy Markdown

Thanks for pushing the Russian Desktop locale work. I audited the current RU Desktop PR cluster and I agree this PR is the right canonical place to consolidate the effort, rather than opening another duplicate PR.

I checked this branch against current origin/main (0bbf325a8) and found one technical blocker plus a few copy-quality items that are worth fixing before merge.

Verification:

  • git merge --no-commit --no-ff pr/41677 applies cleanly on current main.
  • cd apps/desktop && npm run test:ui -- src/i18n/languages.test.ts src/i18n/runtime.test.ts src/i18n/context.test.tsx src/components/language-switcher.test.tsx passes (4 files, 22 tests).
  • cd apps/desktop && npm run typecheck currently fails because ru.ts is stale against the current en.ts: there are missing keys such as notifications.native, settings.nav.notifications, profiles.cloneFrom*, updates.*Backend, shell.statusbar.backendVersion/clientLabel/backendLabel/showTerminal/hideTerminal, plus a few keys that no longer exist such as composer.editQueued, rightSidebar.terminalFocus, assistant.thread.editableCheckpoint, and onboarding.shortcut.

Suggested technical path:

  • Either fully sync ru.ts with the current en.ts, or switch ru.ts to the existing defineLocale() partial-locale pattern so missing Desktop-only strings safely fall back to English.
  • Keep tests behavior-based: locale registration, aliases (ru, ru-RU, ru_ru), display.language persistence, and fallback behavior. Avoid tests that pin exact Russian wording.
  • Use proper Russian plural rules, including the 11-14 exception; count < 5 will produce incorrect forms for values like 11, 12, 13, 14.

Suggested Russian copy polish before merge:

  • Prefer Hermes Desktop as the product name instead of translating it to рабочий стол in errors/status text.
  • Avoid visible calques such as компоновщик, поповер, сырые данные, не поднялся, and Снимите HERMES_DESKTOP_REMOTE_URL....
  • Better wording examples: всплывающая панель instead of поповер, необработанные данные instead of сырые данные, не запустился instead of не поднялся, and Удалите из окружения HERMES_DESKTOP_REMOTE_URL... instead of Снимите....
  • Keep commands, env vars, paths, IDs, MCP, OAuth, localhost, etc. unchanged.

Happy to help with a native Russian technical editorial pass or provide a focused patch if you or the maintainers want to consolidate the branch here.

@Anatoly17

Copy link
Copy Markdown

@DrMaks22 The missing keys you identified (notifications.native, shell.statusbar, etc.) are all present in my translation (#46634), since it was done against the current main (commit 6cb88a0, June 14 2026) — after those sections were added to en.ts.

It also uses defineLocale() throughout, so any future keys added to en.ts will automatically fall back to English without breaking the build.

If it helps move things forward, the up-to-date ru.ts is here:
https://github.com/Anatoly17/hermes-agent/blob/feat/i18n-russian-locale/apps/desktop/src/i18n/ru.ts

Happy to open a fresh PR based on this file if that's easier than rebasing #41677.

@DrMaks22

DrMaks22 commented Jul 9, 2026

Copy link
Copy Markdown

Rechecked the current RU Desktop localization cluster and kept this path duplicate-free: instead of opening another upstream PR, I prepared a focused helper patch against this canonical branch:

DrawusMas#1

What the helper patch does:

  • adds proper Russian plural handling, including the 11-14 exception;
  • polishes visible calques such as компоновщик, системный промпт, and prompt-as-промпт in user-facing UI copy;
  • tightens the Tool Call Display wording (Удобный / Технический) and raw-data terminology;
  • keeps commands, env vars, product names, and technical identifiers unchanged.

Verification on the helper branch:

  • git diff --check -> clean
  • npm run type-check --workspace apps/desktop -> passes
  • npm run test:ui --workspace apps/desktop -- src/i18n/languages.test.ts src/i18n/runtime.test.ts src/i18n/context.test.tsx src/components/language-switcher.test.tsx -> 4 files / 22 tests passed

If the author/maintainers still want #41677 to remain the canonical focused RU Desktop PR, this helper should be safe to merge into the branch for a stronger native Russian technical pass.

@Anatoly17

Copy link
Copy Markdown

Thanks for the review and the plural-handling patch — good catch on the 11–14 exception.

I've refreshed #46634: rebased onto current main, added proper Russian pluralization (shared pluralRu/countRu helper covering the 11–14 case), fixed several count strings that weren't declining correctly, and reconciled the locale with the keys that main has since renamed/removed. typecheck passes and the i18n suite (languages/runtime/context) is green.

Since both #41677 and #46634 cover the same ground, it'd be cleanest to land one. #46634 is now fully current against main and test-clean — happy to have it be the canonical RU Desktop PR, or to fold my plural/terminology work into whichever branch the maintainers prefer. Let me know which way you'd like to consolidate.

@DrMaks22

DrMaks22 commented Jul 9, 2026

Copy link
Copy Markdown

Thanks, @Anatoly17. I rechecked the refreshed #46634 at b23a07f17 locally.

Verification on the refreshed branch:

  • npm run typecheck --workspace apps/desktop -> passes
  • npm run test:ui --workspace apps/desktop -- src/i18n/languages.test.ts src/i18n/runtime.test.ts src/i18n/context.test.tsx src/components/language-switcher.test.tsx -> 4 files / 22 tests passed
  • git diff --check -> clean

I agree that only one RU Desktop PR should land. Since #46634 is now current-main, defineLocale()-based, and test-clean, it is a strong candidate if maintainers are comfortable superseding the earlier duplicate triage. I also opened a tiny helper patch for the remaining Russian wording polish:

Anatoly17#1

That patch only touches user-facing RU copy (сырые данные, системный промпт, prompt-as-промпт, a couple of Desktop labels) and keeps commands/env vars/product names unchanged.

From my side, either consolidation route is fine: land #46634 with that small polish, or fold the same current-main/plural/editorial work back into #41677. The important thing is to keep one focused, test-clean RU Desktop PR rather than adding another duplicate.

@Anatoly17

Copy link
Copy Markdown

Merged your polish patch into #46634Anatoly17#1 (501fdeb76). The RU wording pass is now in: prompt-as-запрос, системная инструкция, необработанные данные, the Hermes Desktop labels, and слэш-команда.

Rechecked on the merged branch:

  • npm run typecheck --workspace apps/desktop → passes
  • npm run test:ui --workspace apps/desktop -- src/i18n/languages.test.ts src/i18n/runtime.test.ts src/i18n/context.test.tsx src/components/language-switcher.test.tsx → 4 files / 22 tests passed

So #46634 now carries the current-main rebase, the shared plural helper, and your editorial polish — one focused, test-clean RU Desktop PR. Thanks for the review and the collaboration, @DrMaks22.

Over to the maintainers on which PR to land — happy for #46634 to be the canonical RU Desktop PR, and equally fine to fold the same commits into #41677 if that's preferred. Either way, one PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P3 Low — cosmetic, nice to have type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

🇷🇺 Russian locale for Desktop app — installer available

5 participants