MiniMax-AI/mcode-stack / stacks/jiachen/skills/making-content
making-content
VerifiedContent production in three modes: rewrite, Xiaohongshu (小红书) image post, short video. Rewrite (default): turns an AI-sounding Chinese or mixed Chinese-English draft (post, newsletter, engineering blog, commentary) into the author's restrained style: few emoji, short paragraphs, hedged claims, neutral wording, English terms split by spaces. Triggers: 按我的风格改, 去 AI 味, 润色, 改改这篇, or a vague 帮我改改 when the context is a structured draft. Also for a Xiaohongshu image post from scratch (title, cover, cards, body, hooks); read references/xhs-post.md first. Also turns a document, research, notes or an article into a 60-180 s vertical video (抖音, 小红书, 视频号, B站: real sources, voice-over, captions, cover). Triggers: 做成视频, 做个短视频, 剪个 90 秒版本, 配音, 换成我的声音, or complaints of 字太密, AI 味太重, 容易走神; read references/video-pipeline.md first.
| File | Kind | Size |
|---|---|---|
| .gitignore | other | 167 B |
| SKILL.md | skill md | 25.6 KB |
| evals/evals.json | config | 4.5 KB |
| references/layouts.md | markdown | 8.5 KB |
| references/text-density-lint.md | markdown | 4.2 KB |
| references/video-pipeline.md | markdown | 12.5 KB |
| references/voice-and-music.md | markdown | 5.5 KB |
| references/xhs-post.md | markdown | 9.0 KB |
| requirements.txt | manifest | 233 B |
| scripts/capture.py | script | 6.4 KB |
| scripts/compositor.html | other | 27.8 KB |
| scripts/fetch_assets.py | script | 4.0 KB |
| scripts/lint.py | script | 8.6 KB |
| scripts/render.py | script | 4.6 KB |
| scripts/timeline.py | script | 8.7 KB |
| scripts/tts.py | script | 5.5 KB |
| templates/cover.html | other | 2.9 KB |
| templates/script.example.json | config | 5.0 KB |
| templates/sources.example.json | config | 58 B |
references/voice-and-music.md
View on GitHub# Voice and music
## Contents
- Edge: the draft voice
- Volcengine voice clone: the posted voice (user setup, request, parameters, errors, docs)
- Letting the user pick a voice setting
- Music: source, choice, credit
- Mix levels
## Edge: the draft voice
`tts.py --engine edge` uses Microsoft Edge's read-aloud voices through the `edge-tts` package: free, no key, word timestamps included. Default voice `zh-CN-YunxiNeural` (male, lively) at `+12%`; `zh-CN-XiaoxiaoNeural` is a common female alternative. It still sounds like TTS, so it is for checking timing and layouts, not for posting.
Behind a TLS-inspecting proxy, set `SSL_CERT_FILE` to the proxy's CA bundle; `tts.py` passes it to the websocket connector.
## Volcengine voice clone: the posted voice
The user's own cloned voice (豆包语音 声音复刻) usually removes most of the "AI feel". It needs three things only the user can do, so ask for them in the first message:
1. In the Volcengine console, open 豆包语音 and create a voice clone (声音复刻) from a recording; training yields a speaker id like `S_xxxxxxxx`.
2. Enable the 声音复刻 2.0 **字符版** resource (billed per character). The 并发版 needs purchased concurrency; with none bought, every request fails with 45000292.
3. Create an API key and grant it that resource; until it is granted, requests fail with 45000030.
The user hands over the key and the speaker id in chat. They go into `VOLC_TTS_API_KEY` and `VOLC_TTS_SPEAKER` for the command, never into a file. Suggest revoking the key when the video is done. Console labels change from time to time; when they do not match, read the docs (below) rather than guessing.
### Request
```text
POST https://openspeech.bytedance.com/api/v3/tts/unidirectional
X-Api-Key: <key>
X-Api-Resource-Id: seed-icl-2.0 (字符版; override with VOLC_TTS_RESOURCE)
X-Api-Request-Id: <fresh uuid> (required; requests without it were rejected)
Content-Type: application/json
{"user": {"uid": "video"},
"req_params": {"text": "...", "speaker": "S_xxxxxxxx",
"context_texts": ["用轻松、口语化、像跟朋友聊天的语气说"],
"audio_params": {"format": "mp3", "sample_rate": 24000, "speech_rate": 25, "enable_subtitle": true}}}
```
The response streams JSON lines: `data` holds base64 audio chunks, `sentence.words` holds `{word, startTime, endTime}` in seconds (that is what `enable_subtitle` turns on), and the last line carries code `20000000` on success. `tts.py` handles all of this and retries twice.
### Parameters worth tuning
| Parameter | Range | Notes |
|---|---|---|
| `speech_rate` | -50 to 100 | 0 is slow for short video; 25 sounded brisk and natural (about 5 字/s with pauses). `VOLC_RATE` in tts.py. |
| `context_texts` | free text | A spoken style instruction. Officially for preset voices; on cloned voices it did no harm in testing. `VOLC_CONTEXT` in tts.py. |
| `pitch` | -12 to 12 | Leave at 0 for a clone; shifting it makes the voice stop sounding like the user. |
### Errors
| Code | Meaning | Fix |
|---|---|---|
| 20000000 | Success | — |
| 45000030 | Resource not granted | Enable 声音复刻 2.0 字符版 and grant the API key access to it |
| 45000292 | Concurrency quota exceeded | The 并发版 has 0 purchased concurrency; use `seed-icl-2.0` (字符版) |
The 字符版 has its own concurrency limit (10 at the time of writing; check the console); `tts.py` uses 4 workers to stay under it.
### Reading the docs
docs.volcengine.com pages render in JavaScript, so WebFetch sees an empty shell. Fetch the JSON behind a page instead, with `DocumentCode` set to the last path segment of the page URL:
```text
https://docs.volcengine.com/api/doc/getDocDetail?type=online&LibraryCode=DoubaoVoice&DocumentCode=tone-training-http
```
## Letting the user pick a voice setting
Voice one representative line, with a number and an English name in it, as 2–3 variants (for example speech_rate 10, 25 with the style instruction, 40), send them as files, and ask which one. Listen for: identifiers read with "杠" or letter by letter, numbers read in the wrong form, flat endings on questions. Respell in `n` and regenerate only that line with `--only N`, into a fresh `--out` directory if the rest is already approved.
## Music: source, choice, credit
**Source.** incompetech.com (Kevin MacLeod): direct mp3 downloads under CC BY 4.0, free with credit. `fetch_assets.py music "Digital Lemonade"` downloads by the exact track title used in the site's file name and prints the credit line.
**Choice.** Offer 2–3 tracks that fit the tone and let the user pick. For tech explainers, light electronic tracks without vocals work, for example "Digital Lemonade".
**Credit.** In the post description: `Music: "Digital Lemonade" Kevin MacLeod (incompetech.com), CC BY 4.0`.
**Platform music instead.** If the user wants a trending sound from the 抖音 library, run `timeline.py` without `--music` and they add the sound in the app.
## Mix levels
Set in `timeline.py`; the loudness target in `render.py`.
| What | Value | Why |
|---|---|---|
| Music under speech | ×0.11 | the voice stays clear on phone speakers |
| Music in pauses | ×0.26 | fills gaps without pumping |
| Speech detection | 0.25 s envelope, 0.3 s gain smoothing | ducking moves smoothly, not word by word |
| Fades | 0.4 s in, 2.5 s out | no hard start or stop |
| Transition whoosh | 0 (off) | pop sounds distracted viewers, and a softer whoosh still felt odd |
| Loudness | -14 LUFS integrated, -1.5 dBTP | the common short-video target |
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| writing-skillsobra/superpowersUse when creating new skills, editing existing skills, or verifying skills work before deployment | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| xlsxanthropics/skillsUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| shipping-and-launchaddyosmani/agent-skillsPrepares production launches. Use when preparing to deploy to production, or when asking what needs to be in place before shipping. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy. | Stars: 119k | Updated | Claude CodeCodex | Verified | Install |
| childhoodthedotmack/claude-memBabysit a shipped release after merge, publication, or deployment. Verify published packages, production behavior, installed plugins, and late CI or user reports until the observation window is clean; use babysit for PR readiness before release. | Stars: 118k | Updated | Claude CodeCodex | Verified | Install |