> ## Documentation Index
> Fetch the complete documentation index at: https://typecast.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# 오디오북 생성

오디오북 생성에는 일관된 보이스, 반복 가능한 파일명, 챕터 단위 출력이 중요합니다. CLI를 쓰면 에이전트가 챕터 초안 생성, 특정 구간 재생성, 승인본 분리를 단순한 명령으로 처리할 수 있습니다.

## 기본값 준비

챕터를 생성하기 전에 보이스와 모델을 설정합니다:

```bash
cast config set voice-id tc_xxx
cast config set model ssfm-v30
cast config set format mp3
```

프로젝트 전용 보이스가 필요하면 먼저 클로닝하고 반환된 `uc_` 보이스 ID를 저장합니다:

```bash
cast voices clone narrator-sample.wav --name "Narrator Draft"
cast config set voice-id uc_xxx
```

## 챕터 생성

```bash
cast "$(cat chapter-01.txt)" \
  --emotion smart \
  --out audiobook/chapter-01.mp3 \
  --format mp3

cast "$(cat chapter-02.txt)" \
  --emotion smart \
  --out audiobook/chapter-02.mp3 \
  --format mp3
```

## 자막 또는 리뷰용 타이밍 생성

```bash
cast "$(cat chapter-01.txt)" \
  --emotion smart \
  --out audiobook/chapter-01.wav \
  --timestamp-out audiobook/chapter-01.timestamps.json
```

상세 타이밍 검토에는 JSON을 사용하고, 오디오북 콘텐츠를 영상 preview로도 보여줘야 하면 `.srt` 또는 `.vtt`로 저장하세요.

## 장면별 감정 연출

톤이 명확한 짧은 구간은 preset emotion이 더 제어하기 쉽습니다:

```bash
cast "The room fell silent as the letter slipped from her hand." \
  --emotion preset \
  --emotion-preset sad \
  --emotion-intensity 1.2 \
  --out audiobook/scene-letter.mp3
```

앞뒤 문맥이 중요한 구간은 smart emotion에 문맥을 함께 전달합니다:

```bash
cast "She opened the door and froze." \
  --emotion smart \
  --prev-text "The hallway had been empty a moment ago." \
  --next-text "A familiar voice whispered her name." \
  --out audiobook/scene-door.mp3
```

## 에이전트 프롬프트 예시

```text
챕터 텍스트 파일에서 오디오북 초안을 생성해줘.
모든 챕터에 같은 보이스를 사용해줘.
출력은 ./audiobook 아래에 저장해줘.
챕터마다 MP3 파일 1개를 생성해줘.
영상 preview가 필요한 챕터는 오디오 옆에 SRT 파일도 생성해줘.
실패한 챕터가 있으면 파일명을 보고하고 계속 진행해줘.
```

## 파일명 규칙

| 자산 | 추천 파일명 |
|------|-------------|
| 전체 챕터 | `chapter-01.mp3` |
| 장면 수정본 | `chapter-01-scene-03-v2.mp3` |
| 승인된 최종본 | `chapter-01-final.mp3` |
| 대체 전달 톤 | `chapter-01-alt-happy.mp3` |

## 고급 기능 사용 기준

| 필요 | 추천 기능 |
|------|-----------|
| 일관된 내레이터 정체성 | `cast config set voice-id ...` |
| 샘플과 맞춘 임시 내레이터 | `cast voices clone narrator-sample.wav --name "Narrator Draft"` |
| 챕터 리뷰용 타이밍 | `--timestamp-out chapter-01.timestamps.json` |
| 챕터 영상 preview | `--timestamp-out chapter-01.srt` |
| 빠른 승인 재생 | `--out` 없이 `cast "one review sentence"` |

<Warning>
  승인된 오디오는 덮어쓰지 마세요. 수정본은 `-v2`, `-v3` 또는 톤 이름을 붙여 저장하도록 에이전트에게 지시하세요.
</Warning>
