automatically clean up voice recordings
Project description
autosnip
Automatically clean up voice recordings
You need a text file containing the script and a wav file containing your recording of the script. When you make a mistake, you say a cue word and start over at an earlier point. Then autosnip stitches the good parts together and spits out a ready-to-use wav file.
Setup
Install autosnip:
pip install autosnip
Download and unpack a speech recognition model from https://alphacephei.com/vosk/models for your language.
Usage
Carefully craft your script with depth and wit. Think of a cue word to signal a mistake to autosnip. The cue word should be a word that does not occur in your script. Record yourself reading the script. Whenever you make a mistake or want to rerecord some part for whatever reason, say the cue word and start over at some earlier point in the script, a good place is the start of the current sentence so there is no break in the flow mid sentence. When you are done, feed the script and your recording into autosnip:
autosnip -s my_script.txt -r my_recording.wav -o my_clean_recording.wav -m vosk-model-en-us-0.22 -c oops
Congratulations! You may now publish your recording into the world.
Example
Check out the example directory.
How it Works
Your recording is transcribed using a VOSK speech recognition model. Start and end time of each word are stored. The transcript is then split apart at each occurance of the cue word. For each section, the whole script is scanned to see where this section fits best, so in theory you don't have to read the parts in order. The sections are patched into the script in the order you recorded them, always overwriting any previous recording. Then the corresponding intervals are selected from the recorded wav file and stitched together with short cross fades.
If you are unhappy with the result at some place, you can just make a new recording of that part (starting with the cue word), append it to your previous recording and rerun autosnip.
Project Status
The happy path is working, however the project is still young and not battle-tested. Feel free to report issues! There is also not yet much performance optimization going on. The runtime is probably O(n²) where n is the number of words in your script, so it may be a good idea to record chapter by chapter instead of a whole book in one go.
Happy Recording!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file autosnip-0.1.4.tar.gz.
File metadata
- Download URL: autosnip-0.1.4.tar.gz
- Upload date:
- Size: 9.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7c2d2b2eca13caf9d5b2c36cc2fb8ed1e8cd14473917347a3452c592f39e0f4d
|
|
| MD5 |
cb9ab69f36dd3b7ef94067805cd64bff
|
|
| BLAKE2b-256 |
b647ef505a7b57b29bacfab95d51609610b5672482b927d479f533d98614efff
|
File details
Details for the file autosnip-0.1.4-py3-none-any.whl.
File metadata
- Download URL: autosnip-0.1.4-py3-none-any.whl
- Upload date:
- Size: 20.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b9303a5406564de96e3398e33c2657b9a2eb071931973111a29245ee7ccd5930
|
|
| MD5 |
06f9d3a413fc0d4685930a18559f6bb0
|
|
| BLAKE2b-256 |
20a50a060d722fd778acac8cc4eb2fd3d99e4f03384d133d30f85959a3b77d23
|