FastGPT i18n Namespace Translation
Treat packages/web/i18n/zh-CN/<namespace>.json as the semantic and structural source of truth. Translate the specified namespace into all sibling locale directories without changing runtime behavior.
Before translating, read both of these references completely:
Workflow
1. Resolve and constrain the scope
- Require explicit namespace names, source files, or
allfrom the user. - Resolve a bare namespace such as
apptopackages/web/i18n/zh-CN/app.json. - Resolve
allto every JSON file directly underpackages/web/i18n/zh-CN/, sorted by filename. - Reject a source outside
zh-CN; ask for the Simplified Chinese source instead. - Discover target locales from sibling directories under
packages/web/i18n/, excludingzh-CN. - Edit only the selected namespace files. Create a missing target namespace file when its locale directory already exists, but never create a new locale.
- Preserve unrelated user changes already present in target files.