Inspiration

I was watching a youtube video about a unique game where you wander a spaceship, coming across terminals and using them to send messages to an A.I. who answers your questions. You could ask about the A.I. itself, about the people it knew and what they were like, and the A.I. would understand and respond.

What it does

Ask it a question, and it will try to figure out what is being asked, whether you're questioning the program directly, asking about yourself, asking about someone else (only if you refer to them as he, she, or they though). It also has limited ability to figure out if you're making a statement about yourself, the program, or someone else.

How I built it

I take in the full line, break it into word and shove it into an array. Then I have the program look for keywords, and then look for other keywords that might help figure out the context. Sometimes it'll look for those secondary keywords nearby, or only after the original keyword. Various flags are triggered for when the program senses the keywords in an order that means something to it.

Challenges I ran into

It was mostly a challange of figuring out the logic of language, and also I had to figure out where to stop because there are too many ways to say the same thing.

Accomplishments that I'm proud of

My program has some ability to avoid being tricked by some things. Instead of simply looking to see if there is a keyword and a secondary keyword in the array, it'll make sure the second keyword is actually after the first one, and that no other keyword that would change the context exists.

What I learned

Got some practice with c++, got familiar with a new programming application I hadn't used before (microsoft visual studio).

What's next for StatementBot

Built With

Share this project:

Updates