This commit is contained in:
2025-06-17 03:15:18 -07:00
parent d0f15d15a8
commit 18aec0b78e
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -4,7 +4,7 @@ txtlyric-to-lrc aligns lyrics to songs in the [lrc](https://en.wikipedia.org/wik
This is a wrapper around [stable-ts](https://github.com/jianfch/stable-ts) ([whisper](https://github.com/openai/whisper)) that is designed to be used with known-good transcriptions like untimed song lyrics. This is a wrapper around [stable-ts](https://github.com/jianfch/stable-ts) ([whisper](https://github.com/openai/whisper)) that is designed to be used with known-good transcriptions like untimed song lyrics.
Lyrics are expected to be placed alongside media files in `txt` files, and lines of lyrics should be separated by newlines. Output files will be placed alongside media in `lrc` files. Lyrics are expected to be placed alongside media files in `txt` files, and lines of lyrics (segments) should be separated by newlines. Output `lrc` files will be written out alongside the original `txt` and media files.
## How to Use ## How to Use
```sh ```sh
@@ -15,7 +15,7 @@ Options:
-h, --help Show this message and exit. -h, --help Show this message and exit.
-m, --model TEXT Which whisper model to use (choices are those of -m, --model TEXT Which whisper model to use (choices are those of
whisper.available_models) whisper.available_models)
-l, --language TEXT [required] -l, --language TEXT What language the lyrics are in [required]
``` ```
## How to Develop ## How to Develop
+1 -1
View File
@@ -19,7 +19,7 @@ song_file_extensions = set([
@click.command() @click.command()
@click.help_option("--help", "-h") @click.help_option("--help", "-h")
@click.option('--model', '-m', default='small', help='Which whisper model to use (choices are those of whisper.available_models)') @click.option('--model', '-m', default='small', help='Which whisper model to use (choices are those of whisper.available_models)')
@click.option('--language', '-l', required=True) @click.option('--language', '-l', required=True, help='What language the lyrics are in')
@click.argument('directory') @click.argument('directory')
def main(model, language, directory): def main(model, language, directory):
print(f"Loading {model} model for use with language {language}...") print(f"Loading {model} model for use with language {language}...")