How to handle collisions in concepts while building a chatbot using ChatScript
We have recently had a project of building implement engine for natural language recognition to create AI for chatbot used in the insurance industry. Its UI was the button menu in the Facebook chat. We needed a bot to understand the user’s message and to get information from input depending on the phrase.
We faced the issue of concept collisions. When you work with big lists of terms, same words might appear in different concepts. So I got into a situation when I had to match and get values from concepts which have collisions in one kind of phrases. How to handle that?
First approach is to exclude values that are in collision between ~concept_A and ~concept_B. However, you might lose a set of values.
Second option is to suggest the user to use parameters in the same order they are mentioned in your pattern.
The third way is to organize the sets of terms moving all collision values to a separate concept, then adding the additional concept with all collisions to the pattern will give matches if values are in collision and not: u: ANY_ORDER_MATCH (I want << {_~concept_A} {_~concept_B} {_~concept_A_collision} >>)
I hope it helped someone. If you'd like to read other problems we faced please go to blog.webbylab.com/how-we-built-ai-for-a-ch…