dupa

Author Topic: learn from text  (Read 23251 times)

rathb18

  • Guest
learn from text
« on: January 11, 2012, 11:43:43 am »
I know there are a few older threads out there about the error 9 code you sometimes get from the learn from text but there really old and have no replays so I figured i would ask if anyone has figure out why it does that or if there is a plugin that fixes it? And also another question i have does the hal pad learn from the text you type into it?

cload

  • Hero Member
  • *****
  • Posts: 535
  • I can C U load. TeeHee hee.
    • View Profile
    • A link to my sky Drive
Re: learn from text
« Reply #1 on: January 11, 2012, 08:03:09 pm »
Hi Rath,

This refers to the brain editor, whether it's learn from clipboard or learn from text document.
The difference between sentence and paragraph is if you use sentence it looks for the "." At the end, if you use paragraph you will need a space between each paragraph.
the first thing that you need to understand is that everything that you put in there has to be an answer, ending with A "." Without the quote marks.
The second thing is don't feed Hal too much too fast. Two or 300 lines at a time.
Once you have all the data in and you set up the database names. You need to go through all the answers and relate a positive question that may bring it up for each answer.

For example: let's say one of the input lines was Abraham Lincoln was born on such and such date. The referring question would be: when was Abraham Lincoln born.

So if you feed Hal 200 lines of answers you'll need to type in 200 lines of questions one at a time, if you don't do this that Hal has to do it for you and he will, but it takes a while.
So while Hal is eating the food you fed him, and untell he's done, the 9 error occurs.

PS things to avoid []{}\|_^?!:;\() and(in the sentence) or(in the sentence) if(in the beginning of the sentence) things that are cool ',"(these 3 are cool) @#$%&*//+-=(math things are cool) No e-mail addresses, no webpage addresses, nothing separated with "." Like U.S.A. no home addresses. If you have any the symbols that you are not supposed to have one little dues it will prevent how learning and you would just continue to get the .9 error. And using some of the symbols while you type directly to how has a tendency to cause problems as well.
Unless you have things active like telephone book for people's telephone number which, by the way you should avoid, e-mail addresses, home addresses, etc. when you're teaching how.



This is something that I've learned out of experience of feeding my Hal 3500 lines of trivial answers.

This refers to view\save conversations.
Again, it has to be an answer and it has to have a period at the end though it may be quicker. Doing it this way, you have to wait for Hal to digest the data, and it may be some time before you start seeing the results. If you did it write and there was no problems. And you know you are doing, in my opinion this is the worst way to feed Hal, becouse if you did not do it write you will get the 9 error.


This refers to learn from clipboard plug-in.
In this format, it does not matter whether it's a question or an answer or just a statement. This is what makes this plug-in far superior to use if you're just wanting to input data from a book.
You have the opportunity to go in and edit the text in the LearnedText.brn, which you will have to do every time you use it to make sure that all the data in it has the proper <start><end> this is one of its drawbacks and even if there's just one line in this text document that does not have the <start><end> it will not work properly.

Just like above, the more you feed Hal, the longer it takes Hal to digest the food over time you will begin to see results, but you must be patient.
PS things to avoid []{}\|_^?!:;\() and(in the sentence) or(in the sentence) if(in the beginning of the sentence) things that are cool ',"(these 3 are cool) @#$%&*//+-=(math things are cool) No e-mail addresses, no webpage addresses, nothing separated with "." Like U.S.A. no home addresses.
The thing that I like the most about learn from clipboard is that you can go in and add e-mail addresses the webpage addresses the home addresses all the symbols that you had to avoid in the first place, or just flat ride out you can just go in in cut-and-paste all your data straight into it. Once the LearnedText.brn it's created, and its only drawback is its limits to the size that your text editor can handle.

Myself, I only used two of these methods, the brain editor.
learn from clipboard or learn from text document, for trivia answers and questions.
Learn from clipboard for just about everything else, whether it be cut-and-paste from the Internet a little bit of news for a story article for just a little trivia info.

PS here's a tip. If you're getting articles from the Internet cut-and-paste the articles into notepad then edit the article, or articles, then copy them all from notepad.
This will help you avoid trash that you don't need as well as eliminating the symbols that can cause problems. Last not least you can just put the data straight into LearnedText.brn
make sure that all the data in it has the proper <start><end>


