Communitygithub.com

unempyd/revenueos

编辑播客音频或视频——修剪开场/结束闲聊、移除填充词、剪切静音、增强音质,并对视频进行相同编辑。适用于用户要求编辑播客、清理音频、移除填充词、修剪录音或改善语音质量的场景。

revenueos 是什么?

该技能用于将原始播客/会议录音处理成精良的播客剧集。它提供智能修剪(通过转录检测开头/结尾)、填充词移除(如“嗯”、“呃”、“um”、“uh”)、静音压缩(>2秒减少到~0.6秒)、音频增强(降噪、均衡、多说话人音量平衡、标准化至−16 LUFS)及视频同步剪辑等核心能力。支持通过OpenAI Whisper API进行转录,并依赖ffmpeg进行音视频处理。工作流程包括检查文件、查找开始/结束点、应用基于时间戳的填充词移除脚本,以及使用精心设计的滤波器链(含动态音频归一化)进行增强。此外,还支持高亮片段剪辑、一分钟精彩集锦制作(含音乐),以及对已渲染剧集的手术式重新剪辑,无需重新运行整个流水线。

兼容平台~Claude Code✓Codex CLI~Cursor
npx skills add https://github.com/unempyd/revenueos/tree/HEAD/skills/creative/podcast-edit

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

播客编辑技能

将原始播客/会议录音处理成精良的播客剧集。

功能

  1. 智能修剪 — 通过转录检测开场/结尾,找到实际播客开始/结束位置
  2. 填充词移除 — 移除口头习惯:嗯、呃、啊、哦、对对对、um、uh 等。
  3. 静音修剪 — 将长段静音(>2秒)缩短为自然停顿(约0.6秒)
  4. 音频增强 — 降噪、均衡、多说话人音量平衡、响度标准化至播客标准(−16 LUFS)
  5. 重新剪辑已完成的剧集 — 从已渲染的剧集里精确移除标记段落,无需重新运行整个流程
  6. 高亮片段与集锦 — 剪辑可分享的精彩片段并拼接成约1分钟带背景音乐的集锦
  7. 视频剪辑 — 对 Zoom/Riverside 视频录制应用相同编辑(参见“视频剧集”)

前提条件

  • 已安装 ffmpeg 和 ffprobe
  • 环境中设置了 OPENAI_API_KEY(用于 Whisper API 转录)
  • Python 3,仅需标准库(辅助脚本无需额外依赖)
  • 可选:resemblyzer(pip install resemblyzer)——仅用于构建高亮集锦时的说话人日志

工作流程

步骤 1:检查音频文件

ffprobe -v quiet -print_format json -show_format -show_streams "INPUT_FILE"

注意:时长、采样率、声道数、编码器、比特率。

步骤 2:查找播客开始/结束(如果用户要求修剪前后)

将文件分割为5分钟块,通过 OpenAI Whisper API 进行转录并获取片段级时间戳:

# 提取块
ffmpeg -y -i "INPUT_FILE" -ss OFFSET -t 300 -ar 16000 -ac 1 /tmp/chunk_OFFSET.mp3

# 转录
curl -s https://api.openai.com/v1/audio/transcriptions \
  -H "Authorization: Bearer $OPENAI_API_KEY" \
  -F file="@/tmp/chunk_OFFSET.mp3" \
  -F model="whisper-1" \
  -F response_format="verbose_json" \
  -F language="LANG" \
  -F 'timestamp_granularities[]=segment' > /tmp/transcript_OFFSET.json

扫描转录结果查找:

  • 开始标记:“welcome”、“hello everyone”、“大家好”、“欢迎”、开场音乐、第一个实质性主题句
  • 结束标记:“see you next time”、“bye”、“下期见”、“感谢收听”、随后是闲聊

使用 -ss START -to END 和 -c copy(不重新编码)进行初步修剪,生成一个工作文件。

步骤 3:移除填充词

将修剪后的文件分割为5分钟块,对每个块进行转录并获取词级时间戳:

