You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Yeah unfortunately the {sentence} tag wasn't defined well enough that it should work across multiple sentences. I think your version would be the more correct way to handle the {sentence} tag.
When I was first designing RiveScript, my bot's use cases were that the user would only ask one question at a time (or else my program would split multiple sentences apart, and reply to each one in turn) and the {sentence} tag was mainly to use the user's recent message echoed back at them, like:
+ knock knock
- Who's there?
+ *
% who is there
- <sentence> who?
+ *
% * who
- Haha! {sentence}<botstar> <star>{/sentence}!
To which their current implementation works great! 🤣 Since you're writing a new module you should fix it properly in your version, I'm not sure if or when I'll update mine.
Currently, I have unit tests in place checking {sentence} (and other tags as well) work with multiple words or sentences within a wildcard parameter. I just created a new to-do that I have to check what will happen if I use more of the same tag in one sentence and if they will be replaced as well.
Let's say in this case.
+ What does your name mean
- <bot name>, the conqueror of worlds in search of 42 that's what <bot name> means.
Hi,
While developing Rivescript-php I found yet another issue. This time it's in the playground.
translates to
This is incorrect according to the docs this should translate to
How to fix:
Fix the code accordingly maybe trim the sentences. I have the same problem in the PHP version, I might trim the sentences I don't know yet.
The text was updated successfully, but these errors were encountered: