← Back to Skills Marketplace
effeceee

Dictation Audio

by effeceee · GitHub ↗ · v2.0.0 · MIT-0
cross-platform ✓ Security Clean
192
Downloads
1
Stars
1
Active Installs
4
Versions
Install in OpenClaw
/install dictation-audio
Description
根据英语单词生成听写音频,每个单词读两遍,中间停顿1秒
README (SKILL.md)

Dictation Audio Generator

根据英语单词生成听写音频,每个单词读两遍,中间停顿1秒。

作者

Maosi English Team

使用方法

# 交互式输入
python3 dictation.py

# 或使用管道
echo -e "band\
practise\
sharp" | python3 dictation.py

输入格式

每行一个单词,支持格式:

  • word - 纯英文单词
  • word中文 - 带中文注释(如 band乐队 会自动提取 band

输出

生成 /tmp/dictation.mp3 文件

音频格式

  • 语音:en-GB-RyanNeural
  • 语速:-20%
  • 停顿:1秒
  • 朗读顺序:单词1 → 停顿 → 单词1 → 停顿 → 单词2 → 停顿 → 单词2 → ...

示例

输入:

band
practise
sharp
need

输出: 4个单词的听写音频,每个单词读两遍,单词间停顿1秒

技术实现

  1. 输入验证:正则过滤,只保留英文字母、空格和连字符
  2. 依赖检查:使用 shutil.which() 验证工具存在
  3. 音频生成:调用 edge-tts 生成单词音频
  4. 静音生成:ffmpeg 生成1秒静音片段
  5. 音频合并:ffmpeg concat 合并所有片段

安全设计

  • 依赖验证:启动时检查 edge-tts 和 ffmpeg 是否可用
  • 输入过滤:正则验证,只允许英文字母、空格和连字符
  • 长度限制:单词最大100字符
  • 临时目录:所有中间文件在系统临时目录,不暴露敏感路径
  • subprocess安全:使用 shutil.which() 验证工具路径,参数列表传递
  • 超时保护:30秒超时防止进程挂起
  • 资源清理:临时文件自动清理

License

Apache License 2.0

Usage Guidance
This skill appears coherent and focused on its stated task. Before installing, ensure you have system ffmpeg available and are comfortable with the edge-tts PyPI package being installed (it may perform network calls to Microsoft's TTS services at runtime). Note the skill writes its final output to /tmp/dictation.mp3 (a global temp path) which may be overwritten if multiple runs happen concurrently; if that matters, consider modifying the output path. Also be aware the registry metadata did not include an enforced install spec for ffmpeg (you must install it yourself). Otherwise no credentials or unexpected file accesses are requested.
Capability Analysis
Type: OpenClaw Skill Name: dictation-audio Version: 2.0.0 The skill bundle is a legitimate utility for generating English dictation audio files. The Python script (dictation.py) implements robust security practices, including strict input validation via regex to prevent injection, safe subprocess execution using argument lists instead of shell strings, and the use of temporary directories for intermediate files.
Capability Assessment
Purpose & Capability
Name/description (generate TTS dictation audio) aligns with the actual code and declared requirements. The script calls edge-tts to synthesize speech and ffmpeg to create/concatenate audio, which are the expected tools for this task.
Instruction Scope
Runtime instructions and the script limit actions to reading stdin, sanitizing input, producing per-word audio and silence, and writing the final file to /tmp/dictation.mp3. The code validates input via regex, uses only temporary files for intermediates, and does not access unrelated files, environment variables, or external endpoints beyond what edge-tts naturally does.
Install Mechanism
The skill is instruction-only at registry level, but SKILL.md metadata suggests installing the Python package edge-tts via pip. ffmpeg has no install step and must be provided by the host. Installing edge-tts from PyPI is a normal approach but is a network operation and will add a CLI dependency; this is proportionate to the stated purpose.
Credentials
No environment variables, credentials, or config paths are requested. The absence of secrets is appropriate for a TTS/audio generation utility.
Persistence & Privilege
The skill does not request persistent/always-enabled status, does not modify other skills or system-wide agent settings, and has no privileged persistence behavior.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install dictation-audio
  3. After installation, invoke the skill by name or use /dictation-audio
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v2.0.0
v2.0: 安全版本
v1.2.0
v1.2.0: 修复concat_list.txt路径安全问题
v1.1.0
v1.1.0安全性修复: 添加依赖检查、输入验证、超时保护
v1.0.0
Initial release - 单词听写音频生成器,支持Apache 2.0 License
Metadata
Slug dictation-audio
Version 2.0.0
License MIT-0
All-time Installs 1
Active Installs 1
Total Versions 4
Frequently Asked Questions

What is Dictation Audio?

根据英语单词生成听写音频,每个单词读两遍,中间停顿1秒. It is an AI Agent Skill for Claude Code / OpenClaw, with 192 downloads so far.

How do I install Dictation Audio?

Run "/install dictation-audio" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Dictation Audio free?

Yes, Dictation Audio is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Dictation Audio support?

Dictation Audio is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Dictation Audio?

It is built and maintained by effeceee (@effeceee); the current version is v2.0.0.

💬 Comments