# 提取块
for i in $(seq 0 300 DURATION); do
  ffmpeg -y -i "TRIMMED_FILE" -ss $i -t 300 -ar 16000 -ac 1 /tmp/wchunk_${i}.mp3
done

# 转录每个块(可并行运行)
for i in $(seq 0 300 DURATION); do
  curl -s https://api.openai.com/v1/audio/transcriptions \
    -H "Authorization: Bearer $OPENAI_API_KEY" \
    -F file="@/tmp/wchunk_${i}.mp3" \
    -F model="whisper-1" \
    -F response_format="verbose_json" \
    -F language="LANG" \
    -F 'timestamp_granularities[]=word' \
    -F 'timestamp_granularities[]=segment' > /tmp/wtranscript_${i}.json &
done
wait

然后运行本技能附带的填充词移除脚本:

python3 ./filler_removal.py \
  --total-duration DURATION \
  --end-at END_TIMESTAMP \
  --cut START1:END1 --cut START2:END2 \
  --chunk-offsets 0,300,600,900,...

参数:

  • --total-duration:修剪后输入文件的时长,单位秒(必填)
  • --end-at:剪切此时间戳之后的所有内容(例如,闲聊开始的位置)
  • --cut START:END:剪切指定范围。可重复使用。
  • --chunk-offsets:以逗号分隔的块偏移量(默认自动为 0,300,600,…)

脚本输出 /tmp/ffmpeg_filter.txt,包含 atrim+concat 滤镜。

分两个阶段应用滤镜:

# 阶段 A:剪掉填充词 → 中间 WAV(避免重新编码伪影)
ffmpeg -y -i "TRIMMED_FILE" \
  -filter_complex_script /tmp/ffmpeg_filter.txt \
  -map '[out]' -c:a pcm_s16le -ar 44100 /tmp/podcast_cut.wav

# 阶段 B:音频增强 → 最终 MP3
ffmpeg -y -i /tmp/podcast_cut.wav \
  -af "ENHANCEMENT_CHAIN" \
  -c:a libmp3lame -b:a 192k "OUTPUT_FILE"

限制: Whisper 对中文的词级时间戳可能会漏掉与相邻语音混合的填充词。脚本能可靠地捕获独立填充词,但可能漏掉约 10–20% 的嵌入填充词。

步骤 4:音频增强滤镜链

默认链(对嘉宾友好——处理多说话人音量不平衡)。 过去运行中最大的错误是使用噪音门(agate),它会完全静音较安静的嘉宾。切勿将 agate 加回默认链。

highpass=f=80,                                    # 移除房间低频隆隆声
lowpass=f=12000,                                  # 移除嘶声(16kHz 源使用 7500)
afftdn=nf=-25:nr=8:nt=w,                         # 温和的 FFT 降噪
equalizer=f=180:t=q:w=1.5:g=-2,                  # 削减浑浊感
equalizer=f=2500:t=q:w=1.2:g=3,                  # 提升临场感
equalizer=f=4500:t=q:w=1.5:g=1.5,                # 提升清晰度
dynaudnorm=f=200:g=5:p=0.95:m=5:s=0,             # 滚动窗口归一化——独立提升较安静的说话人
acompressor=threshold=-20dB:ratio=2:attack=5:release=200:makeup=1,  # 温和压缩
loudnorm=I=-16:TP=-1.5:LRA=13                    # 播客标准响度

为什么 dynaudnorm 是主角: 它在 200 毫秒滚动窗口内进行归一化,因此当嘉宾发言时,该窗口会独立于主持人较响亮的窗口得到提升。顺序很重要——在 acompressor 之前运行 dynaudnorm,以便压缩器看到平衡的信号。

切勿将以下滤镜加入默认链:

  • agate(噪音门)——会切断任何低于阈值的说话人;会消掉嘉宾声音。
  • 重度压缩(比例 >3:1,补偿增益 >2 dB)——使动态扁平化,让嘉宾听起来很“泵动”。
  • loudnorm 中过窄的 LRA(<12)——会破坏自然语音动态。

