Language
Tool descriptions, tool answers, CLI output, logs, diagnostics, the preview interface and this site are served in Russian or English.
Resolution order
The first valid value wins; the default is en:
- the
--lang ru|enCLI flag; VUE_CODEBASE_VIEW_MCP_LANG(view server only);VUE_CODEBASE_MCP_LANG;- the
languagefield of.vue-codebase-mcp.json.
The OS locale is deliberately not inspected: the server must behave the same on every machine. Both servers read one configuration and resolve the language through one shared chain, so they always answer in the same language.
npx vue-codebase-mcp index --root . --lang ru
VUE_CODEBASE_VIEW_MCP_LANG=ru npx vue-codebase-view-mcp preview --root .The same command in two languages, real output on playground/ui-library:
npx vue-codebase-mcp index --root playground/ui-library --mode full --lang enIndex built (full) in 500 ms
components: 7
composables: 2
stores: 0
routes: 0
utils: 3
documents: 10
snapshot: <repo>/playground/ui-library/.vue-codebase-mcp.cache/index.jsonnpx vue-codebase-mcp index --root playground/ui-library --mode full --lang ruИндекс построен (full) за 474 мс
компоненты: 7
composables: 2
stores: 0
маршруты: 0
утилиты: 3
документы: 10
снимок: <repo>/playground/ui-library/.vue-codebase-mcp.cache/index.jsonNote the pluralisation (7 components / 7 компонентов, 3 utils / 3 утилиты) and that counters, the mode name and file paths stay as they are — only the server's own prose is translated.
Diagnostics are codes, not strings
Internally nothing stores rendered messages: a diagnostic is { code, params } (index.parseError, entity.propsExternalType, preview.notRunning, …). The string is born at the boundary — when a tool answer, a CLI message or the preview manifest is produced. Consequences:
- the index snapshot stays language-neutral — switching the language never forces a re-index;
- one code renders correctly in every language, and the ru/en dictionaries are kept in parity by a test;
en.tsis the source of truth for the dictionary shape:ru.tsis typed asMessages, so a missing key fails compilation.
The view interface receives its strings pre-rendered: the server puts the whole localized dictionary into the manifest, and the browser never imports the dictionaries itself.
Search works in both languages
Regardless of the interface language, search understands Russian queries through a built-in synonym dictionary with word-form awareness:
- «кнопка» finds
UiButton(dictionary concept match); - word forms are matched by a common prefix of at least four characters — «кнопкой» → «кнопка», but not «около» → «окно»;
- extend the dictionary via
search.synonymsorsearch.synonymsFile; switch it off withsearch.useDefaultSynonyms: false.
A real call against playground/ui-library, which has no search.synonyms configured at all:
{ "name": "search", "arguments": { "query": "кнопка" } }## Index matches (1)
- **UiButton** · component · `src/components/ui-button/ui/UiButton.vue` (stable)
Базовая кнопка дизайн-системы: варианты, размеры, состояние загрузки.
match: synonym (name): "button", name: "button"Every search result carries the reason it matched (up to four signals), so the model sees what the result actually hung on. See About the Project for the scoring table.
What is not translated
Everything the servers produce comes from one dictionary: tool names and descriptions, tool answers, diagnostics with their codes, search match reasons, CLI output and help, the logs of both packages, the preview interface (its strings travel inside the manifest), and this site.
[vue-codebase-mcp] info: Loaded index snapshot from 2026-11-21T17:47:58.839Z: 12 entities, 10 documents
[vue-codebase-view-mcp] info: Starting preview for ui-library (/…/playground/ui-library)Match reasons are localized the same way diagnostics are: the ranking engine returns { code, params } (synonymName, nameToken, category, …) and the string is assembled on the way out, so --lang en gives match: exact name, category and --lang ru gives совпадение: точное имя, категория.
The one thing that is never translated is the text of your own code: component descriptions, prop and slot descriptions, markdown documentation. The server copies it verbatim, because replacing your wording with a machine translation would be worse than leaving it alone. A component documented in Russian therefore stays Russian under --lang en — see What is MCP → A live example.
Pluralisation
Counts are pluralised per language through pluralFor (1 component / 2 компонента / 5 компонентов). The rules live in the indexer and are reused by the view server — one implementation, two servers.