Skip to content

Commit 159d481

Browse files
committed
Add AI plugin translations to main project locales
Added comprehensive AI-related translations for both English and Chinese locales. This enables the AI plugin to use main app's i18n directly for seamless language switching. - Added ai.title, ai.subtitle sections - Added ai.settings with all configuration labels - Added ai.button with action labels - Added ai.status for connection states - Added ai.input, ai.option for user inputs - Added ai.welcome for welcome messages - Added ai.provider for provider descriptions - Added ai.message for user feedback messages
1 parent 104bd53 commit 159d481

2 files changed

Lines changed: 126 additions & 0 deletions

File tree

console/atest-ui/src/locales/en.json

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,69 @@
9393
"https": "HTTPS Proxy",
9494
"no": "No Proxy"
9595
},
96+
"ai": {
97+
"title": "AI Assistant",
98+
"subtitle": "Natural language to SQL query generator",
99+
"settings": {
100+
"title": "Settings",
101+
"language": "Language",
102+
"provider": "Provider",
103+
"endpoint": "Endpoint",
104+
"model": "Model",
105+
"apiKey": "API Key",
106+
"temperature": "Temperature",
107+
"maxTokens": "Max Tokens",
108+
"advanced": "Advanced Settings",
109+
"localServices": "Local Services",
110+
"cloudServices": "Cloud Services"
111+
},
112+
"button": {
113+
"generate": "Generate",
114+
"save": "Save",
115+
"reset": "Reset",
116+
"refresh": "Refresh",
117+
"testConnection": "Test Connection",
118+
"configure": "Configure",
119+
"close": "Close"
120+
},
121+
"status": {
122+
"connected": "Connected",
123+
"disconnected": "Disconnected",
124+
"connecting": "Connecting..."
125+
},
126+
"input": {
127+
"placeholder": "Enter your query in natural language..."
128+
},
129+
"option": {
130+
"includeExplanation": "Include explanation"
131+
},
132+
"welcome": {
133+
"title": "Welcome to AI Assistant",
134+
"message": "Configure your AI provider to get started",
135+
"noModels": "No AI models found"
136+
},
137+
"provider": {
138+
"ollama": {
139+
"name": "Ollama",
140+
"description": "Local AI, privacy-first"
141+
},
142+
"openai": {
143+
"name": "OpenAI",
144+
"description": "GPT-4 and more"
145+
},
146+
"deepseek": {
147+
"name": "DeepSeek",
148+
"description": "Powerful reasoning AI"
149+
}
150+
},
151+
"message": {
152+
"configSaved": "Configuration saved successfully",
153+
"configSaveFailed": "Saved locally, backend sync failed",
154+
"connectionSuccess": "Connection successful!",
155+
"connectionFailed": "Connection failed",
156+
"generating": "Generating SQL..."
157+
}
158+
},
96159
"//see http spec": "https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/403",
97160
"httpCode": {
98161
"200": "200 OK",

console/atest-ui/src/locales/zh.json

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,69 @@
8989
"https": "HTTPS 代理",
9090
"no": "跳过代理"
9191
},
92+
"ai": {
93+
"title": "AI 助手",
94+
"subtitle": "自然语言转SQL查询生成器",
95+
"settings": {
96+
"title": "设置",
97+
"language": "语言",
98+
"provider": "提供者",
99+
"endpoint": "端点",
100+
"model": "模型",
101+
"apiKey": "API密钥",
102+
"temperature": "温度",
103+
"maxTokens": "最大令牌数",
104+
"advanced": "高级设置",
105+
"localServices": "本地服务",
106+
"cloudServices": "云服务"
107+
},
108+
"button": {
109+
"generate": "生成",
110+
"save": "保存",
111+
"reset": "重置",
112+
"refresh": "刷新",
113+
"testConnection": "测试连接",
114+
"configure": "配置",
115+
"close": "关闭"
116+
},
117+
"status": {
118+
"connected": "已连接",
119+
"disconnected": "已断开",
120+
"connecting": "连接中..."
121+
},
122+
"input": {
123+
"placeholder": "用自然语言输入您的查询..."
124+
},
125+
"option": {
126+
"includeExplanation": "包含解释"
127+
},
128+
"welcome": {
129+
"title": "欢迎使用AI助手",
130+
"message": "配置您的AI提供者以开始使用",
131+
"noModels": "未检测到AI模型"
132+
},
133+
"provider": {
134+
"ollama": {
135+
"name": "Ollama",
136+
"description": "本地AI,隐私优先"
137+
},
138+
"openai": {
139+
"name": "OpenAI",
140+
"description": "GPT-4等模型"
141+
},
142+
"deepseek": {
143+
"name": "DeepSeek",
144+
"description": "强大的推理AI"
145+
}
146+
},
147+
"message": {
148+
"configSaved": "配置保存成功",
149+
"configSaveFailed": "本地保存成功,后端同步失败",
150+
"connectionSuccess": "连接成功!",
151+
"connectionFailed": "连接失败",
152+
"generating": "生成SQL中..."
153+
}
154+
},
92155
"httpCode": {
93156
"200": "200 成功",
94157
"201": "201 已创建",

0 commit comments

Comments
 (0)