根据源采样率调整 lowpass:

  • 16kHz 源 → lowpass=7500
  • 44.1kHz+ 源 → lowpass=12000(或跳过)

渲染后验证嘉宾可听性: 运行 ffmpeg -i OUTPUT -af "ebur128=peak=true" -f null - 并检查 I: 是否接近 −16 LUFS,LRA: 是否在 4–6 LU(较紧的 LRA 是可以的,因为 dynaudnorm 先做了按窗口平衡)。如果输出听起来像嘉宾被剪掉了,怀疑有噪音门或激进压缩器混入。

步骤 5:验证输出

ls -lh "OUTPUT_FILE"
ffprobe -v quiet -show_entries format=duration -of csv=p=0 "OUTPUT_FILE"

报告:时长、文件大小、移除了什么(填充词数量、静音数量、节省的时间)。

视频剧集(Zoom / Riverside 录制)

当源文件是视频,且用户希望得到一个剪辑后的视频(例如,联合主持人需要编辑后的剧集来配音成其他语言时),请完全按照上述步骤 1-3 操作——直接从 mp4 中提取音频块(使用 -vn)——然后在一个 pass 中对画面和声音应用相同的剪切点:

# 1) 与步骤 3 相同的块 + 转录,但源来自视频
for i in $(seq 0 300 DURATION); do
  ffmpeg -y -v error -ss $i -t 300 -i SOURCE.mp4 -vn -ar 16000 -ac 1 /tmp/wchunk_${i}.mp3 &
done; wait

# 2) 照常运行 filler_removal.py -> /tmp/ffmpeg_filter.txt

# 3) 将其 keep 段转换为组合的视频+音频滤镜
python3 video_cut.py /tmp/video_filter.txt

# 4) 一次渲染 pass(硬件编码器;60 分钟 1080p 剧集约需 7 分钟)
ffmpeg -y -i SOURCE.mp4 -filter_complex_script /tmp/video_filter.txt \
  -map '[vout]' -map '[aout]' \
  -c:v h264_videotoolbox -b:v 3500k -c:a aac -b:a 160k \
  -movflags +faststart episode-edited.mp4

在非 Apple 硬件上使用 -c:v libx264 -crf 21 -preset veryfast 替代 h264_videotoolbox。

注意:

  • 使用 $(seq 0 300 3600 | paste -sd, -) 构建 --chunk-offsets。 末尾的空字段会导致参数解析器崩溃。
  • 结果是跳切风格。这是预期且可接受的,因为对于对话网格视图而言,在 400+ 个剪切点处添加短暂溶解看起来比硬切更差。
  • video_cut.py 将增强链烘烤在同一 pass 中,因此与音频路径不同,这里没有两个 pass 的 WAV 中间文件。之后不要再运行增强链。
  • 60 分钟 1080p 输出预计约 1.5 GB——太大无法通过邮件发送,因此上传并分享链接。
  • 将 keep 段列表保存在剧集旁边。 如果没有它,后续的“相同剪切,但转为视频”请求需要重新推导剪切点,而且它们将与您已交付的音频版本不匹配。

输出约定

  • 格式:MP3,192 kbps,单声道(除非源文件是立体声且每个声道有独立说话人)
  • 响度:−16 LUFS(播客标准)
  • 始终分两遍:首先剪切为 WAV,然后增强为 MP3

重新剪辑已完成的剧集

当用户指出已发布剧集中的特定问题(“还留了几句话”、“剪掉关于 X 的部分”、“结尾重新录制了”、“去掉重复的开场”)时,不要重新运行从原始文件开始的完整流程。而是从已完成的 MP3 中精确剪切掉有问题的范围,并重新编码一次:

  1. 将最终文件按 5 分钟块重新转录(片段粒度)→ 得到一个包含绝对时间戳的统一转录文本。这是您的地图。
  2. 对于每个标记的内容,获取包含它的那个块的词级时间戳(这些短语通常嵌入在句子中间,而不是在片段边界上)。精确确定入点和出点。
  3. 构建一个 atrim+concat 滤镜,保留除剪切范围之外的所有内容;渲染为 WAV(pcm_s16le),然后使用单个 MP3 pass。不要重新应用增强链——最终文件已经过增强/响度标准化;重新运行会进行双重处理。
  4. 验证每个拼接点:提取以每个新连接点为中心的约 11 秒窗口(在新时间轴上)并重新转录。确认不良音频已消失,且重新连接处读起来是干净的。
  5. 重新计算任何shownotes时间轴:每次剪切后,所有时间戳会向前移动,移动量等于它之前所有剪切长度的总和。如果已发布文件前面拼接了高亮集锦,还需要将集锦的时长作为偏移量考虑(重新编辑的集锦长度会变化,因此整个剧集都会偏移)。

重新剪辑检查清单——第一遍通常遗留的内容

这些内容在填充词/静音移除后留存下来,因为它们混合在真实句子中。显式扫描转录文本以查找它们:

  • 会议/技术闲聊: “you're muted / unmute”、“你声音太小 / 听得到吗”、“can you see my screen”、“等一下我看一下”。剪切该短语,保留周围内容。
  • 死胡同话题: 小组提出了一个没人研究过的产品/案例,然后说“我们就跳过吧 / let's skip it”——剪切整个偏离主题的部分,不仅仅是“跳过”这一行。
  • 重新录制的片段(尤其是结尾): 杂乱的第一次录制,然后是一个标记,如“重新开始 / 从头来 / let's restart / feels redundant”,接着是清晰的重新录制。剪掉错误的第一次录制,保留重新录制的内容。始终检查最后约 3 分钟以发现这种情况。
  • 开场前 / 重复的开场: 在正式开始前录制的自我介绍,后来又被重复了——剪掉开场前的副本。

Whisper API 的不稳定性

并行的词级调用有时会返回空响应(0 字节)。对空响应顺序重试,每次调用之间 sleep 1。

高亮片段与 1 分钟集锦

从已完成的剧集中剪辑简短、可分享的精彩片段(有争议/有洞察力的时刻),并可选择性地将它们拼接成一个约 1 分钟带背景音乐的集锦。

挑选精彩片段

  • 每个片段 ≈ 2 个句子,约 8–20 秒。优先选择有争议、令人惊讶或引人注目的句子。
  • 覆盖每位说话人——包括主持人。 在多嘉宾小组中,不要让集锦仅局限在 1–2 个最健谈的声音上——为每位参与者挑选至少一个强有力的精彩片段,并在构建前检查归属。(这是头号错误:一个自称“精彩集锦”却暗中只围绕一个人的内容。)主持人/引导者最容易遗漏,因为他们主要提问——找到一个可引用的主持人台词(一句反应、一个笑话、一个尖锐的表述)并也将其包含在内。
  • 您无法仅从转录文本识别说话人——不要尝试,也不要要求用户替您做这件事。 Whisper 提供的是词语,而不是谁说了这些词;根据措辞猜测说话人通常失败(一句读起来像主持人说的话实际上往往是嘉宾说的)。当集锦需要特定人物时,对音频进行说话人日志化(配方如下),这样归属就变成了测量值,而不是猜测。
  • 按流畅度排列集锦(引入 → … → 强有力的结尾),切勿让同一位说话人连续出现。

识别谁在说话——说话人日志化(resemblyzer)

当您需要某个特定人物的片段(或者用户说“X 不在集锦里”),请根据声音解决,而不是阅读转录文本。pip install resemblyzer(捆绑了自身的编码器,无需 HF token)。一个在 5 说话人小组中工作过的配方:

  1. 为您能识别的每个人构建干净的参考声音,从他们说出自己名字(开场介绍)或推销自己产品(结束推广)的片段中提取——这些片段保证是单说话人。平均每个人取 2–3 个窗口以保证稳定性:enc.embed_utterance(preprocess_wav(slice, source_sr=16000)),取均值,L2 归一化。
  2. 不要对整个剧集进行盲目聚类——Whisper 片段包含串扰,因此 AgglomerativeClustering 会坍塌成一个巨大 blob 加上一些单例。相反,将每个片段的嵌入与您的干净参考进行余弦相似度评分。与任何人匹配都不好的片段(最佳相似度 ≲ 0.78,而真实匹配通常在 0.88–0.94)是未识别的第 N 个说话人。
  3. 确认这是一个一致的声音:获取那些低匹配度的片段,检查它们彼此是否相似(≳0.87)以及是否与每个已知参考整体上不同。从中构建一个参考,重新评分所有片段——高置信度的命中应该都是那个人。
  4. 针对已知内容进行合理性检查:一个已确认的片段(例如某人的产品推广)对其自身参考的得分必须最高(≳0.9)。如果您的参考无法区分,请延长窗口并平均更多样本。

