-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Convo.extractResponses method is not working #1562
Comments
That is unusual! Do you have the "collect multiple lines of input" option checked? This is likely the cause. |
Yes, actually I do have that checked. I'll post a JSON of the CMS here soon. |
When using that option, you have to take extra steps to configure the a condition that, when matched, continues with the dialog. See the screenshot below. The default behavior of Botkit assumes the final line of input will match this "end" condition, so it discards it. If you have only one line, then the resulting value is empty. |
@benbrown thanks! I couldn't have figured that one out on my own. Is this the intended behaviour for the bot or a workaround? If yes, then should this be added to the docs (or maybe somewhere in the CMS UI near the checkbox for multi-line input?). |
yes, this is the intended behavior. it should be enforced in the UI. thank you for your feedback. |
Are you sure this is an issue with the Botkit core module?
Seems like it.
What are you trying to achieve or the steps to reproduce?
I created a brand new botkit instance by remixing a botkit-cms instance and a botkit-starter-slack instance to build a conversational slack bot. Then, I followed the instructions given in the slack bot setup checklist to configure the bot. I finally installed the app in my Slack team. I got the conversation working (using the default
hello
template provided in the botkit-cms). After that, I customized the conversation to accept user input as so:Now, when I do the conversation, the bot does go through the full conversation, and it does have the user responses saved in the
convo.transcript
object. But when I try to extract the conversation values (as documented here: https://botkit.ai/docs/readme-studio.html#controllerstudioafter), the object comes up with no values:What was the result you received?
Output:
What did you expect?
The extractResponses() should have the user responses
Context:
The text was updated successfully, but these errors were encountered: