Validate config for transcribe command.
(config: dict)
| 158 | |
| 159 | |
| 160 | def validate_transcribe(config: dict) -> bool: |
| 161 | """Validate config for transcribe command.""" |
| 162 | asr = get(config, "transcribe.asr", "faster-whisper") |
| 163 | |
| 164 | if asr == "whisper-api": |
| 165 | return validate_whisper_api(config) |
| 166 | if asr == "faster-whisper": |
| 167 | return validate_faster_whisper() |
| 168 | if asr == "whisper-cpp": |
| 169 | return validate_whisper_cpp() |
| 170 | # bijian/jianying: no config needed (public endpoints) |
| 171 | return True |
| 172 | |
| 173 | |
| 174 | def validate_subtitle(config: dict) -> bool: |
no test coverage detected