chinese-dictation
Skill5 starsChanged 3 months agoApache-2.0View on GitHub
Generate Chinese (traditional/simplified) dictation practice — extract words+pinyin from a screenshot, produce an HTML page with audio that reads each word aloud with configurable pause between words. Use when user says "听写"、"聽寫"、"语文听写"、"听写练习"、"dictation"、"做个听写"、"听写卡"、"听写音频".
In this repository54 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- agent-teamsSkill
- bilibili-channelSkill
- bot-configSkill
- browser-cliSkill
- bwrap-bypassSkill
- cc-pages-backupSkill
- chat-styleSkill
- code-wiki-reconSkill
- deck-builderSkill
- docx-form-fillerSkill
- evolutionSkill
- explainer-distillSkill
- feishu-bitableSkill
- feishu-docSkill
- feishu-mailSkill
- feishu-sheetSkill
- feishu-user-msgSkill
- fireworks-tech-graphSkill
- frontend-slidesSkill
- gemini-ui-reviewerSkill
- hk-busSkill
- hk-share-award-tax-dipn38Skill
- imagen-generatorSkill
- issue-handlerSkill
- lecture-videoSkill
- lecture-voiceSkill
- lesson-read-aloudSkill
- live-canvasSkill
- lustre-mounterSkill
- manim-teaching-figuresSkill
- math-video-tutorSkill
- memory-gcSkill
- memory-lintSkill
- multimodal-explainerSkill
- music-generatorSkill
- notifySkill
- page-styleSkill
- paper-explainerSkill
- session-handoffSkill
- skill-creatorSkill
- smoke-testSkill
- study-materialSkill
- tmux-installerSkill
- tmux-orchestratorSkill
- tpuguruSkill
- tts-generatorSkill
- veo-generatorSkill
- vscode-referenceSkill
- weather-forecastSkill
- wechat-readerSkill
- wikiSkill
- youtube-channelSkill
- zsh-installerSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 1 is distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 26
If pinyin is missing from the image but you're confident, fill it in.
- Very specific: line 30
Write the words to /tmp/dictation-input.json:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Chinese Dictation Generator
Given a list of Chinese words (with pinyin), produce a self-contained HTML page that:
- Lists every word + pinyin (hidden by default, click to reveal — encourages real practice).
- Generates one tiny ogg per word, and embeds a JavaScript scheduler that plays them sequentially with a client-side adjustable interval. User can change the gap (e.g. 5s → 10s), pause/resume, skip to next word, or stop entirely — all live in the browser, no need to regenerate.
Designed for elementary-school 中文/語文 homework. Defaults to 繁體中文 reading voice; works for simplified too.
When to invoke
User (Chris) typically shares a screenshot of a textbook 生字 page or 聽寫表. The expected workflow is fully autonomous: read the image → extract 字+拼音 → generate the dictation page → send the URL. Don't ask back about voice/pause/etc — defaults are already production-tested. If the page is part of a series (e.g. user already did page 24, now sends page 25), use a slug like pageNN for clean URL grouping.
Workflow (Claude side)
Step 1 — Extract words from the image
You (Claude) read the user's screenshot directly. For each entry on the page, extract:
hanzi— the character(s) to dictate (preserve traditional form if the source is traditional)pinyin— full pinyin with tone marks (e.g.qiū qiān, notqiu1 qian1)
If pinyin is missing from the image but you're confident, fill it in. If a word is ambiguous, ask the user before generating.
Step 2 — Run the generator
Write the words to /tmp/dictation-input.json:
{
"title": "第一週聽寫",
"slug": "week1",
"words": [
{"hanzi": "鞦韆", "pinyin": "qiū qiān"},
{"hanzi": "翱翔", "pinyin": "áo xiáng"},
{"hanzi": "璀璨", "pinyin": "cuǐ càn"}
],
"pause_seconds": 20,
"repeat": 2,
"voice": "vindemiatrix"
}Then run:
python3 ~/.claude/skills/chinese-dictation/scripts/generate.py /tmp/dictation-input.jsonOutput (one line, the public URL):
https://www.closecrab.com/pages/dictation-week1-20260523-145912.htmlSend that URL to the user.
Important: title is the Chinese display name shown in the page; slug is the ASCII-only filename component for clean URLs. If you omit slug, the URL falls back to dictation-{timestamp}.html (still clean, just less descriptive). Never put Chinese in the URL — picks like week1, unit3-lesson5, 2025-spring work well.
Defaults / tuning
| Field | Default | Notes |
pause_seconds | 5 | Default value pre-filled in the page's input box — user can change it live (1-60s) without regenerating. Pick a sensible default for the typical student. |
repeat | 2 | How many times each word is read. Standard dictation reads twice. (Baked into each word's ogg; not adjustable client-side.) |
voice | erinome | Verified by Chris (2026-05-23) as the best Gemini voice for 繁體中文 dictation — sounds like a CCTV news anchor. The only "Clear"-tagged female voice in Gemini's 30. Don't change unless explicitly asked. |
engine | gemini | edge is also supported (voice: zh-TW-HsiaoChenNeural) but lacks emotion — Chris prefers gemini+erinome. |
title | 聽寫-MMDD | Chinese display name shown on the page (h1 + browser tab). |
slug | (none) | Optional ASCII slug for the URL. If omitted, URL is dictation-{timestamp}.html. |
What the generated HTML contains
- Header — title, date, word count, estimated duration.
- Audio player — single
<audio>element, the user clicks play and writes along. - Word grid — every word shown as a card with hanzi + pinyin blurred by default. Click a card to reveal (for self-check after listening). A "全部顯示 / 全部隱藏" toggle button up top.
- Print-friendly —
@media printreveals all answers for the teacher's answer key.
Pause tuning
The first time you generate dictation for a particular student, suggest the user try pause_seconds: 20, then offer to regenerate with adjusted timing based on feedback ("太快了" → 25, "太慢了" → 15).
Tips
- Traditional vs simplified: pass
hanziexactly as the user wants to practice. The script doesn't auto-convert. - Multi-character words (詞組): treat as a single dictation unit, e.g.
{"hanzi": "鞦韆"}not two entries. - Phrases with same word reading multiple times:
repeat: 3if they need more practice.
Files
scripts/generate.py— main entry, JSON → HTML+audio → CC Pages upload.- Dependencies:
ffmpeg,tts-generatorskill (Gemini 3.1 Flash TTS).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

