Skip to main content

A clean interface to Windows speech recognition and text-to-speech capabilities.

Project description

Allows your Windows python program to:
  • execute a callback when certain phrases are heard

  • execute a callback when any understandable text is heard

  • have different callbacks for different groups of phrases

  • convert text to speech.

Example

Showing speaking out loud and listening for all recognizable words.

import speech
import time

def callback(phrase, listener):
    if phrase == "goodbye":
        listener.stoplistening()
    speech.say(phrase)

listener = speech.listenforanything(callback)
while listener.islistening():
    time.sleep(.5)

Requirements

Requires Windows XP or Vista, and Python 2.4 or 2.5.

In addition to easy_installing speech.py, you’ll need pywin32 (for Python 2.5 or 2.4) and the Microsoft Speech kit (installer here).

Resources

Please let me know if you like or use this module - it would make my day!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

speech-0.4.10.zip (7.2 kB view hashes)

Uploaded Source

Built Distributions

speech-0.4.10-py2.5.egg (8.0 kB view hashes)

Uploaded Source

speech-0.4.10-py2.4.egg (8.0 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page