How to use the jetson nano to give a human voice to chatgpt and to talk with it with my own voice (chatgpt should understand what I want to mean)

Hello to everyone.

Actually I’m working on a project. I would like to give a realistic humanoid voice to chat gpt,converting the text produced by it into a humanoid voice and using my voice with a mic to talk with it. In short terms I want to do the same thing that the “amazon echo / Alexa” voice assistant does,without buying it,but using only what I already have…the Jetson nano. I’m exploring different ways to do that,such as the following ones :

these ideas go close to the goal that I want to achieve,for sure I can grab some tecniques from them,but I don’t understand what’s missing in the puzzle.

Regarding the voiceGPT app for Chrome,I don’t use Chrome,but Firefox and for Firefox it does not work. And anyway,to install a chrome extension is not properly a challenge for me. Even if it is useful,I’m looking for new (and not too hard) challenges to train my problem solving skills.

Regarding the rhasspy project,it is not good because it is an extension for HomeAssistant ; HomeAssistant has the chatgpt integration,but I’ve checked that the answers given by it are pretty limited to the home automation. So,this idea should be discarded.

Regarding the idea proposed on the youtube video,I want to save your time. This is the python script he used :

import os
from gtts import gTTS
myText='Get Ready Player 1'
myOutput=gTTS(text=myText, lang="it",slow=False)
myOutput.save('talk.mp3')
os.system('mpg123 talk.mp3')

as you can see,it gets the text from the sentence I wrote inside the variable “myText”. I imagine that the script should be changed. The variable “myText” should be something that I want to ask to chatgpt and the variable “myOutput.save” should be the chatgpt answer. Inside the script should be also added the ability of chatgpt to understand what my voice wants to mean and even a loop cycle made with a unlimited number of questions and answers. How can I do all that using the jetson nano ? I would be happy if someone explained how he/she would make it. Come someone suggest to me some relevant video and textual tutorial that will bring me on the right road ? Thanks.

Hi @marietto2008, I’ve also seen people using the pyttsx3 library on Jetson, so you might want to try playing around with that also alongside gTTS and see which voice you like better. There is also the https://github.com/dusty-nv/jetson-voice project which has a container built for Nano.

Regarding the structure of your program, yes you will need a main loop for your script that does the chat dialog management - basically of this form:

while True:
     # get user query / question - either from text input or ASR
     # send query to chatGTP / retrieve answer
     # generate TTS and play audio

It will require some experimenting on your part to find what works best - you might also find some relevant projects on the Jetson Community Projects page here:

thanks. its interesting for sure,but I didn’t find the section where is explained how to integrate the openAI / chatGPT answers. And anyway,even if it was explained,it could be hard for me to integrate the speech recognition code with the openAI code to achieve my goal. Luckily I found a python script that does everything I want. Unfortunately it doesn’t work. But maybe it can be fixed. Do you want to give a look at the post that I have created,here :

thanks very much.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.