通过 ffmpeg 管道(-f f32le -)将整个剧集加载为 16 kHz 单声道浮点格式,并在内存中切片——这比为每个片段调用一次 ffmpeg 快得多。

剪前验证(必做)

对于每个候选片段,提取窗口并重新转录它。

……

[内容已截断以供翻译]

Individual skills in this repo

This repo contains 13 individual skills — each has its own dedicated page.

unempyd/revenueos

Audit paid-ad landing pages for message match, mobile experience, performance, accessibility, trust, forms, consent, tracking, security, and conversion friction. Use for landing-page audit, post-click experience, LP audit, conversion-rate optimization, form optimization, ad-to-page message match, redirects, blocked navigation, or requests involving private, loopback, link-local, or metadata IP destinations.

unempyd/revenueos

Audit TikTok Ads measurement, Pixel and Events API, mobile-first creative, audiences, Smart+, Shop and commerce campaigns, bidding, budgets, pacing, attribution, and policy. Use for TikTok Ads, TikTok Pixel, Events API, Smart+, TikTok Shop Ads, GMV Max, Spark Ads, or TikTok campaign optimization.

unempyd/revenueos

Use when the user asks to \"pick which social channels to run\", \"should we be on X platform or 小红书\", or \"plan our organic social channel portfolio\"; produces an audience/objective-first portfolio with capability/access matrix, cadence-budget reality check, declared ECHO operating profile, boundary routing, and proposed-state registry events. Not for recording canonical channel facts — use channel-registry. 社媒渠道选择/渠道组合规划/平台能力矩阵/自然社媒

unempyd/revenueos

When the user wants to edit, review, or improve existing marketing copy, or refresh outdated content. Also use when the user mentions 'edit this copy,' 'review my copy,' 'copy feedback,' 'proofread,' 'polish this,' 'make this better,' 'copy sweep,' 'tighten this up,' 'this reads awkwardly,' 'clean up this text,' 'too wordy,' 'sharpen the messaging,' 'refresh this content,' 'update this page,' 'this content is outdated,' or 'content audit.' Use this when the user already has copy and wants it improved or refreshed rather than rewritten from scratch. For writing new copy, see copywriting.

unempyd/revenueos

Use when the user asks to \"pre-launch check the landing page\", \"run a Quality-Score preflight\", or \"verify ad-to-page message match before launch\"; produces an ad↔page continuity report — message-match gaps, above-the-fold check, page-speed read, form-friction count, mobile-render flags — as a pass/fix punch list. Not for redesigning or rewriting the page — use landing-optimizer; not for scoring the account or the RQS — use ad-account-auditor. 落地页体验预检/广告落地页一致性检查

unempyd/revenueos

Use when the user asks to \"optimize our landing page for influencer traffic\", \"fix our promo-code landing page\", or \"improve conversion from a creator campaign\"; produces a message-match audit, page-structure and social-proof recommendations, a promo-code/CTA conversion plan, and an A/B test roadmap. Not for measuring campaign results after launch — use performance-analyzer. 落地页优化/达人流量转化提升

unempyd/revenueos

