Square Bear's AIML Learning File

  • 38 Replies
  • 14190 Views
*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6089
  • Mostly Harmless
Square Bear's AIML Learning File
« on: March 17, 2009, 01:30:03 pm »
New AIML Learning File

AIML Botmaster Steve Worswick (Square Bear) has written a file that will allow users to teach your bot new facts rather than just correcting its replies using badanswer.aiml. The user should say LEARN then the fact. For example:

Human: Learn the sun is hot
Bot: Ok I will learn that the sun is hot.

Human: Learn London is in England
Bot: Ok I will learn that London is in England.

Human: Learn a cat has four legs.
Bot: Ok I will learn that a cat has 4 legs.

Human: What has 4 legs?
Bot: a cat.

Human: What is the sun
Bot: hot.

Human: Learn the sun is hot and yellow
Bot: Ok I will learn that the sun is hot and yellow.

Human: What is hot and yellow
Bot: the sun.

Human: What is the sun
Bot: hot and yellow.

Human: Where is London
Bot: in England.

Human: What is in England
Bot: London.

Human: Learn Dr Wallace is an AI expert
Bot: Ok I will learn that Dr Wallace is an AI expert.

Human: What is an AI expert
Bot: Dr Wallace.

Human: Who is an AI expert
Bot: Dr Wallace.

Human: Who is Dr Wallace
Bot: an AI expert.

Human: What is hot
Bot: the sun.

Human: What has a cat?
Bot: 4 legs.

Square-Bear will update this file to cover more complicated knowledge such as "Learn the 2012 Olympic Games will be held in London", "Where will the 2012 Olympic Games be?". The current version of the file is available, along with all my other public AIML files at: http://square-bear.co.uk/aiml Square-Bear says, "Feel free to use it in your bots!"

Source : Alice Bot Blog - http://alicebot.blogspot.com/2009/03/new-aiml-learning-file.html
« Last Edit: March 17, 2009, 01:36:07 pm by Freddy »

*

Maviarab

  • Trusty Member
  • **********
  • Millennium Man
  • *
  • 1194
  • Lost in Giallo
    • The Celluloid Sage
Re: Square Bear's AIML Learning File
« Reply #1 on: March 18, 2009, 12:37:08 pm »
Sounds very good :)

*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6089
  • Mostly Harmless
Re: Square Bear's AIML Learning File
« Reply #2 on: March 18, 2009, 02:45:07 pm »
Yes, interesting that an AIML bot can now actually learn stuff even though it has to be told to learn - kinda like humans really!

*

Maviarab

  • Trusty Member
  • **********
  • Millennium Man
  • *
  • 1194
  • Lost in Giallo
    • The Celluloid Sage
Re: Square Bear's AIML Learning File
« Reply #3 on: March 18, 2009, 07:37:35 pm »
More correct than you realise, over 95% of what we learn 'we are told' be it by a book, teacher, parents etc.

We actually find out very little ourselves I have found.

*

Dante

  • Mechanical Turk
  • *****
  • 160
Re: Square Bear's AIML Learning File
« Reply #4 on: March 20, 2009, 11:46:45 pm »
If I remember, I acutally PM'ed square bear a few years ago to create a list of his AIML (there were loads of forum posts, and Sqaure bear's AIML was like gold in a stream, you had to seive it out). Couple of months later, he adds it to his site, do I get a thanks? No....just another idea of mine. :P



*

Maviarab

  • Trusty Member
  • **********
  • Millennium Man
  • *
  • 1194
  • Lost in Giallo
    • The Celluloid Sage
Re: Square Bear's AIML Learning File
« Reply #5 on: March 21, 2009, 07:23:25 am »
Must remember to get that man a medal...... ::)

*

Dante

  • Mechanical Turk
  • *****
  • 160
Re: Square Bear's AIML Learning File
« Reply #6 on: March 21, 2009, 12:20:48 pm »
It's alright, I'm not a boastful man......gold-plated will do fine ;)



*

squarebear

  • Trusty Member
  • ********
  • Replicant
  • *
  • 688
  • It's Hip to be Square
Re: Square Bear's AIML Learning File
« Reply #7 on: April 14, 2009, 04:58:20 pm »
If I remember, I acutally PM'ed square bear a few years ago to create a list of his AIML (there were loads of forum posts, and Sqaure bear's AIML was like gold in a stream, you had to seive it out). Couple of months later, he adds it to his site, do I get a thanks? No....just another idea of mine. :P
lol sorry Danate. Many thanks for your continued support and inspiration. ;D
Feeling Chatty?
www.mitsuku.com

*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6089
  • Mostly Harmless
Re: Square Bear's AIML Learning File
« Reply #8 on: February 02, 2013, 05:18:22 pm »
SquareBear,

I'm playing with Program# at the moment.  I'm just wondering how this code works.  Does it store the data somewhere ?  Is it only meant to be used by Pandorabots ?

I can make custom tags for my app...

*

squarebear

  • Trusty Member
  • ********
  • Replicant
  • *
  • 688
  • It's Hip to be Square
Re: Square Bear's AIML Learning File
« Reply #9 on: February 05, 2013, 09:23:38 pm »
Hi Freddy. Sorry, I must have missed this.

