@juspay/neurolink
Version:
The pipe layer of an AI nervous system: one interface connecting provider neurons to your application, across three inference types — generate, stream and decide. `decide` returns typed, calibrated judgements from a non-generative model (~400ms, ~$0.00002
41 lines (40 loc) • 1.27 kB
TypeScript
/**
* Deepgram Speech-to-Text Handler
*
* Implementation of STT using Deepgram's Speech Recognition API.
*
* @module voice/providers/DeepgramSTT
*/
import type { TTSAudioFormat, STTHandler, STTLanguage, STTOptions, STTResult, TranscriptionSegment } from "../../types/index.js";
/**
* Deepgram Speech-to-Text Handler
*
* Supports real-time streaming, speaker diarization, and smart formatting.
*
* @see https://developers.deepgram.com/docs
*/
export declare class DeepgramSTT implements STTHandler {
private readonly apiKey;
private readonly baseUrl;
/**
* Maximum audio duration in seconds (2 hours)
*/
readonly maxAudioDuration = 7200;
/**
* Deepgram supports streaming
*/
readonly supportsStreaming = true;
constructor(apiKey?: string);
isConfigured(): boolean;
getSupportedFormats(): TTSAudioFormat[];
getSupportedLanguages(): Promise<STTLanguage[]>;
transcribe(audio: Buffer | ArrayBuffer, options?: STTOptions): Promise<STTResult>;
/**
* Streaming transcription using WebSocket
*/
transcribeStream(audioStream: AsyncIterable<Buffer>, options: STTOptions): AsyncIterable<TranscriptionSegment>;
/**
* Get MIME type for audio format
*/
private getMimeType;
}