零依赖、编译进二进制。位于 internal/i18n/。
type Locale string // "zh" | "en"
type MsgID int
func Resolve(getenv Env) Locale
func T(loc Locale, id MsgID) string
func Missing(loc Locale) []MsgID
Resolve 优先级:OPENTMD_LANG → LC_ALL → LC_MESSAGES → LANG,无法识别时回退 enMsgID 必须在 zh、en 都有非空译文,且两者文本不同(测试强制)<missing message>,不会 panicopentmd config test:状态含义行(可达 / Key 被拒 / 需要付费 / 模型不存在 / 路径错误 / 限流 / 不可达)opentmd telemetry status/clear:本地仅存提示与清空提示TUI 的回复语言仍由 [tui] language 与 /language 控制;i18n 只负责 CLI 面向人的固定文案,不改变模型行为。
MsgID 常量到 msgCount 之前LocaleEN 与 LocaleZH 两条翻译go test ./internal/i18n 会遍历全部 ID 做穷尽检查