fix: Add missing LM Studio translations and fix test assertions

- Added missing LM Studio translation keys to all non-English locale files
- Fixed test assertions in config-manager.spec.ts to match new config structure
- Fixed test assertion in service-factory.spec.ts for LM Studio embedder
- All provider options are now always included in config objects (with undefined values when not configured)
This commit is contained in:
MuriloFP 2025-07-04 17:04:38 -03:00 committed by Daniel Riccio
parent 58804a1f71
commit ea3de32ab0
No known key found for this signature in database
GPG key ID: FFD5FD825F8E8209
20 changed files with 87 additions and 6 deletions

View file

@ -82,6 +82,9 @@ describe("CodeIndexConfigManager", () => {
modelId: "text-embedding-3-large",
openAiOptions: { openAiNativeApiKey: "test-openai-key" },
ollamaOptions: { ollamaBaseUrl: "" },
openAiCompatibleOptions: undefined,
geminiOptions: undefined,
lmStudioOptions: { lmStudioBaseUrl: "" },
qdrantUrl: "http://qdrant.local",
qdrantApiKey: "test-qdrant-key",
searchMinScore: 0.4,
@ -118,7 +121,10 @@ describe("CodeIndexConfigManager", () => {
openAiCompatibleOptions: {
baseUrl: "https://api.example.com/v1",
apiKey: "test-openai-compatible-key",
modelDimension: undefined,
},
geminiOptions: undefined,
lmStudioOptions: { lmStudioBaseUrl: "" },
qdrantUrl: "http://qdrant.local",
qdrantApiKey: "test-qdrant-key",
searchMinScore: 0.4,
@ -157,6 +163,8 @@ describe("CodeIndexConfigManager", () => {
baseUrl: "https://api.example.com/v1",
apiKey: "test-openai-compatible-key",
},
geminiOptions: undefined,
lmStudioOptions: { lmStudioBaseUrl: "" },
qdrantUrl: "http://qdrant.local",
qdrantApiKey: "test-qdrant-key",
searchMinScore: 0.4,
@ -193,8 +201,10 @@ describe("CodeIndexConfigManager", () => {
openAiCompatibleOptions: {
baseUrl: "https://api.example.com/v1",
apiKey: "test-openai-compatible-key",
// modelDimension is undefined when not set
modelDimension: undefined,
},
geminiOptions: undefined,
lmStudioOptions: { lmStudioBaseUrl: "" },
qdrantUrl: "http://qdrant.local",
qdrantApiKey: "test-qdrant-key",
searchMinScore: 0.4,
@ -234,6 +244,9 @@ describe("CodeIndexConfigManager", () => {
apiKey: "test-openai-compatible-key",
},
geminiOptions: undefined,
lmStudioOptions: {
lmStudioBaseUrl: "",
},
qdrantUrl: "http://qdrant.local",
qdrantApiKey: "test-qdrant-key",
searchMinScore: 0.4,
@ -1207,8 +1220,9 @@ describe("CodeIndexConfigManager", () => {
modelId: "text-embedding-3-large",
openAiOptions: { openAiNativeApiKey: "test-openai-key" },
ollamaOptions: { ollamaBaseUrl: undefined },
geminiOptions: undefined,
openAiCompatibleOptions: undefined,
geminiOptions: undefined,
lmStudioOptions: { lmStudioBaseUrl: undefined },
qdrantUrl: "http://qdrant.local",
qdrantApiKey: "test-qdrant-key",
searchMinScore: 0.4,

View file

@ -320,7 +320,7 @@ describe("CodeIndexServiceFactory", () => {
// Assert
expect(MockedCodeIndexLmStudioEmbedder).toHaveBeenCalledWith({
lmStudioBaseUrl: "http://localhost:1234",
lmStudioModelId: testModelId,
embeddingModelId: testModelId,
})
})
@ -341,7 +341,7 @@ describe("CodeIndexServiceFactory", () => {
// Assert
expect(MockedCodeIndexLmStudioEmbedder).toHaveBeenCalledWith({
lmStudioBaseUrl: "http://localhost:1234",
lmStudioModelId: undefined,
embeddingModelId: undefined,
})
})

View file

@ -119,7 +119,10 @@
"searchMinScoreResetTooltip": "Restablir al valor per defecte (0.4)",
"searchMaxResultsLabel": "Màxim de resultats de cerca",
"searchMaxResultsDescription": "Nombre màxim de resultats de cerca a retornar quan es consulta l'índex de la base de codi. Els valors més alts proporcionen més context però poden incloure resultats menys rellevants.",
"resetToDefault": "Restablir al valor per defecte"
"resetToDefault": "Restablir al valor per defecte",
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Permet que Roo realitzi operacions automàticament sense requerir aprovació. Activeu aquesta configuració només si confieu plenament en la IA i enteneu els riscos de seguretat associats.",

View file

@ -119,7 +119,10 @@
"searchMinScoreResetTooltip": "Auf Standardwert zurücksetzen (0.4)",
"searchMaxResultsLabel": "Maximale Suchergebnisse",
"searchMaxResultsDescription": "Maximale Anzahl von Suchergebnissen, die bei der Abfrage des Codebase-Index zurückgegeben werden. Höhere Werte bieten mehr Kontext, können aber weniger relevante Ergebnisse enthalten.",
"resetToDefault": "Auf Standard zurücksetzen"
"resetToDefault": "Auf Standard zurücksetzen",
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Erlaubt Roo, Operationen automatisch ohne Genehmigung durchzuführen. Aktiviere diese Einstellungen nur, wenn du der KI vollständig vertraust und die damit verbundenen Sicherheitsrisiken verstehst.",

View file

@ -93,6 +93,7 @@
},
"ollamaUrlPlaceholder": "http://localhost:11434",
"openAiCompatibleBaseUrlPlaceholder": "https://api.example.com",
"lmstudioUrlPlaceholder": "http://localhost:1234",
"modelDimensionPlaceholder": "1536",
"qdrantUrlPlaceholder": "http://localhost:6333",
"saveError": "Failed to save settings",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Resultados máximos de búsqueda",
"searchMaxResultsDescription": "Número máximo de resultados de búsqueda a devolver al consultar el índice de código. Valores más altos proporcionan más contexto pero pueden incluir resultados menos relevantes.",
"resetToDefault": "Restablecer al valor predeterminado"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Permitir que Roo realice operaciones automáticamente sin requerir aprobación. Habilite esta configuración solo si confía plenamente en la IA y comprende los riesgos de seguridad asociados.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Résultats de recherche maximum",
"searchMaxResultsDescription": "Nombre maximum de résultats de recherche à retourner lors de l'interrogation de l'index de code. Des valeurs plus élevées fournissent plus de contexte mais peuvent inclure des résultats moins pertinents.",
"resetToDefault": "Réinitialiser par défaut"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Permettre à Roo d'effectuer automatiquement des opérations sans requérir d'approbation. Activez ces paramètres uniquement si vous faites entièrement confiance à l'IA et que vous comprenez les risques de sécurité associés.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "अधिकतम खोज परिणाम",
"searchMaxResultsDescription": "कोडबेस इंडेक्स को क्वेरी करते समय वापस करने के लिए खोज परिणामों की अधिकतम संख्या। उच्च मान अधिक संदर्भ प्रदान करते हैं लेकिन कम प्रासंगिक परिणाम शामिल कर सकते हैं।",
"resetToDefault": "डिफ़ॉल्ट पर रीसेट करें"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Roo को अनुमोदन की आवश्यकता के बिना स्वचालित रूप से ऑपरेशन करने की अनुमति दें। इन सेटिंग्स को केवल तभी सक्षम करें जब आप AI पर पूरी तरह से भरोसा करते हों और संबंधित सुरक्षा जोखिमों को समझते हों।",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Hasil Pencarian Maksimum",
"searchMaxResultsDescription": "Jumlah maksimum hasil pencarian yang dikembalikan saat melakukan query indeks basis kode. Nilai yang lebih tinggi memberikan lebih banyak konteks tetapi mungkin menyertakan hasil yang kurang relevan.",
"resetToDefault": "Reset ke default"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Izinkan Roo untuk secara otomatis melakukan operasi tanpa memerlukan persetujuan. Aktifkan pengaturan ini hanya jika kamu sepenuhnya mempercayai AI dan memahami risiko keamanan yang terkait.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Risultati di ricerca massimi",
"searchMaxResultsDescription": "Numero massimo di risultati di ricerca da restituire quando si interroga l'indice del codice. Valori più alti forniscono più contesto ma possono includere risultati meno pertinenti.",
"resetToDefault": "Ripristina al valore predefinito"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Permetti a Roo di eseguire automaticamente operazioni senza richiedere approvazione. Abilita queste impostazioni solo se ti fidi completamente dell'IA e comprendi i rischi di sicurezza associati.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "最大検索結果数",
"searchMaxResultsDescription": "コードベースインデックスをクエリする際に返される検索結果の最大数。値を高くするとより多くのコンテキストが提供されますが、関連性の低い結果が含まれる可能性があります。",
"resetToDefault": "デフォルトにリセット"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Rooが承認なしで自動的に操作を実行できるようにします。AIを完全に信頼し、関連するセキュリティリスクを理解している場合にのみ、これらの設定を有効にしてください。",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "최대 검색 결과",
"searchMaxResultsDescription": "코드베이스 인덱스를 쿼리할 때 반환할 최대 검색 결과 수입니다. 값이 높을수록 더 많은 컨텍스트를 제공하지만 관련성이 낮은 결과가 포함될 수 있습니다.",
"resetToDefault": "기본값으로 재설정"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Roo가 승인 없이 자동으로 작업을 수행할 수 있도록 허용합니다. AI를 완전히 신뢰하고 관련 보안 위험을 이해하는 경우에만 이러한 설정을 활성화하세요.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Maximum Zoekresultaten",
"searchMaxResultsDescription": "Maximum aantal zoekresultaten dat wordt geretourneerd bij het doorzoeken van de codebase-index. Hogere waarden bieden meer context maar kunnen minder relevante resultaten bevatten.",
"resetToDefault": "Reset naar standaard"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Sta Roo toe om automatisch handelingen uit te voeren zonder goedkeuring. Schakel deze instellingen alleen in als je de AI volledig vertrouwt en de bijbehorende beveiligingsrisico's begrijpt.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Maksymalna liczba wyników wyszukiwania",
"searchMaxResultsDescription": "Maksymalna liczba wyników wyszukiwania zwracanych podczas zapytania do indeksu bazy kodu. Wyższe wartości zapewniają więcej kontekstu, ale mogą zawierać mniej istotne wyniki.",
"resetToDefault": "Przywróć domyślne"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Pozwól Roo na automatyczne wykonywanie operacji bez wymagania zatwierdzenia. Włącz te ustawienia tylko jeśli w pełni ufasz AI i rozumiesz związane z tym zagrożenia bezpieczeństwa.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Resultados máximos de busca",
"searchMaxResultsDescription": "Número máximo de resultados de busca a retornar ao consultar o índice de código. Valores mais altos fornecem mais contexto, mas podem incluir resultados menos relevantes.",
"resetToDefault": "Redefinir para o padrão"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Permitir que o Roo realize operações automaticamente sem exigir aprovação. Ative essas configurações apenas se confiar totalmente na IA e compreender os riscos de segurança associados.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Максимальное количество результатов поиска",
"searchMaxResultsDescription": "Максимальное количество результатов поиска, возвращаемых при запросе индекса кодовой базы. Более высокие значения предоставляют больше контекста, но могут включать менее релевантные результаты.",
"resetToDefault": "Сбросить к значению по умолчанию"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Разрешить Roo автоматически выполнять операции без необходимости одобрения. Включайте эти параметры только если полностью доверяете ИИ и понимаете связанные с этим риски безопасности.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Maksimum Arama Sonuçları",
"searchMaxResultsDescription": "Kod tabanı dizinini sorgularken döndürülecek maksimum arama sonucu sayısı. Daha yüksek değerler daha fazla bağlam sağlar ancak daha az alakalı sonuçlar içerebilir.",
"resetToDefault": "Varsayılana sıfırla"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Roo'nun onay gerektirmeden otomatik olarak işlemler gerçekleştirmesine izin verin. Bu ayarları yalnızca yapay zekaya tamamen güveniyorsanız ve ilgili güvenlik risklerini anlıyorsanız etkinleştirin.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "Số Kết Quả Tìm Kiếm Tối Đa",
"searchMaxResultsDescription": "Số lượng kết quả tìm kiếm tối đa được trả về khi truy vấn chỉ mục cơ sở mã. Giá trị cao hơn cung cấp nhiều ngữ cảnh hơn nhưng có thể bao gồm các kết quả ít liên quan hơn.",
"resetToDefault": "Đặt lại về mặc định"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "Cho phép Roo tự động thực hiện các hoạt động mà không cần phê duyệt. Chỉ bật những cài đặt này nếu bạn hoàn toàn tin tưởng AI và hiểu rõ các rủi ro bảo mật liên quan.",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "最大搜索结果数",
"searchMaxResultsDescription": "查询代码库索引时返回的最大搜索结果数。较高的值提供更多上下文,但可能包含相关性较低的结果。",
"resetToDefault": "恢复默认值"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "允许 Roo 自动执行操作而无需批准。只有在您完全信任 AI 并了解相关安全风险的情况下才启用这些设置。",

View file

@ -120,6 +120,10 @@
"searchMaxResultsLabel": "最大搜尋結果數",
"searchMaxResultsDescription": "查詢程式碼庫索引時傳回的最大搜尋結果數。較高的值提供更多上下文,但可能包含相關性較低的結果。",
"resetToDefault": "重設為預設值"
,
"lmstudioProvider": "LM Studio",
"lmstudioUrlLabel": "LM Studio URL:",
"lmstudioUrlPlaceholder": "http://localhost:1234"
},
"autoApprove": {
"description": "允許 Roo 無需核准即執行操作。僅在您完全信任 AI 並了解相關安全風險時啟用這些設定。",