I think Dave Morton was looking at getting it to work with Program O but yes, it is designed primarily for use with Pandorabots, as they support the <learn> and <eval> tags. It makes new categories depending on what it has learned and stores them in memory, which takes priority over the update.aiml file. Each learned fact is only available for the user who taught it, in order that it doesn't learn nonsense like "Tony iz a gay n00b lol" for everyone who talks to it.

There is also the <learnf> tag on the subscription servers which writes its learned knowledge to a file called learn.aiml and is accessible to all users. However, this needs to be checked carefully to avoid it filling up with rubbish.

One of the advantages of using a Flash interface, is that everytime Mitsuku learns something new, she emails me to let me know and I can decide whether to add it to her permanent knowledge or not.
Feeling Chatty?
www.mitsuku.com

*

Art

  • At the end of the game, the King and Pawn go into the same box.
  • Global Moderator
  • ******************
  • Hal 4000
  • *
  • 4407
Re: Square Bear's AIML Learning File
« Reply #10 on: February 06, 2013, 12:15:49 am »
While thinking about chatbots and the technology behind then (at present), I thought it would be really cool if one could first establish 'enough, necessary' filters in place and then let the bot go free! It would / could absorb anything and everything that it could (within it's realm of curiousness), sex, drugs, rock-N-roll, sports, places, people, etc. Once it established limit was reached (either timed or volume as in Gigabytes), it would then start filing and cataloging everything it had learned and would, on it's own, based on the above mentioned filters, discard everything it felt wasn't pertinent or proper.

Years ago certain bots used to have a "Bad Names" file where some words were automatically added as they were found. Today's bots can do so much more in such a short period of time that such endeavors might not be possible.

Basically, instead of limiting the bot from the start, let it go, then allow it to reject that which does not fit acceptable criteria. (whatever you definition of acceptable happens to be)! :0

Just a thought....
In the world of AI, it's the thought that counts!

*

Bragi

  • Trusty Member
  • ********
  • Replicant
  • *
  • 564
    • Neural network design blog
Re: Square Bear's AIML Learning File
« Reply #11 on: February 06, 2013, 08:40:04 am »
Quote
It makes new categories depending on what it has learned and stores them in memory, which takes priority over the update.aiml file.
I still find the usage of update.aiml a bit puzzling. Why not simply fix the patterns themselves instead of putting the fixes in a separate file? As far as I can see, the 'graphmaster', as described by Richard Wallace doesn't specify that the filenames should be stored in the path. Without that, it becomes impossible to know from where each pattern came from unless you reload them from the xml files all the time (which can be slow for big sets). Furthermore, how do you fix the definitions in update.aiml?

*

squarebear

  • Trusty Member
  • ********
  • Replicant
  • *
  • 688
  • It's Hip to be Square
Re: Square Bear's AIML Learning File
« Reply #12 on: February 06, 2013, 10:57:03 am »
The new categories go into a new file as you wouldn't want things like "When I say hello, you say f**k off!" being learned and remembered for all users. If you put them directly into the update.aiml file, you would have to keep checking just in case something like that had been added. Keeping them separate makes it a lot more manageable, as you don't have to go through categories which you know to be genuine.

update.aiml is used when you are adding new categories when reviewing your chatlogs. Once it gets to about 1Mb or so, you can rename it to something else and start a new update.aiml file. The order of the files or where the patterns are stored is unimportant, apart from realising that the files that are loaded later take priority if a duplicate category is activated. This is why update.aiml is loaded last, as it has your changes in it.

Hope that makes sense.

Not sure what you mean by "fix the patterns"? Update.aiml is used for new patterns. It can be used for corrections but that would be bad practice, as you will end up with many duplicate patterns.
Feeling Chatty?
www.mitsuku.com

*

Bragi

  • Trusty Member
  • ********
  • Replicant
  • *
  • 564
    • Neural network design blog
Re: Square Bear's AIML Learning File
« Reply #13 on: February 06, 2013, 12:18:42 pm »
Quote
as you will end up with many duplicate patterns.
Which is the case with Alice.

*

Freddy

  • Administrator
  • **********************
  • Colossus
  • *
  • 6089
  • Mostly Harmless
Re: Square Bear's AIML Learning File
« Reply #14 on: February 06, 2013, 01:18:20 pm »
Thanks for the explanation SquareBear and no worries about missing it  :)

My bot is currently only on the desktop, I'm not sure if I will make a public one.  It's more of an assistant, but I would like it to chat well.

It sounds like I have to implement my own learning feature then.  Shouldn't be too bad.  I can do "If I say this you say that" easily enough and other things.

As for online bots, yes we need to be weary of what they learn !  ;D

Is there a good editor or tool for AIML that will find duplicate patterns ?  I thought of Gaitobot editor maybe, haven't been able to download it the past few days as my ISP was having problems connecting to sites.

 


Users Online

25 Guests, 5 Users
Users active in past 15 minutes:
ivan.moony, Freddy, keghn, Art, marc13120
[Administrator]
[Global Moderator]
[Roomba]
[Trusty Member]

Most Online Today: 45. Most Online Ever: 208 (August 27, 2008, 09:36:30 am)

Articles