Skip to content

Commit

Permalink
Handle OpenAI whisper transcription edge case (#2621)
Browse files Browse the repository at this point in the history
remove openai whisper transcription provider response_format option
  • Loading branch information
shatfield4 authored Nov 12, 2024
1 parent e41a9be commit cf3b085
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions collector/utils/WhisperProviders/OpenAiWhisper.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ class OpenAiWhisper {
.create({
file: fs.createReadStream(fullFilePath),
model: this.model,
response_format: "text",
temperature: this.temperature,
})
.then((response) => {
Expand All @@ -33,7 +32,7 @@ class OpenAiWhisper {
};
}

return { content: response, error: null };
return { content: response.text, error: null };
})
.catch((error) => {
this.#log(
Expand Down

0 comments on commit cf3b085

Please sign in to comment.