eng-doc-courseware-pipeline
Installation
Review the source and dependencies with a prompt. A package is available to download.
Install with an AI assistant
Copy the prompt so your assistant can review the pinned revision and dependencies first.
View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "eng-doc-courseware-pipeline" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-00fadeac8e19bef861e27d7c29070e6a0fc2819754805bf36b09d001c69f4a7d. Verify the upstream source and version against https://skillhub.cn/skills/user_e879f717/eng-doc-courseware-skill before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.
Source and setup
skillhub.cn
Setup guidance pending
See the original source for supported tools, dependencies, and permissions.
Installation test pending
Pack the full pipeline "image/English text → strictly formatted Word document → single-page interactive lesson" into a one-click reusable skill. Used to generate postgraduate entrance exam English close-reading lesson materials from images or English sources (including paragraph/sentence reading audio, per-sentence reading technique explanations, Chinese translations, exam vocabulary flashcards, grammar analysis, vocabulary+sentence dictation challenges, and an AI study companion), while producing a strictly formatted Word document. Covers visual extraction, vocabulary and grammar proofreading, python-docx formatting, Edge TTS audio generation, interactive lesson assembly and local preview, and includes reusable scripts and templates.
Introduction source: third_party · user_e879f717 · 1.0.0 Reference
SkillPi interpretation
- Tasks
- Translation pending; see source documentation.
- Audience
- Not specified in the source documentation.
- Inputs and outputs
- Translation pending; see source documentation.
- Software, accounts and paid services
- Translation pending; see source documentation.
- Limits and differences
- Translation pending; see source documentation.
- Testing
- Not tested
Browse files
Frontmatter
name: eng-doc-courseware-pipeline
description: 将「图片/英文文本 → 格式严格 Word 文档 → 单页互动课件」整条流水线打包为一个可一键复用的 skill。当用户需要从图片或英文材料生成考研英语精读课件(含分段落/分句朗读音频、每句朗读技巧讲解、中文翻译、考研词汇卡片、语法解析、词汇+语句默写闯关、AI 学伴),且同时产出一份严格格式 Word 文档时使用。覆盖视觉提取、词汇语法校对、python-docx 格式化、Edge TTS 音频生成、互动课件组装与本地预览,并内置完整可复用脚本与模板。
agent_created: trueeng-doc-courseware-pipeline · 图文转文档 + 互动课件 全流程流水线
把一段英文材料(图片或纯文本)端到端转化为:(1) 一份格式严格的 Word 文档;(2) 一套单页互动课件(朗读精练 / 词汇卡片 / 语法解析 / 默写闯关 / AI 学伴)。本 skill 是「eng-courseware-builder + AI师傅课程制作 + TeachAny」三套能力的合并与固化版本,所有确定性步骤都预置了可运行脚本,创意内容步骤给出了明确产出规范,无需重新描述上下文即可直接运行。
何时使用
- 用户给图片/截图/英文文本,要求「提取英文 → 校对 → 生成 Word → 做互动课件」。
- 用户要求制作考研/英语精读类互动课件,八项需求(段落朗读、分句朗读、朗读技巧讲解、中文翻译、词汇卡、语法解析、默写、AI 学伴)需全部覆盖。
- 用户希望这条多步流水线可重复执行、可一键复用。
输入参数(调用本 skill 时向用户确认或直接从上下文取得)
| 参数 | 含义 | 默认值 |
|---|---|---|
SOURCE |
图片路径列表,或已提取的英文文本文件路径,或直接给的英文文本 | 必填 |
TOPIC |
课件大标题 / Word 文件名(建议用原文标题) | 提取时从 [TITLE] 行或首段推断 |
OUT_DIR |
成品存放目录(Word 与课件副本) | 用户桌面 ~/Desktop |
WORK_DIR |
中间工作目录(音频、js、html 等) | 当前工作区下新建 courseware_<topic>/ |
EN_VOICE / ZH_VOICE |
Edge TTS 英文/中文音色 | en-US-AriaNeural / zh-CN-XiaoyiNeural |
IMA_UPLOAD |
是否把 Word 上传到 ima 知识库 | false |
依赖(用 WorkBuddy 管理的 Python 运行)
PY="C:/Users/丁/.workbuddy/binaries/python/envs/default/Scripts/python.exe"
$PY -m venv C:/Users/丁/.workbuddy/binaries/python/envs/default # 仅首次
$PY -m pip install python-docx edge-tts eng_to_ipa
Node 仅用于校验脚本语法:
C:/Users/丁/.workbuddy/binaries/node/versions/22.22.2/node.exe。
执行逻辑(7 步,确定性步骤直接跑 lib/ 脚本,创意步骤按规范产出)
S0 准备
- 确认
SOURCE;确保依赖已装。 - 建
WORK_DIR(courseware_<topic>/),后续所有中间产物都放这里。
S1 提取英文(agent 步骤,确定性靠 Read 工具)
- 若
SOURCE是图片:用 Read 工具逐张读取,从视觉内容提取英文文字,保留原始段落结构。 - 若
SOURCE是文本文件/文本:直接使用。 - 输出:写到
WORK_DIR/content.txt,每行一段;标题行加[TITLE]前缀,需加粗的小标题/正文加[B]前缀(详见references/format_spec.md)。示例:[TITLE] Zheng He, the great ancient Chinese explorer 1 In 1999, an American journalist reported ...
S2 词汇与语法校对(agent 步骤)
- 对提取文本做拼写/语法/用词检查,自动纠正(如逗号拼接句 comma splice 改为分号;拼写/时态/搭配错误)。
- 直接修改
content.txt(保留[TITLE]/[B]标记)。
S3 生成 Word 文档(tool 步骤 → lib/build_doc.py)
$PY <skill>/lib/build_doc.py <WORK_DIR>/content.txt "<OUT_DIR>"
- 按
references/format_spec.md格式化:Arial 14pt、行距固定 30 磅、段前段后 0 磅、首行缩进 2 字符、标题居中、无空白行。 - 文件名 = 标题(
[TITLE]行文本),保存到OUT_DIR。 - 校验:用 python-docx 读回,确认无空段落、行距/字体/缩进正确(参考
lib/verify_doc.py思路,可在 SKILL 调用时临时补一段校验)。
S4 编写课件数据源(agent 步骤 → course_data.py)
- 基于
assets/course_data_template.py与references/course_data_schema.md,把校对后文本拆成:reading:按自然段拆分;每段给para_audio、translation,再逐句给audio、tech_audio、tech(朗读技巧中文说明:连读/重读/弱读/停顿)。vocab:挑 15–20 个考研重点词,补ipa/pos/meaning/root/derivatives/phrases/audio。grammar:5–8 个本课考点,给rule/example/analysis。dictation:vocab(中文释义→英文)、sentence(用______挖空 + 中文提示,answer 为关键英文词)。
- 音频路径用相对路径且带
tts/前缀(如tts/para_p1.mp3、tts/s_p1_1.mp3、tts/tech_p1_1.mp3、tts/word_encounter.mp3)。注意:build_audio.py会把out_rel直接拼到工作目录,所以路径必须已含tts/前缀,否则会出现tts/tts/嵌套。 - 把写好的文件保存为
WORK_DIR/course_data.py。
S5 生成全部 TTS 音频 + course_data.js(tool 步骤 → lib/build_audio.py)
cd <WORK_DIR> && $PY <skill>/lib/build_audio.py
- 用 Edge TTS 生成:段落朗读、每句朗读、每句技巧讲解(中文)、每个词汇朗读,共约 40–50 个 mp3 落到
WORK_DIR/tts/。 - 同时用
eng_to_ipa构建音素词典PHONEMES,并写出WORK_DIR/course_data.js(供网页加载,先写数据后跑音频,断点安全)。 - 单文件失败自动重试 3 次;已存在且 ≥200 字节视为成功、跳过(可断点续跑)。
S6 组装互动课件(tool 步骤 → assets/index_template.html)
cp <skill>/assets/index_template.html <WORK_DIR>/index.html
- 模板是单文件、数据驱动(读
course_data.js的COURSE/PHONEMES),已内置五大模块 + AI 学伴,无需改动即可用。 - 校验:
node --check抽取的内联脚本语法;确认tts/*.mp3与course_data.js齐全。
S7 预览与交付(tool 步骤)
cd <WORK_DIR> && $PY -m http.server 8765 --bind 127.0.0.1
- 浏览器打开
http://127.0.0.1:8765/index.html预览(麦克风跟读需 Chrome + localhost/https;file://直接打开能听音频但无法录音)。 - 把整个
WORK_DIR复制到OUT_DIR(如~/Desktop/郑和互动课件/),作为持久副本交付。
输出说明
- Word 文档:
<OUT_DIR>/<TOPIC>.docx(严格格式,符合 S3 要求)。 - 互动课件:
<WORK_DIR>/index.html+course_data.js+tts/*.mp3(约 40–50 个音频);OUT_DIR下另有同名副本文件夹。 - 在线预览:
http://127.0.0.1:8765/index.html(本地静态服务)。
已知坑 / 注意
- 音频路径前缀:
course_data.py中音频字段必须带tts/前缀(如tts/para_p1.mp3),build_audio.py会直接拼到工作目录;漏写前缀会导致tts/tts/嵌套且段落缺失。 - 逐字跟读评测:基于浏览器 Web Speech API 的逐词+音素级近似评测;若需工业级声学打分,在
startReadAlong处替换为讯飞/腾讯/微软评测 API。 - 麦克风权限:跟读录音仅在 Chrome 通过
localhost或https打开时启用。 - 断点续跑:音频/文档命中已存在且有效则跳过,可安全重跑
build_audio.py/build_doc.py。
参考文件
references/workflow.md— 端到端分步详解与命令清单references/format_spec.md— Word 格式细则与字段映射references/course_data_schema.md—COURSE/PHONEMES完整 JSON Schema 与拆解建议assets/course_data_template.py— 课件数据源模板(含示例,复制后填内容)assets/index_template.html— 互动课件外壳(数据驱动,无需改动)lib/build_doc.py— 内容文件 → 格式化 Wordlib/build_audio.py— 数据源 → TTS 音频 + course_data.jslib/serve.py— 本地静态预览服务器
Current listing version
1.0.0
Safety and assessment details
Quality assessment
Out of 100 · Assessment report from SkillPi LAB.
Highlights
- 提供从图片/英文文本到格式严格 Word 文档再到单页互动课件的完整端到端流水线
- 覆盖考研英语精读课件的八大核心需求(朗读、技巧讲解、翻译、词汇、语法、默写、AI 学伴)
- 内置可复用脚本与模板,支持一键复用,显著提升教育内容制作效率
Highlights
- 触发场景描述清晰:明确针对图片/文本转 Word + 互动课件的需求
- 目标用户定位准确(考研英语学习者),功能边界无歧义
Areas to improve
-
description 内容重复 Reported severity: Minor
frontmatter 与 skill_body 开头均包含完整 description,存在冗余
Recommendation: 建议保留 frontmatter 中的 description,skill_body 开头可简化为标题直接进入正文
Highlights
- 执行逻辑分 7 步清晰拆解,agent 与 tool 步骤分工明确
- 输入参数表格化,依赖与输出说明完整
- 关键风险点(如音频路径前缀)有明确警告
Highlights
- 依赖环境路径具体,Python 包列表明确
- 音频生成支持断点续跑与失败重试,提升鲁棒性
- Word 格式通过 python-docx 校验,确保输出合规
- 课件模板为单文件数据驱动,降低部署复杂度
The arithmetic mean of the first four original scores, rounded to a whole number.
Static text checks
100 / 100 · skillpi-20261123-no-r3-v1
No current rules matched the text.
This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.
Permissions and checks before use
Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.
-
Install or fetch external dependencies
Use official sources and pin versions. Check install scripts in an isolated environment. This document check does not cover code downloaded later.
Mentioned in main document · lines 33
Domains or addresses referenced in the document
These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.
- 127.0.0.1
Security rating and access scope
safe · Static evidence review; not a runtime safety guarantee.
Translation pending; see source documentation.
Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.
User discussion
No verified reviews yet.