As you know I am hoping to use ChatGPT to control the NPC dialogue in my game.
In the last post I got the microphone working within Unity and so begun my first baby step in this direction.
The next step was to round trip a conversation from the Player to ChatGPT and back again.
I had in mind the following:
Player speaks (audio .wav) >> STT (text transcription) >> ChatGPT reply (text) >> TTS (audio .wav)
Having done some research on the available Speech-To-Text and Text-To-Speech services available from stand-alone to web services by Google, Azure and Amazon I opted for using Azure's services.
I set up an account for these on Azure and set up a pay-as-you-go account on ChatGPT so i could make use of its API. I then set up a little console app to test it all out.
Have a listen to my very first results. I think they are quite promising...
A conversation with ChatGPT pretending to be a farmer.
Seeding ChatGPT with information
So my next go has been to extend the previous code with some data about the game environment and the character that I want it to play. It seems quite promising. Check it out...
ChatGPT with a different voice actor and seeded with specific information.
Comments