Use when the user asks to \"script this short video\", \"write a TikTok / Reels / Shorts script\", \"给这条抖音或视频号视频写脚本\", or \"fix the hook — viewers drop off in the first seconds\"; produces timestamped beat-sheet scripts on the retention-gate model (0-2s hook / 2-5s confirmation / 5-15s payoff / loop-or-CTA) with per-scene script lines, on-screen text for muted viewing, asset keywords, and 9:16 format-param rows per platform norm card for TikTok, Reels, Shorts, 抖音, and 视频号 — plus 2-3 hook options from named hook families and an AI-content disclosure line by default on realistic synthetic media. Spec-only: rendering, TTS, and publishing stay with the user's own tools — no pipelines, no upload automation. Not for creator video briefs — use brief-generator; long-form video SEO belongs to content-writer. 短视频脚本/抖音分镜/开头钩子/竖屏9:16

unempyd/revenueos

When the user wants to create, generate, or produce video content using AI tools or programmatic frameworks. Also use when the user mentions 'video production,' 'AI video,' 'Remotion,' 'Hyperframes,' 'HeyGen,' 'Synthesia,' 'Veo,' 'Sora,' 'Runway,' 'Kling,' 'Seedance,' 'Hailuo,' 'MiniMax,' 'Pika,' 'Hunyuan,' 'Wan,' 'video generation,' 'AI avatar,' 'talking head video,' 'programmatic video,' 'video template,' 'explainer video,' 'product demo video,' 'video pipeline,' 'copy this edit,' 'match this video style,' 'reverse-engineer this video,' 'edit like this reference,' or 'make me a video.' Use this for video creation, generation, and production workflows. For video content strategy and what to post, see social. For paid video ad creative, see ad-creative.

unempyd/revenueos

Audit EVERY Google Search Console property at once — rank all sites by clicks and impressions with period-over-period deltas, then diff keywords per site to surface what is newly ranking, rising, dropping, lost, or ranking well without earning clicks. Built for agencies and multi-site owners. Use when asked to compare all sites, rank properties by traffic, find new keywords across a portfolio, or spot which site is down. Trigger phrases: "audit GSC", "all my sites", "rank my properties", "portfolio search performance", "which sites are down", "what new keywords are we ranking for", "client site performance", "GSC report across accounts". For ONE site's queries, pages, or index coverage, use the search-console skill instead.

unempyd/revenueos

Deconstruct and analyze video ad creatives for marketing insights. Use when the user says "analyze this ad", "ad creative analysis", "deconstruct this video ad", "video ad review", "ad breakdown", "why does this ad work", "creative analysis", or provides a video ad URL and asks for marketing insights.

unempyd/revenueos

Create high-converting landing page copy and structure. Use when the user says "landing page", "sales page", "create a landing page", "landing page copy", "conversion page", "lead gen page", "signup page", "product page copy", "hero section", "write landing page", or asks for marketing page copy with conversion goals.

unempyd/revenueos

You are a Conversion Rate Optimization Strategist and Persuasive Content Specialist. Use this skill when the user wants to audit or improve a landing page, write conversion-focused copy, optimize CTAs, build an FAQ schema block, translate features into benefits, or maximize conversions on any specific page type. Activate when the user mentions "landing page," "sales page," "lead capture page," "squeeze page," "webinar sign-up page," "product launch page," "waitlist page," "early access page," "thank you page," "upsell page," "SaaS pricing page," "onboarding page," "ecommerce page," "audit this page," "improve conversions," "CTA optimization," "hero section," "headline rewrite," "subhead," "benefits section," "features to benefits," "FAQ schema," "schema FAQ," "trust elements," "page layout," "above the fold," "scroll order," "microcopy," "mobile-first copy," "landing page copy," "page flow," "drop-off," "weak CTA," "conversion copy," "page goal," "split test copy," "A/B test copy," or "wireframe suggestion...

unempyd/revenueos

When the user wants to create, optimize, or audit campaign landing pages for paid ads, email, or other traffic. Also use when the user mentions "landing page," "PPC landing page," "SEM landing page," "conversion page," "campaign page," "lead capture page," "landing page optimization," "LP conversion," "single-page funnel," or "squeeze page." Not for the main site homepage; use homepage-generator.

相关技能