Spaces:
Running
Running
Upload 29 files
Browse files- index.html +37 -36
- kimi-js/kimi-module.js +29 -6
- kimi-locale/de.json +7 -1
- kimi-locale/en.json +7 -1
- kimi-locale/es.json +7 -1
- kimi-locale/fr.json +7 -1
- kimi-locale/it.json +7 -1
- kimi-locale/ja.json +7 -1
- kimi-locale/zh.json +7 -1
index.html
CHANGED
|
@@ -174,10 +174,10 @@
|
|
| 174 |
</div>
|
| 175 |
|
| 176 |
<div class="settings-tabs">
|
| 177 |
-
<button class="settings-tab" data-tab="voice">
|
| 178 |
<i class="fas fa-microphone"></i> <span data-i18n="tab_voice">Language & Voice</span>
|
| 179 |
</button>
|
| 180 |
-
<button class="settings-tab
|
| 181 |
<i class="fas fa-robot"></i> <span data-i18n="tab_llm">API & Models</span>
|
| 182 |
</button>
|
| 183 |
<button class="settings-tab" data-tab="personality">
|
|
@@ -200,6 +200,40 @@
|
|
| 200 |
<h3><i class="fas fa-volume-up"></i> <span data-i18n="voice_settings">Voice Settings</span></h3>
|
| 201 |
|
| 202 |
<div class="config-row">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 203 |
<label class="config-label" data-i18n="speech_rate" for="voice-rate">Speech Rate</label>
|
| 204 |
<div class="config-control">
|
| 205 |
<div class="slider-container">
|
|
@@ -234,40 +268,7 @@
|
|
| 234 |
</div>
|
| 235 |
</div>
|
| 236 |
</div>
|
| 237 |
-
|
| 238 |
-
<div class="config-row">
|
| 239 |
-
<label class="config-label" data-i18n="language">Language</label>
|
| 240 |
-
<div class="config-control">
|
| 241 |
-
<select class="kimi-select" id="language-selection" aria-label="Language">
|
| 242 |
-
<option value="en" data-i18n="language_english">English</option>
|
| 243 |
-
<option value="fr" data-i18n="language_french">French</option>
|
| 244 |
-
<option value="es" data-i18n="language_spanish">Spanish</option>
|
| 245 |
-
<option value="de" data-i18n="language_german">German</option>
|
| 246 |
-
<option value="it" data-i18n="language_italian">Italian</option>
|
| 247 |
-
<option value="ja" data-i18n="language_japanese">Japanese</option>
|
| 248 |
-
<option value="zh" data-i18n="language_chinese">Chinese</option>
|
| 249 |
-
</select>
|
| 250 |
-
</div>
|
| 251 |
-
</div>
|
| 252 |
-
|
| 253 |
-
<div class="config-row">
|
| 254 |
-
<label class="config-label" data-i18n="preferred_voice">Preferred Voice</label>
|
| 255 |
-
<div class="config-control">
|
| 256 |
-
<select class="kimi-select" id="voice-selection" aria-label="Preferred Voice">
|
| 257 |
-
<option value="auto" data-i18n="automatic">Automatic</option>
|
| 258 |
-
</select>
|
| 259 |
-
</div>
|
| 260 |
-
</div>
|
| 261 |
-
|
| 262 |
-
<div class="config-row">
|
| 263 |
-
<label class="config-label" data-i18n="voice_test_label">Voice Test</label>
|
| 264 |
-
<div class="config-control">
|
| 265 |
-
<button class="kimi-button" id="test-voice" aria-label="Voice Test">
|
| 266 |
-
<i class="fas fa-play"></i> <span data-i18n="voice_test_button">Test the
|
| 267 |
-
Voice</span>
|
| 268 |
-
</button>
|
| 269 |
-
</div>
|
| 270 |
-
</div>
|
| 271 |
</div>
|
| 272 |
</div>
|
| 273 |
<!-- Personality Tab -->
|
|
|
|
| 174 |
</div>
|
| 175 |
|
| 176 |
<div class="settings-tabs">
|
| 177 |
+
<button class="settings-tab active" data-tab="voice">
|
| 178 |
<i class="fas fa-microphone"></i> <span data-i18n="tab_voice">Language & Voice</span>
|
| 179 |
</button>
|
| 180 |
+
<button class="settings-tab" data-tab="llm">
|
| 181 |
<i class="fas fa-robot"></i> <span data-i18n="tab_llm">API & Models</span>
|
| 182 |
</button>
|
| 183 |
<button class="settings-tab" data-tab="personality">
|
|
|
|
| 200 |
<h3><i class="fas fa-volume-up"></i> <span data-i18n="voice_settings">Voice Settings</span></h3>
|
| 201 |
|
| 202 |
<div class="config-row">
|
| 203 |
+
<label class="config-label" data-i18n="language">Language</label>
|
| 204 |
+
<div class="config-control">
|
| 205 |
+
<select class="kimi-select" id="language-selection" aria-label="Language">
|
| 206 |
+
<option value="en" data-i18n="language_english">English</option>
|
| 207 |
+
<option value="fr" data-i18n="language_french">French</option>
|
| 208 |
+
<option value="es" data-i18n="language_spanish">Spanish</option>
|
| 209 |
+
<option value="de" data-i18n="language_german">German</option>
|
| 210 |
+
<option value="it" data-i18n="language_italian">Italian</option>
|
| 211 |
+
<option value="ja" data-i18n="language_japanese">Japanese</option>
|
| 212 |
+
<option value="zh" data-i18n="language_chinese">Chinese</option>
|
| 213 |
+
</select>
|
| 214 |
+
</div>
|
| 215 |
+
</div>
|
| 216 |
+
|
| 217 |
+
<div class="config-row">
|
| 218 |
+
<label class="config-label" data-i18n="preferred_voice">Preferred Voice</label>
|
| 219 |
+
<div class="config-control">
|
| 220 |
+
<select class="kimi-select" id="voice-selection" aria-label="Preferred Voice">
|
| 221 |
+
<option value="auto" data-i18n="automatic">Automatic</option>
|
| 222 |
+
</select>
|
| 223 |
+
</div>
|
| 224 |
+
</div>
|
| 225 |
+
|
| 226 |
+
<div class="config-row">
|
| 227 |
+
<label class="config-label" data-i18n="voice_test_label">Voice Test</label>
|
| 228 |
+
<div class="config-control">
|
| 229 |
+
<button class="kimi-button" id="test-voice" aria-label="Voice Test">
|
| 230 |
+
<i class="fas fa-play"></i> <span data-i18n="voice_test_button">Test the
|
| 231 |
+
Voice</span>
|
| 232 |
+
</button>
|
| 233 |
+
</div>
|
| 234 |
+
</div>
|
| 235 |
+
|
| 236 |
+
<div class="config-row">
|
| 237 |
<label class="config-label" data-i18n="speech_rate" for="voice-rate">Speech Rate</label>
|
| 238 |
<div class="config-control">
|
| 239 |
<div class="slider-container">
|
|
|
|
| 268 |
</div>
|
| 269 |
</div>
|
| 270 |
</div>
|
| 271 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 272 |
</div>
|
| 273 |
</div>
|
| 274 |
<!-- Personality Tab -->
|
kimi-js/kimi-module.js
CHANGED
|
@@ -1228,7 +1228,12 @@ async function loadAvailableModels() {
|
|
| 1228 |
searchInput.type = "text";
|
| 1229 |
searchInput.className = "kimi-input";
|
| 1230 |
searchInput.id = "models-search";
|
| 1231 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1232 |
searchWrap.appendChild(searchInput);
|
| 1233 |
modelsContainer.appendChild(searchWrap);
|
| 1234 |
if (typeof loadAvailableModels._searchValue === "string") {
|
|
@@ -1240,7 +1245,8 @@ async function loadAvailableModels() {
|
|
| 1240 |
recSection.className = "models-section recommended-models";
|
| 1241 |
const title = document.createElement("div");
|
| 1242 |
title.className = "models-section-title";
|
| 1243 |
-
|
|
|
|
| 1244 |
recSection.appendChild(title);
|
| 1245 |
const list = document.createElement("div");
|
| 1246 |
list.className = "models-list";
|
|
@@ -1260,16 +1266,27 @@ async function loadAvailableModels() {
|
|
| 1260 |
toggleBtn.type = "button";
|
| 1261 |
toggleBtn.className = "kimi-button";
|
| 1262 |
toggleBtn.style.marginLeft = "8px";
|
| 1263 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1264 |
const label = document.createElement("span");
|
| 1265 |
-
label.
|
| 1266 |
header.appendChild(label);
|
| 1267 |
header.appendChild(toggleBtn);
|
| 1268 |
const refreshBtn = document.createElement("button");
|
| 1269 |
refreshBtn.type = "button";
|
| 1270 |
refreshBtn.className = "kimi-button";
|
| 1271 |
refreshBtn.style.marginLeft = "8px";
|
| 1272 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1273 |
refreshBtn.addEventListener("click", async () => {
|
| 1274 |
try {
|
| 1275 |
refreshBtn.disabled = true;
|
|
@@ -1302,7 +1319,13 @@ async function loadAvailableModels() {
|
|
| 1302 |
const nowCollapsed = list.style.display !== "none";
|
| 1303 |
list.style.display = nowCollapsed ? "none" : "block";
|
| 1304 |
loadAvailableModels._allCollapsed = nowCollapsed;
|
| 1305 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1306 |
});
|
| 1307 |
allSection.appendChild(header);
|
| 1308 |
allSection.appendChild(list);
|
|
|
|
| 1228 |
searchInput.type = "text";
|
| 1229 |
searchInput.className = "kimi-input";
|
| 1230 |
searchInput.id = "models-search";
|
| 1231 |
+
// use i18n placeholder key
|
| 1232 |
+
if (window.kimiI18nManager && typeof window.kimiI18nManager.t === "function") {
|
| 1233 |
+
searchInput.setAttribute("data-i18n-placeholder", "models_search_placeholder");
|
| 1234 |
+
} else {
|
| 1235 |
+
searchInput.placeholder = "Filter models...";
|
| 1236 |
+
}
|
| 1237 |
searchWrap.appendChild(searchInput);
|
| 1238 |
modelsContainer.appendChild(searchWrap);
|
| 1239 |
if (typeof loadAvailableModels._searchValue === "string") {
|
|
|
|
| 1245 |
recSection.className = "models-section recommended-models";
|
| 1246 |
const title = document.createElement("div");
|
| 1247 |
title.className = "models-section-title";
|
| 1248 |
+
// i18n aware title
|
| 1249 |
+
title.setAttribute("data-i18n", "models_recommended_title");
|
| 1250 |
recSection.appendChild(title);
|
| 1251 |
const list = document.createElement("div");
|
| 1252 |
list.className = "models-list";
|
|
|
|
| 1266 |
toggleBtn.type = "button";
|
| 1267 |
toggleBtn.className = "kimi-button";
|
| 1268 |
toggleBtn.style.marginLeft = "8px";
|
| 1269 |
+
// toggle show/hide label via i18n when available
|
| 1270 |
+
if (window.kimiI18nManager && typeof window.kimiI18nManager.t === "function") {
|
| 1271 |
+
const currentKey = loadAvailableModels._allCollapsed === false ? "button_hide" : "button_show";
|
| 1272 |
+
toggleBtn.setAttribute("data-i18n", currentKey);
|
| 1273 |
+
toggleBtn.textContent = window.kimiI18nManager.t(currentKey);
|
| 1274 |
+
} else {
|
| 1275 |
+
toggleBtn.textContent = loadAvailableModels._allCollapsed === false ? "Hide" : "Show";
|
| 1276 |
+
}
|
| 1277 |
const label = document.createElement("span");
|
| 1278 |
+
label.setAttribute("data-i18n", "models_all_title");
|
| 1279 |
header.appendChild(label);
|
| 1280 |
header.appendChild(toggleBtn);
|
| 1281 |
const refreshBtn = document.createElement("button");
|
| 1282 |
refreshBtn.type = "button";
|
| 1283 |
refreshBtn.className = "kimi-button";
|
| 1284 |
refreshBtn.style.marginLeft = "8px";
|
| 1285 |
+
if (window.kimiI18nManager && typeof window.kimiI18nManager.t === "function") {
|
| 1286 |
+
refreshBtn.setAttribute("data-i18n", "button_refresh");
|
| 1287 |
+
} else {
|
| 1288 |
+
refreshBtn.textContent = "Refresh";
|
| 1289 |
+
}
|
| 1290 |
refreshBtn.addEventListener("click", async () => {
|
| 1291 |
try {
|
| 1292 |
refreshBtn.disabled = true;
|
|
|
|
| 1319 |
const nowCollapsed = list.style.display !== "none";
|
| 1320 |
list.style.display = nowCollapsed ? "none" : "block";
|
| 1321 |
loadAvailableModels._allCollapsed = nowCollapsed;
|
| 1322 |
+
if (window.kimiI18nManager && typeof window.kimiI18nManager.t === "function") {
|
| 1323 |
+
const key = nowCollapsed ? "button_show" : "button_hide";
|
| 1324 |
+
toggleBtn.setAttribute("data-i18n", key);
|
| 1325 |
+
toggleBtn.textContent = window.kimiI18nManager.t(key);
|
| 1326 |
+
} else {
|
| 1327 |
+
toggleBtn.textContent = nowCollapsed ? "Show" : "Hide";
|
| 1328 |
+
}
|
| 1329 |
});
|
| 1330 |
allSection.appendChild(header);
|
| 1331 |
allSection.appendChild(list);
|
kimi-locale/de.json
CHANGED
|
@@ -242,5 +242,11 @@
|
|
| 242 |
"delete_memory_button_title": "Diesen Eintrag löschen",
|
| 243 |
"memory_management": "Gedächtnisverwaltung",
|
| 244 |
"add": "Hinzufügen",
|
| 245 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 246 |
}
|
|
|
|
| 242 |
"delete_memory_button_title": "Diesen Eintrag löschen",
|
| 243 |
"memory_management": "Gedächtnisverwaltung",
|
| 244 |
"add": "Hinzufügen",
|
| 245 |
+
"api_key_label": "API Key",
|
| 246 |
+
"models_search_placeholder": "Modelle filtern...",
|
| 247 |
+
"models_recommended_title": "Empfohlene Openrouter-Modelle",
|
| 248 |
+
"models_all_title": "Alle Openrouter-Modelle",
|
| 249 |
+
"button_show": "Anzeigen",
|
| 250 |
+
"button_hide": "Ausblenden",
|
| 251 |
+
"button_refresh": "Aktualisieren"
|
| 252 |
}
|
kimi-locale/en.json
CHANGED
|
@@ -243,5 +243,11 @@
|
|
| 243 |
"help_providers": "You can use multiple AI providers: OpenRouter, OpenAI, Groq, Together, DeepSeek, Custom OpenAI-compatible, or Local (Ollama). Enter the Base URL and Model ID when required, save your API key per provider, then use ‘Test API Key’.",
|
| 244 |
"api_key_presence_hint": "Green = API key saved for current provider. Grey = no key saved.",
|
| 245 |
"api_key_test_hint": "Green = API connectivity verified. Grey = not tested or failed.",
|
| 246 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 247 |
}
|
|
|
|
| 243 |
"help_providers": "You can use multiple AI providers: OpenRouter, OpenAI, Groq, Together, DeepSeek, Custom OpenAI-compatible, or Local (Ollama). Enter the Base URL and Model ID when required, save your API key per provider, then use ‘Test API Key’.",
|
| 244 |
"api_key_presence_hint": "Green = API key saved for current provider. Grey = no key saved.",
|
| 245 |
"api_key_test_hint": "Green = API connectivity verified. Grey = not tested or failed.",
|
| 246 |
+
"api_key_label": "API Key",
|
| 247 |
+
"models_search_placeholder": "Filter models...",
|
| 248 |
+
"models_recommended_title": "Recommended Openrouter models",
|
| 249 |
+
"models_all_title": "All Openrouter models",
|
| 250 |
+
"button_show": "Show",
|
| 251 |
+
"button_hide": "Hide",
|
| 252 |
+
"button_refresh": "Refresh"
|
| 253 |
}
|
kimi-locale/es.json
CHANGED
|
@@ -242,5 +242,11 @@
|
|
| 242 |
"delete_memory_button_title": "Eliminar esta memoria",
|
| 243 |
"memory_management": "Gestión de Memoria",
|
| 244 |
"add": "Agregar",
|
| 245 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 246 |
}
|
|
|
|
| 242 |
"delete_memory_button_title": "Eliminar esta memoria",
|
| 243 |
"memory_management": "Gestión de Memoria",
|
| 244 |
"add": "Agregar",
|
| 245 |
+
"api_key_label": "API Key",
|
| 246 |
+
"models_search_placeholder": "Filtrar modelos...",
|
| 247 |
+
"models_recommended_title": "Modelos Openrouter recomendados",
|
| 248 |
+
"models_all_title": "Todos los modelos Openrouter",
|
| 249 |
+
"button_show": "Mostrar",
|
| 250 |
+
"button_hide": "Ocultar",
|
| 251 |
+
"button_refresh": "Actualizar"
|
| 252 |
}
|
kimi-locale/fr.json
CHANGED
|
@@ -243,5 +243,11 @@
|
|
| 243 |
"help_providers": "Vous pouvez utiliser plusieurs fournisseurs d’IA : OpenRouter, OpenAI, Groq, Together, DeepSeek, un service OpenAI‑compatible personnalisé, ou Local (Ollama). Renseignez la Base URL et le Model ID si nécessaire, enregistrez votre clé API par fournisseur, puis utilisez ‘Test API Key’.",
|
| 244 |
"api_key_presence_hint": "Vert = clé API enregistrée pour le fournisseur courant. Gris = aucune clé enregistrée.",
|
| 245 |
"api_key_test_hint": "Vert = connectivité API vérifiée. Gris = non testé ou échec.",
|
| 246 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 247 |
}
|
|
|
|
| 243 |
"help_providers": "Vous pouvez utiliser plusieurs fournisseurs d’IA : OpenRouter, OpenAI, Groq, Together, DeepSeek, un service OpenAI‑compatible personnalisé, ou Local (Ollama). Renseignez la Base URL et le Model ID si nécessaire, enregistrez votre clé API par fournisseur, puis utilisez ‘Test API Key’.",
|
| 244 |
"api_key_presence_hint": "Vert = clé API enregistrée pour le fournisseur courant. Gris = aucune clé enregistrée.",
|
| 245 |
"api_key_test_hint": "Vert = connectivité API vérifiée. Gris = non testé ou échec.",
|
| 246 |
+
"api_key_label": "API Key",
|
| 247 |
+
"models_search_placeholder": "Filtrer les modèles...",
|
| 248 |
+
"models_recommended_title": "Modèles Openrouter recommandés",
|
| 249 |
+
"models_all_title": "Tous les modèles Openrouter",
|
| 250 |
+
"button_show": "Afficher",
|
| 251 |
+
"button_hide": "Masquer",
|
| 252 |
+
"button_refresh": "Rafraîchir"
|
| 253 |
}
|
kimi-locale/it.json
CHANGED
|
@@ -242,5 +242,11 @@
|
|
| 242 |
"delete_memory_button_title": "Elimina questa memoria",
|
| 243 |
"memory_management": "Gestione della Memoria",
|
| 244 |
"add": "Aggiungi",
|
| 245 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 246 |
}
|
|
|
|
| 242 |
"delete_memory_button_title": "Elimina questa memoria",
|
| 243 |
"memory_management": "Gestione della Memoria",
|
| 244 |
"add": "Aggiungi",
|
| 245 |
+
"api_key_label": "API Key",
|
| 246 |
+
"models_search_placeholder": "Filtra modelli...",
|
| 247 |
+
"models_recommended_title": "Modelli Openrouter consigliati",
|
| 248 |
+
"models_all_title": "Tutti i modelli Openrouter",
|
| 249 |
+
"button_show": "Mostra",
|
| 250 |
+
"button_hide": "Nascondi",
|
| 251 |
+
"button_refresh": "Aggiorna"
|
| 252 |
}
|
kimi-locale/ja.json
CHANGED
|
@@ -242,5 +242,11 @@
|
|
| 242 |
"delete_memory_button_title": "このメモリを削除",
|
| 243 |
"memory_management": "メモリ管理",
|
| 244 |
"add": "追加",
|
| 245 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 246 |
}
|
|
|
|
| 242 |
"delete_memory_button_title": "このメモリを削除",
|
| 243 |
"memory_management": "メモリ管理",
|
| 244 |
"add": "追加",
|
| 245 |
+
"api_key_label": "API Key",
|
| 246 |
+
"models_search_placeholder": "モデルをフィルタ...",
|
| 247 |
+
"models_recommended_title": "おすすめの Openrouter モデル",
|
| 248 |
+
"models_all_title": "すべての Openrouter モデル",
|
| 249 |
+
"button_show": "表示",
|
| 250 |
+
"button_hide": "非表示",
|
| 251 |
+
"button_refresh": "更新"
|
| 252 |
}
|
kimi-locale/zh.json
CHANGED
|
@@ -242,5 +242,11 @@
|
|
| 242 |
"delete_memory_button_title": "删除该记忆",
|
| 243 |
"memory_management": "记忆管理",
|
| 244 |
"add": "添加",
|
| 245 |
-
"api_key_label": "API Key"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 246 |
}
|
|
|
|
| 242 |
"delete_memory_button_title": "删除该记忆",
|
| 243 |
"memory_management": "记忆管理",
|
| 244 |
"add": "添加",
|
| 245 |
+
"api_key_label": "API Key",
|
| 246 |
+
"models_search_placeholder": "筛选模型...",
|
| 247 |
+
"models_recommended_title": "推荐的 Openrouter 模型",
|
| 248 |
+
"models_all_title": "所有 Openrouter 模型",
|
| 249 |
+
"button_show": "显示",
|
| 250 |
+
"button_hide": "隐藏",
|
| 251 |
+
"button_refresh": "刷新"
|
| 252 |
}
|