Speech Synthesis

Convert text to spoken audio.

Overview

The Speech Synthesis framework manages voices and speech synthesis for iOS, tvOS, and watchOS. (To perform text-to-speech tasks in macOS, use the NSSpeechSynthesizer class.) Synthesizing speech requires two main steps:

  1. Create one or more AVSpeechUtterance objects containing text to be spoken. Optionally, configure speech parameters (such as voice and rate) for each utterance.

  2. Pass utterances to a AVSpeechSynthesizer object to produce spoken audio. Optionally, use that object to control or respond to ongoing speech.

Topics

Spoken Text Attributes

AVSpeechUtterance

A chunk of text to be spoken, along with parameters that affect its speech.

AVSpeechSynthesisVoice

A distinct voice for use in speech synthesis.

Speech Synthesis Controls

AVSpeechSynthesizer

An object that produces synthesized speech from text utterances and provides controls for monitoring or controlling ongoing speech.

AVSpeechSynthesizerDelegate

Methods you can implement to respond to events that occur during speech synthesis.