Function: transcribePieces()
transcribePieces(
pieces,transcribe,options):Promise<{pieces:PieceOutcome[];seconds:number;text:string; }>
Defined in: packages/agentos/src/io/hearing/transcribePieces.ts:163
Transcribes the pieces; answers the whole text and each piece's outcome.
Parameters
pieces
The pieces in the order of the recording. An async iterable is asked for its next piece only when the job has room to send it.
Iterable<PieceInput, any, any> | AsyncIterable<PieceInput, any, any>
transcribe
The caller's transcription of one piece.
options
The sentence cut, and how the job runs.
Returns
Promise<{ pieces: PieceOutcome[]; seconds: number; text: string; }>
text, the pieces' texts joined at their seams, after previousText when one is given; pieces, each
piece's outcome in order; seconds, the sum of the outcomes' seconds.
Throws
When a piece fails every attempt. The pieces before it have been reported to onPiece by
then, and no piece after it is reported.
Throws
The reason of options.signal, after interrupting a pending source read and awaiting pieces in flight.
Throws
The original source or onPiece error, after awaiting pieces in flight.