Skip to content

Live Transcription from Twilio Voice Stream (Nodejs) - Please help debug #127

Closed Answered by swiecki
kaliq-i asked this question in General help
Discussion options

You must be logged in to vote

Have you checked to make sure the encoding types match what the APIs want? Twilio spits out audio/x-mulaw at a sample rate of 8000 hz. Deepgram can accept that but you need to specify:

const deepgramLive = transcriber.transcription.live({
      punctuate: true,
      endpointing: true,
      language: "en-GB",
      encoding: "mulaw",
      sample_rate: 8000,
    });

My understanding is Twilio's audio will be audio/x-mulaw once decoded from base64. If that's the case then you may need to decode the strings before passing them with the above encoding.

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by SandraRodgers
Comment options

You must be logged in to vote
1 reply
@SandraRodgers
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants