Skip to content

hwuu/spk2ai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Speak to AI (now ChatGPT)

With this small program, you can speak to ChatGPT and get answers with a synthetic voice, like talking to a real person. Most of the code lines were generated by ChatGPT; I just did a little refinement.

Usage:

spk2ai.py [-h] [--config CONFIG]

Optional arguments:

  • -h, --help: Show help message and exit
  • --config CONFIG: Specify the path of the config file

Config file template:

{
  "speech_region": "<region>",
  "speech_key": "<api key of Speech Service>",
  "openai_api_key": "<api key of ChatGPT>",
  "language": "zh-CN",
  "voice": "Xiaoxiao"
}

In the config file you can specify a language and a voice of the speech synthesizer, see details in:

About

Talk with AI by voice

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages