-
Notifications
You must be signed in to change notification settings - Fork 215
Closed
Description
Be reader
of type io.Reader
transcription, err := client.Audio.Transcriptions.New(ctx, openai.AudioTranscriptionNewParams{
Model: openai.F(openai.AudioModelWhisper1),
File: openai.F[io.Reader](reader),
})
The above call fails with:
POST "https://api.openai.com/v1/audio/transcriptions": 400 Bad Request {
"error": {
"message": "Unrecognized file format. Supported formats: ['flac', 'm4a', 'mp3', 'mp4', 'mpeg', 'mpga', 'oga', 'ogg', 'wav', 'webm']",
"type": "invalid_request_error",
"param": null,
"code": null
}
}
Edit:
Seems like filename in
openai-go/internal/apiform/encoder.go
Line 316 in 8d58dfa
filename := "anonymous_file" |
Fix in PR #92 seems to fix it
jacobzim-stl
Metadata
Metadata
Assignees
Labels
No labels