Generating
Transcription
Transcribes audio into the input language.
npm i @xsai/generate-transcriptionExamples
Basic
import { } from '@xsai/generate-transcription'
import { } from 'node:fs'
const { } = await ({
: '',
: 'http://localhost:8000/v1/',
: await ('./test/fixtures/basic.wav', { : 'audio/wav' }),
: 'basic.wav',
: 'en',
: 'deepdml/faster-whisper-large-v3-turbo-ct2',
})Verbose + Segments
import { } from '@xsai/generate-transcription'
import { } from 'node:fs'
const { , , , } = await ({
: '',
: 'http://localhost:8000/v1/',
: await ('./test/fixtures/basic.wav', { : 'audio/wav' }),
: 'basic.wav',
: 'en',
: 'deepdml/faster-whisper-large-v3-turbo-ct2',
: 'verbose_json',
})Verbose + Words
import { } from '@xsai/generate-transcription'
import { } from 'node:fs'
const { , , , } = await ({
: '',
: 'http://localhost:8000/v1/',
: await ('./test/fixtures/basic.wav', { : 'audio/wav' }),
: 'basic.wav',
: 'en',
: 'deepdml/faster-whisper-large-v3-turbo-ct2',
: 'verbose_json',
: 'word',
})