diff --git a/webview-ui/playwright/roo-code-types.ts b/webview-ui/playwright/roo-code-types.ts index 5d0c0bbf15..3748a0b09c 100644 --- a/webview-ui/playwright/roo-code-types.ts +++ b/webview-ui/playwright/roo-code-types.ts @@ -1,4 +1,5 @@ export { DEFAULT_MODES } from "../../packages/types/src/mode" +export { DEFAULT_OPEN_AI_CODEX_USE_WEBSOCKET } from "../../packages/types/src/provider-settings/openai-codex" export const DEFAULT_AUTO_CLOSE_ZOO_OPENED_FILES = false export const DEFAULT_AUTO_CLOSE_ZOO_OPENED_FILES_AFTER_USER_EDITED = false diff --git a/webview-ui/playwright/vite.config.ts b/webview-ui/playwright/vite.config.ts index 6a25d792f5..01a0b4b548 100644 --- a/webview-ui/playwright/vite.config.ts +++ b/webview-ui/playwright/vite.config.ts @@ -13,6 +13,7 @@ const rooCodeTypesShimImporters = [ "/webview-ui/src/components/chat/CodeIndexPopover.tsx", "/webview-ui/src/components/chat/ModeSelector.tsx", "/webview-ui/src/components/settings/UISettings.tsx", + "/webview-ui/src/components/settings/providers/OpenAICodexWebSocketToggle.tsx", ] export default defineConfig({ diff --git a/webview-ui/src/components/settings/__tests__/SettingsView.unsaved-changes.spec.tsx b/webview-ui/src/components/settings/__tests__/SettingsView.unsaved-changes.spec.tsx index 575da5a833..1a02f5750a 100644 --- a/webview-ui/src/components/settings/__tests__/SettingsView.unsaved-changes.spec.tsx +++ b/webview-ui/src/components/settings/__tests__/SettingsView.unsaved-changes.spec.tsx @@ -8,6 +8,7 @@ import React from "react" import SettingsView from "../SettingsView" import { vscode } from "@src/utils/vscode" +import { OpenAICodexWebSocketToggle } from "../providers/OpenAICodexWebSocketToggle" const postMessage = vi.spyOn(vscode, "postMessage").mockImplementation(() => {}) @@ -684,6 +685,45 @@ describe("SettingsView - Unsaved Changes Detection", () => { }) }) + it.each([true, false, undefined])( + "buffers Codex WebSocket edits from %s until Save despite a live refresh", + async (enabled) => { + const configuration: ProviderSettings = { + apiProvider: providerIdentifiers.openaiCodex, + apiModelId: "gpt-5.6-sol", + openAiCodexUseWebSocket: enabled, + } + vi.mocked(useExtensionState, { partial: true }).mockReturnValue({ + ...defaultExtensionState, + apiConfiguration: configuration, + }) + vi.mocked(ApiOptions).mockImplementation(({ apiConfiguration, setApiConfigurationField }) => ( + setApiConfigurationField("openAiCodexUseWebSocket", value)} + /> + )) + const view = renderWithExtensionState(, { queryClient }) + fireEvent.click(await screen.findByRole("checkbox", { name: "settings:openAiCodexWebSocket.label" })) + vi.mocked(useExtensionState, { partial: true }).mockReturnValue({ + ...defaultExtensionState, + apiConfiguration: { ...configuration }, + }) + view.rerender() + const checkbox = screen.getByRole("checkbox", { name: "settings:openAiCodexWebSocket.label" }) + if (enabled) expect(checkbox).not.toBeChecked() + else expect(checkbox).toBeChecked() + expect(configuration.openAiCodexUseWebSocket).toBe(enabled) + expect(postMessage).not.toHaveBeenCalledWith(expect.objectContaining({ type: "upsertApiConfiguration" })) + fireEvent.click(screen.getByTestId("save-button")) + expect(postMessage).toHaveBeenCalledWith({ + type: "upsertApiConfiguration", + text: "default", + apiConfiguration: { ...configuration, openAiCodexUseWebSocket: !enabled }, + }) + }, + ) + it("keeps OpenAI-compatible reasoning edits cached until Save despite a live state refresh", async () => { const configuration: ProviderSettings = { apiProvider: providerIdentifiers.openai, diff --git a/webview-ui/src/components/settings/providers/OpenAICodex.tsx b/webview-ui/src/components/settings/providers/OpenAICodex.tsx index ee2abf0e2b..26ed874817 100644 --- a/webview-ui/src/components/settings/providers/OpenAICodex.tsx +++ b/webview-ui/src/components/settings/providers/OpenAICodex.tsx @@ -14,6 +14,7 @@ import { vscode } from "@src/utils/vscode" import { ModelPicker } from "../ModelPicker" import { OpenAICodexRateLimitDashboard } from "./OpenAICodexRateLimitDashboard" import { OpenAICodexSpeedSelector } from "./OpenAICodexSpeedSelector" +import { OpenAICodexWebSocketToggle } from "./OpenAICodexWebSocketToggle" interface OpenAICodexProps { apiConfiguration: ProviderSettings @@ -77,6 +78,10 @@ export const OpenAICodex: React.FC = ({ value={apiConfiguration[OPEN_AI_CODEX_SERVICE_TIER_KEY]} onValueChange={(value) => setApiConfigurationField(OPEN_AI_CODEX_SERVICE_TIER_KEY, value)} /> + setApiConfigurationField("openAiCodexUseWebSocket", value)} + /> ) } diff --git a/webview-ui/src/components/settings/providers/OpenAICodexWebSocketToggle.tsx b/webview-ui/src/components/settings/providers/OpenAICodexWebSocketToggle.tsx new file mode 100644 index 0000000000..8e985774da --- /dev/null +++ b/webview-ui/src/components/settings/providers/OpenAICodexWebSocketToggle.tsx @@ -0,0 +1,25 @@ +import { Checkbox } from "vscrui" +import { DEFAULT_OPEN_AI_CODEX_USE_WEBSOCKET } from "@roo-code/types" + +import { useAppTranslation } from "@src/i18n/TranslationContext" + +interface OpenAICodexWebSocketToggleProps { + value?: boolean + onChange: (enabled: boolean) => void +} + +export function OpenAICodexWebSocketToggle({ value, onChange }: OpenAICodexWebSocketToggleProps) { + const { t } = useAppTranslation() + return ( +
+ onChange(checked === true)}> + {t("settings:openAiCodexWebSocket.label")} + +

+ {t("settings:openAiCodexWebSocket.description")} +

+
+ ) +} diff --git a/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.spec.tsx b/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.spec.tsx index d73120ada3..4a82a1a4c8 100644 --- a/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.spec.tsx +++ b/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.spec.tsx @@ -17,6 +17,7 @@ vi.mock("@src/i18n/TranslationContext", () => ({ t: (key: string) => ({ "settings:openAiCodexSpeed.label": "Speed", + "settings:openAiCodexWebSocket.label": "Use WebSocket", "settings:openAiCodexSpeed.tooltip": "Fast uses Codex priority processing for about 1.5x speed and consumes more subscription quota.", "settings:openAiCodexSpeed.standard": "Standard", @@ -95,3 +96,26 @@ describe("OpenAICodex speed selector", () => { expect(postMessage).not.toHaveBeenCalled() }) }) + +describe("OpenAICodex WebSocket preference", () => { + it.each([undefined, false, true])( + "renders saved preference %s and edits through the cached settings callback", + (enabled) => { + const setApiConfigurationField = vi.fn() + const configuration: ProviderSettings = { + apiProvider: providerIdentifiers.openaiCodex, + openAiCodexUseWebSocket: enabled, + } + render() + const checkbox = screen.getByRole("checkbox", { name: "Use WebSocket" }) + if (enabled) expect(checkbox).toBeChecked() + else expect(checkbox).not.toBeChecked() + fireEvent.click(checkbox) + expect(setApiConfigurationField).toHaveBeenLastCalledWith("openAiCodexUseWebSocket", !enabled) + expect(configuration.openAiCodexUseWebSocket).toBe(enabled) + expect(vscode.postMessage).not.toHaveBeenCalledWith( + expect.objectContaining({ type: "upsertApiConfiguration" }), + ) + }, + ) +}) diff --git a/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.fixture.tsx b/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.fixture.tsx index 2061f00614..2030599d3e 100644 --- a/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.fixture.tsx +++ b/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.fixture.tsx @@ -6,9 +6,13 @@ import { OpenAiCodexServiceTier } from "@roo-code/types/model" import { TranslationContext } from "@src/i18n/TranslationContext" import { TooltipProvider } from "@src/components/ui/tooltip" import { OpenAICodexSpeedSelector } from "../OpenAICodexSpeedSelector" +import { OpenAICodexWebSocketToggle } from "../OpenAICodexWebSocketToggle" const translations: Record = { "settings:common.select": "Select", + "settings:openAiCodexWebSocket.label": "Use WebSocket", + "settings:openAiCodexWebSocket.description": + "Keeps the ChatGPT connection open between requests. Uses HTTP if a WebSocket connection cannot be established.", "settings:openAiCodexSpeed.label": "Speed", "settings:openAiCodexSpeed.tooltip": "Fast uses Codex priority processing for about 1.5x speed and consumes more subscription quota.", @@ -25,7 +29,9 @@ export const OpenAICodexFixture = () => (
{}} /> + {}} /> {}} /> + {}} />
diff --git a/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.tsx b/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.tsx index a0fcafdf93..30d3912264 100644 --- a/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.tsx +++ b/webview-ui/src/components/settings/providers/__tests__/OpenAICodex.visual.tsx @@ -21,7 +21,9 @@ const themes = [ ] as const for (const theme of themes) { - test(`renders both OpenAI Codex speeds in the VS Code ${theme.name} theme`, async ({ mount }) => { + test(`renders OpenAI Codex speed and WebSocket preferences in the VS Code ${theme.name} theme`, async ({ + mount, + }) => { const component = mountedStory(await mount("openai-codex")) const selectors = component.getByTestId("openai-codex-service-tier") const comboboxes = component.getByRole("combobox", { name: "Speed" }) @@ -29,6 +31,10 @@ for (const theme of themes) { await expect(selectors).toHaveCount(2) await expect(comboboxes).toHaveCount(2) + const checkboxes = component.getByRole("checkbox", { name: "Use WebSocket" }) + await expect(checkboxes).toHaveCount(2) + await expect(checkboxes.first()).not.toBeChecked() + await expect(checkboxes.last()).toBeChecked() await selector.evaluate((element, { bodyClass, themeId }) => { const { document } = element.ownerDocument.defaultView! diff --git a/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-dark.png b/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-dark.png index a168e8656e..1c03f9c427 100644 Binary files a/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-dark.png and b/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-dark.png differ diff --git a/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-light.png b/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-light.png index 70d6eb1ad4..9a079717a7 100644 Binary files a/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-light.png and b/webview-ui/src/components/settings/providers/__tests__/__screenshots__/openai-codex-speed-selector-states-light.png differ diff --git a/webview-ui/src/i18n/locales/ca/settings.json b/webview-ui/src/i18n/locales/ca/settings.json index 71cd18cecb..9484e259cc 100644 --- a/webview-ui/src/i18n/locales/ca/settings.json +++ b/webview-ui/src/i18n/locales/ca/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Limitar el nombre màxim de tokens en la resposta", "maxOutputTokensLabel": "Tokens màxims de sortida", "maxTokensGenerateDescription": "Tokens màxims a generar en la resposta", + "openAiCodexWebSocket": { + "label": "Utilitza WebSocket", + "description": "Manté oberta la connexió amb ChatGPT entre peticions. Utilitza HTTP si no es pot establir una connexió WebSocket." + }, "openAiCodexSpeed": { "label": "Velocitat", "tooltip": "El mode ràpid utilitza el processament prioritari de Codex per oferir aproximadament 1,5 vegades més velocitat i consumeix més quota de subscripció.", diff --git a/webview-ui/src/i18n/locales/de/settings.json b/webview-ui/src/i18n/locales/de/settings.json index 4403a19dbb..8cc033910e 100644 --- a/webview-ui/src/i18n/locales/de/settings.json +++ b/webview-ui/src/i18n/locales/de/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Begrenze die maximale Anzahl von Tokens in der Antwort", "maxOutputTokensLabel": "Maximale Ausgabe-Tokens", "maxTokensGenerateDescription": "Maximale Tokens, die in der Antwort generiert werden", + "openAiCodexWebSocket": { + "label": "WebSocket verwenden", + "description": "Hält die Verbindung zu ChatGPT zwischen Anfragen offen. Verwendet HTTP, wenn keine WebSocket-Verbindung hergestellt werden kann." + }, "openAiCodexSpeed": { "label": "Geschwindigkeit", "tooltip": "Der schnelle Modus nutzt die priorisierte Codex-Verarbeitung für etwa 1,5-fache Geschwindigkeit und verbraucht mehr von deinem Abonnementkontingent.", diff --git a/webview-ui/src/i18n/locales/en/settings.json b/webview-ui/src/i18n/locales/en/settings.json index 2e4ff9298d..abdda9a994 100644 --- a/webview-ui/src/i18n/locales/en/settings.json +++ b/webview-ui/src/i18n/locales/en/settings.json @@ -1179,6 +1179,10 @@ "limitMaxTokensDescription": "Limit the maximum number of tokens in the response", "maxOutputTokensLabel": "Max output tokens", "maxTokensGenerateDescription": "Maximum tokens to generate in response", + "openAiCodexWebSocket": { + "label": "Use WebSocket", + "description": "Keeps the ChatGPT connection open between requests. Uses HTTP if a WebSocket connection cannot be established." + }, "openAiCodexSpeed": { "label": "Speed", "tooltip": "Fast uses Codex priority processing for about 1.5x speed and consumes more subscription quota.", diff --git a/webview-ui/src/i18n/locales/es/settings.json b/webview-ui/src/i18n/locales/es/settings.json index 22788f89f9..f952d0be41 100644 --- a/webview-ui/src/i18n/locales/es/settings.json +++ b/webview-ui/src/i18n/locales/es/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Limitar el número máximo de tokens en la respuesta", "maxOutputTokensLabel": "Tokens máximos de salida", "maxTokensGenerateDescription": "Tokens máximos a generar en la respuesta", + "openAiCodexWebSocket": { + "label": "Usar WebSocket", + "description": "Mantiene abierta la conexión con ChatGPT entre solicitudes. Usa HTTP si no se puede establecer una conexión WebSocket." + }, "openAiCodexSpeed": { "label": "Velocidad", "tooltip": "El modo rápido usa el procesamiento prioritario de Codex para ofrecer aproximadamente 1,5 veces más velocidad y consume más cuota de suscripción.", diff --git a/webview-ui/src/i18n/locales/fr/settings.json b/webview-ui/src/i18n/locales/fr/settings.json index f57562ebf2..f633874c0b 100644 --- a/webview-ui/src/i18n/locales/fr/settings.json +++ b/webview-ui/src/i18n/locales/fr/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Limiter le nombre maximum de tokens dans la réponse", "maxOutputTokensLabel": "Tokens de sortie maximum", "maxTokensGenerateDescription": "Tokens maximum à générer dans la réponse", + "openAiCodexWebSocket": { + "label": "Utiliser WebSocket", + "description": "Garde la connexion à ChatGPT ouverte entre les requêtes. Utilise HTTP si une connexion WebSocket ne peut pas être établie." + }, "openAiCodexSpeed": { "label": "Vitesse", "tooltip": "Le mode rapide utilise le traitement prioritaire de Codex pour une vitesse environ 1,5 fois supérieure et consomme davantage de quota d'abonnement.", diff --git a/webview-ui/src/i18n/locales/hi/settings.json b/webview-ui/src/i18n/locales/hi/settings.json index 52a29ff287..4e8b5ada5b 100644 --- a/webview-ui/src/i18n/locales/hi/settings.json +++ b/webview-ui/src/i18n/locales/hi/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "प्रतिक्रिया में टोकन की अधिकतम संख्या सीमित करें", "maxOutputTokensLabel": "अधिकतम आउटपुट टोकन", "maxTokensGenerateDescription": "प्रतिक्रिया में उत्पन्न करने के लिए अधिकतम टोकन", + "openAiCodexWebSocket": { + "label": "WebSocket का उपयोग करो", + "description": "अनुरोधों के बीच ChatGPT का कनेक्शन खुला रखता है। WebSocket कनेक्शन स्थापित न हो पाने पर HTTP का उपयोग करता है।" + }, "openAiCodexSpeed": { "label": "गति", "tooltip": "तेज़ मोड लगभग 1.5 गुना गति के लिए Codex की प्राथमिकता प्रोसेसिंग का उपयोग करता है और अधिक सदस्यता कोटा खर्च करता है।", diff --git a/webview-ui/src/i18n/locales/id/settings.json b/webview-ui/src/i18n/locales/id/settings.json index e3ae8c18fc..1c4e8279f2 100644 --- a/webview-ui/src/i18n/locales/id/settings.json +++ b/webview-ui/src/i18n/locales/id/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Batasi jumlah maksimum token dalam respons", "maxOutputTokensLabel": "Token output maksimum", "maxTokensGenerateDescription": "Token maksimum untuk dihasilkan dalam respons", + "openAiCodexWebSocket": { + "label": "Gunakan WebSocket", + "description": "Menjaga koneksi ChatGPT tetap terbuka di antara permintaan. Menggunakan HTTP jika koneksi WebSocket tidak dapat dibuat." + }, "openAiCodexSpeed": { "label": "Kecepatan", "tooltip": "Mode Cepat menggunakan pemrosesan prioritas Codex untuk kecepatan sekitar 1,5x dan memakai lebih banyak kuota langganan.", diff --git a/webview-ui/src/i18n/locales/it/settings.json b/webview-ui/src/i18n/locales/it/settings.json index c6ddf94a03..72463c3812 100644 --- a/webview-ui/src/i18n/locales/it/settings.json +++ b/webview-ui/src/i18n/locales/it/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Limita il numero massimo di token nella risposta", "maxOutputTokensLabel": "Token di output massimi", "maxTokensGenerateDescription": "Token massimi da generare nella risposta", + "openAiCodexWebSocket": { + "label": "Usa WebSocket", + "description": "Mantiene aperta la connessione a ChatGPT tra le richieste. Usa HTTP se non è possibile stabilire una connessione WebSocket." + }, "openAiCodexSpeed": { "label": "Velocità", "tooltip": "La modalità veloce usa l'elaborazione prioritaria di Codex per una velocità circa 1,5 volte superiore e consuma più quota dell'abbonamento.", diff --git a/webview-ui/src/i18n/locales/ja/settings.json b/webview-ui/src/i18n/locales/ja/settings.json index e07b01c510..69e796ac7f 100644 --- a/webview-ui/src/i18n/locales/ja/settings.json +++ b/webview-ui/src/i18n/locales/ja/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "レスポンスの最大トークン数を制限する", "maxOutputTokensLabel": "最大出力トークン", "maxTokensGenerateDescription": "レスポンスで生成する最大トークン数", + "openAiCodexWebSocket": { + "label": "WebSocket を使用", + "description": "リクエスト間で ChatGPT への接続を維持する。WebSocket 接続を確立できない場合は HTTP を使用する。" + }, "openAiCodexSpeed": { "label": "速度", "tooltip": "高速モードは Codex の優先処理を使用して約1.5倍の速度を実現し、サブスクリプションの利用枠をより多く消費します。", diff --git a/webview-ui/src/i18n/locales/ko/settings.json b/webview-ui/src/i18n/locales/ko/settings.json index 49efb31701..5955e24983 100644 --- a/webview-ui/src/i18n/locales/ko/settings.json +++ b/webview-ui/src/i18n/locales/ko/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "응답에서 최대 토큰 수 제한", "maxOutputTokensLabel": "최대 출력 토큰", "maxTokensGenerateDescription": "응답에서 생성할 최대 토큰 수", + "openAiCodexWebSocket": { + "label": "WebSocket 사용", + "description": "요청 사이에도 ChatGPT 연결을 유지해요. WebSocket 연결을 설정할 수 없으면 HTTP를 사용해요." + }, "openAiCodexSpeed": { "label": "속도", "tooltip": "빠른 모드는 Codex 우선 처리를 사용하여 약 1.5배 빠른 속도를 제공하며 구독 할당량을 더 많이 사용합니다.", diff --git a/webview-ui/src/i18n/locales/nl/settings.json b/webview-ui/src/i18n/locales/nl/settings.json index 54e76a1a00..97c68a2b12 100644 --- a/webview-ui/src/i18n/locales/nl/settings.json +++ b/webview-ui/src/i18n/locales/nl/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Beperk het maximale aantal tokens in het antwoord", "maxOutputTokensLabel": "Maximale output tokens", "maxTokensGenerateDescription": "Maximale tokens om te genereren in het antwoord", + "openAiCodexWebSocket": { + "label": "WebSocket gebruiken", + "description": "Houdt de verbinding met ChatGPT open tussen verzoeken. Gebruikt HTTP als er geen WebSocket-verbinding kan worden gemaakt." + }, "openAiCodexSpeed": { "label": "Snelheid", "tooltip": "De snelle modus gebruikt prioriteitsverwerking van Codex voor ongeveer 1,5 keer hogere snelheid en verbruikt meer abonnementquotum.", diff --git a/webview-ui/src/i18n/locales/pl/settings.json b/webview-ui/src/i18n/locales/pl/settings.json index 411362c9b6..d9112df467 100644 --- a/webview-ui/src/i18n/locales/pl/settings.json +++ b/webview-ui/src/i18n/locales/pl/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Ogranicz maksymalną liczbę tokenów w odpowiedzi", "maxOutputTokensLabel": "Maksymalne tokeny wyjściowe", "maxTokensGenerateDescription": "Maksymalne tokeny do wygenerowania w odpowiedzi", + "openAiCodexWebSocket": { + "label": "Używaj WebSocket", + "description": "Utrzymuje połączenie z ChatGPT między żądaniami. Używa HTTP, jeśli nie można nawiązać połączenia WebSocket." + }, "openAiCodexSpeed": { "label": "Szybkość", "tooltip": "Tryb szybki korzysta z priorytetowego przetwarzania Codex, zapewniając około 1,5 raza większą szybkość i zużywając więcej limitu subskrypcji.", diff --git a/webview-ui/src/i18n/locales/pt-BR/settings.json b/webview-ui/src/i18n/locales/pt-BR/settings.json index a65d642a68..03e195324e 100644 --- a/webview-ui/src/i18n/locales/pt-BR/settings.json +++ b/webview-ui/src/i18n/locales/pt-BR/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Limitar o número máximo de tokens na resposta", "maxOutputTokensLabel": "Tokens máximos de saída", "maxTokensGenerateDescription": "Tokens máximos para gerar na resposta", + "openAiCodexWebSocket": { + "label": "Usar WebSocket", + "description": "Mantém a conexão com o ChatGPT aberta entre as solicitações. Usa HTTP se não for possível estabelecer uma conexão WebSocket." + }, "openAiCodexSpeed": { "label": "Velocidade", "tooltip": "O modo rápido usa o processamento prioritário do Codex para oferecer cerca de 1,5 vez mais velocidade e consome mais cota da assinatura.", diff --git a/webview-ui/src/i18n/locales/ru/settings.json b/webview-ui/src/i18n/locales/ru/settings.json index 177aaa870e..690d714ee4 100644 --- a/webview-ui/src/i18n/locales/ru/settings.json +++ b/webview-ui/src/i18n/locales/ru/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Ограничить максимальное количество токенов в ответе", "maxOutputTokensLabel": "Максимальные выходные токены", "maxTokensGenerateDescription": "Максимальные токены для генерации в ответе", + "openAiCodexWebSocket": { + "label": "Использовать WebSocket", + "description": "Сохраняет соединение с ChatGPT между запросами. Если WebSocket-соединение установить не удалось, используется HTTP." + }, "openAiCodexSpeed": { "label": "Скорость", "tooltip": "Быстрый режим использует приоритетную обработку Codex, обеспечивая примерно 1,5-кратную скорость и расходуя больше квоты подписки.", diff --git a/webview-ui/src/i18n/locales/tr/settings.json b/webview-ui/src/i18n/locales/tr/settings.json index a3bbceb764..2eda61c38c 100644 --- a/webview-ui/src/i18n/locales/tr/settings.json +++ b/webview-ui/src/i18n/locales/tr/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Yanıttaki maksimum token sayısını sınırla", "maxOutputTokensLabel": "Maksimum çıktı tokenları", "maxTokensGenerateDescription": "Yanıtta oluşturulacak maksimum token sayısı", + "openAiCodexWebSocket": { + "label": "WebSocket kullan", + "description": "İstekler arasında ChatGPT bağlantısını açık tutar. WebSocket bağlantısı kurulamazsa HTTP kullanır." + }, "openAiCodexSpeed": { "label": "Hız", "tooltip": "Hızlı mod, yaklaşık 1,5 kat hız için Codex öncelikli işlemeyi kullanır ve daha fazla abonelik kotası tüketir.", diff --git a/webview-ui/src/i18n/locales/vi/settings.json b/webview-ui/src/i18n/locales/vi/settings.json index 4f25fcceb6..cc30749afb 100644 --- a/webview-ui/src/i18n/locales/vi/settings.json +++ b/webview-ui/src/i18n/locales/vi/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "Giới hạn số lượng token tối đa trong phản hồi", "maxOutputTokensLabel": "Token đầu ra tối đa", "maxTokensGenerateDescription": "Token tối đa để tạo trong phản hồi", + "openAiCodexWebSocket": { + "label": "Dùng WebSocket", + "description": "Giữ kết nối với ChatGPT mở giữa các yêu cầu. Dùng HTTP nếu không thể thiết lập kết nối WebSocket." + }, "openAiCodexSpeed": { "label": "Tốc độ", "tooltip": "Chế độ Nhanh sử dụng xử lý ưu tiên của Codex để đạt tốc độ nhanh hơn khoảng 1,5 lần và tiêu tốn nhiều hạn mức đăng ký hơn.", diff --git a/webview-ui/src/i18n/locales/zh-CN/settings.json b/webview-ui/src/i18n/locales/zh-CN/settings.json index fee64e4f54..2a6bf76b54 100644 --- a/webview-ui/src/i18n/locales/zh-CN/settings.json +++ b/webview-ui/src/i18n/locales/zh-CN/settings.json @@ -1099,6 +1099,10 @@ "limitMaxTokensDescription": "限制响应中的最大 Token 数量", "maxOutputTokensLabel": "最大输出 Token 数", "maxTokensGenerateDescription": "响应中生成的最大 Token 数", + "openAiCodexWebSocket": { + "label": "使用 WebSocket", + "description": "在请求之间保持与 ChatGPT 的连接。如果无法建立 WebSocket 连接,则使用 HTTP。" + }, "openAiCodexSpeed": { "label": "速度", "tooltip": "快速模式使用 Codex 优先处理,速度约为 1.5 倍,但会消耗更多订阅配额。", diff --git a/webview-ui/src/i18n/locales/zh-TW/settings.json b/webview-ui/src/i18n/locales/zh-TW/settings.json index eefd6012cf..ee914e6a5f 100644 --- a/webview-ui/src/i18n/locales/zh-TW/settings.json +++ b/webview-ui/src/i18n/locales/zh-TW/settings.json @@ -1126,6 +1126,10 @@ "limitMaxTokensDescription": "限制回應中的最大 Token 數量", "maxOutputTokensLabel": "最大輸出 Token 數", "maxTokensGenerateDescription": "回應中產生的最大 Token 數", + "openAiCodexWebSocket": { + "label": "使用 WebSocket", + "description": "在請求之間保持與 ChatGPT 的連線。如果無法建立 WebSocket 連線,則使用 HTTP。" + }, "openAiCodexSpeed": { "label": "速度", "tooltip": "快速模式使用 Codex 優先處理,速度約為 1.5 倍,但會消耗更多訂閱配額。",