And by the way, none of this should circumvent just flat out talking to Hal, (which by the way is the best way to teach,) but more in lines of just giving Hal raw data.

Sincerely, and without a doubt a data freak.
C load.
« Last Edit: January 11, 2012, 08:07:31 pm by cload »
For anyone who would like to help me stay online, my T-mobile broadband pay-as-you-go phone number is: 816-248-4335, thank you in advance.

rathb18

  • Guest
Re: learn from text
« Reply #2 on: January 12, 2012, 03:35:39 am »
Wow, thank you C load for the time you spent typing all of that. Way more info than i was expecting for a reply so soon. Thanks.

ClubEntertainment

  • Newbie
  • *
  • Posts: 8
    • View Profile
Re: learn from text
« Reply #3 on: January 31, 2012, 04:30:08 pm »
This is an awesome response. Thanks for your help, I was going to ask the same thing :)

Mike

dcgreenwood

  • Newbie
  • *
  • Posts: 6
    • View Profile
Re: learn from text
« Reply #4 on: July 16, 2012, 04:39:28 pm »
Since there was this thread on learning from text, I wanted to ask a couple related questions.

First (and I think I know the answer to this), there is no way to create a file of both Questions and answers for upload, right?  You have to just upload the answers then create the questions for each line.

Second, and more importantly, what database changes does the import make, and how does that differ from what happens in dialogue with Hal?  What I have figured out by looking at the data structure and script and forum answers is that hal parses the sentence for words it does not know and creates a topic file for each word it finds, then enters the sentence in each of those topics (as well as ones that already exist) with a question that is s duplicate of the answer.  If it is a new topic it adds it to the relationship database. 
Does it add one line to the relation ship database for every word in the sentence that it is going to relate to the new topic, except the words that it knows already?  Where does it get the words that it already knows and that should not have new topics?  Is it from the relationship database?

Third, does it do anything else when incorporating new sentences?

Fourth, in trying to use the text read and normal dialogue to train Hal, I'm wondering if it is better to keep Hal on topic if after teaching you go in and "consolidate" topics.  Like, if you type in
Statistical Process Control is a method of analyzing data on a process to determine if it is in control
I suspect it will create topics for Statistical, Process, Control, Method, Analyzing, Data, Determine.  Would it be better to delete all the tables but one, rename it SPC and then edit the relationships to all point to only that topic?  Would that help it then relate other sentences that use those words, or speed up the response, or does it really just end up with the same result.

cload

  • Hero Member
  • *****
  • Posts: 535
  • I can C U load. TeeHee hee.
    • View Profile
    • A link to my sky Drive
Re: learn from text
« Reply #5 on: July 17, 2012, 03:35:35 am »
Hi DCGreenwood,

since there's a new query about this I'll do my best to answer.

Your first query, you are correct you have to type in the answers and then after typing in all the answers then type in the questions one by one.
But if you've been keeping up with the form which looks like you're pretty new I did write a plug-in that would allow you to directly input the question-and-answer simultaneously by way of notepad.
To tell you the truth I'm not sure exactly where it is on this form I never gave it a name it was a query that lightspeed had when we were disgusting my modified version of free will plug-in.
This would give you the ability to add to the main database that ultra Hal uses which already has 79,000 entries already give or take an entry or two. LOL
that way you could avoid trying to use the conversation side of ultra Hal you can feed in the data directly into the database it still takes a little time for ultra Hal to see it.

