ggerganov commited on
Commit
cd282f3
·
unverified ·
1 Parent(s): d8f85b8

Update README.md

Browse files
Files changed (1) hide show
  1. examples/stream/README.md +17 -0
examples/stream/README.md CHANGED
@@ -10,6 +10,23 @@ More info is available in [issue #10](https://github.com/ggerganov/whisper.cpp/i
10
 
11
  https://user-images.githubusercontent.com/1991296/194935793-76afede7-cfa8-48d8-a80f-28ba83be7d09.mp4
12
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
13
  The `stream` tool depends on SDL2 library to capture audio from the microphone. You can build it like this:
14
 
15
  ```bash
 
10
 
11
  https://user-images.githubusercontent.com/1991296/194935793-76afede7-cfa8-48d8-a80f-28ba83be7d09.mp4
12
 
13
+ ## Slidingwindow mode
14
+
15
+ Setting the `--step` argument to `0` enables the sliding window mode:
16
+
17
+ ```java
18
+ ./stream -m ./models/ggml-small.en.bin -t 6 --step 0 --length 30000 -vth 0.6
19
+ ```
20
+
21
+ In this mode, the tool will transcribe only after some speech activity is detected. A very
22
+ basic VAD detector is used, but in theory a more sophisticated approach can be added. The
23
+ `-vth` argument determines the VAD threshold - higher values will make it detect silence more often.
24
+ It's best to tune it to the specific use case, but a value around `0.6` should be OK in general.
25
+ When silence is detected, it will transcribe the last `--length` milliseconds of audio and output
26
+ a transcription block that is suitable for parsing.
27
+
28
+ ## Building
29
+
30
  The `stream` tool depends on SDL2 library to capture audio from the microphone. You can build it like this:
31
 
32
  ```bash