{"id":18053,"date":"2018-06-06T07:52:24","date_gmt":"2018-06-06T07:52:24","guid":{"rendered":"https:\/\/developer.kore.ai\/v10-1\/?post_type=docs&#038;p=14314"},"modified":"2022-10-05T17:11:12","modified_gmt":"2022-10-05T16:11:12","slug":"additional-notes-nlp-settings-guidelines","status":"publish","type":"post","link":"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/nlp\/additional-notes-nlp-settings-guidelines\/","title":{"rendered":"NLP Settings and Guidelines"},"content":{"rendered":"<p><span style=\"font-weight: 400\">This article provides you with some essential guidelines to help you optimize your workflow with the XO Platform&rsquo;s NLP, and thus improve your VA&rsquo;s performance. For this purpose, we also recommend that you read <\/span><a href=\"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/chatbot-overview\/nlp-guide\/\"><span style=\"font-weight: 400\">NLP Overview<\/span><\/a> <span style=\"font-weight: 400\">and <\/span><a href=\"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/nlp\/optimizing-bots\/\"><span style=\"font-weight: 400\">Optimizing NLP<\/span><\/a><span style=\"font-weight: 400\">.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h1><span class=\"ez-toc-section\" id=\"Intent_Naming_Guidelines\"><span style=\"font-weight: 400\">Intent Naming Guidelines<\/span><\/span><\/h1>\n<p><span style=\"font-weight: 400\">Follow the below guidelines when naming your task (intent identifier):<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use an action verb, an object, and possibly a modifier (placed before or after the object). Typically, an intent name consists of 2 to 4 words.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use less than 5 words to convey the purpose of the task.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use the same verb in different tasks if the action is similar (For example, Show Issue\/Show Report instead of Show Issue\/Get Report).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid single-word actions.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid determiners (the, a, my, that, etc.)<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid digits but if you cannot, always use the numerical form.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid Kore.ai Platform terms such as task, alert, action, cancel, discard, amend, and webhook.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid using a potential entity in an intent name (For example, Get Weather Today, where today is a potential entity).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use special characters such as () &amp; \/ \\ $ [ ] + *.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use punctuation such as &ndash; , . ! ? &lsquo; &ldquo;.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use pronouns (i.e. Show Me All Issues)<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use terms related to the VA name (For example, Create Asana Task).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use a word both as a verb and as a noun (For example, Update Issue\/Get Updates).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">For List of Items entity type, do not have the combination of following characters while defining synonyms &ndash; (), %, &deg; (degree symbol for degrees i.e. 30&deg;C).<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Dialog Tasks must always contain an action verb, an object, and possibly a modifier (placed before or after the object). You must map almost all actions to the form <\/span><em><span style=\"font-weight: 400\">how + what<\/span><\/em><span style=\"font-weight: 400\"> and complete the sentence <\/span><em><span style=\"font-weight: 400\">the goal is to<\/span><\/em><span style=\"font-weight: 400\">:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">Do Something<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">Get Status<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">Send Detailed Report<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">Email Report Critical<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">Get 3 Day Forecast<\/span><\/em><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Alerts must contain an object and possibly a modifier (placed before or after the object). Avoid using verbs in alert altogether. Avoid using the word <\/span><em><span style=\"font-weight: 400\">alert<\/span><\/em><span style=\"font-weight: 400\"> in an alert name. Alerts must be mapped to the form <\/span><em><span style=\"font-weight: 400\">what<\/span><\/em><span style=\"font-weight: 400\"> and complete the sentence <\/span><em><span style=\"font-weight: 400\">alert me on:<\/span><\/em><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Something<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Status Updates<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Critical Status Update<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Changes<\/span><\/li>\n<\/ul>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"ML_Training_Guidelines\"><span style=\"font-weight: 400\">ML Training Guidelines<\/span><\/span><\/h2>\n<p><span style=\"font-weight: 400\">Here are a few recommendations that will improve the training of the Machine Learning engine within your assistant:<\/span><\/p>\n<p>&nbsp;<\/p>\n<h3><span class=\"ez-toc-section\" id=\"General_Recommendations\"><span style=\"font-weight: 400\">General Recommendations:<\/span><\/span><\/h3>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Batch test suites are compulsory, for comparing various ML models. Run the batch suite, configure the parameters, re-run the suite and compare the results.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">There is no set rule as to which ML model to go for. It is a trial and error method &ndash;&nbsp; configure the engine, run batch suites and compare results.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">If your dataset is large, then the stop words and synonyms are recognized automatically by the ML engine and taken care of without having to enable them explicitly.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Check for influencer words and if needed add them as stop words, for the n-gram algorithm.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Prepare examples that are as diverse as possible.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid adding noise or pleasantries. If unavoidable, add noise so that it is equally represented across intents, else you can easily overfit noise to intents.<\/span><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Using_the_Confusion_Matrix\"><span style=\"font-weight: 400\">Using the Confusion Matrix<\/span><\/span><\/h3>\n<p><span style=\"font-weight: 400\">The Confusion Matrix can be used to identify training sentences that are borderline and fix them accordingly. Each dot in the matrix represents an utterance and can be individually edited.&nbsp;<\/span><\/p>\n<p><span style=\"font-weight: 400\">The graph can further be studied for each of the following parameters:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Prevent false positives and false negatives by assigning the utterance to the correct intent. Click on the dot and on the edit utterance page assign the utterance to the correct intent.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Improve cohesion by adding synonyms or rephrasing the utterance. Cohesion can be defined as the similarity between each pair of intents. The higher the cohesion the better the intent training.&nbsp;<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Enlarge the distance between each pair of training phrases in the two intents. The larger the distance the better the prediction.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Confusing phrases should be avoided i.e. phrases that are similar between intents.<\/span><\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Using_The_K-fold_Model\"><span style=\"font-weight: 400\">Using The K-fold Model&nbsp;<\/span><\/span><\/h3>\n<p><span style=\"font-weight: 400\">The K-fold Model is ideal for large datasets, but can be used for less data too with two-folds. Track and fine-tune the F1-score, Precision, and Recall as per your requirements. A higher value of recall score is recommended.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h1><span class=\"ez-toc-section\" id=\"Patterns\"><span style=\"font-weight: 400\">Patterns<\/span><\/span><\/h1>\n<p><span style=\"font-weight: 400\">While using synonyms is great for words used in the name, users may sometimes refer to a task using slang, metaphors, or other idiomatic expressions.<\/span><\/p>\n<p><span style=\"font-weight: 400\">For example, a task name might be <\/span><em><span style=\"font-weight: 400\">Get Current Weather<\/span><\/em><span style=\"font-weight: 400\">, but the user inputs,<\/span><em><span style=\"font-weight: 400\"> What&rsquo;s happening with today&rsquo;s rain situation?<\/span><\/em><span style=\"font-weight: 400\">. In such cases, none of the words used in the task name are used, yet the input has the same meaning. To optimize the accuracy and recognition of the NLP interpreter for your VA, you can create patterns.<\/span><\/p>\n<p><span style=\"font-weight: 400\">When the <\/span><a href=\"https:\/\/kore.ai\/platform\/design-and-build\/natural-language-processing\/\"><span style=\"font-weight: 400\">NLP<\/span><\/a><span style=\"font-weight: 400\"> interpreter matches a synonym to one task or field, and a pattern to a different task or field, the pattern match is prioritized and used for recognition over the synonym match.<\/span><\/p>\n<table style=\"width: 100%;border-collapse: collapse;background-color: #fffbea;height: 36px\">\n<tbody>\n<tr style=\"height: 36px\">\n<td style=\"width: 100%;height: 36px\"><strong>Note<\/strong><span style=\"font-weight: 400\">: Patterns are evaluated in the order of their listing, so ensure&nbsp; that you add patterns in the order of most restrictive to least restrictive.<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><span style=\"font-weight: 400\">The following are some general guideline for creating intent patterns:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use a minimum of 3 words.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use words in their canonical forms (i.e. infinitive verbs, singular nouns).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use lowercase both for words and their synonyms.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use the US spelling of words (i.e. <\/span><em><span style=\"font-weight: 400\">normalize<\/span><\/em><span style=\"font-weight: 400\"> instead of <\/span><em><span style=\"font-weight: 400\">normalize<\/span><\/em><span style=\"font-weight: 400\">).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid using determiners and pronouns (the, a, my, that).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid using digits.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Avoid using entity values in defining a task pattern.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use elision (i.e. what&rsquo;s ).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use special characters such as () &amp; \/ \\ $ [ ] + *.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use punctuation such as &ndash; , . ! ? &lsquo; &ldquo;.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">For a quick guide towards the usage of patterns, refer to <\/span><a href=\"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/how-tos\/how-to-use-patterns-for-intents-entities\/\"><span style=\"font-weight: 400\">How to use Patterns<\/span><\/a><span style=\"font-weight: 400\">.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Pattern_Operators\"><span style=\"font-weight: 400\">Pattern Operators<\/span><\/span><\/h2>\n<ul>\n<li style=\"font-weight: 400\"><strong>AND: ( X Y )<\/strong><span style=\"font-weight: 400\">: An ordered relationship of words in sequence. This is the default setting. i.e. when you specify a pattern as <\/span><em><span style=\"font-weight: 400\">cancel booking, it <\/span><\/em><span style=\"font-weight: 400\">is the same as <\/span><em><span style=\"font-weight: 400\">(cancel booking )<\/span><\/em><span style=\"font-weight: 400\">.<\/span><span style=\"font-weight: 400\"><br \/><\/span><span style=\"font-weight: 400\">For example, <\/span><em><span style=\"font-weight: 400\">(Cancel booking )<\/span><\/em><span style=\"font-weight: 400\"> matches <\/span><em><span style=\"font-weight: 400\">Cancel my flight booking<\/span><\/em><span style=\"font-weight: 400\"> but doesn&rsquo;t match <\/span><em><span style=\"font-weight: 400\">I have booked a flight, can I cancel?<\/span><\/em><span style=\"font-weight: 400\">. The XO Platform uses patterns with increasing numbers of wildcards between words (up to 3 for an intent). So a pattern of <\/span><em><span style=\"font-weight: 400\">Cancel Order<\/span><\/em><span style=\"font-weight: 400\"> can match:<\/span><\/li>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">cancel booking,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">cancel my booking,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">cancel that last booking,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">cancel last week&rsquo;s booking.<\/span><\/li>\n<\/ul>\n<li style=\"font-weight: 400\"><strong>OR: [X Y Z]<\/strong><span style=\"font-weight: 400\">: Any of these can be interchangeably used in the user utterance. For example, ([get make] me [food drink dessert]) will match any of the below utterances:<\/span><\/li>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Get me food,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Make me a drink,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Get me a drink,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Get me a dessert,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Make me some quick food.<\/span><\/li>\n<\/ul>\n<li style=\"font-weight: 400\"><strong>NOT: !X<\/strong><span style=\"font-weight: 400\">: Words that should not appear in the user utterance for an intent match. For example, (!forecast) is marked as a pattern for an intent named <\/span><em><span style=\"font-weight: 400\">Get current weather<\/span><\/em><span style=\"font-weight: 400\"> and the VA supports another intent called <\/span><em><span style=\"font-weight: 400\">Get 3-day weather forecast.<\/span><\/em><\/li>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">User utterance: <\/span><em><span style=\"font-weight: 400\">Planning a trip to California get me the forecast<\/span><\/em><\/li>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">will not match <\/span><em><span style=\"font-weight: 400\">Get current weather<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">will match <\/span><em><span style=\"font-weight: 400\">Get 3-day weather forecast<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">Note that the word means <\/span><em><span style=\"font-weight: 400\">not after this point<\/span><\/em><span style=\"font-weight: 400\">. So (!forecast the weather) and (get the weather !forecast) are different. The utterance <\/span><em><span style=\"font-weight: 400\">get the forecast for the weather<\/span><\/em><span style=\"font-weight: 400\"> matches the second but not the first.<\/span><\/li>\n<\/ul>\n<\/ul>\n<li style=\"font-weight: 400\"><strong>Optional: {X}<\/strong><span style=\"font-weight: 400\">: For example, {phone} If the user utterance is <\/span><em><span style=\"font-weight: 400\">Get me a phone number<\/span><\/em><span style=\"font-weight: 400\"> or <\/span><em><span style=\"font-weight: 400\">get me a number<\/span><\/em><span style=\"font-weight: 400\"> the Platform will treat it equally.<\/span><\/li>\n<li style=\"font-weight: 400\"><strong>Enforce Phrase:<\/strong><span style=\"font-weight: 400\"> X_Y: To enforce occurrence of the phrase as is in the user utterance, without any words in between. For example, book_tickets. The utterance <\/span><em><span style=\"font-weight: 400\">book tickets<\/span><\/em><span style=\"font-weight: 400\"> or <\/span><em><span style=\"font-weight: 400\">I want to book tickets <\/span><\/em><span style=\"font-weight: 400\">will match but not <\/span><em><span style=\"font-weight: 400\">Can I book some tickets?<\/span><\/em><span style=\"font-weight: 400\">.<\/span><\/li>\n<li style=\"font-weight: 400\"><strong>Concepts: <\/strong><span style=\"font-weight: 400\">The XO Platform has a large set of inbuilt concepts that developers can use to define a pattern. For example, (I [like love] ~world_country) will match<\/span><\/li>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">I like India,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">I love traveling to Australia,<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">I would like to visit an African country.<\/span><\/li>\n<\/ul>\n<li style=\"font-weight: 400\"><strong>Unordered: &lt;&lt;, &gt;&gt;<\/strong><span style=\"font-weight: 400\">: Used to find words in any order. For example, &lt;&lt;Cancel Booking&gt;&gt; matches <\/span><em><span style=\"font-weight: 400\">Cancel my flight booking<\/span><\/em><span style=\"font-weight: 400\"> and also <\/span><em><span style=\"font-weight: 400\">I have a flight booking, can I cancel?.<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><strong>Start\/End of Statement: &lt;, &gt;:<\/strong><span style=\"font-weight: 400\"> For example, ( <\/span><em><span style=\"font-weight: 400\">book tickets&nbsp; &gt;<\/span><\/em><span style=\"font-weight: 400\"> ) will match <\/span><em><span style=\"font-weight: 400\">I want to book tickets<\/span><\/em><span style=\"font-weight: 400\">but will not match <\/span><em><span style=\"font-weight: 400\">book tickets tomorrow.<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><strong>Quote: &lsquo; &ndash;<\/strong><span style=\"font-weight: 400\">: If you quote words or use words that are not in canonical form, the system will restrict itself to what you used in the pattern. For example, (<\/span><em><span style=\"font-weight: 400\">like to book tickets<\/span><\/em><span style=\"font-weight: 400\">) This matches <\/span><em><span style=\"font-weight: 400\">I would like to book tickets for a trip to London <\/span><\/em><span style=\"font-weight: 400\">but not <\/span><em><span style=\"font-weight: 400\">I need to book tickets for a trip to London<\/span><\/em><span style=\"font-weight: 400\">.&nbsp;<\/span><\/li>\n<\/ul>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Entity_Patterns\"><span style=\"font-weight: 400\">Entity Patterns<\/span><\/span><\/h2>\n<p><span style=\"font-weight: 400\">As above, to detect entities, developers can use a combination of entity patterns and NER training. Entity patterns guide the XO Platform to where to look for a valid value for the entity. It is possible for an entity pattern to be found in several places in a sentence and the Platform will extract the value from the first instance that has a valid value. Apart from the task pattern guidelines above, follow the below guideline for entity patterns:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Include the positional wildcard * that indicates the expected position of the entity ( i.e. (from * to), (in * &gt;)); without it the pattern is invalid.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use words that should be present in the pattern before and after the position of the entity. Words after the positional wildcard help to delimit the search range for a valid entity value.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use start and end of sentence symbols (&lt; and &gt;) to separate the positional wildcard, but these are not strictly necessary because the XO Platform tool does not cross a sentence boundary to extract an entity value (except for a Description).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use other positional wildcards in your field pattern. All field patterns are processed in the same way and all other positional wildcards except one are ignored.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use field names or their synonyms in patterns or entity patterns. Only consider up to two wildcard words between the specified words.<\/span><\/li>\n<\/ul>\n<p><strong>Examples<\/strong><\/p>\n<p><span style=\"font-weight: 400\">Following are some examples of entity patterns to recognize the <\/span><em><span style=\"font-weight: 400\">from <\/span><\/em><span style=\"font-weight: 400\">and <\/span><em><span style=\"font-weight: 400\">to <\/span><\/em><span style=\"font-weight: 400\">flight number for an intent to <\/span><em><span style=\"font-weight: 400\">change flight<\/span><\/em><span style=\"font-weight: 400\">.<\/span><\/p>\n<p><span style=\"font-weight: 400\">The pattern operators defined above can be applied to entity patterns also.<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><strong>Pattern<\/strong><span style=\"font-weight: 400\">: word1 *n &ndash; up to n words after the occurrence of word1<\/span><span style=\"font-weight: 400\"><br \/><\/span><span style=\"font-weight: 400\">pattern for entity ToFlight &ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">to *1<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">ToFlight captured from user utterance <\/span><em><span style=\"font-weight: 400\">change flight to ABC123 <\/span><\/em><span style=\"font-weight: 400\">but not from <\/span><em><span style=\"font-weight: 400\">change flight&nbsp; for ABC123.<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><strong>Pattern<\/strong><span style=\"font-weight: 400\">: word1 * word2 or word1 word2 *n &ndash; multiple entities from a user utterance.<\/span><span style=\"font-weight: 400\"><br \/><\/span><span style=\"font-weight: 400\">patterns for entity ToFlight&ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">to * from<\/span><\/em><span style=\"font-weight: 400\">, and <\/span><em><span style=\"font-weight: 400\">from to *1.<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">patterns for entity FromFlight &ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">from * to <\/span><\/em><span style=\"font-weight: 400\">and <\/span><em><span style=\"font-weight: 400\">to from *1.<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">ToFlight&amp; FromFlight captured from user utterance <\/span><em><span style=\"font-weight: 400\">change flight from XYZ321 to ABC123<\/span><\/em><span style=\"font-weight: 400\"> and <\/span><em><span style=\"font-weight: 400\">change flight to ABC123 from XYZ321<\/span><\/em><span style=\"font-weight: 400\"> but not from <\/span><em><span style=\"font-weight: 400\">change flightfor ABC123 using XYZ321.<\/span><\/em><br \/>\n<table style=\"width: 100%;border-collapse: collapse;background-color: #fffbea;height: 36px\">\n<tbody>\n<tr style=\"height: 36px\">\n<td style=\"width: 100%;height: 36px\"><strong>Note<\/strong><span style=\"font-weight: 400\"><span style=\"font-weight: 400\">: W<\/span><\/span>hen multiple patterns are entered for an entity, a match of either one will be taken.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/li>\n<li style=\"font-weight: 400\"><strong>Pattern<\/strong><span style=\"font-weight: 400\">: [ word1 word2 ] *n &ndash; match against any one word or phrase as defined within [&hellip;].<\/span><span style=\"font-weight: 400\"><br \/><\/span><span style=\"font-weight: 400\">pattern for entity ToFlight&ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">to *1.<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">pattern for entity FromFlight &ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">[ using from ] *1.<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">ToFlight&amp; FromFlight are captured from user utterance <\/span><em><span style=\"font-weight: 400\">change flight&nbsp; from XYZ321 to ABC123<\/span><\/em><span style=\"font-weight: 400\"> and <\/span><em><span style=\"font-weight: 400\">change flight&nbsp; to ABC123 using XYZ321<\/span><\/em><span style=\"font-weight: 400\"> but not from <\/span><em><span style=\"font-weight: 400\">change flight&nbsp; for ABC123 using XYZ321.<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><strong>Pattern<\/strong><span style=\"font-weight: 400\">: ~concept *n &ndash; pattern built using concepts.<\/span><span style=\"font-weight: 400\"><br \/><\/span><span style=\"font-weight: 400\">pattern for entity ToFlight&ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">to *1.<\/span><\/em><em><span style=\"font-weight: 400\"><br \/><\/span><\/em><span style=\"font-weight: 400\">the pattern for entity FromFlight &ndash;&nbsp; <\/span><em><span style=\"font-weight: 400\">~from *1<\/span><\/em><span style=\"font-weight: 400\"> wherefrom<\/span> <span style=\"font-weight: 400\">is a concept as (using) (from)<\/span><span style=\"font-weight: 400\"><br \/><\/span><span style=\"font-weight: 400\">ToFlight&amp; FromFlight are captured from user utterance <\/span><em><span style=\"font-weight: 400\">change flight from XYZ321 to ABC123<\/span><\/em><span style=\"font-weight: 400\"> and <\/span><em><span style=\"font-weight: 400\">change flight&nbsp; to ABC123 using XYZ321<\/span><\/em><span style=\"font-weight: 400\"> but not from <\/span><em><span style=\"font-weight: 400\">change flight for ABC123 using XYZ321.<\/span><\/em><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">For more information on how to add patterns, refer to <\/span><a href=\"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/nlp\/fundamental-meaning\/#Manage_Patterns_and_Rules\"><span style=\"font-weight: 400\">Managing Patterns<\/span><\/a><span style=\"font-weight: 400\">.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Negative_Patterns\"><span style=\"font-weight: 400\">Negative Patterns<\/span><\/span><\/h2>\n<p><span style=\"font-weight: 400\">Negative patterns are used to eliminate intents detected by the Fundamental Meaning or Machine Learning models.<\/span><\/p>\n<p><span style=\"font-weight: 400\">For example, a user says <\/span><em><span style=\"font-weight: 400\">I was trying to Book a Flight when I faced an issue<\/span><\/em><span style=\"font-weight: 400\">. Though the machine identifies the intent as <\/span><em><span style=\"font-weight: 400\">Book a Flight<\/span><\/em><span style=\"font-weight: 400\">, that is not what the user wants to do. In such a case, defining <\/span><em><span style=\"font-weight: 400\">was trying to * <\/span><\/em><span style=\"font-weight: 400\">as a negative pattern, would ensure that the matched intent is ignored.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h1><span class=\"ez-toc-section\" id=\"Synonyms\"><span style=\"font-weight: 400\">Synonyms<\/span><\/span><\/h1>\n<p><span style=\"font-weight: 400\">Synonyms must be used when the words used to identify an intent\/entity are used interchangeably. Synonyms are defined for both intents and entities.<\/span><\/p>\n<p><span style=\"font-weight: 400\">Each intent has a name. For example, if your intent name is <\/span><em><span style=\"font-weight: 400\">Guided Search<\/span><\/em><span style=\"font-weight: 400\">. There are many synonyms that a user might enter to start this task, <\/span><em><span style=\"font-weight: 400\">such as Search Flights,<\/span><\/em><span style=\"font-weight: 400\"> or <\/span><em><span style=\"font-weight: 400\">Show me flights.<\/span><\/em><\/p>\n<p><span style=\"font-weight: 400\">As a developer, you must limit the name of a task to only two or three words, then consider synonyms for each of those words.<\/span><\/p>\n<p><strong>Example<\/strong><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Browse &ndash; Find, Search.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Flight&ndash;&nbsp; Seat, Ticket.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Consider alternative spelling for your synonyms, for example: <\/span><em><span style=\"font-weight: 400\">check in<\/span><\/em><span style=\"font-weight: 400\">, <\/span><em><span style=\"font-weight: 400\">check-in<\/span><\/em><span style=\"font-weight: 400\"> or checkin.<\/span><\/p>\n<p><span style=\"font-weight: 400\">Synonyms must be ideally defined only for words defined as part of the task name. The synonyms added at the VA level are applicable for all the tasks, i.e. when a developer adds a synonym for a word in Task A, those synonyms are also used for any other tasks with the same words in the task name. For example, synonyms defined for the word browse in the <\/span><em><span style=\"font-weight: 400\">Guided Search<\/span><\/em><span style=\"font-weight: 400\"> are also used for the <\/span><em><span style=\"font-weight: 400\">Keyword Search<\/span><\/em><span style=\"font-weight: 400\">. Synonyms can (and should) be used to increase the number of variations that we expect from a user requesting an intent. They supplement existing intent names with alternative wording, while not being so generic as to match everything. Remember that synonyms are unidirectional so tool=bar does not mean bar=tool.<\/span><\/p>\n<p><span style=\"font-weight: 400\">The general guideline for Synonyms are as follows:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use words in their canonical forms (i.e. infinitive verbs, singular nouns).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use lowercase both for words and their synonyms.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Keep synonym phrases to less than 5 words.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use the US spelling of words (i .e. <\/span><em><span style=\"font-weight: 400\">normalize<\/span><\/em><span style=\"font-weight: 400\"> instead of <\/span><em><span style=\"font-weight: 400\">normalize<\/span><\/em><span style=\"font-weight: 400\">).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Use intent over meaning (i.e. <\/span><em><span style=\"font-weight: 400\">get<\/span><\/em><span style=\"font-weight: 400\"> is a good synonym to <\/span><em><span style=\"font-weight: 400\">show<\/span><\/em><span style=\"font-weight: 400\"> if the context of the action means <\/span><em><span style=\"font-weight: 400\">find and display<\/span><\/em><span style=\"font-weight: 400\">).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t add synonyms to determiners or pronouns (the, a, my, that, etc.).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use a synonym that could match in two conflicting tasks.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use special characters such as () &amp; \/ \\ $ [ ] + *.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use punctuation such as &ndash; , . ! ? &lsquo; &ldquo;.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t assign synonyms to multiple words (For example, this is wrong: wrong, bad).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t add synonyms to digits.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t use the phrasal form (i.e. don&rsquo;t use <\/span><em><span style=\"font-weight: 400\">lookup<\/span><\/em><span style=\"font-weight: 400\"> as a synonym; simply use <\/span><em><span style=\"font-weight: 400\">look<\/span><\/em><span style=\"font-weight: 400\">).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Don&rsquo;t abbreviate to less than 2 letters.<\/span><\/li>\n<\/ul>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Synonym_Operations\"><span style=\"font-weight: 400\">Synonym Operations<\/span><\/span><\/h2>\n<p><span style=\"font-weight: 400\">A match between the user input and synonym for entity (only for List of Values and Lookup types) identification can occur in one of the following ways:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><strong>Partial Match<\/strong><span style=\"font-weight: 400\"> &ndash; This is the default behavior whereby one or more words in the input must match one or more words for a given synonym. For example, the user utterance&nbsp; <\/span><em><span style=\"font-weight: 400\">inflight services<\/span><\/em><span style=\"font-weight: 400\"> will match <\/span><em><span style=\"font-weight: 400\">inflight magazine..<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><strong>Exact Match<\/strong><span style=\"font-weight: 400\"> &ndash; Here the input must contain all the words for a given synonym. For example, <\/span><em><span style=\"font-weight: 400\">book inflight services <\/span><\/em><span style=\"font-weight: 400\">will match <\/span><em><span style=\"font-weight: 400\">add inflight services<\/span><\/em><span style=\"font-weight: 400\">. But <\/span><em><span style=\"font-weight: 400\">inflight services <\/span><\/em><span style=\"font-weight: 400\">&nbsp;will not match <\/span><em><span style=\"font-weight: 400\">inflight magazine<\/span><\/em><span style=\"font-weight: 400\">. To trigger an exact match, the synonym must be enclosed within double-quotes.<\/span><\/li>\n<li style=\"font-weight: 400\"><strong>Full Match<\/strong><span style=\"font-weight: 400\"> &ndash; The entire input must exactly match a given synonym word. For example, a <\/span><em><span style=\"font-weight: 400\">flight booking<\/span><\/em><span style=\"font-weight: 400\"> should match &lt;flight booking&gt; but <\/span><em><span style=\"font-weight: 400\">my flight booking<\/span><\/em><span style=\"font-weight: 400\"> should NOT match &lt;flight booking&gt;. Similarly, a <\/span><em><span style=\"font-weight: 400\">flight booking<\/span><\/em><span style=\"font-weight: 400\"> should not match &lt;my flight booking&gt;. To trigger an exact match, the synonym must be enclosed within angular brackets.<\/span><\/li>\n<\/ul>\n<p><strong>Canonical Form Match<\/strong><span style=\"font-weight: 400\"> &ndash; This is the default behavior wherein the user input is matched with the synonym or its canonical form. For example, <\/span><em><span style=\"font-weight: 400\">Book me a flight<\/span><\/em><span style=\"font-weight: 400\"> will match with the synonym <\/span><em><span style=\"font-weight: 400\">booking request<\/span><\/em><span style=\"font-weight: 400\"> since <\/span><em><span style=\"font-weight: 400\">book <\/span><\/em><span style=\"font-weight: 400\">is the canonical form of <\/span><em><span style=\"font-weight: 400\">booking<\/span><\/em><span style=\"font-weight: 400\">. To disable this behavior, prefix the synonym with a single apostrophe as <\/span><em><span style=\"font-weight: 400\">checking<\/span><\/em><span style=\"font-weight: 400\">. (post v7.1)<\/span><\/p>\n<table style=\"width: 100%;border-collapse: collapse;background-color: #fffbea;height: 36px\">\n<tbody>\n<tr style=\"height: 36px\">\n<td style=\"width: 100%;height: 36px\"><strong>Note<\/strong><span style=\"font-weight: 400\">: <em>Synonyms can be added to identify intents as well as entities. Entity identification is triggered only after an Intent is identified.<\/em><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><span style=\"font-weight: 400\">For more information on how to add synonyms, refer to <\/span><span style=\"font-weight: 400\"><a href=\"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/nlp\/fundamental-meaning\/#Manage_Synonyms\" rel=\"noopener noreferrer\" target=\"_blank\">Managing Synonyms<\/a><\/span><span style=\"font-weight: 400\">.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h1><span class=\"ez-toc-section\" id=\"Concepts\"><span style=\"font-weight: 400\">Concepts<\/span><\/span><\/h1>\n<p><span style=\"font-weight: 400\">Concepts are clusters of related and synonymous terms that you want to be considered as a group identified by a single term.<\/span><\/p>\n<p><strong>Allowed concept naming conventions:<\/strong><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Must have <\/span><strong>~<\/strong><span style=\"font-weight: 400\"> as a prefix<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Allowed characters in concept name are:<\/span><\/li>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">a to z and A-Z<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">1 to 9<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">_ (underscore)<\/span><\/li>\n<\/ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">At least one alphabet symbol must follow the ~.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Must not start or end with a _ (underscore).<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Concepts are case insensitive. i.e ~myConcept is the same as ~myconcept<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Examples for allowed concept names:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~my_concept<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~Sample<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~test123<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~my_new_concept<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Examples of invalid concepts names:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~_concept<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~concept_<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~a-concept<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">~123test<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">You can also define custom concepts using emojis.<\/span><\/p>\n<p><span style=\"font-weight: 400\">For more information, refer to <\/span><a href=\"https:\/\/developer.kore.ai\/v10-1\/docs\/bots\/nlp\/fundamental-meaning\/#Manage_Concepts\"><span style=\"font-weight: 400\">Custom Concepts<\/span><\/a><span style=\"font-weight: 400\">.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h1><span class=\"ez-toc-section\" id=\"Standard_Responses\"><span style=\"font-weight: 400\">Standard Responses<\/span><\/span><\/h1>\n<p><span style=\"font-weight: 400\">Standard Responses are template messages that the Platform uses to respond to specific situations during a conversation. Examples of these situations include resolution of ambiguous user inputs, requisition for authorization, obtaining confirmations, informing about interruptions and resumptions, and more. Standard Responses are categorized into the following:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Statements<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Greetings<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Queries<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Errors &amp; Warning<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Questions and Choices<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">While the Platform does come with canned responses, developers are encouraged to customize these messages and to add variations.<\/span><\/p>\n<p><span style=\"font-weight: 400\">To provide a seamless end-user experience across the conversational journey, developers may have to review each of the Standard Responses to ensure that they fit the overall persona\/theme of the VA.<\/span><\/p>\n<p><span style=\"font-weight: 400\">Standard Responses can be plain text messages or can be generated through JavaScript to compose dynamic messages and templates for supported channels. Where applicable, Standard Responses support contextual tags that help the developer to customize the messages.<\/span><\/p>\n<p><span style=\"font-weight: 400\">For example, when a user requests what a VA can do, the VA responds with a message. Here<\/span><em><span style=\"font-weight: 400\"> are the tasks I can perform for you<\/span><\/em><span style=\"font-weight: 400\">. <\/span><em><span style=\"font-weight: 400\">&lt;list-of-tasks&gt;<\/span><\/em><span style=\"font-weight: 400\">. In this example, the developer may choose to modify this message and reuse the tag &lt;list-of-tasks&gt;where appropriate. These tags are replaced with the actual text context during the conversation with run-time values.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h1><span class=\"ez-toc-section\" id=\"The_Knowledge_Graph\"><span style=\"font-weight: 400\">The Knowledge Graph<\/span><\/span><\/h1>\n<p><span style=\"font-weight: 400\">For executable tasks, the intent is identified based on either the task name (used in the Fundamental Meaning model) or Machine Learning utterances defined for a task. This approach is appropriate when a task can be distinctly identified from other tasks, using language semantics, and statistical probabilities derived from the machine learning model.<\/span><\/p>\n<p><span style=\"font-weight: 400\">In the case of FAQs, this approach may not fare well as most of the FAQs are similar to each other in terms of semantic variation, and will require additional intelligence about the domain to find a more appropriate answer.<\/span><\/p>\n<p><span style=\"font-weight: 400\">Kore.ai&rsquo;s Knowledge Graph-based model provides that additional intelligence required to represent the importance of key domain terms and their relationships in identifying the user&rsquo;s intent (in this case the most appropriate question).<\/span><\/p>\n<p><span style=\"font-weight: 400\">We will use the following two examples to explain the different configurations required to build a Knowledge Graph.<\/span><\/p>\n<table>\n<tbody>\n<tr>\n<th>\n<p><strong>Example A<\/strong><\/p>\n<\/th>\n<th>\n<p><strong>Example B<\/strong><\/p>\n<\/th>\n<\/tr>\n<tr>\n<td rowspan=\"2\">\n<p><span style=\"font-weight: 400\">Consider a VA trained with the following questions:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">A1: How to book a flight?<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">A2: What is the process to check in for a flight?<\/span><\/em><\/li>\n<\/ul>\n<\/td>\n<td rowspan=\"2\">\n<p><span style=\"font-weight: 400\">Consider a VA trained with the following questions:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">B1: Can I book tickets for two people?<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">B2: How do I book an extra seat for my baby?<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">B3: How can I change my booking?<\/span><\/em><\/li>\n<li style=\"font-weight: 400\"><em><span style=\"font-weight: 400\">B4: How do I check in for my flight?<\/span><\/em><\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><span style=\"font-weight: 400\">The following are a few challenges with intent recognition using a typical model based on pure machine learning and semantic rules:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Results obtained from machine learning-based models have a tendency to produce a false positive result if the user utterance has more matching terms with the irrelevant question.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">The model fails when the VA needs to comprehend based on domain terms and relationships. For example, the user utterance <\/span><em><span style=\"font-weight: 400\">What is the process to book a flight?<\/span><\/em><span style=\"font-weight: 400\"> will incorrectly fetch A2 as a preferred match instead of A1. As A2 has more terms matching with user utterance than A1.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">This model fails to fetch the correct response if part of a question is stated in a connection with another question. Example, A: the user utterance <\/span><em><span style=\"font-weight: 400\">I have booked a flight, can I check in?<\/span><\/em><span style=\"font-weight: 400\"> results in the ambiguity between A1 &amp; A2. Example B: User utterance <\/span><em><span style=\"font-weight: 400\">I booked tickets for two people, how do I do the check in<\/span><\/em><span style=\"font-weight: 400\">? will incorrectly match B1 over B4.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">In the Kore.ai Knowledge Graph model, having all the questions at the root level is equivalent to using a model based on term frequency and semantic rules. This challenge is mitigated by the multilevel KG approach which allows you to assign FAQs to nodes based on key terms and organize them into parent and child nodes.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Key_Domain_Terms_and_their_Relationship\"><span style=\"font-weight: 400\">Key Domain Terms and their Relationship<\/span><\/span><\/h2>\n<p><span style=\"font-weight: 400\">Identifying key terms and their relationships is an important aspect of building ontology.&nbsp;<\/span><\/p>\n<p><span style=\"font-weight: 400\">Let us understand this using our sample Example A. Both A1 and A2 are about an air travel procedure, one talks about booking a flight&nbsp; while the other talks about checking in for a flight. So while creating an ontology, we can create a parent node with two child nodes as <\/span><em><span style=\"font-weight: 400\">booking <\/span><\/em><span style=\"font-weight: 400\">and <\/span><em><span style=\"font-weight: 400\">check in<\/span><\/em><span style=\"font-weight: 400\">. Then A1 and A2 can be assigned to the child nodes of <\/span><em><span style=\"font-weight: 400\">booking <\/span><\/em><span style=\"font-weight: 400\">and<\/span><em><span style=\"font-weight: 400\"> check in <\/span><\/em><span style=\"font-weight: 400\">respectively.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<h2><span class=\"ez-toc-section\" id=\"Knowledge_Graph_Traits\"><span style=\"font-weight: 400\">Knowledge Graph Traits<\/span><\/span><\/h2>\n<table style=\"width: 100%;border-collapse: collapse;background-color: #fffbea;height: 36px\">\n<tbody>\n<tr style=\"height: 36px\">\n<td style=\"width: 100%;height: 36px\"><span style=\"font-weight: 400\"><strong>Note<\/strong>: Traits replace Classes starting from v6.4 of the XO Platform.<\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>&nbsp;<\/p>\n<p><span style=\"font-weight: 400\">When using traits, ensure you use it judicially as overuse may result in false negatives. When using traits, please also ensure:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Good coverage of traits.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">Traits should not get generalized improperly.<\/span><\/li>\n<li style=\"font-weight: 400\"><span style=\"font-weight: 400\">All the FAQs get tagged to mutually exclusive traits.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">Following is the example of how classes work: Let&rsquo;s say we create a class called <\/span><em><span style=\"font-weight: 400\">Request<\/span><\/em><span style=\"font-weight: 400\"> and add request related phrases to it. If the user says <\/span><em><span style=\"font-weight: 400\">I would like to get WebEx<\/span><\/em><span style=\"font-weight: 400\"> and <\/span><em><span style=\"font-weight: 400\">I would like to get trained<\/span><\/em><span style=\"font-weight: 400\"> for the Request class, this FAQ is only considered across the Knowledge Graph paths where the word request is tagged with. This is a positive scenario. But if the user says <\/span><em><span style=\"font-weight: 400\">Can you help with getting WebEx?<\/span><\/em><span style=\"font-weight: 400\">, and we did not have similar utterances trained for the <\/span><em><span style=\"font-weight: 400\">Request <\/span><\/em><span style=\"font-weight: 400\">class, it gets tagged with <\/span><em><span style=\"font-weight: 400\">None<\/span><\/em><span style=\"font-weight: 400\"> class, and this FAQ is only used with the paths where the word <\/span><em><span style=\"font-weight: 400\">request <\/span><\/em><span style=\"font-weight: 400\">isn&rsquo;t present. This results in a failure.<\/span><\/p>\n<p><span style=\"font-weight: 400\">Another possibility is that if the user says <\/span><em><span style=\"font-weight: 400\">I want to request help fixing WebEx<\/span><\/em><span style=\"font-weight: 400\"> and we have trained the<\/span><em><span style=\"font-weight: 400\"> Request<\/span><\/em><span style=\"font-weight: 400\"> class with some utterances having <\/span><em><span style=\"font-weight: 400\">I want to request<\/span><\/em><span style=\"font-weight: 400\">, and based on the training provided across all classes, the engine may generalize and tag this feature (phrase containing <\/span><em><span style=\"font-weight: 400\">Iwant to request<\/span><\/em><span style=\"font-weight: 400\"> ) to the <\/span><em><span style=\"font-weight: 400\">Request <\/span><\/em><span style=\"font-weight: 400\">class. In this case, if the <\/span><em><span style=\"font-weight: 400\">Request <\/span><\/em><span style=\"font-weight: 400\">class is not present in the help path for WebEx, this results in failure of identifying the input against <\/span><strong>help<\/strong><span style=\"font-weight: 400\"> &gt; WebEx.<\/span><\/p>\n<p><span style=\"font-weight: 400\">The cases where traits are useful are when we have a mutually exclusive set of FAQs. For example, in a Travel Assistant, we can have a set of FAQs for the booking process, and one for booking issues.&nbsp;<\/span><\/p>\n<ul>\n<li><strong>FAQs for the booking process&nbsp;<\/strong>\n<ul>\n<li><span style=\"font-weight: 400\">How do I make a booking online?<\/span><\/li>\n<li><span style=\"font-weight: 400\">What is the process for booking a flight??<\/span><\/li>\n<\/ul>\n<\/li>\n<li><strong>FAQs for booking Issues:<\/strong>\n<ul>\n<li><span style=\"font-weight: 400\">I am having issues making a booking.<\/span><\/li>\n<li><span style=\"font-weight: 400\">How to resolve an issue with my booking?<\/span><\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><span style=\"font-weight: 400\">When a user says <\/span><em><span style=\"font-weight: 400\">What is the process for making a booking when your mobile app doesn&rsquo;t work? <\/span><\/em><span style=\"font-weight: 400\">, the engine may find that this input is similar to both A2 and B2, and may present both of them as suggestions. We know that <\/span><em><span style=\"font-weight: 400\">Issue <\/span><\/em><span style=\"font-weight: 400\">is mutually exclusive to buy, and it does not make sense to present <\/span><em><span style=\"font-weight: 400\">buy<\/span><\/em><span style=\"font-weight: 400\"> related FAQs at all, in this case. The opposite (matching <\/span><em><span style=\"font-weight: 400\">Issue <\/span><\/em><span style=\"font-weight: 400\">FAQs for <\/span><em><span style=\"font-weight: 400\">buy <\/span><\/em><span style=\"font-weight: 400\">related questions) may be a much bigger problem. To solve this, we will create two traits, one for type <\/span><em><span style=\"font-weight: 400\">issues <\/span><\/em><span style=\"font-weight: 400\">and another for <\/span><em><span style=\"font-weight: 400\">buy<\/span><\/em><span style=\"font-weight: 400\">. Every input is classified into either <\/span><em><span style=\"font-weight: 400\">buy<\/span><\/em><span style=\"font-weight: 400\"> or <\/span><em><span style=\"font-weight: 400\">issue <\/span><\/em><span style=\"font-weight: 400\">and only the relevant questions will be used in finding an appropriate answer.<\/span><\/p>\n<div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This article provides you with some essential guidelines to help you optimize your workflow with the XO Platform&rsquo;s NLP, and thus improve your VA&rsquo;s performance. For this purpose, we also recommend that you read NLP Overview and Optimizing NLP. Intent Naming Guidelines Follow the below guidelines when naming your task (intent identifier): Use an action&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[6],"tags":[],"class_list":["post-18053","post","type-post","status-publish","format-standard","hentry","category-nlp"],"_links":{"self":[{"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/posts\/18053","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/comments?post=18053"}],"version-history":[{"count":29,"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/posts\/18053\/revisions"}],"predecessor-version":[{"id":48282,"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/posts\/18053\/revisions\/48282"}],"wp:attachment":[{"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/media?parent=18053"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/categories?post=18053"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/developer.kore.ai\/v10-1\/wp-json\/wp\/v2\/tags?post=18053"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}