APIs to simplify interaction with the Google Cloud Speech-to-Text service.

Before calling these APIs, be sure you’ve saved your Google Cloud credentials at ~/cloud_speech.json. For more information, see these setup instructions.

This API is designed for the Voice Kit, but it has no dependency on the Voice HAT/Bonnet, so may be used without it.

class aiy.cloudspeech.CloudSpeechClient(service_accout_file=None)

Bases: object

recognize(language_code='en-US', hint_phrases=None)
recognize_bytes(data, language_code='en-US', hint_phrases=None)

Data must be encoded according to the AUDIO_FORMAT.