Add OpenAI Whisper Realtime integration

This commit is contained in:
James Babcock committed 2026-07-20 00:19:31 -07:00
1 parent 161dbd104e
commit 008f2277ca
7 files changed
+320 -28

No files matched your search

+19 -3
View File
@@ -233,15 +233,21 @@ export const firmwareDebugFlagsSetting = new ConfigSettingBoolean({
defaultValue: false,
});
export type VoiceProvider = "onboard" | "elevenlabs";
export type VoiceProvider = "onboard" | "elevenlabs" | "whisper";
const voiceProviderLabels: Record<VoiceProvider, string> = {
onboard: "On-device",
elevenlabs: "ElevenLabs",
whisper: "Whisper",
};
export const voiceProviderSetting = new ConfigSettingEnum<VoiceProvider>({
id: "voice-provider",
label: "Provider",
storageKey: "voice.provider",
defaultValue: "onboard",
values: ["onboard", "elevenlabs"],
formatValue: (value) => (value === "elevenlabs" ? "ElevenLabs" : "On-device"),
values: ["onboard", "elevenlabs", "whisper"],
formatValue: (value) => voiceProviderLabels[value] ?? value,
});
export const saveVoiceRecordingsSetting = new ConfigSettingBoolean({
@@ -261,6 +267,16 @@ export const elevenLabsApiKeySetting = new ConfigSettingString({
formatValue: (value) => (value ? `${value.slice(0, 6)}...` : "(not set)"),
});
export const openAiApiKeySetting = new ConfigSettingString({
id: "openai-api-key",
label: "OpenAI key",
storageKey: "voice.openAiApiKey",
defaultValue: "",
editorTitle: "OpenAI API key",
glassesEditTitle: "Edit OpenAI key",
formatValue: (value) => (value ? `${value.slice(0, 6)}...` : "(not set)"),
});
export const anthropicApiKeySetting = new ConfigSettingString({
id: "anthropic-api-key",
label: "Anthropic key",
+2
View File
@@ -5,6 +5,7 @@ import {
anthropicApiKeySetting,
batteryDisplayModeSetting,
elevenLabsApiKeySetting,
openAiApiKeySetting,
enumSettingMenuItem,
firmwareDebugFlagsSetting,
rawScreenshotsEnabledSetting,
@@ -54,6 +55,7 @@ function settingsSections(): SettingsSection[] {
label: "API Keys",
items: [
textSettingMenuItem(elevenLabsApiKeySetting),
textSettingMenuItem(openAiApiKeySetting),
textSettingMenuItem(anthropicApiKeySetting),
],
},