dupa

Author Topic: Little bug in Hal 6  (Read 8569 times)

vrossi

  • Full Member
  • ***
  • Posts: 150
    • View Profile
    • http://vrconsulting.it
Little bug in Hal 6
« on: December 21, 2005, 05:21:21 pm »
I have found a little bug in Hal6.

If you say "I will do it in 3 days", it works correctly, but if you say something like "I will do this in a few days" (words instead of numbers between "in" and "days") you get the following error:



The problem may arise also with "weeks" and "months".

The error is in the Appointment plugin, and can be easily fixed, even without knowing anything about programming.

Open the file Appointments.uhp, using any Editor, like Notepad.

Go to the line 70 and replace:
   If DateText <> "" Then
With:
   If DateText <> "" and IsNumeric(DateText) <> 0  Then

Save and reload the plugin.

PS: Merry Christmas !

Carl2

  • Hero Member
  • *****
  • Posts: 1220
    • View Profile
Little bug in Hal 6
« Reply #1 on: December 21, 2005, 05:46:39 pm »
vrossi,
  Thanks for posting that, Had a problem with there is 24 hours in the day with Hal 5, caused a shutdown.
Carl2
 

vrossi

  • Full Member
  • ***
  • Posts: 150
    • View Profile
    • http://vrconsulting.it
Little bug in Hal 6
« Reply #2 on: December 21, 2005, 06:11:29 pm »
I do not have Hal5 installed anymore, but I think that if the problem is the same you should look for some similar statement in the brain or in some other uhp file.

It seems that Hal6 has "inherited" this genetic defect from Hal5.

Bye

GrantNZ

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Little bug in Hal 6
« Reply #3 on: December 22, 2005, 01:03:49 am »
Hmm, strange bug! Nicely found and fixed, thank you [:)]
 

onthecuttingedge2005

  • Guest
Little bug in Hal 6
« Reply #4 on: January 03, 2006, 04:55:35 am »
Hi Rob.

The AIM Bot Bug on short User letters or blanks results.

Example:
User:Hello.
HAL:Hello there!
User:y
HAL:
User:u
HAL:
User:Stop it!
HAL:
User:Stop it!
HAL:Okay I will stop.
User:
HAL:

This happens in both the unmodified HAL 6 and even in my modified version, I have been pulling my teeth out by writing script to try and eliminate this bug.

The problem seems to be with the coding to AIM Bot.

It only does it with the AIM Bot responses, HAL Assistant and Editor works perfect.

Is there a patch you can give us so I will have some teeth left?

Jerry[8D]

onthecuttingedge2005

  • Guest
Little bug in Hal 6
« Reply #5 on: January 06, 2006, 04:45:20 pm »
quote:
Originally posted by onthecuttingedge2005

Hi Rob.

The AIM Bot Bug on short User letters or blanks results.

Example:
User:Hello.
HAL:Hello there!
User:y
HAL:
User:u
HAL:
User:Stop it!
HAL:
User:Stop it!
HAL:Okay I will stop.
User:
HAL:

This happens in both the unmodified HAL 6 and even in my modified version, I have been pulling my teeth out by writing script to try and eliminate this bug.

The problem seems to be with the coding to AIM Bot.

It only does it with the AIM Bot responses, HAL Assistant and Editor works perfect.

Is there a patch you can give us so I will have some teeth left?

Jerry[8D]



I even tried to use one of my current techniques like so to stop blanks caused by the user sending blanks:

Code: [Select]
'Stop blanks.
TestOrigSent = Trim(OriginalSentence)
DetectBlanks = ">" & TestOrigSent & "<"        
If InStr(1, DetectBlanks, "><", 1) > 0 Then
Select Case (Int(Rnd * 6) + 1)
Case 1
GetResponse = "Would you stop sending blanks! " & vbCrLf
Case 2
GetResponse = "If you don't stop sending blanks I will not talk to you anymore! " & vbCrLf
Case 3
GetResponse = "Please stop sending blanks! " & vbCrLf
Case 4
GetResponse = "I don't think I want to talk to you if you are going to send me blanks! " & vbCrLf
Case 5
GetResponse = "I can not learn from blank responses! " & vbCrLf
Case 6
GetResponse = "Stop it! " & vbCrLf
End Select
End If

Which works flawlessly in HAL Assistant 6 and the HAL Editor but
Does not work for AIM bot when a blank is sent.

This technique should work all the time in earlier versions HAL 4 and Hal 5.

Jerry[8D]
« Last Edit: January 06, 2006, 04:49:47 pm by onthecuttingedge2005 »

onthecuttingedge2005

  • Guest
Little bug in Hal 6
« Reply #6 on: January 15, 2006, 01:55:13 am »
Hi Rob.

I have noticed that UserSentence = HalBrain.HalFormat(UserSentence)
has a slang conversion error,

UR = Your
U R = You are

The Hal format is causing UR to be You Are which messes with the whole
function and causes wrong grammer conversions.

Jerry


