# Doubao Narration

Generates Mandarin and multilingual narration with Volcengine Doubao Speech.

- Repository: https://github.com/calesthio/OpenMontage (74341 stars)
- Category: Media
- License: AGPL-3.0
- Last updated: 2026-10-28
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add calesthio/OpenMontage --skill doubao-tts -g -a claude-code -y`
Codex: `npx skills add calesthio/OpenMontage --skill doubao-tts -g -a codex -y`
Cursor: `npx skills add calesthio/OpenMontage --skill doubao-tts -g -a cursor -y`
Gemini CLI: `npx skills add calesthio/OpenMontage --skill doubao-tts -g -a gemini-cli -y`

## Description

Generate Mandarin and multilingual narration with Volcengine Doubao Speech 2.0. Use when creating Chinese voiceovers, when the user prefers Doubao/Volcengine/火山引擎/豆包 TTS, or when narration needs character-level timestamp metadata for subtitles.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Doubao TTS

Requires `DOUBAO_SPEECH_API_KEY` in `.env`.
Set `DOUBAO_SPEECH_VOICE_TYPE` for the default voice, or pass `voice_id` to the tool.

## Current API

Use the new-console API key flow:

```text
X-Api-Key: ${DOUBAO_SPEECH_API_KEY}
X-Api-Resource-Id: seed-tts-2.0
```

Do not use `X-Api-App-Id` and `X-Api-Access-Key` with a new-console API Key. If the API returns `load grant: requested grant not found`, the key type or auth header is probably wrong.

For long-form video narration, prefer the async endpoint:

```text
POST https://openspeech.bytedance.com/api/v3/tts/submit
POST https://openspeech.bytedance.com/api/v3/tts/query
```

This returns `audio_url` plus `sentences[].words[]` timing metadata that can be used to build subtitles.

## OpenMontage Usage

Generate with the TTS selector:

```python
from tools.audio.tts_selector import TTSSelector

result = TTSSelector().execute({
    "preferred_provider": "doubao",
    "text": "如果 AI 真的会改变未来，普通人到底该怎么参与？",
    "voice_id": "zh_female_vv_uranus_bigtts",
    "output_path": "projects/my-video/assets/audio/narration.mp3",
    "speech_rate": 0,
    "enable_timestamp": True,
})
```

Or call the provider directly:

```python
from tools.audio.doubao_tts import DoubaoTTS

result = DoubaoTTS().execute({
    "text": "短样本试听文本。",
    "voice_id": "zh_female_vv_uranus_bigtts",
    "output_path": "projects/my-video/assets/audio/doubao_sample.mp3",
})
```

The provider writes:

- `output_path`: downloaded audio file
- `metadata_path`: full query response JSON, defaulting to `<output_path>.json`

## Recommended Workflow

The rest: https://github.com/calesthio/OpenMontage/blob/HEAD/.agents/skills/doubao-tts/SKILL.md
