diff --git a/aider/commands.py b/aider/commands.py index 2bd602f3c..3a0a2e5f5 100644 --- a/aider/commands.py +++ b/aider/commands.py @@ -55,6 +55,7 @@ class Commands: coder, voice_language=None, voice_input_device=None, + voice_format=None, verify_ssl=True, args=None, parser=None, @@ -1119,7 +1120,7 @@ class Commands: self.io.tool_error("To use /voice you must provide an OpenAI API key.") return try: - self.voice = voice.Voice(audio_format="wav", device_name=self.voice_input_device) + self.voice = voice.Voice(audio_format=self.voice_format or "wav", device_name=self.voice_input_device) except voice.SoundDeviceError: self.io.tool_error( "Unable to import `sounddevice` and/or `soundfile`, is portaudio installed?" diff --git a/aider/main.py b/aider/main.py index 2d0e55e84..26357c447 100644 --- a/aider/main.py +++ b/aider/main.py @@ -806,6 +806,7 @@ def main(argv=None, input=None, output=None, force_git_root=None, return_coder=F None, voice_language=args.voice_language, voice_input_device=args.voice_input_device, + voice_format=args.voice_format, verify_ssl=args.verify_ssl, args=args, parser=parser,