atc-transcription
v1.0.0
Published
React Native module for transcribing WAV files using WhisperKit
Downloads
5
Maintainers
Readme
ATC Transcription
A React Native module for transcribing WAV files using WhisperKit.
Installation
npm install atc-transcriptionFor iOS, you'll need to add WhisperKit to your Podfile:
pod 'WhisperKit'Then run:
cd ios && pod installUsage
import ATCTranscriptionModule from 'atc-transcription';
const transcribeAudio = async (filePath: string) => {
try {
const result = await ATCTranscriptionModule.transcribeAudio(filePath);
console.log('Transcription:', result.text);
console.log('Segments:', result.segments);
} catch (error) {
console.error('Transcription failed:', error);
}
};API
transcribeAudio(filePath: string): Promise<TranscriptionResult>
Transcribes an audio file at the given path.
Parameters:
filePath: Absolute path to the WAV file
Returns:
TranscriptionResult: Object containing the full transcription text and segmented results
Types
interface TranscriptionSegment {
start: number;
end: number;
text: string;
}
interface TranscriptionResult {
text: string;
segments: TranscriptionSegment[];
}Requirements
- iOS 13.0+
- React Native 0.60+
- WhisperKit framework
License
MIT
