Commit 003d26b
Changed files (1)
src
preview
src/preview/ytdlp.py
@@ -258,7 +258,7 @@ async def preview_ytdlp(
await save_messages(messages=sent_messages, key=url, metadata=metadata)
if any(x in info["extractor"] for x in ["youtube", "bilibili"]) and append_transcription and (video_path.is_file() or audio_path.is_file()):
res = await fetch_subtitle(url=url, provider="free")
- subtitles = res.get("subtitle", "")
+ subtitles = res.get("subtitles", "")
if not subtitles:
ytdlp_transcription_engine = "gemini" if "youtube" in info["extractor"] else ytdlp_transcription_engine # use gemini to bypass censorship
res = await asr_file(audio_path, ytdlp_transcription_engine, duration, client=client, message=message, slient=True)