<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>article Re-use intents with context in Chatbot</title>
    <link>https://community.sinch.com/t5/Chatbot/Re-use-intents-with-context/ta-p/14027</link>
    <description>&lt;DIV class="lia-message-template-content-zone"&gt;&lt;P&gt;In your bot's &lt;A href="https://community.sinch.com/t5/Chatbot/Conversation-design-intro/ta-p/9589" target="_self"&gt;conversation design&lt;/A&gt;, each intent represents a unique user goal or action triggering a specific block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yet, users might say the same thing at different points in the conversation. For instance, one could expect to trigger a "yes" intent for different reasons. In this type of scenario, you can re-use the same intent (in this example: "yes") in different contexts.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Context acts as a differentiating factor, allowing the bot to understand the specific conditions under which the same intent should be interpreted differently.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For this tutorial, we’re going to use pizza bot where intent yes and no has been used in order_pizza flow and you want to use yes and no intent inside of free dessert flow.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H2&gt;Add context to your bot&lt;/H2&gt;&lt;P&gt;For this tutorial, we’re going to use a pizza ordering bot where the intents&amp;nbsp;&lt;EM&gt;yes&lt;/EM&gt; and &lt;EM&gt;no&lt;/EM&gt; are used in order_pizza flow. Now, we want to use &lt;EM&gt;yes&lt;/EM&gt; and &lt;EM&gt;no&lt;/EM&gt; intents inside the free dessert flow.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To do so, we need to add an output context to a block, and a required context to an Intent block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;Add an output context to a block&lt;/H3&gt;&lt;P&gt;To add an output context to your block: &lt;/P&gt;&lt;/DIV&gt;&lt;DIV class="lia-message-template-content-zone"&gt;&lt;P&gt;1. Drag and drop a &lt;STRONG&gt;Message&lt;/STRONG&gt; block into your flow.&lt;/P&gt;&lt;P&gt;2. Add a &lt;STRONG&gt;Text message.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Screenshot 2024-02-09 at 16.27.14 (1).png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4321i1730F6A67FECF139/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 16.27.14 (1).png" alt="Screenshot 2024-02-09 at 16.27.14 (1).png" /&gt;&lt;/span&gt;&lt;P&gt; &lt;/P&gt;&lt;SPAN&gt;3. Navigate to the &lt;STRONG&gt;NLP&lt;/STRONG&gt; section within the tab bar.&lt;/SPAN&gt;&lt;P&gt;4. Add an output context named &lt;STRONG&gt;free_dessert&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 16.29.30.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4319iB6BD123DA6377313/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 16.29.30.png" alt="Screenshot 2024-02-09 at 16.29.30.png" /&gt;&lt;/span&gt;5.&amp;nbsp;&lt;SPAN&gt;Click on &lt;STRONG&gt;Save&lt;/STRONG&gt;.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="lia-message-template-content-zone"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="lia-message-template-content-zone"&gt;&lt;H3&gt;Add a required context to your intent&lt;/H3&gt;&lt;P&gt;1. Drag and drop an intent block onto your canvas and select the existing &lt;STRONG&gt;yes&lt;/STRONG&gt; intent.&lt;/P&gt;&lt;P&gt;2. Again, head to the &lt;STRONG&gt;NLP&lt;/STRONG&gt; section and add a required context.&lt;/P&gt;&lt;P&gt;3. Type&amp;nbsp;&lt;STRONG&gt;free_dessert&lt;/STRONG&gt; to match the output context created earlier. Please note that an intent can have multiple required contexts, since it can be re-used at different points in the conversation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 16.42.45.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4324i741CD5E4A5E67CAF/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 16.42.45.png" alt="Screenshot 2024-02-09 at 16.42.45.png" /&gt;&lt;/span&gt;&lt;P&gt; 4. Click on &lt;STRONG&gt;Save&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;Configure a response based on context&lt;/H3&gt;&lt;P&gt;Link the &lt;STRONG&gt;yes&lt;/STRONG&gt; intent to a message block tailored for users who want the free dessert.&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 17.03.41.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4325iD85F55AFE5C3D96A/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 17.03.41.png" alt="Screenshot 2024-02-09 at 17.03.41.png" /&gt;&lt;/span&gt;&lt;P&gt; &lt;/P&gt;&lt;H3&gt;&lt;STRONG&gt;Enhancing flow visualization&lt;/STRONG&gt;&lt;/H3&gt;&lt;P&gt;Creating a clear and understandable bot conversation flow is essential. While direct connection arrows to intent nodes aren't possible, enhancing your flow's clarity through visual connections between message blocks and intents is achievable. This approach visually delineates the conversation's progression and response logic based on user interactions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To enhance your context visualisation on the canvas, we sugget to use Parent connections. Parent connections are nothing but a visual tool: they do not bear any logic.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To add Parent connections to your blocks with context:&lt;/P&gt;&lt;P&gt;1. Open the block that bears the ouput context.&lt;/P&gt;&lt;P&gt;2. Navigate to the&amp;nbsp;&lt;STRONG&gt;Settings&lt;/STRONG&gt; tab. &lt;/P&gt;&lt;P&gt;3. Under &lt;STRONG&gt;Parent&lt;/STRONG&gt; dropdown, select the &lt;STRONG&gt;Free_dessert&lt;/STRONG&gt; block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 17.06.45.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4327i935AC1E0B7945CD6/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 17.06.45.png" alt="Screenshot 2024-02-09 at 17.06.45.png" /&gt;&lt;/span&gt;&lt;P&gt;4. Click &lt;STRONG&gt;Save.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;See also:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.sinch.com/t5/Chatbot/Add-an-intent-to-your-bot/ta-p/13248" target="_blank" rel="noopener"&gt;Add an intent to your bot&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.sinch.com/t5/Chatbot/Recognize-expressions-with-intents/ta-p/13237" target="_blank" rel="noopener"&gt;Recognize expressions with intents&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.sinch.com/t5/Chatbot/Canvas-overview/ta-p/13056" target="_blank" rel="noopener"&gt;Canvas overview&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;!--         notionvc: f392881f-afa3-43ce-8911-7e9727eeb803         --&gt;&lt;/P&gt;&lt;/DIV&gt;</description>
    <pubDate>Tue, 13 Feb 2024 16:18:32 GMT</pubDate>
    <dc:creator>Agatha_Morisca</dc:creator>
    <dc:date>2024-02-13T16:18:32Z</dc:date>
    <item>
      <title>Re-use intents with context</title>
      <link>https://community.sinch.com/t5/Chatbot/Re-use-intents-with-context/ta-p/14027</link>
      <description>&lt;DIV class="lia-message-template-content-zone"&gt;&lt;P&gt;In your bot's &lt;A href="https://community.sinch.com/t5/Chatbot/Conversation-design-intro/ta-p/9589" target="_self"&gt;conversation design&lt;/A&gt;, each intent represents a unique user goal or action triggering a specific block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yet, users might say the same thing at different points in the conversation. For instance, one could expect to trigger a "yes" intent for different reasons. In this type of scenario, you can re-use the same intent (in this example: "yes") in different contexts.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Context acts as a differentiating factor, allowing the bot to understand the specific conditions under which the same intent should be interpreted differently.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;For this tutorial, we’re going to use pizza bot where intent yes and no has been used in order_pizza flow and you want to use yes and no intent inside of free dessert flow.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H2&gt;Add context to your bot&lt;/H2&gt;&lt;P&gt;For this tutorial, we’re going to use a pizza ordering bot where the intents&amp;nbsp;&lt;EM&gt;yes&lt;/EM&gt; and &lt;EM&gt;no&lt;/EM&gt; are used in order_pizza flow. Now, we want to use &lt;EM&gt;yes&lt;/EM&gt; and &lt;EM&gt;no&lt;/EM&gt; intents inside the free dessert flow.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To do so, we need to add an output context to a block, and a required context to an Intent block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;Add an output context to a block&lt;/H3&gt;&lt;P&gt;To add an output context to your block: &lt;/P&gt;&lt;/DIV&gt;&lt;DIV class="lia-message-template-content-zone"&gt;&lt;P&gt;1. Drag and drop a &lt;STRONG&gt;Message&lt;/STRONG&gt; block into your flow.&lt;/P&gt;&lt;P&gt;2. Add a &lt;STRONG&gt;Text message.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-center" image-alt="Screenshot 2024-02-09 at 16.27.14 (1).png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4321i1730F6A67FECF139/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 16.27.14 (1).png" alt="Screenshot 2024-02-09 at 16.27.14 (1).png" /&gt;&lt;/span&gt;&lt;P&gt; &lt;/P&gt;&lt;SPAN&gt;3. Navigate to the &lt;STRONG&gt;NLP&lt;/STRONG&gt; section within the tab bar.&lt;/SPAN&gt;&lt;P&gt;4. Add an output context named &lt;STRONG&gt;free_dessert&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 16.29.30.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4319iB6BD123DA6377313/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 16.29.30.png" alt="Screenshot 2024-02-09 at 16.29.30.png" /&gt;&lt;/span&gt;5.&amp;nbsp;&lt;SPAN&gt;Click on &lt;STRONG&gt;Save&lt;/STRONG&gt;.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class="lia-message-template-content-zone"&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV class="lia-message-template-content-zone"&gt;&lt;H3&gt;Add a required context to your intent&lt;/H3&gt;&lt;P&gt;1. Drag and drop an intent block onto your canvas and select the existing &lt;STRONG&gt;yes&lt;/STRONG&gt; intent.&lt;/P&gt;&lt;P&gt;2. Again, head to the &lt;STRONG&gt;NLP&lt;/STRONG&gt; section and add a required context.&lt;/P&gt;&lt;P&gt;3. Type&amp;nbsp;&lt;STRONG&gt;free_dessert&lt;/STRONG&gt; to match the output context created earlier. Please note that an intent can have multiple required contexts, since it can be re-used at different points in the conversation.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 16.42.45.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4324i741CD5E4A5E67CAF/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 16.42.45.png" alt="Screenshot 2024-02-09 at 16.42.45.png" /&gt;&lt;/span&gt;&lt;P&gt; 4. Click on &lt;STRONG&gt;Save&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;H3&gt;Configure a response based on context&lt;/H3&gt;&lt;P&gt;Link the &lt;STRONG&gt;yes&lt;/STRONG&gt; intent to a message block tailored for users who want the free dessert.&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 17.03.41.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4325iD85F55AFE5C3D96A/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 17.03.41.png" alt="Screenshot 2024-02-09 at 17.03.41.png" /&gt;&lt;/span&gt;&lt;P&gt; &lt;/P&gt;&lt;H3&gt;&lt;STRONG&gt;Enhancing flow visualization&lt;/STRONG&gt;&lt;/H3&gt;&lt;P&gt;Creating a clear and understandable bot conversation flow is essential. While direct connection arrows to intent nodes aren't possible, enhancing your flow's clarity through visual connections between message blocks and intents is achievable. This approach visually delineates the conversation's progression and response logic based on user interactions.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To enhance your context visualisation on the canvas, we sugget to use Parent connections. Parent connections are nothing but a visual tool: they do not bear any logic.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;To add Parent connections to your blocks with context:&lt;/P&gt;&lt;P&gt;1. Open the block that bears the ouput context.&lt;/P&gt;&lt;P&gt;2. Navigate to the&amp;nbsp;&lt;STRONG&gt;Settings&lt;/STRONG&gt; tab. &lt;/P&gt;&lt;P&gt;3. Under &lt;STRONG&gt;Parent&lt;/STRONG&gt; dropdown, select the &lt;STRONG&gt;Free_dessert&lt;/STRONG&gt; block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2024-02-09 at 17.06.45.png" style="width: 999px;"&gt;&lt;img src="https://community.sinch.com/t5/image/serverpage/image-id/4327i935AC1E0B7945CD6/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screenshot 2024-02-09 at 17.06.45.png" alt="Screenshot 2024-02-09 at 17.06.45.png" /&gt;&lt;/span&gt;&lt;P&gt;4. Click &lt;STRONG&gt;Save.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;See also:&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.sinch.com/t5/Chatbot/Add-an-intent-to-your-bot/ta-p/13248" target="_blank" rel="noopener"&gt;Add an intent to your bot&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.sinch.com/t5/Chatbot/Recognize-expressions-with-intents/ta-p/13237" target="_blank" rel="noopener"&gt;Recognize expressions with intents&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.sinch.com/t5/Chatbot/Canvas-overview/ta-p/13056" target="_blank" rel="noopener"&gt;Canvas overview&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;!--         notionvc: f392881f-afa3-43ce-8911-7e9727eeb803         --&gt;&lt;/P&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 13 Feb 2024 16:18:32 GMT</pubDate>
      <guid>https://community.sinch.com/t5/Chatbot/Re-use-intents-with-context/ta-p/14027</guid>
      <dc:creator>Agatha_Morisca</dc:creator>
      <dc:date>2024-02-13T16:18:32Z</dc:date>
    </item>
  </channel>
</rss>

