Find a YouTube video, download it, cut it into a bilingual (EN/ZH) clip, and publish it to 视频号/公众号 (portrait) and/or 哔哩哔哩/Bilibili (landscape). Use when the user wants to search YouTube for videos to repurpose, download one, add 中英字幕 to third-party footage, or adapt and publish a 转载 video. Whole pipeline or any single stage. Also use it for picks from a scout list ("发前 3 条", "第 2 个拆系列", "继续发剩下的"). Args may name a platform: wechat | bili | all.
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Repost?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/yanmxa-repost-skills)
---
name: repost
description: >
Find a YouTube video, download it, cut it into a bilingual (EN/ZH) clip, and
publish it to 视频号/公众号 (portrait) and/or 哔哩哔哩/Bilibili (landscape). Use
when the user wants to search YouTube for videos to repurpose, download one,
add 中英字幕 to third-party footage, or adapt and publish a 转载 video.
Whole pipeline or any single stage. Also use it for picks from a scout list
("发前 3 条", "第 2 个拆系列", "继续发剩下的"). Args may name a platform:
wechat | bili | all.
---
# repost
End-to-end pipeline for this channel: **search → download → edit → publish**.
Use the bundled [command recipes](references/commands.md) from the user’s media workspace. Resolve `scripts/` relative to this skill directory. Do only the requested stages.
### Choose the requested stage
- **剪辑 / 转字幕 / 拆系列 / 做封面 / 准备发布文案**: deliver the requested local files. A platform name here chooses the deliverable’s format; remote post lists, upload forms and publication records belong to the publish stage.
- **发布 / 投稿 / 补发**: use the requested final version and any matching validated assets. Run step 5 only for the requested destinations. For an unqualified repost publication, `wechat` defaults to 视频号; `bili` is B站 and `all` means 视频号 + B站. 公众号 requires an explicit request. Use the channel’s portrait layout for 视频号 and `--layout bili` for B站; reuse the translation across renders.
- **查状态 / 给链接**: read the requested platform’s receipt; verify in the account’s作品列表 if pending or unclear. A status inquiry is read-only.
Use the [command recipes](references/commands.md) for standalone editing. For authorized publishing, use the available browser integration; the [platform reference](references/publishing.md) describes the form workflow. Credit the source channel and use the platform’s 转载 declaration. Once publication is authorized, carry it through without routine prompts. Hand login or verification back to the user when required; confirm one-time edits to an existing public post.
## 0. Resume — check what's already done (always first when given a URL)
Each video lives in a topic dir `<日期>-<选题>/`, keyed by its YouTube id in
`metadata.json`. Before downloading anything:
```sh
grep -l "<video_id>" 2026-*/metadata.json
```
Hit → `ls` that dir and start from the first missing artifact; never redo a
finished stage:
| artifact | stage that makes it |
|---|---|
| `metadata.json` | create the dir right after download (see step 5 for its fields) |
| `source.clean.en.srt` | 3.1 clean |
| `zh.json` | 3.2 translate |
| `*-vertical.mp4` | 3.3 render |
| `validation/` | 3.4 sync check |
| `cover.jpg` | 4 cover |
| `publications/<platform>.json` | step 5 only — status for that destination |
Source files go in `downloads/<video_id>.*`.
**Several URLs at once** (the user often sends a batch): run each video's
download → translate → render in parallel, but **publish strictly one at a time**
(queue the validated topic dirs and publish them sequentially). Report each
published time as it lands.
## 1. Search → use the scout tool
When the workspace has a scout tool or pick list, reuse its metadata. Otherwise use the yt-dlp search recipe in [command recipes](references/commands.md) for the requested subject and time window, and present the matches for selection.
**Picks by number** ("发前 3 条", "第 2、5 条", "#1 拆系列") refer to the newest
`scout/*.md` list (unless the user names one): resolve them to URLs from its
推荐转载 table, then run this pipeline per URL. Reuse that list's
`scout/<stem>.json` entry (title, channel, upload date, description) for step 2's
`metadata.json` instead of fetching it again.
## 2. Download
Use the [download recipe](references/commands.md) with `downloads/<id>.*`, original audio, English captions and a thumbnail. Then create the topic dir `<日期>-<选题>/` with `metadata.json`
(source_id/source_url/source_channel/source_title/source_upload_date).
## 3. Edit — portrait, subtitles in the band, NEVER on the picture
For editorial cuts or a shorter adaptation, use the shared [editing guide](references/editing.md)
to pick cuts for each segment. Preserve the speaker’s meaning and attribution.
For a full translation, preserve the source timeline. For an excerpt, cut picture,
sound and cues together and validate against the selected excerpt. For trimmed excerpts pass the matching cut source to `scripts/validate.py --source`. For a series,
put the retained clean-cue ranges for each part in `<topic>/series.json` (e.g. `[{"cues":[[0,6],[10,41]]}]`), run `scripts/split_series.py <topic>`, then render each part and validate it with `--source downloads/<id>-pN.mp4`.
See [render options](references/commands.md). The channel defaults are:
- **Portrait for 视频号, even for dense code/dashboards** — subs sit in the empty
band, never over the picture. Landscape only if the user asks; Bilibili gets
`--layout bili`.
- **No subtitle background box** in any layout (verticalize.py enforces it).
- **No zoom** by default; `--zoom-at` only to emphasise one specific detail.
1. `scripts/clean_srt.py` the `.en-orig.srt` if present, else `.en.srt` (the plain
`en` track of an AI-dubbed video can be a back-translation — verified garbage),
→ `<topic>/source.clean.en.srt` + `<topic>/transcript.txt` (one numbered cue
per line). Read the whole transcript; it drives the title, translation, cover.
2. **Translate every clean cue** → `<topic>/zh.json` (`{"<cue-index>": "中文"}`).
Never use YouTube's machine zh — it drifts.
- ≤ ~120 cues: translate yourself.
- More: split into ~100-cue ranges and launch one **general-purpose Agent**
per range in a single message (plain parallel Agent calls — not the Workflow
tool, which needs the user's explicit opt-in). Give every agent the same
glossary (product/code names, key terms) and tell it to read the whole
transcript first, translate only its range, write `zh-part-N.json`, and
write `en-fix-part-N.json` for **English cues the ASR mangled** — the EN line
is on screen too, so fix code/API names, product names, numbers (e.g.
"Torch. 2 3" → `torch.zeros(2, 3)`, "Oxer" → `oxker`), checking spellings
against the thumbnail/slides. Then `/usr/bin/python3 scripts/merge_zh.py
<topic>` (fails loudly on any missing cue).
- A speaker's own slip (wrong unit, misspoken number): keep the EN as said,
make the ZH correct.
3. `scripts/verticalize.py` → `<topic>/<id>-vertical.mp4` (`--title` Chinese,
**≤ ~12 CJK chars so it stays on one line** — it is on screen the whole video;
`--kicker "<channel> · <English title>"`).
4. `scripts/validate.py <topic>` — must print OK, then **Read the output frames it
lists** and confirm the picture matches the subtitle at that moment. Any
mismatch blocks publishing.
## 4. Cover — always a designed cover, never a black frame
The vertical clips open on a black intro, so the platform's auto-cover (first
frame) is a black screen. **Never ship that.** Generate a cover that states the
topic at a glance with `scripts/make_cover.py`: a big yellow keyword (a term or
number from the talk) + a Chinese one-line subtitle (+ optional english tagline).
Make it eye-catching: pass `--bg-image` so a real picture fills the top. Pick it
from the video, not blindly from the thumbnail:
- Grab candidates with ffmpeg (`-ss T -frames:v 1`) or tile a contact sheet
(`-vf fps=1/60,scale=320:-2,tile=8x4`) and choose a **speaker close-up with eyes
open** or the most striking diagram/screen. Talking-head frames: check a few
seconds apart, blinks are common.
- Crop out anything that isn't ours: the source's branding/title text (thumbnail
logo panels), burned-in captions, lyrics, picture-in-picture clutter.
- Thumbnails work when they are clean (no channel text); a mostly-white
thumbnail fades badly into the navy — use a frame instead.
- Keep the subtitle to one line (~10 CJK chars); make_cover shrinks rather than
orphaning 1–2 chars, but shorter reads better.
Use the approved wording and compare the final platform crops with the exact delivery copy, as described in [版本与封面定稿](references/editing.md#版本与封面定稿). Read the rendered cover before using it.
Set and verify the custom cover before publishing. If it cannot be set, stop
rather than shipping a black cover and relying on a one-time edit later.
## 5. Publish
Enter this stage on a publication request. Follow [分平台发布记录](references/publication.md) for every destination. Search only that target account’s list for the same work before submitting. Compare source IDs, episode start times and titles/descriptions for mirrors; on 视频号 read full card descriptions in the iframe (snapshots may truncate). A match or inaccessible list affects only that destination.
- **视频号** (channels.weixin.qq.com): import the existing `publishTopic` export
from the bundled `scripts/publish_channels_ego.mjs` when using Ego Browser and call `await publishTopic(task, absolutePath)`
in the Ego Browser runtime. With another browser integration, follow the [form workflow](references/publishing.md) and write the same per-platform receipt. The module is a JavaScript API, not a publishing CLI.
Pass an active Ego Browser TaskSpace (`task`, with page `p1`) and the absolute
path to the topic directory. The caller owns the TaskSpace lifecycle.
Prepare `metadata.json` with `source_id`, `source_url`, `short_title` (≤16
chars) and `description` (summary + `转载自 <channel>[ 官方] YouTube:《原标题》,原视频发布于
YYYY-MM-DD。 原视频:<url> [原片由 <sponsor> 赞助,保留完整内容;]中英字幕由 <实际署名> 整理翻译。 #tags`
— use “官方” only for the company's own channel; credit sponsors and mark launch
claims as 宣称). The first YouTube URL in `description` must match `source_id`,
including the start time for a series episode. Set `collection` to the name
of an existing 合集 when applicable. Provide exactly one `*-vertical.mp4`,
`cover.jpg`, and a passing `validation/validation.json` for the current render
and its validation frames. Review those frames yourself before calling.
The publisher validates the files, checks the 视频号 list and reserves its own receipt immediately before submission. Pass the verified account name via the optional `account` option. It records the observed status and list timestamp; check the matching card for public visibility if still pending. A lost response requires read-only reconciliation.
- **After each publish, close the loop with scout:**
- If the video came from a `scout/*.md` list, mark the matching platform in its row once public
(e.g. `✅ 视频号已发 MM-DD HH:MM` or `✅ B站已发 MM-DD HH:MM`) so the list doubles as the tracker
for "继续发剩下的".
- If the workspace maintains `scout/channels.txt` and the source channel is new, append
`<channel_url> # <name> (1)` so tomorrow's scout watches it.
- **Changing an already-published post's cover or description**: manual only,
after explicit user confirmation. Have the user use 修改描述和封面 in 视频号.
The edit is one-time, cannot be undone, and leaves a public 修改记录.
- **公众号** (mp.weixin.qq.com): when explicitly requested, use Ego Browser to
create and save the video into 素材库, wait for approval, then publish from
the 素材库 entry. Final confirmation needs the user's admin WeChat QR scan.
- **哔哩哔哩 / Bilibili** (member.bilibili.com): use Ego Browser on
`/platform/upload/video/frame` with the **`--layout bili`** render. Fill
标题/简介/标签/分区, select 内容为转载 and enter the source credit, then set
the cover and click 立即投稿. Record 稿件投递成功 as submitted. Update this receipt when review or public visibility is verified.
If a session logs out (视频号/B站 shows a login QR), hand it to the user to scan —
you can't log in. Report the published time/URL after each platform.