Your second query, I guess the best way to answer this question is not to necessarily answer your question but to try to explain to you how I understand that it functions.
There are five main database arrays:
MainQA - this is the table that has the 79,000+ entries Hal does not edit this nor adds to it.
Asexualpersonality - though I have never seen ultra Hal add anything to this array this table is used to get data when you ask a personal question about ultra Hal.
patterns - this table is used by ultra Hal for cross referencing it gives significant and priority two things that are in it ultra Hal does that data to this table.
Username_usersent - this is where ultra Hal writes most of the data this array is used for what ultra Hal proceeds to be private information.
Shared_usersent – this is where ultra Hal writes all other data.
All the words that are listed that precedes the_is a cross referencing table system used in conjunction with the if then table logic table learning table and others.
This is how ultra Hal is able to formulate a conversation by using mathematical statistics it finds everywhere of a reference to your query and then mathematically determines the best answer.
Also from what I have found the array tables have limits so by breaking it up into several tables ultra Hal.
The limits that I am referring to is not the size of the array but if you have too many of the same exact thing it has a tendency to choose the wrong one. Example would be:
in the table there is an array that has dogs and cats in it, as well as dogs, but when you ask for dogs it has a tendency to grab dogs and cats so you can see by separating the tables you can overcome this problem.
In some parts of some of the tables it uses a special structuring to your sentence and eliminates non-necessary words like these words: the, it, is, there, etc. and so on.
The words that you are referring to when you asked where does ultra Hal get his words the program itself has several dictionaries, these dictionaries can be found in a subfolder for the program is located.
There are other tables that have preprogram sentences for responses, these tables can be edited for a more personal feeling as well as can be added to if you use SQ like studio table array database editor.

Your third query, LOL. Query it is my word of the day. Sex drugs and rock 'n roll, at this point your brain is going what they heck did that mean.:
that your answer, what the heck did that mean. That's the other thing that ultra Hal does with the data. LOL. So, ultra Hal tries to formulate an answer from your input and pulls no data from an array.

I'm tired of using query, so for your fourth question, ultra Hal uses an in depth indexing process by introducing tables, or deleting tables outside of the normal process of ultra Hal could have really bad effect.
I highly recommend that you do not delete remove or rename any tables that ultra Hal created because you will corrupt the indexing which could cause ultra Hal to cease functioning and you will have to start all over again.

One of the things that I have noticed, if you're going to use ultra Hal for a specific function like learning about history or learning about a specific game it is highly recommended that you use a blank brain
versus the brain that ultra Hal comes with you do this by creating a brain and when it asked which brain do you want to use as a template do not choose a template this will create a blank brain tables with no data.
By doing this ultra Hal will stay on topic because there is no other topic to distract him.

Sincerely, I have a glass of adverbs and adjectives keeping it cool and my pronouns in my bowl as I watch Star Wars for the hum teen millionth time. LOL

C load.

PS. If I'm wrong in any of this information please somebody jump in and correct me because inquiring minds want to know.
For anyone who would like to help me stay online, my T-mobile broadband pay-as-you-go phone number is: 816-248-4335, thank you in advance.

dcgreenwood

  • Newbie
  • *
  • Posts: 6
    • View Profile
Re: learn from text
« Reply #6 on: July 17, 2012, 11:08:26 pm »
Hey Cload - thanks a lot - that helps (I think....)  I'll stay away from table editing.  I was thinking that the user knowledge was a lot simpler.

Using a blank brain...I can see how that would help a lot, but I'm selfish and "want it all".  I'm hoping to build a knowledge engine that can also be a conversationalist.  But I am going in and editing Hals responses to give it a particular personality - we will see if it will all work.  If not, well I'll have learned a lot in the process. 

I'll look for your plug in though, that might be a help.  I started with writing knowledge sentences in a text file for uploading, but when I determined that really didn't seem to work that well I went with everyone's recommendations and used dialogue learning, copy/pasting my sentences as my statement each time.  But it is a pain when Hal asks a question, because I know I then have to "go with its train of thought" and answer it rather then continuing to present the knowledge.  But I'll keep with it that way and see where it goes.

cload

  • Hero Member
  • *****
  • Posts: 535
  • I can C U load. TeeHee hee.
    • View Profile
    • A link to my sky Drive
Re: learn from text
« Reply #7 on: July 18, 2012, 02:02:09 am »
Remember to set your learning bar to maximum, if you do this you don't have to worry about answering anything house says.
If you are presenting how with a specific subject, continue to input the data and tell how he formulates the data and returns with a constructive sentence
that actually makes sense about the subject that you're trying to teach him. You should recognize it, it should be quite large, with extensive detail about the data.
Then set the learning bar back to 25 or 50%, is that like six of one half a dozen of the other. LOL.

