Skip to content
Discussion options

You must be logged in to vote

The issue was that I was using mime_type. But correct approach was to use mimeType. This discrepancy occurred because I had taken code from python documentation. It would be better if example code is mentioned in the documentation of typescript. I used this code and it worked:

  const audioBuffer = await audioBlob.arrayBuffer();
      const base64Audio = btoa(
        String.fromCharCode(...new Uint8Array(audioBuffer))
      );

      const transcriptionMessage = new HumanMessage({
        content: [
          {
            type: "text",
            text: "Transcribe this audio. Return only the transcribed text without any additional formatting or explanations.",
          },
          { …

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
2 replies
@PaperBoardOfficial
Comment options

@dosubot
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by PaperBoardOfficial
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant