speech
Use when the user asks for text-to-speech narration or voiceover, accessibility reads, audio prompts, or batch speech generation. OpenAI remains the default; Atlas Cloud is an explicit optional backend for asynchronous multilingual speech. Custom voice creation is out of scope.
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-11
- Stars
- ★ 3.3w
- Forks
- 3.9k
01 前言 Front Matter
- name
- speech
- author
- openai
- description
- Use when the user asks for text-to-speech narration or voiceover, accessibility reads, audio prompts, or batch speech generation. OpenAI remains the default; Atlas Cloud is an explicit optional backend for asynchronous multilingual speech. Custom voice creation is out of scope.
02 资源文件 31
- 参考文档agents/openai.yaml299 B
- 资产文件assets/grants/nih_specific_aims.tex8.9 KB
- 资产文件assets/grants/nsf_proposal_template.tex12.8 KB
- 资产文件assets/journals/nature_article.tex6.1 KB
- 资产文件assets/journals/neurips_article.tex8.7 KB
- 资产文件assets/journals/plos_one.tex11.4 KB
- 资产文件assets/posters/beamerposter_academic.tex8.3 KB
- 资产文件assets/speech-small.svg742 B
- 资产文件assets/speech.png1.2 KB
- 许可证LICENSE.txt10.5 KB
- 参考文档references/accessibility.md696 B
- 参考文档references/atlas-cloud.md2.4 KB
- 参考文档references/audio-api.md1.0 KB
- 参考文档references/cli.md4.0 KB
- 参考文档references/codex-network.md1.1 KB
- 参考文档references/conferences_formatting.md16.8 KB
- 参考文档references/grants_requirements.md22.3 KB
- 参考文档references/ivr.md708 B
- 参考文档references/journals_formatting.md17.2 KB
- 参考文档references/narration.md671 B
- 参考文档references/posters_guidelines.md16.7 KB
- 参考文档references/prompting.md1.5 KB
- 参考文档references/sample-prompts.md991 B
- 参考文档references/voice-directions.md2.1 KB
- 参考文档references/voiceover.md790 B
- 脚本scripts/atlas_text_to_speech.py13.8 KB
- 脚本scripts/customize_template.py6.7 KB
- 脚本scripts/query_template.py8.7 KB
- 脚本scripts/text_to_speech.py15.2 KB
- 脚本scripts/validate_format.py8.6 KB
- 脚本tests/test_atlas_text_to_speech.py6.6 KB
03 SKILL.md 正文
Speech Generation Skill
Generate spoken audio for the current project (narration, product demo voiceover, IVR prompts, accessibility reads). OpenAI remains the default with gpt-4o-mini-tts-2025-12-15; Atlas Cloud is available only when the user explicitly selects it. Prefer the bundled CLIs for deterministic, reproducible runs.
When to use
- Generate a single spoken clip from text
- Generate a batch of prompts (many lines, many files)
Decision tree (single vs batch)
- If the user provides multiple lines/prompts or wants many outputs -> batch
- Else -> single
Workflow
- Decide intent: single vs batch (see decision tree above).
- Collect inputs up front: exact text (verbatim), desired voice, delivery style, format, and any constraints.
- If batch: write a temporary JSONL under tmp/ (one job per line), run once, then delete the JSONL.
- Augment instructions into a short labeled spec without rewriting the input text.
- Run
scripts/text_to_speech.pyfor the default OpenAI path, orscripts/atlas_text_to_speech.pyonly when Atlas Cloud was selected (seereferences/cli.md). - For important clips, validate: intelligibility, pacing, pronunciation, and adherence to constraints.
- Iterate with a single targeted change (voice, speed, or instructions), then re-check.
- Save/return final outputs and note the final text + instructions + flags used.
Temp and output conventions
- Use
tmp/speech/for intermediate files (for example JSONL batches); delete when done. - Write final artifacts under
output/speech/when working in this repo. - Use
--outor--out-dirto control output paths; keep filenames stable and descriptive.
Dependencies (install if missing)
Prefer uv for dependency management.
OpenAI backend package:
uv pip install openai
If uv is unavailable:
python3 -m pip install openai
The Atlas Cloud backend uses only the Python standard library.
Environment
- Default OpenAI calls require
OPENAI_API_KEY. - Optional Atlas Cloud calls require
ATLASCLOUD_API_KEY.
If the selected provider key is missing, give the user these steps:
- Create an API key in that provider's console.
- Set
OPENAI_API_KEYorATLASCLOUD_API_KEYas an environment variable in their system. - Offer to guide them through setting the environment variable for their OS/shell if needed.
- Keep provider credentials out of chat. Direct the user to set the selected key locally and confirm when ready.
If installation isn't possible in this environment, tell the user which dependency is missing and how to install it locally.
Defaults & rules
- Keep OpenAI as the default provider. Do not switch to Atlas Cloud unless the user requests it.
- Use
gpt-4o-mini-tts-2025-12-15unless the user requests another model. - Default voice:
cedar. If the user wants a brighter tone, prefermarin. - Built-in voices only. Custom voices are out of scope for this skill.
instructionsare supported for GPT-4o mini TTS models, but not fortts-1ortts-1-hd.- Input length must be <= 4096 characters per request. Split longer text into chunks.
- Enforce 50 requests/minute. The CLI caps
--rpmat 50. - Require
OPENAI_API_KEYbefore any live API call. - For Atlas Cloud, default to
xai/tts-v1, voiceeve, languageauto, and requireATLASCLOUD_API_KEY. - Atlas generation submits exactly one POST. Only prediction GET requests may retry, and polling must stay finite.
- Download Atlas outputs without an Authorization header and reject non-HTTPS or private-network targets.
- Provide a clear disclosure to end users that the voice is AI-generated.
- Use the OpenAI Python SDK (
openaipackage) for default OpenAI calls; the dedicated Atlas CLI uses its asynchronous HTTP contract. - Prefer the matching bundled CLI over writing new one-off scripts.
Instruction augmentation
Reformat user direction into a short, labeled spec. Only make implicit details explicit; do not invent new requirements.
Quick clarification (augmentation vs invention):
- If the user says "narration for a demo", you may add implied delivery constraints (clear, steady pacing, friendly tone).
- Do not introduce a new persona, accent, or emotional style the user did not request.
Template (include only relevant lines):
Voice Affect: <overall character and texture of the voice>
Tone: <attitude, formality, warmth>
Pacing: <slow, steady, brisk>
Emotion: <key emotions to convey>
Pronunciation: <words to enunciate or emphasize>
Pauses: <where to add intentional pauses>
Emphasis: <key words or phrases to stress>
Delivery: <cadence or rhythm notes>
Augmentation rules:
- Keep it short; add only details the user already implied or provided elsewhere.
- Do not rewrite the input text.
- If any critical detail is missing and blocks success, ask a question; otherwise proceed.
Examples
Single example (narration)
Input text: "Welcome to the demo. Today we'll show how it works."
Instructions:
Voice Affect: Warm and composed.
Tone: Friendly and confident.
Pacing: Steady and moderate.
Emphasis: Stress "demo" and "show".
Batch example (IVR prompts)
{"input":"Thank you for calling. Please hold.","voice":"cedar","response_format":"mp3","out":"hold.mp3"}
{"input":"For sales, press 1. For support, press 2.","voice":"marin","instructions":"Tone: Clear and neutral. Pacing: Slow.","response_format":"wav"}
Instructioning best practices (short list)
- Structure directions as: affect -> tone -> pacing -> emotion -> pronunciation/pauses -> emphasis.
- Keep 4 to 8 short lines; avoid conflicting guidance.
- For names/acronyms, add pronunciation hints (e.g., "enunciate A-I") or supply a phonetic spelling in the text.
- For edits/iterations, repeat invariants (e.g., "keep pacing steady") to reduce drift.
- Iterate with single-change follow-ups.
More principles: references/prompting.md. Copy/paste specs: references/sample-prompts.md.
Guidance by use case
Use these modules when the request is for a specific delivery style. They provide targeted defaults and templates.
- Narration / explainer:
references/narration.md - Product demo / voiceover:
references/voiceover.md - IVR / phone prompts:
references/ivr.md - Accessibility reads:
references/accessibility.md
CLI + environment notes
- CLI commands + examples:
references/cli.md - API parameter quick reference:
references/audio-api.md - Atlas Cloud asynchronous workflow and safeguards:
references/atlas-cloud.md - Instruction patterns + examples:
references/voice-directions.md - If network approvals / sandbox settings are getting in the way:
references/codex-network.md
Reference map
references/cli.md: how to run speech generation/batches viascripts/text_to_speech.py(commands, flags, recipes).references/audio-api.md: API parameters, limits, voice list.references/atlas-cloud.md: optional Atlas Cloud model, CLI, polling, and download contract.references/voice-directions.md: instruction patterns and examples.references/prompting.md: instruction best practices (structure, constraints, iteration patterns).references/sample-prompts.md: copy/paste instruction recipes (examples only; no extra theory).references/narration.md: templates + defaults for narration and explainers.references/voiceover.md: templates + defaults for product demo voiceovers.references/ivr.md: templates + defaults for IVR/phone prompts.references/accessibility.md: templates + defaults for accessibility reads.references/codex-network.md: environment/sandbox/network-approval troubleshooting.
04 同仓库更多 Skills
wealthville-pool-scoring
Score DeFi liquidity pools before providing liquidity. Returns a 0-100 pool score and an Enter/Hold/Exit/Reduce/Avoid verdict with calibrated confidence for ~68,800 Solana pools and 575 EVM pools, plus a public miss-inclusive track record. Use when asked whether a pool is worth LPing into, which pools look best right now, or how accurate the scores have actually been.
technical-debt-auditor
Scans a codebase and produces a quantified technical debt report with a prioritized remediation plan. Analyzes dead code, TODO/FIXME/HACK markers, dependency staleness, complexity hotspots, code duplication signals, test coverage gaps, unused exports, and outdated patterns. Use this skill when the user asks to audit their codebase for tech debt, wants a health check of their code quality, says things like "where should I focus refactoring", "find code smells", "audit my codebase", "what technical debt do we have", "prioritize cleanup work", or asks about code quality metrics. Also trigger when the user mentions "code rot", "legacy cleanup", "refactoring priorities", or wants to understand the overall health of a project before a major effort. Trigger even if the user doesn't say "technical debt" explicitly — any request to systematically assess code quality and identify improvement priorities belongs here.
readonly-sql-guard
Make an agent's database access provably read-only. Use when an agent runs caller-supplied SQL against a production/ERP/analytics database (a "query" MCP tool, text-to-SQL, an admin console), or when reviewing DB-access code for write/DDL/side-effect/transaction-escape risks. Checks what a statement CALLS, not just its shape.
web-artifacts-builder
Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use for complex artifacts requiring state management, routing, or shadcn/ui components - not for simple single-file HTML/JSX artifacts.
webapp-testing
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs.
discernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals, or emails, estimates or projections, analysis or interpretation of data, factual claims they may rely on, or a multi-step argument — invoke this skill BEFORE finalizing your reply and then, if it applies, append 2-3 short follow-up questions, each tied to something specific in what you just produced, that help the user check key facts, probe the reasoning or assumptions, and notice missing context. Do this at most once per conversation. Skip it when the user asked a trivial how-to or simple lookup, wants a purely educational explanation, asked you only to format, convert, or assemble a file from content they provided, is writing code they will run, is doing creative writing or casual chat, or already asked you to double-check, cite, or review — the skill file explains these boundaries and the exact output format.