Skip to main content

Transcription

Available Models

A full list of models can be viewed on the Models page or retrieved dynamically via API endpoints: https://openai.bothub.chat/v1/models and https://bothub.chat/api/v2/replicate/v1/models

Transcription is the process of converting audio or speech into text. With the available model, you can automatically recognize speech from: voice messages, interviews and podcasts, calls and meetings, videos and streams, and voice recordings.

This is convenient for creating subtitles, searching through audio, automating customer support, and processing voice content. Currently, the following model is available for transcription:

  • whisper-1

The model supports many languages, is capable of recognizing noisy speech, and is well-suited for both short and long audio files.


Supported File Formats​

The API supports popular audio formats: mp3, mp4, mpeg, mpga, m4a, wav, webm.


Transcription Example​

import OpenAI from 'openai';
import fs from 'fs';

const openai = new OpenAI({
apiKey: 'YOUR_BOTHUB_API_KEY',
baseURL: 'https://openai.bothub.chat/v1'
});

async function main() {
const { text } = await openai.audio.transcriptions.create({
file: fs.createReadStream("/path/to/file.mp3"),
model: "whisper-1",
});

console.log(text)
}

main();

Main Parameters​

ParameterTypeDescription
filefileAudio file for transcription
modelstringSpeech recognition model (whisper-1)
languagestringAudio language in ISO-639-1 format (optional)
promptstringAdditional context to improve recognition
response_formatstringResponse format (json, text, srt, verbose_json, vtt)
temperaturenumberRandomness/variability level of generation

Recommendations​

info

For more accurate transcription, it is recommended to:

  • use a high-quality audio source
  • minimize background noise
  • specify the language using the language parameter
  • split long recordings into several parts

You can view the official OpenAI documentation here