I did modify the suffix and openai api accepted the input
following guide helped changing the suffix:
def transcribe(audio):
print(audio)
myfile=Path(audio)
myfile=myfile.rename(myfile.with_suffix('.wav'))
audio_file= open(myfile, "rb")
transcript = openai.Audio.transcribe("whisper-1", audio_file)
print(transcript)
1 Like