Non-English videos: hardcoded --sub-langs "en.*" fetches the auto-translated track (429s, and worse transcripts when it succeeds)
Summary
download.py hardcodes --sub-langs "en.*", so on a non-English video yt-dlp is asked for YouTube's auto-translated English track rather than the original-language captions. Two consequences:
Rate limiting. Auto-translated caption tracks are throttled far more aggressively than the original-language track. On a Korean video I hit
HTTP Error 429: Too Many Requestsonenrepeatedly, whilekodownloaded instantly (110 KB, <1s) in the same minute. Since theenfetch was the only one attempted,/watchfell through to "no subtitles" and (keyless) produced a frames-only report for a video that has perfectly good captions.Transcript quality. Even when the
enfetch succeeds, the auto-translation is materially worse than the source track: fewer segments, heavily overlapping/duplicated cues, and lost nuance.
Same 2-minute range of the same video, captions only:
en (auto-translated) — 24 segments[00:25] wanted to stay in a village, eat delicious food, and get a glimpse of the local people's lives. So, I plan to stay here in Gangjin for a while and try a bit of a "living travel" experience.
[00:28] a while and try a bit of a "living travel" experience. Among the many places,
[00:31] Among the many places,ko (original) — 32 segments[00:22] 그 지역 사람들의 삶도 좀 엿보고 그러고 싶었는데 그래서 이곳 강진에
[00:25] 그러고 싶었는데 그래서 이곳 강진에 잠시 머무르면서 살이 좀 여행을
[00:28] 잠시 머무르면서 살이 좀 여행을 해보려고 합니다 많지 중에이 전라남도Reproduce
python3 skills/watch/scripts/watch.py "https://www.youtube.com/watch?v=l9t23gFQ67E" \
--detail transcript --start 0 --end 120(Korean-language video, auto-captions only, no manual subs.)
Observed: WARNING: Unable to download video subtitles for 'en': HTTP Error 429 → Transcript: none available.
Confirming the original track is fine:
yt-dlp --skip-download --write-auto-subs --sub-langs "ko" --sub-format vtt -o "t.%(ext)s" \
"https://www.youtube.com/watch?v=l9t23gFQ67E"
# → t.ko.vtt, 110 KB, no 429Affected code
skills/watch/scripts/download.py:78(fetch_captions) and:135(download_url) —"--sub-langs", "en.*"skills/watch/scripts/download.py:44(_pick_subtitle) — prefers.en./.en-US./.en-GB./.en-orig., so even when an original-language VTT is present it is passed over.
Suggested fix
Ask for the original language alongside English, and prefer the original track when picking. yt-dlp's info.json already carries the answer in language (e.g. "ko"), so no extra request is needed:
def _original_language(out_dir: Path) -> str | None:
"""Original spoken language of the video, per yt-dlp's info.json."""
try:
raw = json.loads((out_dir / "video.info.json").read_text(encoding="utf-8"))
except Exception:
return None
lang = raw.get("language") or raw.get("original_language")
return lang.split("-")[0] if isinstance(lang, str) and lang else None
def _pick_subtitle(out_dir: Path) -> Path | None:
candidates = sorted(out_dir.glob("video*.vtt"))
if not candidates:
return None
# Prefer the original spoken language: YouTube's auto-translated tracks
# duplicate overlapping cues and lose nuance.
orig = _original_language(out_dir)
if orig:
native = [c for c in candidates if f".{orig}." in c.name or f".{orig}-" in c.name]
if native:
return native[0]
preferred = [
c for c in candidates
if any(marker in c.name for marker in (".en.", ".en-US.", ".en-GB.", ".en-orig."))
]
return preferred[0] if preferred else candidates[0]--sub-langs needs to request the original too. A general fix would derive the list from the probed language; the minimal version is to widen the pattern. English-language videos are unaffected either way, since _original_language returns en and the existing English preference still applies (and it falls back untouched when info.json is missing or unparseable).
Happy to open a PR if you'd like the general version (probe language first, then request <lang>,en.*).
Environment
- watch 0.2.0 (Claude Code plugin install)
- macOS 15.5 (Darwin 25.5.0), arm64
- yt-dlp and ffmpeg 9.0.1 via Homebrew
- Keyless (no Whisper key),
WATCH_DETAIL=balanced
Note
Verified against the video above; the transcript excerpts are from actual runs before and after the change.
Source: bradautomates/claude-video