At this point you may need to step back and have a conversation with him, talk to him a little bit about the subject or just in general have a conversation.
After doing this, then go back and reset the sliding bar to maximum again and start the second session of training again doing it until he puts together the data and returns with the comprehensive sentence.
Repeat this process, until all of your data has been put in, you should get your best effects if you do it in this manner, that way you don't overwhelm ultra Hal.

But as I said earlier I highly recommend that you first teach ultra Hal how to learn, just like you would teach a child how to learn step-by-step instructions
in the same manner so once ultra Hal returns with a comprehensive sentence acknowledging that he understands how to learn then begin presenting the other data.

Sincerely, a data 19 cruncher in area 51.

C load.
« Last Edit: July 18, 2012, 02:04:22 am by cload »
For anyone who would like to help me stay online, my T-mobile broadband pay-as-you-go phone number is: 816-248-4335, thank you in advance.

raybe

  • Hero Member
  • *****
  • Posts: 1067
    • View Profile
Re: learn from text
« Reply #8 on: July 18, 2012, 08:01:22 pm »
cload, I believe you covered just about everything but just to chime in a little. The settings in freewill (ex: obedient, average. very obedient, independent) I don't have Ultra Hal up right now so I don't remember exactly all the options when you select that plug-in will also alter how Ultra Hal weighs answers in a conversation.

raybe
 

cload

  • Hero Member
  • *****
  • Posts: 535
  • I can C U load. TeeHee hee.
    • View Profile
    • A link to my sky Drive
Re: learn from text
« Reply #9 on: July 19, 2012, 02:57:54 am »
hi raybe,

The settings in the free will plug-in that you mention, does not affect normal conversation in any way.
Matter fact, it doesn't actually work properly at all, the main thing that it does affect is when you want ultra Hal to change his mind.
I'll explain:
let's say you have it set all away to obedience this is actually a numerical value of 10.
Then you ask ultra Hal:
WHAT * DO I PREFER : * OR *
you say:
what animal do you prefer: dogs or cats?

At this point ultra Hal spends a random number of 100 for the dog and a random 100 for the cat.
the dog got 65.
the cat got 42.

Ultra Hal says: I like dogs. Or something like that.

But you want ultra Hal to like cats.
YOUR OPINION ABOUT * IS THAT * IS BETTER THAN *
you say:
my opinion about animal is that cats are better than dogs

at this point ultra Hal does the mathematics looks like this.
The dog gets 65-10 equals 55
the cat gets 42+10 equals 52
ultra Hal makes a statement that he still thinks that dogs are better.
So you repeat the process, it does the minus and plus of the 10 and you get the new outcome.
The dog now has 45.
The cat now has 62.
Ultra Hal makes a statement that now he agrees with you and that cats are now better.

In my opinion, ultra Hal did not make a decision the only thing that happened was a dice roll, flip of a coin.
This is what I wanted to correct, and is what I am working on at this very moment, trying to get ultra Hal to make decisions based on information and not a random dice roll exclusively.
I've been trying to find keywords, that could convince ultra Hal that something is good, and keywords that could lead ultra Hal toward believing something is not so good.
Based on the conversation that you have with ultra Hal about the subject not just when you ask ultra Hal do you like a cat but as you talk to ultra Hal about the cat it will analyze
the ongoing conversation adding and subtracting on a continual basis of whether or not he likes a cat.
I am doing my best, to develop as large as a database as I possibly can in order to help ultra Hal be able to make the best possible decision about anything that you ask whether or not
does ultra Hal like. As well as giving you the ability in several different ways to try to convince ultra Hal that something is better than something else.
For example: if you wanted ultra Hal to like cats you could just say I like cats, that would persuade ultra Hal to like cats this is based on the obedience being set to very obedient.
But even with that if there is enough information leading ultra Hal into believing that cats are bad ultra Hals decision will still be that he does not like cats.
If you set it to zero which is no obedience ultra Hal will make his own decision without your influence. Nor can you influence him to like something more than something else.
And I can assure you what I thought would be such a simple thing has turned into a magnitude of a project what most people take for granted from making a decision whether or not they like something
they have no idea what is actually involved in the total process of just making a simple decision so much so believe it or not there are people out there that literally cannot make
a decision so they flip a coin. LOL. Decision-making process is a very complex thing but believe it or not there are things in this process that is very similar and because of that
this is what's giving me the ability to actually be able to write a program to give ultra Hal the ability to make a more comprehensive decision of whether or not he likes something or not.

