Upgrade to our Platinum service and get your own custom designed 3D avatar
Bot Libre Dev

Is there any tool that generates pattern based on the key words

by sreekar posted Jul 4 2017, 7:06

Hi Admin,

I want to generate patterns based on the key words i tried but i can't , is there any code or tool to generate patterns based on the key words please let me know if any such tools or code that helps me.

and also can i know how to remove dot (.) at the end of the response in the code.

Thanks,

Sreekar C


by admin posted Jul 4 2017, 13:46
You can use response lists for keyword responses.

Question
Response
keywords: keyword1 keyword2

See,
https://www.botlibre.com/forum-post?id=483549


For an AIML or Self pattern that evaluates keywords you can use a simple wildcard pattern,

In Self,

Pattern("^ [keyword1 keyword2] ^")

In AIML,

<pattern>^ [keyword1 keyword2] ^</pattern>

Updated: Jul 4 2017, 13:47
Thumbs up: 0, thumbs down: 0, stars: 0.0
Views: 2409, today: 2, week: 6, month: 22

by sreekar posted Jul 4 2017, 15:30
Thank you admin,

If my key words are not unique or it is duplicate then what can i do

For example:

 
  • keyword *  
and i have one more pattern
 
  • keyword (keyword) *
In this case my pattern will be always matching first one.even though my question matches second pattern in this type of situation what should i do

Thumbs up: 0, thumbs down: 0, stars: 0.0
Views: 2279, today: 2, week: 4, month: 19

by sreekar posted Jul 4 2017, 15:42
In AIML,

 
  • keyword *
     
  • (example) keyword *
If my question is related to pattern 2 but my pattern is getting matched to pattern 1 only.

I tried

 
  • [example] keyword * this type also but its not working for me
PlZ help me


Also tell me how i can generate aiml pattern if i have more than two keyword ie; keyword 1, keyword 2, keyword 3

These keyword can be placed in different positions in my pattern can you explain me more about this.


Also let me know is there any java code or script to generate different aiml patterns with multiple keywords in multiple combinations


Thanks in advance 😊

Thumbs up: 0, thumbs down: 0, stars: 0.0
Views: 2451, today: 2, week: 4, month: 22

by admin posted Jul 4 2017, 17:03
If you have two patterns that match the same question then the pattern matching the first word will be used.

AIML is not very good for supporting keywords, I would recommend a response list instead.

For AIML for multiple keywords you can either use multiple categories, or use,

<pattern>^ [keyword1 keyword2 keyword3] ^</pattern>

Thumbs up: 0, thumbs down: 0, stars: 0.0
Views: 2421, today: 1, week: 4, month: 22

Id: 18194220
Posted: Jul 4 2017, 7:06
Updated: Jul 4 2017, 13:43
Replies: 4
Views: 2443, today: 1, week: 4, month: 36
0 0 0.0/5