Open
Description
Description
File: https://github.com/vercel/ai/blob/main/packages/groq/src/groq-transcription-model.ts
Problem:
The current implementation in groq-transcription-model.ts for creating the formData appends a file with a static filename "audio" without an extension:
formData.append('file', new File([blob], 'audio', { type: mediaType }));
This causes the Groq API to return an invalid_request_error because it expects a filename with one of the supported audio file extensions.
Error Message from Groq API:
{
"error": {
"message": "file must be one of the following types: [flac mp3 mp4 mpeg mpga m4a ogg opus wav webm]",
"type": "invalid_request_error"
}
}
AI SDK Version
- "ai": "^4.3.16"
- "@ai-sdk/groq": "^1.2.9"