import type { WhisperContext, WhisperContextOptions, VadContext, VadContextOptions, TranscribeOptions, TranscribeResult, GpuDevice } from "./types"; export type { WhisperContextOptions, VadContextOptions, TranscribeOptions, TranscribeOptionsBase, TranscribeOptionsFile, TranscribeOptionsBuffer, TranscribeResult, TranscriptSegment, StreamingSegment, StreamingToken, WhisperContext, VadContext, WhisperContextConstructor, VadContextConstructor, GpuDevice, } from "./types"; export declare const WhisperContextClass: import("./types").WhisperContextConstructor; export declare const VadContextClass: import("./types").VadContextConstructor; export declare const transcribe: (context: WhisperContext, options: TranscribeOptions, callback: import("./types").TranscribeCallback) => void; export declare const transcribeAsync: (context: WhisperContext, options: TranscribeOptions) => Promise; /** * Create a new WhisperContext * * @example * ```typescript * const ctx = createWhisperContext({ * model: './models/ggml-base.en.bin', * use_gpu: true, * use_coreml: true, * }); * * const result = await transcribeAsync(ctx, { * fname_inp: './audio.wav', * language: 'en', * }); * * console.log(result.segments); * ctx.free(); * ``` */ export declare function createWhisperContext(options: WhisperContextOptions): WhisperContext; /** * Create a new VadContext for voice activity detection * * @example * ```typescript * const vad = createVadContext({ * model: './models/ggml-silero-v6.2.0.bin', * threshold: 0.5, * }); * * const samples = new Float32Array(512); * const probability = vad.process(samples); * * vad.free(); * ``` */ export declare function createVadContext(options: VadContextOptions): VadContext; /** * Enumerate available GPU backend devices. * Returns an array of GPU/IGPU devices with their properties. * The `index` field matches what `gpu_device` option expects in WhisperContextOptions. * Never throws — returns an empty array if no GPUs are available or on any error. * * @example * ```typescript * const gpus = getGpuDevices(); * for (const gpu of gpus) { * console.log(`[${gpu.index}] ${gpu.description} (${gpu.type}, ${(gpu.memory_total / 1e9).toFixed(1)} GB)`); * } * // Use a specific GPU: * const ctx = createWhisperContext({ model: '...', gpu_device: gpus[1].index }); * ``` */ export declare function getGpuDevices(): GpuDevice[]; declare const _default: { WhisperContext: import("./types").WhisperContextConstructor; VadContext: import("./types").VadContextConstructor; transcribe: (context: WhisperContext, options: TranscribeOptions, callback: import("./types").TranscribeCallback) => void; transcribeAsync: (context: WhisperContext, options: TranscribeOptions) => Promise; createWhisperContext: typeof createWhisperContext; createVadContext: typeof createVadContext; getGpuDevices: typeof getGpuDevices; }; export default _default; //# sourceMappingURL=index.d.ts.map