Public declaration syntax from forge-ts/packages/forge-media/src/transcription.ts Original source SHA-256: 7be0cbc6e1d295993b410f0d6055173a101fd9b374078fef6497c095258ea0e3 Function bodies and constant values are omitted. This is not the complete implementation. Source line 15 export interface TranscriptionSegment { /** Start time of the segment in seconds. */ readonly start: number; /** End time of the segment in seconds. */ readonly end: number; /** The transcribed text for this segment. */ readonly text: string; } Source line 27 export interface TranscriptionOptions { /** Language hint (ISO 639-1 code, e.g., 'en', 'fr', 'de'). */ readonly language?: string; /** Prompt hint to guide the transcription model. */ readonly prompt?: string; } Source line 37 export interface TranscriptionResult { /** The full transcribed text. */ readonly text: string; /** The detected or specified language. */ readonly language?: string; /** Duration of the audio in seconds, if known. */ readonly durationSeconds?: number; /** Word-level or sentence-level timing segments. */ readonly segments: readonly TranscriptionSegment[]; } Source line 65 export interface TranscriptionProvider { /** Returns the model identifier. */ modelId(): string; /** Returns the provider name. */ providerName(): string; /** * Transcribes audio to text. * * @param audio - The raw audio data. * @param options - Optional transcription parameters. * @returns The transcription result. * @throws {ForgeMediaError} If transcription fails. */ transcribe(audio: Uint8Array, options?: TranscriptionOptions): Promise; } Source line 97 export async function transcribe( provider: TranscriptionProvider, audio: Uint8Array, options?: TranscriptionOptions ): Promise;