Extract the transcript from a video link, and after AI proofreading, archive it to the benchmarking blogger directory.
Workflow
Step 0: Environment preparation before first use (only needed the first time)
If this is a skill just installed from an open-source repository, you need to prepare the runtime environment first:
# 1. 系统依赖(macOS)
brew install yt-dlp ffmpeg
# 2. Python 虚拟环境 + 腾讯云 ASR SDK
python3 -m venv .claude/skills/li-transcript/scripts/.venv
.claude/skills/li-transcript/scripts/.venv/bin/pip install tencentcloud-sdk-python-asr
3. Create a .env file in the project root directory and fill in the Tencent Cloud keys (apply in the console https://console.cloud.tencent.com/cam/capi )
Format:
TENCENT_SECRET_ID=your_id
TENCENT_SECRET_KEY=your_key
环境准备好之后,跳到 Step 1。
### Step 1:转录视频
运行转录脚本(脚本和 venv 都在 skill 目录下,自包含):
```bash
.claude/skills/li-transcript/scripts/.venv/bin/python3 .claude/skills/li-transcript/scripts/video2text.py "视频链接"
The script will output:
- stderr: progress information +
[标题] xxx(original video title) - stdout: plain text transcript with timestamps removed
Troubleshooting order when the script reports an error:
- Whether the
.envin the project root directory containsTENCENT_SECRET_IDandTENCENT_SECRET_KEY(the script will search upward from the current directory for up to 6 levels) .claude/skills/li-transcript/scripts/.venv/whether it is normal (rebuild:python3 -m venv .claude/skills/li-transcript/scripts/.venv && .claude/skills/li-transcript/scripts/.venv/bin/pip install tencentcloud-sdk-python-asr)- Whether the video link is supported by yt-dlp
Step 2: AI proofreading
Proofread the raw transcript, changing only typos and not the content:
- Homophone/near-homophone correction: infer from context (e.g. "艺人公司" → "一人公司", "四动会" → "私董会", "体校" → "提效")
- Proper noun correction: technical terms, product names, personal names, English words
- Obvious ASR garbled text: replace with reasonable inference
Keep colloquial expressions ("啊", "嗯", "就是说"), do not rewrite sentence structure, do not beautify the style.
Proofreading is performed directly, without listing differences one by one—if users want to verify, they can compare with the original text themselves.
Step 3: Identify the author & archive
Identify the author—by priority:
- The user has already told you → use it directly
- There is a self-introduction in the transcript ("Hello everyone, I am XXX", "I am XXX") → extract it
- If neither → ask the user
Match benchmarking—read the 05-选题研究/对标博主/短视频/ directory list:
- Matched an existing blogger → archive to that directory
- No match → ask the user "[name] is not yet in the benchmarking list, create it?", and if agreed, create the directory
The author and whether to create a benchmarking entry can be combined into one question to reduce back-and-forth.
Determine the title—prefer the original title obtained by yt-dlp (the [标题] line in stderr); if unavailable, summarize one from the transcript content.
Step 4: Save the file
Path:05-选题研究/对标博主/短视频/[博主名]/[YYYY年M月]/[视频标题].md
If the time directory does not exist, create it.
Format—adjust the YAML field names according to the video source platform:
---
[平台]数据:
点赞数:
收藏数:
评论数:
分享数:
观看数:
tags:
---
# 标题
[视频标题]
# 封面花字
# 视频脚本
[校对后的完整逐字稿]
Platform determination rules:
- URL contains
xiaohongshu.com→小红书数据 - URL contains
bilibili.com→B站数据 - URL contains
douyin.com→抖音数据 - URL contains
youtube.comoryoutu.be→YouTube数据 - Other →
平台数据
After saving, tell me the path in one sentence.