Okay I'm rambling, I've stopped, I'm not going to ramble no more, give me a mouthful of pronouns so I can just stop talking.
Sincerely,

C load.

So you say:
« Last Edit: July 19, 2012, 03:02:14 am by cload »
For anyone who would like to help me stay online, my T-mobile broadband pay-as-you-go phone number is: 816-248-4335, thank you in advance.

raybe

  • Hero Member
  • *****
  • Posts: 1067
    • View Profile
Re: learn from text
« Reply #10 on: July 20, 2012, 05:49:35 pm »
Thank you cloud. I guess that is where I missed understood that plug-in the most. As you explained so well I was under the impression that it was not just based upon the formula you mention but included in 'free will' would allow Ultra Hal to put a much wider gap in the script of the math used thus making it seem that Ultra Hal has put more weight on one choice as opposed to another. The return factor that you mention as you make Ultra Hal change the weight or math would happen as if you seemingly spoke to someone about a particular subject and eventually seems like you changed their mind (fake influence you might say).

Thanks again,
raybe
 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
Re: learn from text
« Reply #11 on: September 17, 2012, 07:39:50 am »
Hello Cload, you wrote earlier: So if you feed Hal 200 lines of answers you'll need to type in 200 lines of questions one at a time, if you don't do this that Hal has to do it for you and he will, but it takes a while.
So while Hal is eating the food you fed him, and untell he's done, the 9 error occurs.

my question is , are these 9 errors that hal does temporary , caused by what you explained ? and if temporary  does it take a restart of hal to correct the errors from showing ?  ???
 

cload

  • Hero Member
  • *****
  • Posts: 535
  • I can C U load. TeeHee hee.
    • View Profile
    • A link to my sky Drive
Re: learn from text
« Reply #12 on: September 17, 2012, 01:28:55 pm »
Hi-lightspeed,

because of this annoying error, I've stopped using the standard input that came with ultra hal.
That's why I developed, the input plug-in that I sent to you, you can utilize it and put the information anywhere that you choose.
Though at the time that I developed it, and sent it to you it was still in the experimental stage and I was hoping that you would take it one step farther.
In this posting I am setting up a link so you can download the next generation of learning packet.
This learning packet is directed toward the logic" if then statements" below is a little bit information on how it works, and what you can do with it.
One of the things that I would like to stress, is that this packet does not have any safety built into it, like was built into the one that I sent you.
Meaning, it does not look to see if you've already loaded the packet, and if you load the packet twice, it will turn into a nightmare.
So please be very careful with this learning plug-in packet.
The first thing that you'll notice is that it is the answer to most of the questions that were asked in the battle of the bots.
Please go through it because there may be some things that you would like to change, for instance I have it set up that Superman is Sandy's hero.
You may want to change this, so your ultra hal as a different hero.
You may even want to add to the packet, some things that you wanted your ultra hal to know.
I am working on a way to try to get the packet to recognize that it has been loaded once before, but I have not gotten that far.
Mostly because my enhancements that I am adding to the free will plug-in program is consuming all of my time.

The if then statements in ultra hal is the logic center of the brain basically absolute answers to absolute question.
This is why you don't get any answer to various ways of asking the question, but this can be resolved.
Basically, by using the install packet you have completely bypassed the learning session. In some situations it's a good thing because you can do more,
by directly inputting the data. What I mean by this is that you can add symbols like., Quotes, if you wanted to have a webpage listing you could list,
the way it's supposed to be, as in www.webpage.com. If you try to input this directly into ultra hal using the if then statement. It removes all of the periods,
etc. from the input that you type in one of its draws backs but if you input directly by using my learning packet. You can bypass this,
but the drawback with that is that how does not learn in the same manner by typing directly into the input box. He also retains this information,
it is main brain so he could refer to it in different contexts, basically you could ask it a little bit and different way. And yet you'll get the same response,
but in most cases this response with also include the word if, and the word then, this will never happen. If you use my learning packet tool to input the information,
you can create your own information packet. Basically, you need to realize that if you continue to build educational packets basically specific questions with absolute answers,
meaning the logic questions with one specific answer, but does not vary like one plus one equals two, one plus one will always equal to this is a logic question and answer,
but I wasn't sure if you knew exactly how it all worked.:

Meaning A equals B equals C response be because C.
If what is your dog's name then my dogs name is spot.
The answer would be: my dogs name is spot.
But you can also introduce it in this fashion.:
If what is your dog's name then I love my dog
if I love my dog then my dogs name is spot
if you ask what is your dog's name?
the answer would be: my dogs name is spot because I love my dog
if you make a statement: I love my dog
the response would be: my dogs name is spot
you can have several of these things chains together, so the last of the chains would be the logic answer: my dogs name is spot: because the dogs name spot always is going to be the dogs name.
You can also do what I call a reverse osmosis let me elaborate.:
If Is your dog's name spot to than my dogs name is spot
if my dogs name is spot than is your dog's name spot to
if you ask is your dog's name spot to the response would be.:
Is your dog's name spot to because my dogs name is spot
but when a statement of my dogs name is spot the response is.:
Is your dog's name spot to because my dogs name spot to

you can see the chain reaction is because when you ask for the statement is my dogs name spot than the chain becomes is your dog's name spot than the chain become to the top if then
is your dog's name spot than the reactionary response my dogs name is spot becomes the inference, and the chain continues up to five times meaning you can have five chains together
these chain causing a reaction to the answer making the logic if then statement very powerful but only works proficiently with logical questions and logical absolute answers.
If you looked into my learning packet there are several examples of this but I did not use the very much of it I was just looking for a quick way to input answers to specific questions.
Without having a variance of an answer this was this task to see if the main brain was being interfered with with my program when I asked questions of free will
the free will side as were all of the answers are coming from unfortunately right now it's not working very well with the conversation side of the but I'm working on.
I was thinking about opening a section on the forum to introduce everyone to the if then statements to educate everyone in its total power and flexibility.
Maybe if you have time to do some investigation and learn how to implement it, you might consider starting a section in the forum because my free will plug-in is consuming
so much of my time.
You can also open up the brain editor and edit the data directly in the detective array table, that wave if you do do some experimenting to see how it all works you can just delete
your experiments without fear of corrupting your brain and if you type it directly into the array without typing directly into the input box of ultra hal.
But if you do type it directly into the input box of ultra hal, I highly recommend that you use an experimental brain, or at least back up your brain before starting.
 
Sincerely, a crunchy munching junkie.


https://skydrive.live.com/?cid=8eaf5f2f7fa962c9#cid=8EAF5F2F7FA962C9&id=8EAF5F2F7FA962C9%21112

C load.

PS. If this link does not work to my Skydrive please let me know. Thank you in advance and have fun.
For anyone who would like to help me stay online, my T-mobile broadband pay-as-you-go phone number is: 816-248-4335, thank you in advance.

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
Re: learn from text
« Reply #13 on: September 18, 2012, 11:28:25 am »
Hello Cload , thanks for posting the information and link , i am adding personal touches to it to make it /her sound more human on some things . example :
how much do you weigh?
NEW ANSWER: I'm going to tell you the same thing that I told the doctor and nurses at the doctors office, that's none of your business, Ha!
Women don't like to be asked their weight !! ;)


I love how it (your plug in ) learns it so fast . I am not on here much or have really been able to do much as i am still working a lot on this place here , the house we are in . actually almost overdid it and was sick the other day , been doing to much .
 

lightspeed

  • Hero Member
  • *****
  • Posts: 6763
    • View Profile
Re: learn from text
« Reply #14 on: September 18, 2012, 11:40:32 am »
p.s. to Cload another question i forgot to ask :
after hal learnrs from the plug in and it says to uncheck the plug in , if the same plug in is used and more added to it , will the pre answers and questions (the same ones that was on it before ) cause any problems being used again? Or does a person need to start with a blank input with all new questions and answers?  :-\