YouTube transcripts via yt-dlp audio + Whisper transcription
- YouTube delivers audio and video streams via the same CDN infrastructure; cloud IP restrictions that block `yt-dlp` video downloads also block `yt-dlp` audio-only downloads from GitHub Actions runners running on AWS IP ranges
- As of 2024–2025, yt-dlp downloads from cloud/datacenter IPs (including GitHub Actions) are actively blocked by YouTube, producing HTTP 403 errors or "Sign in to confirm you're not a bot" challenges, regardless of whether the requested format is video or audio
- The only currently identified workaround that avoids paid third-party infrastructure is passing browser-exported cookies to yt-dlp via `--cookies`, stored as a base64-encoded GitHub Actions secret — but this requires periodic manual maintenance as cookies expire within weeks to months
- Using vanilla `openai-whisper` with the `small` model on a CPU-only GitHub Actions runner, transcribing a 60-minute audio file takes approximately 72–120 minutes — not the "3–5 minutes" estimated in the original item, which appears to assume GPU availability
- `faster-whisper` with int8 quantization delivers 4–7x speedup over vanilla `openai-whisper` on CPU, reducing the same 60-min audio to ~7–15 minutes of runner time, making the approach economically viable on the free Actions tier
- The Whisper `small` model achieves 3.2–3.4% WER on clean English speech; `medium` achieves 2.7–2.9% WER — a 0.5–0.7 percentage point improvement that widens for noisy or accented audio but is modest for well-recorded English talks
- The `small` model requires ~461 MB download; `medium` requires ~1.5 GB. Both should be cached via `actions/cache` to avoid re-downloading on every workflow run
- Option B (OpenAI Whisper API at `whisper-1`, $0.006/min) requires `OPENAI_API_KEY`, which is not in the AGENTS.md approved credentials table; it cannot be implemented without explicit owner approval
Research Question
Can we bypass YouTube's IP-based transcript block by downloading the audio track with
yt-dlp (a different endpoint from the transcript API) and then transcribing it with
OpenAI Whisper?
Findings
Executive Summary
The hypothesis that yt-dlp audio CDN downloads are less restricted than the transcript API on GitHub Actions IPs is false: audio and video both traverse the same YouTube CDN infrastructure and are subject to the same cloud IP block. This means the proposed fallback chain (caption fetch fails → audio download → local Whisper) fails at the second step from any GitHub Actions runner. If the audio download barrier is cleared — most likely via browser cookies stored as a GitHub secret — faster-whisper with int8 quantization on the small model provides a practical transcription path (~7–15 min per 60-min talk, free). Option B (Whisper API) is blocked by the credential gate: OPENAI_API_KEY is not an approved credential.
Key Findings
- [high] YouTube delivers audio and video streams via the same CDN infrastructure; cloud IP restrictions that block
yt-dlpvideo downloads also blockyt-dlpaudio-only downloads from GitHub Actions runners running on AWS IP ranges. - [high] As of 2024–2025, yt-dlp downloads from cloud/datacenter IPs (including GitHub Actions) are actively blocked by YouTube, producing HTTP 403 errors or "Sign in to confirm you're not a bot" challenges, regardless of whether the requested format is video or audio.
- [high] The only currently identified workaround that avoids paid third-party infrastructure is passing browser-exported cookies to yt-dlp via
--cookies, stored as a base64-encoded GitHub Actions secret — but this requires periodic manual maintenance as cookies expire within weeks to months. - [high] Using vanilla
openai-whisperwith thesmallmodel on a CPU-only GitHub Actions runner, transcribing a 60-minute audio file takes approximately 72–120 minutes — not the "3–5 minutes" estimated in the original item, which appears to assume GPU availability. - [high]
faster-whisperwith int8 quantization delivers 4–7x speedup over vanillaopenai-whisperon CPU, reducing the same 60-min audio to ~7–15 minutes of runner time, making the approach economically viable on the free Actions tier. - [medium] The Whisper
smallmodel achieves 3.2–3.4% WER on clean English speech;mediumachieves 2.7–2.9% WER — a 0.5–0.7 percentage point improvement that widens for noisy or accented audio but is modest for well-recorded English talks. - [high] The
smallmodel requires ~461 MB download;mediumrequires ~1.5 GB. Both should be cached viaactions/cacheto avoid re-downloading on every workflow run. - [high] Option B (OpenAI Whisper API at
whisper-1, $0.006/min) requiresOPENAI_API_KEY, which is not in the AGENTS.md approved credentials table; it cannot be implemented without explicit owner approval. - [medium] The OpenAI Whisper API
whisper-1model is equivalent in quality tolarge-v2locally, delivering higher accuracy than any local model size runnable on GitHub Actions CPU within a reasonable time budget. - [medium] Third-party transcript APIs (the companion backlog item
2026-02-28-transcript-via-third-party-apis.md) sidestep the cloud IP block entirely and may offer a better cost/complexity tradeoff than maintaining YouTube cookies in a GitHub secret.
Assumptions
- [assumption] GitHub Actions runners use AWS IP ranges. Justification: GitHub-hosted runners are known to run on Azure and AWS infrastructure; both are in cloud IP ranges that YouTube blocks. This assumption is consistent with the prior research item's documented block.
- [assumption] The cookies workaround would require the owner to use a personal Google account. Justification: The research corpus does not specify a dedicated YouTube account. Using a personal account exposes personal cookies to GitHub Secrets, which is a security consideration.
Analysis
The evidence converges on a clear conclusion: the hypothesis is false, and the proposed architecture cannot work without first solving the same cloud IP block problem that the transcript API approach already fails on.
The yt-dlp + Whisper approach has genuine merit as a Tier 2 fallback if audio download succeeds — the faster-whisper int8 optimisation resolves the runtime concern entirely, and the small model accuracy is adequate for research transcription. The approach becomes viable under one of: (a) the cookies workaround is accepted by the owner with its maintenance requirements; (b) a third-party proxy is interposed; or (c) YouTube's blocking policy changes.
The original item's runtime estimate ("~3–5 min for a 60-min talk on a free GitHub runner") deserves correction: it appears to have assumed GPU availability. The ubuntu-latest free runner is CPU-only, and vanilla whisper-small takes 72–120 minutes on that hardware. faster-whisper resolves this but was not mentioned in the original design. Any implementation should use faster-whisper, not openai-whisper.
Option B was correctly identified as the simpler path, but it introduces an unapproved credential. The cost ($0.36/hour) is low enough to be acceptable for a personal research workflow, but the credential gate must be addressed first.
Risks, Gaps, and Uncertainties
- Empirical testing not performed. The blocking of yt-dlp from GitHub Actions is well-documented in community reports but not tested in this specific repository's workflow. A 5-minute test step in
fetch-transcript.ymlwould confirm the block definitively. - Cookies lifespan is variable. There is no community consensus on the exact expiry window; some report weeks, others months. The operational burden of the cookies approach is therefore uncertain.
- faster-whisper accuracy at int8. The benchmark comparison between float32 and int8 Whisper small shows negligible WER difference in most tests, but this is not universally verified for domain-specific technical vocabulary in research talks.
- Sources marked
[ ]: The three primary sources in the item's Sources section (yt-dlp GitHub, openai/whisper GitHub, OpenAI platform docs) were not directly read; they are represented by secondary evidence. Their content is well-characterised in the literature.
Open Questions
- Should the owner approve
OPENAI_API_KEYfor the Whisper API path? At $0.006/min, a year of weekly 60-min talk transcriptions would cost ~$18.72 — a low barrier for the accuracy gain. - Does the third-party API research item (
2026-02-28-transcript-via-third-party-apis.md) yield a cleaner solution that avoids cookies maintenance entirely? - What is the empirical yt-dlp exit code from this repository's GitHub Actions runner? A single test step would close the uncertainty about whether this runner's IPs are actually blocked.
Open Questions
- Are
yt-dlpaudio CDN endpoints blocked from GitHub Actions AWS IP ranges? - What is accuracy difference between
smallandmediumWhisper models for academic talk audio? - Is the runtime acceptable on a free GitHub runner for talks > 60 minutes?
sources
- [ ]
yt-dlpdocs - [ ] OpenAI Whisper (local)
- [ ] OpenAI Whisper API