openai
openai copied to clipboard
Can't use createSpeech without saving to file.
OpenAI.instance.audio.createSpeech insists on saving the result to a file. It doesn't seem necessary (and is problematic for me). (Perhaps it could return the result if the file and directory were null?)
Looking at its implementation, I also can't directly call await OpenAINetworkingClient.post ... since it is not exported.
Yeah, this makes sense, but what would be the expected behavior here?
I'd like to invoke it using a BytesSource
: https://pub.dev/documentation/audioplayers/latest/audioplayers/BytesSource-class.html
would that be possible?
I have opened a PR that hopefully adds this: https://github.com/anasfik/openai/pull/177
I'm new to Dart so please check it over, it should work however.
Edit: works, example code in PR