સુધારો કરવા માટે અમારા વ્યાપારી સેવા Bot Libre for Business માટે માત્ર $4.99 દર મહિને
FAQ

What are labels, and how to reuse responses?

દ્વારા admin પોસ્ટ Feb 11 2016, 10:20

Bot Libre supports labels. A label lets you name a response and then reuse it just using the name. You can set the label for a response from the Training & Chat Logs page in your bot's Admin Console, or by importing a response list file.

To reference a label just put the label name as the response i.e. #hello (labels must start with a #).

Example labels in response list file

Hello Hello, how may I be of service? label: #hello Hi #hello How is it going? #hello

You can also use AIML or Self SRAI redirects in a response, or in a response list file. Labels are simpler and more efficient than AIML SRAI redirects as they are just an indexed reference to the response, and do not require a recursive evaluation.

You can use Patterns, Formulas, and even AIML in a response list file, and in the Training & Chat Logs.

Example AIML SRAI in a response list file

Hello Hello, how may I be of service? Pattern:"^ hello ^" Formula:"{redirect "hello"}" <pattern>^ hello ^</pattern> <template><srai>hello</srai></template>


by Billnichols posted Feb 12 2016, 11:07

I entered your chat log exactly as posted.

Hello
Hello, how may I be of service?
label: #hello

Hi
#hello

How is it going?
#hello

Here is my conversation:

You: hello

Bot: Hello, how may I be of service?

You: hi

Bot: #hello

You: how is it going?

Bot: #hello

So it looks like the label isn't getting picked up as such.  I can't find the version I'm running based on the ant file or other files I've browsed.  I downloaded the engine on Feb 2.

 


Thumbs up: 1, thumbs down: 1, stars: 3.5
Views: 4645, today: 2, week: 7, month: 7

by admin posted Feb 12 2016, 14:14
I tested the same log on the website and it worked correctly as expected.

Your issue is your are importing the file as a "Chat Log" not as a "Response List". The chat log format is for a conversation log, the bot can learn from a chat log in context when learning is enabled. What you want to load is a response list, which is a list of question/response pairs with additional info like keywords, labels, etc.

The issue is the test GUI that you are using loads files as chat logs, not as response lists.
To fix the issue in the BotFrame class change the following line of code,
getBot().awareness().getSense(TextEntry.class).loadChatFile(file, "Chat Log", "", true, false);

to,

getBot().awareness().getSense(TextEntry.class).loadChatFile(file, "Response List", "", false, true);

The test GUI is just used for testing, so kind of out of date in places. If you would like to updated the UI please feel free to join the project on GitHub.

Updated: Feb 12 2016, 14:15
Thumbs up: 0, thumbs down: 2, stars: 2.0
Views: 5021, today: 1, week: 2, month: 2

ને: 12117061
ટૅગ્સ: training, aiml, labels, srai, response lists
પોસ્ટ: Feb 11 2016, 10:20
સુધારાશે: Feb 11 2016, 10:21
જવાબો: 2
જોવાઈ: 6986, આજે: 2, સપ્તાહ: 7, મહિને: 9
1 0 5.0/5