Gettr Transcribe (MLX Whisper)
Quick start
CODEBLOCK0
To explicitly set the transcription language (recommended for non-English content):
CODEBLOCK1
Common language codes: zh (Chinese), en (English), ja (Japanese), ko (Korean), es (Spanish), fr (French), de (German), ru (Russian).
This outputs:
Summarization is handled separately by the caller (see your prompt for summarization instructions).
Workflow (GETTR URL → transcript)
Inputs to confirm
Ask for:
- - GETTR post URL
- Language (optional): if the video is non-English and auto-detection fails, ask for the language code (e.g.,
zh for Chinese)
Notes:
- - This skill does not handle authentication-gated GETTR posts.
- This skill does not translate; outputs stay in the video's original language.
- If transcription quality is poor or mixed with English, re-run with explicit
--language flag.
Prereqs (local)
- -
mlx_whisper installed and on PATH - INLINECODE13 installed (recommended:
brew install ffmpeg)
Step 0 — Parse the slug and pick an output directory
Parse the slug directly from the GETTR URL — just read the last path segment, no script needed:
- -
https://gettr.com/post/p1abc2def → slug = INLINECODE16 - INLINECODE17 → slug = INLINECODE18
Output directory: INLINECODE19
Directory structure:
- - INLINECODE20
- INLINECODE21
Step 1 — Get the audio/video URL via browser automation
Use browser automation to navigate to the GETTR URL and extract the media URL from the rendered DOM.
For /streaming/ URLs (primary path)
Streaming pages provide a direct .m4a audio download. Extract it by deriving from the og:video meta tag:
- 1. Navigate to the GETTR streaming URL and wait for the page to fully load (JavaScript must execute)
- Extract the audio URL via JavaScript:
const ogVideo = document.querySelector('meta[property="og:video"]')?.getAttribute("content");
// Replace .m3u8 with /audio.m4a to get the direct audio download URL
const audioUrl = ogVideo.replace(".m3u8", "/audio.m4a");
- 3. Use the
.m4a URL for the pipeline in Step 2
The .m4a URL is a direct file download (no HLS), so it downloads faster and more reliably than the .m3u8 stream.
For /post/ URLs (fallback path)
Post pages do not have a "Download Audio" button. Extract the og:video URL from the rendered DOM:
- 1. Navigate to the GETTR post URL and wait for the page to fully load
- Extract the video URL via JavaScript:
document.querySelector('meta[property="og:video"]')?.getAttribute("content");
- 3. Use the
.m3u8 URL directly for the pipeline in Step 2
If browser automation is not available or fails, see references/troubleshooting.md for how to guide the user to manually extract the URL from their browser.
Step 2 — Run the pipeline (download + transcribe)
Feed the extracted URL and slug into the pipeline:
CODEBLOCK4
To explicitly set the language (recommended when auto-detection fails):
CODEBLOCK5
The pipeline does two things:
- 1. Downloads audio as 16kHz mono WAV via ffmpeg (handles both
.m4a and .m3u8 inputs) - Transcribes with MLX Whisper, outputting VTT with timestamps
If the pipeline fails with HTTP 412 (stale signed URL)
This error occurs with /streaming/ URLs when the signed URL has expired. Re-run browser automation to get a fresh URL, then retry the pipeline.
If browser automation is not available or fails, see references/troubleshooting.md for how to guide the user to manually extract the fresh URL from their browser.
Notes:
- - By default, language is auto-detected. For non-English content where detection fails, use
--language. - If too slow or memory-heavy, try smaller models:
mlx-community/whisper-medium or mlx-community/whisper-small. - If quality is poor, try the full model:
mlx-community/whisper-large-v3 (slower but more accurate). - If
--word-timestamps causes issues, the pipeline retries automatically without it.
Bundled scripts
- -
scripts/run_pipeline.sh: download + transcription pipeline (takes an audio/video URL and slug) - INLINECODE42 : download/extract audio from HLS (.m3u8) or direct (.m4a) URL to 16kHz mono WAV
Error handling
- - No audio track: The download script validates output and reports if the source has no audio.
- HTTP 412 errors: Occurs with
/streaming/ URLs when the signed URL has expired. Re-run browser automation to get a fresh URL (see Step 1); if that fails, see references/troubleshooting.md.
Troubleshooting
See references/troubleshooting.md for detailed solutions to common issues including:
- - HTTP 412 errors (stale signed URLs)
- Download errors
- Transcription quality issues
Gettr 转录 (MLX Whisper)
快速开始
bash
1. 从URL中解析slug(直接读取即可——无需脚本)
https://gettr.com/post/p1abc2def → slug = p1abc2def
https://gettr.com/streaming/p3xyz → slug = p3xyz
2. 通过浏览器自动化获取音频/视频URL(参见下方步骤1)
对于 /streaming/ 类型的URL:提取 .m4a 音频URL
对于 /post/ 类型的URL:提取 og:video 的 .m3u8 URL
3. 运行下载+转录流水线
bash scripts/run_pipeline.sh <音频或视频URL>
如需显式指定转录语言(建议非英语内容使用):
bash
bash scripts/run_pipeline.sh --language zh <音频或视频URL>
常用语言代码:zh(中文)、en(英语)、ja(日语)、ko(韩语)、es(西班牙语)、fr(法语)、de(德语)、ru(俄语)。
输出结果:
- - ./out/gettr-transcribe//audio.wav
- ./out/gettr-transcribe//audio.vtt
摘要生成由调用方单独处理(请参考您的提示词了解摘要生成说明)。
工作流程(GETTR URL → 转录文本)
需要确认的输入
请询问:
- - GETTR 帖子URL
- 语言(可选):如果视频为非英语且自动检测失败,请询问语言代码(例如中文使用 zh)
注意事项:
- - 本技能不处理需要身份验证的GETTR帖子。
- 本技能不进行翻译;输出内容保持视频原始语言。
- 如果转录质量较差或混有英语,请使用显式 --language 参数重新运行。
本地先决条件
- - 已安装 mlx_whisper 并配置在PATH中
- 已安装 ffmpeg(推荐:brew install ffmpeg)
步骤0 — 解析slug并选择输出目录
直接从GETTR URL中解析slug——只需读取最后一个路径段,无需脚本:
- - https://gettr.com/post/p1abc2def → slug = p1abc2def
- https://gettr.com/streaming/p3xyz789 → slug = p3xyz789
输出目录:./out/gettr-transcribe//
目录结构:
- - ./out/gettr-transcribe//audio.wav
- ./out/gettr-transcribe//audio.vtt
步骤1 — 通过浏览器自动化获取音频/视频URL
使用浏览器自动化导航到GETTR URL,并从渲染后的DOM中提取媒体URL。
对于 /streaming/ 类型的URL(主要路径)
流媒体页面提供直接的 .m4a 音频下载。通过从 og:video 元标签推导获取:
- 1. 导航到GETTR流媒体URL,等待页面完全加载(JavaScript必须执行)
- 通过JavaScript提取音频URL:
javascript
const ogVideo = document.querySelector(meta[property=og:video])?.getAttribute(content);
// 将 .m3u8 替换为 /audio.m4a 以获取直接音频下载URL
const audioUrl = ogVideo.replace(.m3u8, /audio.m4a);
- 3. 在步骤2的流水线中使用 .m4a URL
.m4a URL是直接文件下载(非HLS),因此比 .m3u8 流下载更快、更可靠。
对于 /post/ 类型的URL(备用路径)
帖子页面没有下载音频按钮。从渲染后的DOM中提取 og:video URL:
- 1. 导航到GETTR帖子URL,等待页面完全加载
- 通过JavaScript提取视频URL:
javascript
document.querySelector(meta[property=og:video])?.getAttribute(content);
- 3. 在步骤2的流水线中直接使用 .m3u8 URL
如果浏览器自动化不可用或失败,请参阅 references/troubleshooting.md 了解如何引导用户手动从浏览器中提取URL。
步骤2 — 运行流水线(下载+转录)
将提取的URL和slug输入流水线:
bash
bash scripts/run_pipeline.sh <音频或视频URL>
如需显式设置语言(建议在自动检测失败时使用):
bash
bash scripts/run_pipeline.sh --language zh <音频或视频URL>
流水线执行两项操作:
- 1. 通过ffmpeg将音频下载为16kHz单声道WAV格式(支持 .m4a 和 .m3u8 输入)
- 使用MLX Whisper进行转录,输出带时间戳的VTT格式
如果流水线因HTTP 412错误(签名URL过期)而失败
此错误发生在 /streaming/ 类型的URL中,当签名URL已过期时。重新运行浏览器自动化以获取新的URL,然后重试流水线。
如果浏览器自动化不可用或失败,请参阅 references/troubleshooting.md 了解如何引导用户手动从浏览器中提取新的URL。
注意事项:
- - 默认情况下,语言会自动检测。对于检测失败的非英语内容,请使用 --language 参数。
- 如果速度太慢或内存占用过高,请尝试较小的模型:mlx-community/whisper-medium 或 mlx-community/whisper-small。
- 如果质量较差,请尝试完整模型:mlx-community/whisper-large-v3(较慢但更准确)。
- 如果 --word-timestamps 导致问题,流水线会自动重试而不使用该参数。
捆绑脚本
- - scripts/runpipeline.sh:下载+转录流水线(接收音频/视频URL和slug)
- scripts/downloadaudio.sh:从HLS(.m3u8)或直接(.m4a)URL下载/提取音频为16kHz单声道WAV格式
错误处理
- - 无音轨:下载脚本会验证输出,并在源文件没有音频时报告。
- HTTP 412错误:当签名URL过期时,/streaming/ 类型的URL会出现此错误。重新运行浏览器自动化以获取新的URL(参见步骤1);如果失败,请参阅 references/troubleshooting.md。
故障排除
请参阅 references/troubleshooting.md 了解常见问题的详细解决方案,包括:
- - HTTP 412错误(过期的签名URL)
- 下载错误
- 转录质量问题