Jump to content
  • Advertisement
Sign in to follow this  
m0ng00se

Design Issue in AI chatbot code

This topic is 3897 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm looking for ideas on the best way to implement a small design issue. User inputs a sentence. Computer does a string match. The string match is done in context using an integer key to identify what block of keywords to search for a match (relating to last computer input). For example: Computer says: "Do you like fire engines" That question has a hidden key (say 2001) that tells the computer to check all key words starting with 2001 for a match to part of the user reply. That works fine. Say the computer finds a match then it has to select a response that matches (random shuffle appropriate responses etc). Therein is the problem. I can match all the responses with the 2001 key but each response has to have it's own unique key so to identify the block for the next key words. For example: User may reply "yes I do" Computer matches "_YES_" amongst 2001 block and chooses response. Computer says "Do you like ambulances also?" which is a different subject and no longer a 2001 keycode. But to match the response to the key I've had to link 2001 to the response. Does that make any sense to anybody? m0ng00se

Share this post


Link to post
Share on other sites
Advertisement
It's okay I solved it.
So simple really.
Use eight numbers.
First four identify the context block.
Next four identify the next block.
Duh!

m0ng00se

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!