Chatbot knowledge base

I’m trying to set up a chatbot, and one of the actions—Knowledge Base Lookup—is causing issues. When a user enters their question in the chat, HubSpot starts searching the Knowledge Base but gets stuck. It doesn’t return any results or a message saying nothing was found. However, if the user types anything else afterward, even just one letter, the bot then returns the search results for the first query. The issue seems to be that the action doesn’t trigger immediately, and I can’t figure out why. Here are some screenshots with an issue:

Hi @KKarvanova! Welcome to the Community-- happy to have you here :blush:

Is your chatbot live on your site? Have you tried using another browser or an incognito window to see if the same behavior occurs?

Thank you :blush:

Yes, i`s a live chatbot. I observe the same behavior in different browsers, in incognito mode and in the CRM preview.

I figured out the issue with the knowledge base search. The workflow I wanted to implement was as follows: the user enters the chat and can either choose one of the options or ask a question in free form. If the question doesn’t contain specific words like “purchase” (which would immediately direct them to sales), the bot would start searching for relevant information.
However, the problem is that the search trigger works differently. It uses the input provided after the trigger is activated for the search. The question the user asked before that is not processed by the chat in any way.
So, the interaction flow with the user will not be like this:
Start → Trigger with question options → Free-form user input → Search in the database → Display result
but rather like this:
Start → Trigger with question options (where we disable free-form input and add an option to “Ask a question”) → Search in the database → Display result.

Maybe we can do smth with this using js snippets? Save message for example