xsAI v0.3 "future base" is now available! Read Announcement
xsAI0.4.0-beta.10
Streaming

Transcription

Transcribes audio into the input language.

install sizeminified sizeminzipped size
npm i @xsai/stream-transcription

Examples

Before using this package, please verify that your provider supports "stream": true.

Basic

import {  } from '@xsai/stream-transcription'
import {  } from 'node:fs'

const {  } = ({
  : '',
  : 'https://api.openai.com/v1/',
  : await ('./test/fixtures/basic.wav', { : 'audio/wav' }),
  : 'basic.wav',
  : 'en',
  : 'gpt-4o-transcribe',
})

On this page