feat(voice): add privacy and compliance UX warning for Gemini Live backend (#26454)

This commit is contained in:
Coco Sheng
2026-05-04 14:32:15 -04:00
committed by GitHub
parent d313cd7dde
commit 60a6a47d56
6 changed files with 126 additions and 12 deletions
@@ -18,6 +18,7 @@ import {
type WhisperModelProgress,
} from '@google/gemini-cli-core';
import { CliSpinner } from './CliSpinner.js';
import { WarningMessage } from './messages/WarningMessage.js';
interface VoiceModelDialogProps {
onClose: () => void;
@@ -68,6 +69,9 @@ export function VoiceModelDialog({
const currentWhisperModel =
settings.merged.experimental.voice?.whisperModel ?? 'ggml-base.en.bin';
const [highlightedBackend, setHighlightedBackend] =
useState<string>(currentBackend);
const handleKeypress = useCallback(
(key: Key) => {
if (key.name === 'escape') {
@@ -101,6 +105,10 @@ export function VoiceModelDialog({
[setSetting, onClose],
);
const handleBackendHighlight = useCallback((value: string) => {
setHighlightedBackend(value);
}, []);
const handleWhisperModelSelect = useCallback(
async (modelName: string) => {
if (modelManager.isModelInstalled(modelName)) {
@@ -203,14 +211,22 @@ export function VoiceModelDialog({
</Box>
</Box>
) : (
<Box marginTop={1}>
<Box marginTop={1} flexDirection="column">
{view === 'backend' ? (
<DescriptiveRadioButtonSelect
items={backendOptions}
onSelect={handleBackendSelect}
initialIndex={currentBackend === 'whisper' ? 1 : 0}
showNumbers={true}
/>
<>
<DescriptiveRadioButtonSelect
items={backendOptions}
onSelect={handleBackendSelect}
onHighlight={handleBackendHighlight}
initialIndex={currentBackend === 'whisper' ? 1 : 0}
showNumbers={true}
/>
{highlightedBackend === 'gemini-live' && (
<Box marginTop={1}>
<WarningMessage text="When using the Gemini Live backend, voice recordings are sent to Google Cloud for transcription. Enterprise users should verify this aligns with their data privacy and compliance requirements." />
</Box>
)}
</>
) : (
<DescriptiveRadioButtonSelect
items={whisperOptions}