intelligentnode / IntelliNode

Access the latest AI models like ChatGPT, LLaMA, Diffusion, Gemini Hugging face, and beyond through a unified prompt layer and performance evaluation
https://show.intellinode.ai
Apache License 2.0
225 stars 15 forks source link

Update Openai wrapper to add speech to text functionality #17

Closed Barqawiz closed 1 year ago

Barqawiz commented 1 year ago

Update the openai wrapper to add the audio function (speech 2 text) from openai api.

Openai audio reference: https://platform.openai.com/docs/api-reference/audio


  1. Update the IntelliNode Openai wrapper with audio function:

Function name:

async speechToText(params) { 
//TODO: add the implementation details.
}
  1. You can add the audio related helpers like loading audio files in AudioHelper.


  1. Add unit test case in OpenAIWrapper.test.js and ensure it works as expected.
async function testSpeechToText() { }


pushoo-sharma commented 1 year ago

Question: The task looks like to generating audio but the link provided is for transcribing audio and returning text as audio Can I get more clarity on this? Thanks. cc @Barqawiz

Barqawiz commented 1 year ago

Yes you are right, the description confused the task.

It is speech to text, I just fixed the description.

pushoo-sharma commented 1 year ago

Thanks,

  1. Do we have any sample account to test OpenAI APIs on running test cases
  2. I have created a new directory for storing audio files under samples/audios, do I need to pull it from somewhere or will that be fine?

@Barqawiz

Barqawiz commented 1 year ago