What it does

The Quest Giver can be approached and talked to. It utilizes speech recognition to listen to user commands and will respond using text-to-speech! The Quest Giver remembers individual users and which quest they are currently working towards. The user can speak with the bot to turn in quests, get new ones, or suggest their own quest ideas! Each adventure has an associated XP value, so each task holds its appropriate weight. Compete with friends to see who accomplishes the most!

How I built it

I made this program in Python. I hashed together a speech recognition library with the Wit AI API to help process user speech. Then, I used Google's text-to-speech tool to bring life into the Quest Giver's dialogue. Finally, I developed a robust system to handle different user actions and the necessary follow-up questions for a range of edge cases. All quest and user data is stored away in local JSON files, so even if the program were to be restarted, important data like the user's XP and current quest are retained.

Challenges we ran into

My first attempts in setting up text-to-speech and speech recognition showed me that I had a lot of work to do to get this project in a presentable state. The original TTS library I was using was incredibly robotic, so I undertook a more complex system for the sake of higher-quality output. Similarly, the first implementation of the speech recognition system left me saying the same word over and over again hoping that the computer would finally hear what I was trying to say. Once I got my program functional, I wanted to port it to my Raspberry Pi, so that I could include a hardware component to this project, but I ran into many issues. After struggling with Pi's software issues for some time, I decided to focus back on the code itself to introduce some polish with the time I had left.

Accomplishments that we're proud of

I'm proud of the language processing logic I employed. I knew that with the scope of this project, I had to keep my implementation on the simpler side. I was able to identify synonym groupings to listen for. Depending on the context, the program can look for a match in one or two of these groupings to be confident in what the user is asking for. The result is a pleasant conversation logic that flows naturally.

What we learned

I learned a lot about text-to-speech and speech processing. My journey these past 24 hours has led me through topics including APIs, package installation, and data storage in JSON formats.

What's next for QuestGiver

Once I have the proper hardware components, I would love to have the quest giver connected to some LED lights. I think having a physical object to receive quests from would be rather magical. I envision a crystal orb that I can speak into and receive little side-quests to do when I'm bored.

Built With

Share this project:

Updates