Listen to our top text-to-speech upgrades for 64-bit devices.

Posted by Rakesh Iyer, Staff Software Engineer and Leland Rechis, Group Product Manager

We’re significantly upgrading the speech services of Google’s speech engine, enabling us to deliver clearer, more natural voices. All 421 voices in 67 languages ​​have been upgraded with a new voice model and synthesizer.

If you’re already using TTS and the Speech Services by Google engine, you don’t need to do anything – everything happens behind the scenes, as your users have automatically downloaded the latest update. We have seen a significant improvement in quality with this change, especially in terms of clarity and naturalness.

With this upgrade we will also change the default voice in the en-US to one built using newer speaker data, resulting in a drastic improvement in addition to our new stack. If your users have not selected a system voice and you rely on the system’s default settings, they will hear a slightly different speaker. You can hear the difference below:

Speaker change and upgrade for EN-US

Example current speaker

Example Upgraded Speaker

Speaker upgrades in a few other languages

Current

Upgraded

HI-IN

HI-IN

PT-BR

PT-BR

ES-VS

ES-VS

This update will be rolled out to all 64-bit Android devices via the Google Play Store in the coming weeks as part of the Speech Services by Google apk. If you’re concerned that your users haven’t updated this yet, you can check the minimum version code 210390644 on the com.google.android.tts package.

If you haven’t already used TTS in your projects, or if you haven’t given users the option to choose a voice in your app, it’s pretty simple and easy to experiment with. We’ve included some sample code to get you started.

Here’s an example of how to set up voice synthesis, get a list of voices, and set a specific voice. We finally send a simple utterance to the synthesizer.

public class Main activity stretches AppCompatActivity {
private static last String TAG = “TextToSpeechSample”;

private TextToSpeech tts;

private last UtteranceProgressListener progressListener =
new ones utteranceProgressListener() {
@Override
public emptiness onStart(String utteranceId) {
log.d(TAG, “Started utterance” + utterance ID);
}

@Override
public emptiness finished(String utteranceId) {
log.d(TAG, “Done with utterance” + utterance ID);
}

@Override
public emptiness onError(Strings) { }
};

private last TextToSpeech.OnInitListener initListener = new ones OnInitListener() {
@Override
public emptiness opInit(int status) {
tts.setOnUtteranceProgressListener(progressListener);
in front of (Voice Voice: tts.getVoices()) {
if (voice.getName().equals(“nl-nl-x-iog-local”)) {
tts.setVoice(voice);
tts.speak(“1 2 3”TextToSpeech.QUEUE_ADD, new ones Bundle(), “utterance ID”);
pause;
}
}
}
};

@Override
protected emptiness onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
tts = new ones Text to speech(this oneinitListener);
}

@Override
protected emptiness on Destroy() {
if (tts != zero) {
tts.shutdown();
}
super.onDestroy();
}
}

We are excited to see this improved experience in your app!