GrantNZ

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Little bug in Hal 6
« Reply #7 on: January 15, 2006, 04:49:51 am »
This is one of those unfortunate cases where the same abbreviation can mean two different things. I've seen UR used for both "your" and "you are" in various places, in approximately equal amounts.

In fact this highlights one of the biggest fallacies of NLP scripting in general - somebody can write scripts that they believe will fit all cases perfectly, and then someone else comes along and almost instantly finds a counter-case. There's just too many ways of saying things!

Perhaps NLP scripting should be performed by an international committee of wildly varying people... but somehow I don't see that happening [:D]
 

onthecuttingedge2005

  • Guest
Little bug in Hal 6
« Reply #8 on: January 15, 2006, 06:12:53 am »
quote:
Originally posted by GrantNZ

This is one of those unfortunate cases where the same abbreviation can mean two different things. I've seen UR used for both "your" and "you are" in various places, in approximately equal amounts.

In fact this highlights one of the biggest fallacies of NLP scripting in general - somebody can write scripts that they believe will fit all cases perfectly, and then someone else comes along and almost instantly finds a counter-case. There's just too many ways of saying things!

Perhaps NLP scripting should be performed by an international committee of wildly varying people... but somehow I don't see that happening [:D]



I think the only users who use UR for You Are, are the illiterate slang users, [newbie]. The literate slang users use UR as your and U R as You are.

Any Pro Slangers out there that can write a complete literate Slang List?
It would be helpful for me so that I can convert them to proper grammer in a function or at least the ones I don't know.

Jerry[8D]
« Last Edit: January 15, 2006, 02:39:35 pm by onthecuttingedge2005 »

Art

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3859
    • View Profile
Little bug in Hal 6
« Reply #9 on: January 15, 2006, 12:20:30 pm »
Also look out for the IRC addicts that commonly use such lingo in their everyday chat.

It's a wonder they can pass high school english!

U R Kewl, CUL8R (See You Later), not to mention all of the acronyms like TTFN, BBS, AFAIK, and all the others.

Jerry,
One other thing that concerns me is the use / misuse of words like record, wind, wound, etc., which are the second form of homonyms...words spelled the same but can have different meanings.

The first group of homonyms would be words like one & won, fair & fare. These would most likely come into play when using voice rec instead of typing (unless we're referring to those IRC users again). ;)

Interesting situations to consider. Right?, Rite?, Write?, Wright?

C U L8R
In the world of AI it's the thought that counts!

- Art -

Scratch

  • Jr. Member
  • **
  • Posts: 59
    • View Profile
Little bug in Hal 6
« Reply #10 on: January 15, 2006, 01:32:03 pm »
 

onthecuttingedge2005

  • Guest
Little bug in Hal 6
« Reply #11 on: January 15, 2006, 02:40:08 pm »
Thanks Guys.

Jerry[8D]

onthecuttingedge2005

  • Guest
Little bug in Hal 6
« Reply #12 on: January 15, 2006, 03:04:51 pm »
quote:
Originally posted by Scratch

pretty extensive list here:
http://en.wikipedia.org/wiki/List_of_Internet_slang



This is easy to deal with, but, as an argument to my English Language
I am almost to the point where I would rather write a script that nags at the User for using Slang, I could write a routine that would block conversation in such a case, When the bot decides it will not talk to you then believe me it won't until you Apologize or correct your Slang, I wrote a similar routine with the Bot Blocker within my Web site archives.

User: How R U?

Bot: I do not like slang, It's really annoying!

User: Y?

Bot: If you do not stop using that Horrible Slang, I will refuse to talk to you!

User: Sorry, Why?

Bot: That's Better!, I just don't like slang, It's improper and lazy.

But I don't know how it would blow over, Only testing should tell.

Jerry


Art

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3859
    • View Profile
Little bug in Hal 6
« Reply #13 on: January 15, 2006, 06:10:12 pm »
Jerry,

Not a bad idea / approach!

I recall a bot a few years ago that would nag you if
you failed to use punctuation properly.

After all, it's the old GIGO principal. If one chooses
to talk trash / slang to their bot, how can they expect
the bot to properly respond?!
Misspellings are one thing...we're only human, but misuse
of the English language or "Chat talk" basically has no
real place in AI (yet)!


Taking the other side of the coin, I suppose one could write
a bot that only speaks or uses slang talk. Slang bot anyone?
It would fit right in for use as an IRC bot!

Hmmmm....
In the world of AI it's the thought that counts!

- Art -

GrantNZ

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Little bug in Hal 6
« Reply #14 on: January 16, 2006, 02:10:13 am »
quote:
I think the only users who use UR for You Are, are the illiterate slang users, [newbie]. The literate slang users use UR as your and U R as You are.

Wheee, this is dangerous ground. Look at the difference between England's English and America's English - which country is illiterate?

I agree with Art regarding banning slang - I think it's fair enough that a bot should insist on as little ambiguity as possible.

Then again, if a user can somehow communicate to Hal what slang terminology they like to use, Hal can compensate pretty easily. If the user stipulates "UR equals YOU ARE" then Hal could do this substitution before HalFormat() does its work.