text-to-speech
Skill này làm gì
Skill này tạo âm thanh nói độc lập từ văn bản bằng mô hình Starfish. Nó dành cho người cần lời thuyết minh, lời kể hoặc âm thanh podcast dưới dạng file âm thanh.
Khi nào nên dùng
- ✓Khi bạn cần một file âm thanh lời kể từ kịch bản.
- ✓Khi bạn muốn chọn giọng theo ngôn ngữ hoặc giới tính trước khi tạo.
- ✓Khi bạn muốn điều chỉnh tốc độ hoặc cao độ của giọng cho bản ghi.
Liên kết skill
https://github.com/calesthio/OpenMontage/blob/main/.claude/skills/text-to-speech/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Làm một lời thuyết minh tiếng Anh giọng nam trầm, bình tĩnh cho đoạn văn này, nói chậm hơn một chút.”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Agent liệt kê các giọng tương thích với mô hình, chọn giọng phù hợp với yêu cầu, gửi văn bản và đưa bạn liên kết để tải âm thanh về.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Text-to-Speech (HeyGen Starfish)
Generate speech audio files from text using HeyGen's in-house Starfish TTS model. This skill is for standalone audio generation — separate from video creation.
Authentication
All requests require the X-Api-Key header. Set the HEYGEN_API_KEY environment variable.
curl -X GET "https://api.heygen.com/v1/audio/voices" \
-H "X-Api-Key: $HEYGEN_API_KEY"
Tool Selection
If HeyGen MCP tools are available (mcp__heygen__*), prefer them over direct HTTP API calls.
| Task | MCP Tool | Fallback (Direct API) |
|---|---|---|
| List TTS voices | mcp__heygen__list_audio_voices |
GET /v1/audio/voices |
| Generate speech audio | mcp__heygen__text_to_speech |
POST /v1/audio/text_to_speech |
Default Workflow
- List voices with
mcp__heygen__list_audio_voices(orGET /v1/audio/voices) - Pick a voice matching desired language, gender, and features
- Call
mcp__heygen__text_to_speech(orPOST /v1/audio/text_to_speech) with text and voice_id - Use the returned
audio_urlto download or play the audio
List TTS Voices
Retrieve voices compatible with the Starfish TTS model.
Note: This uses
GET /v1/audio/voices— a different endpoint from the video voices API (GET /v2/voices). Not all video voices support Starfish TTS.
curl
curl -X GET "https://api.heygen.com/v1/audio/voices" \
-H "X-Api-Key: $HEYGEN_API_KEY"
TypeScript
interface TTSVoice {
voice_id: string;
language: string;
gender: "female" | "male" | "unknown";
name: string;
preview_audio_url: string | null;
support_pause: boolean;
support_locale: boolean;
type: string;
}
interface TTSVoicesResponse {
error: null | string;
data: {
voices: TTSVoice[];
};
}
async function listTTSVoices(): Promise<TTSVoice[]> {
const response = await fetch("https://api.heygen.com/v1/audio/voices", {
headers: { "X-Api-Key": process.env.HEYGEN_API_KEY! },
});
const json: TTSVoicesResponse = await response.json();
if (json.error) {
throw new Error(json.error);
}
return json.data.voices;
}
Python
import requests
import os
def list_tts_voices() -> list:
response = requests.get(
"https://api.heygen.com/v1/audio/voices",
headers={"X-Api-Key": os.environ["HEYGEN_API_KEY"]}
)
data = response.json()
if data.get("error"):
raise Exception(data["error"])
return data["data"]["voices"]
Response Format
{
"error": null,
"data": {
"voices": [
{
"voice_id": "f38a635bee7a4d1f9b0a654a31d050d2",
"name": "Chill Brian",
"language": "English",
"gender": "male",
"preview_audio_url": "https://resource.heygen.ai/text_to_speech/WpSDQvmLGXEqXZVZQiVeg6.mp3",
"support_pause": true,
"support_locale": false,
"type": "public"
}
]
}
}
Generate Speech Audio
Convert text to speech audio using a specified voice.
Endpoint
POST https://api.heygen.com/v1/audio/text_to_speech
Request Fields
| Field | Type | Req | Description |
|---|---|---|---|
text |
string | Y | Text content to convert to speech |
voice_id |
string | Y | Voice ID from GET /v1/audio/voices |
speed |
number | Speech speed, 0.5-1.5 (default: 1) | |
pitch |
integer | Voice pitch, -50 to 50 (default: 0) | |
locale |
string | Accent/locale for multilingual voices (e.g., en-US, pt-BR) |
|
elevenlabs_settings |
object | Advanced settings for ElevenLabs voices |
ElevenLabs Settings (optional)
| Field | Type | Description |
|---|---|---|
model |
string | Model selection (eleven_v3, eleven_turbo_v2_5, etc.) |
similarity_boost |
number | Voice similarity, 0.0-1.0 |
stability |
number | Output consistency, 0.0-1.0 |
style |
number | Style intensity, 0.0-1.0 |
curl
curl -X POST "https://api.heygen.com/v1/audio/text_to_speech" \
-H "X-Api-Key: $HEYGEN_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "Hello! Welcome to our product demo.",
"voice_id": "YOUR_VOICE_ID",
"speed": 1.0
}'
TypeScript
interface TTSRequest {
text: string;
voice_id: string;
speed?: number;
pitch?: number;
locale?: string;
elevenlabs_settings?: {
model?: string;
similarity_boost?: number;
stability?: number;
style?: n
Câu hỏi thường gặp
Tôi có thể chọn giọng nào?
Skill nói chỉ liệt kê các giọng tương thích với mô hình Starfish, và không phải mọi giọng video đều được hỗ trợ.
Có giống với tạo video không?
Không. Skill chỉ dành cho âm thanh, tách biệt với việc tạo video.
Có cần khóa API không?
Có. Nó dùng khóa API HeyGen được lưu trong cài đặt HEYGEN_API_KEY.
Chi tiết
Mô tả gốc của tác giả
Generate speech audio from text using HeyGen's Starfish TTS model. Use when: (1) Generating standalone speech audio files from text, (2) Converting text to speech with voice selection, speed, and pitch control, (3) Creating audio for voiceovers, narration, or podcasts, (4) Working with HeyGen's /v1/audio endpoints, (5) Listing available TTS voices by language or gender.
repo: calesthio/OpenMontage
Độ phổ biến
- Sao GitHub
- 75k
- Vị trí xếp hạng
- #2703
- Giấy phép
- AGPL-3.0
- Cập nhật
- 28/10/2026
Bình luận
- …
Thêm skill từ kho mã này
3d-asset-generation
75kGiúp agent của bạn chọn cách tạo đối tượng 3D cho một cảnh, bằng thư viện có sẵn, các tool chuyển văn bản hoặc ảnh thành 3D, và Blender để lắp ráp cuối cùng.
acestep
75kGiúp agent của bạn tạo nhạc nền, bài hát, jingle và các stem cho video bằng trình tạo nhạc mã nguồn mở ACE-Step.
agents
75kGiúp agent của bạn xây dựng trợ lý AI giọng nói bằng ElevenLabs, như bot chăm sóc khách hàng và nhân vật giọng nói tương tác.
ai-video-gen
75kGiúp agent của bạn tạo các đoạn video AI từ mô tả bằng văn bản hoặc ảnh tham khảo, chọn trong số nhiều dịch vụ tạo video.
Skill tương tự
openai-whisper-api
394kCho phép agent của bạn chuyển bản ghi âm thành văn bản bằng dịch vụ chuyển đổi của OpenAI, với tùy chọn nhãn người nói và tệp đầu ra.
openai-whisper
394kGiúp agent của bạn chuyển âm thanh thành văn bản trên chính máy tính bằng lệnh Whisper, không cần khóa API và không cần tải lên đám mây.
sag
394kGiúp agent của bạn đọc văn bản thành tiếng nói bằng giọng ElevenLabs và phát kết quả trên máy tính, kèm mẹo về phát âm và biểu cảm.