Online demo: https://whisper.ggerganov.com/command/
-Terminal version: https://github.com/ggerganov/whisper.cpp/examples/command
+Terminal version: [examples/command](/examples/command)
## Build instructions
\r
https://user-images.githubusercontent.com/1991296/204038393-2f846eae-c255-4099-a76d-5735c25c49da.mp4\r
\r
-Web version: https://github.com/ggerganov/whisper.cpp/examples/command.wasm\r
+Web version: [examples/command.wasm](/examples/command.wasm)\r
\r
## Building\r
\r
https://user-images.githubusercontent.com/1991296/197385372-962a6dea-bca1-4d50-bf96-1d8c27b98c81.mp4
+Real-time transcription demo:
+
+https://user-images.githubusercontent.com/1991296/204126266-ce4177c6-6eca-4bd9-bca8-0e46d9da2364.mp4
+
## Usage
```java
params.language = "en";
params.n_threads = max_threads;
params.offset_ms = 0;
+ params.no_context = true;
params.single_segment = self->stateInp.isRealtime;
CFTimeInterval startTime = CACurrentMediaTime();
result = [result stringByAppendingString:[NSString stringWithUTF8String:text_cur]];
}
+ const float tRecording = (float)self->stateInp.n_samples / (float)self->stateInp.dataFormat.mSampleRate;
+
// append processing time
- result = [result stringByAppendingString:[NSString stringWithFormat:@"\n\n[processing time: %5.3f s]", endTime - startTime]];
+ result = [result stringByAppendingString:[NSString stringWithFormat:@"\n\n[recording time: %5.3f s]", tRecording]];
+ result = [result stringByAppendingString:[NSString stringWithFormat:@" \n[processing time: %5.3f s]", endTime - startTime]];
// dispatch the result to the main thread
dispatch_async(dispatch_get_main_queue(), ^{