Author Topic: Ultra-Hal in French  (Read 5811 times)

Alexia92

  • Guest
Ultra-Hal in French
« on: January 23, 2010, 03:17:18 am »
Hello,

As far I know, there is not Ultra-HAL in french. That's why since 2 weeks I am trying to rewrite the Brain of HAL (VBScript) and with a new SQLite Database.
The database has for the moment 1 table "LEXICON" with 2 fields "PHRASE" and "RESPONSE".
It will be very interresting to make first like this, because it is more easy for the french language, then of course, we will add more option in the code like it has for the english version.

Download Attachment: Lexicon.zip
1.5 KB

For the VBScript, I tried to make like this:

When the user ask a question, HAL makes a query of this questions (with more loops) and show the result. Of course, it saves the questions and the answer in his DB for the next time.

I tried this code (from the original program):

Keywords = HalBrain.RemoveExtraSpaces(CurrentSubject & " " & MentionedName & " " & HalBrain.TopicSearch(UserSentence, "topicRelationships") & " " & HalBrain.ExtractKeywords(" " & HalBrain.AlphaNumericalOnly(UserSentence) & " "))
    If Len(Keywords) > 2 Or Len(LastTopicList) > 2 Then
        If Len(Keywords) > 2 Then
            KeywordList = Split(Keywords, " ")
            'Create list of tables that exist for each keyword
            For i = LBound(KeywordList) To UBound(KeywordList)
                TopicTable = HalBrain.TopicSearch(" " & KeywordList(i) & " ", "topicRelationships")
                If TopicTable <> "" And InStr(1, " " & TopicList, " " & Trim(TopicTable) & " ", vbTextCompare) = 0 Then TopicList = TopicList & TopicTable & " "
            Next
            TopicList = HalBrain.RemoveExtraSpaces(TopicList)
        End If
        If TopicList <> "" Or Len(LastTopicList) > 2 Then
            TableList = Split(Trim(TopicList & " " & LastTopicList), " ")
            LastTopicList = TopicList
            'Search through each table for a good response. If a response exceeds the hurdle
            'for a table, no other table will be searched. Otherwise, the highest relevance
            'response across all tables are stored for possible later use.
            For i = LBound(TableList) To UBound(TableList)
                UserBrainRel = 0
                HalUserBrain = HalBrain.QABrain(LongUserSent, "_" & Trim(LCase(TableList(i))), UserBrainRel)
                If HalBrain.CheckRepetition(HalUserBrain, UserSentence) = True Or HalBrain.CheckRepetition(HalUserBrain, PrevSent) = True Or HalBrain.CheckRepetition(HalUserBrain, PrevUserSent) = True Then UserBrainRel = 0
                If UserBrainRel > HighestRel Then
                    HighestRel = UserBrainRel
                    HighestRelResponse = HalUserBrain
                End If
                Score = UserBrainRel + 1
                Hurdle = GainControl + 1
                If Score > Hurdle Then
                    GetResponse = GetResponse & HalUserBrain & "<NOMORE>" & vbCrLf
                    Exit For
                End If
            Next
        End If
    End If
    HalBrain.DebugWatch GetResponse, "Auto Topic Focus"


But it doesn't work. May be can someone help me?

Thanks

Alexia
« Last Edit: January 23, 2010, 03:31:08 am by Alexia92 »

GT40

  • Hero Member
  • *****
  • Posts: 2095
  • Hey, I see you!
    • View Profile
    • My Bots
Ultra-Hal in French
« Reply #1 on: January 23, 2010, 06:03:36 am »

Hi and welcome Alexia!!

Sorry if I can't help you (I'm not really interested in Hal, I know, it's a shame), but I think trying to make a French version is a GREAT project. A never-ending task, not easy at all (but if it's easy, where is fun?). And I guess some people here will answer you that English and French languages are too different.

But if you need a beta tester, despite what I wrote above, you can count on me.[:)]

« Last Edit: January 23, 2010, 06:08:05 am by GT40 »
Time to waste with skits, bots & other useless things? Why not visit
http://gt40.chez-alice.fr/Haptek/MyBots.htm ? Oops, sorry, a museum!

Alexia92

  • Guest
Ultra-Hal in French
« Reply #2 on: January 23, 2010, 06:55:25 am »
Hello GT40,

Thank you for your replie.

Yes, it can be a big project because french and english are very 2 differents languages (that's why I want only to test like I explained and make the rest step by step), but for the moment I only need to know how to connect the LEXICON DB and how to search in this DB (with query) to show the result.
That's why I posted a code and I thought it was may be the code where HAL search a response. So if someone can help me, it is will great.

Thanks

Alexia

GT40

  • Hero Member
  • *****
  • Posts: 2095
  • Hey, I see you!
    • View Profile
    • My Bots
Ultra-Hal in French
« Reply #3 on: January 29, 2010, 06:51:01 am »

Deafening silence...

Time to waste with skits, bots & other useless things? Why not visit
http://gt40.chez-alice.fr/Haptek/MyBots.htm ? Oops, sorry, a museum!

onthecuttingedge2005

  • Guest
Ultra-Hal in French
« Reply #4 on: February 10, 2010, 01:17:58 am »
I have been playing with Babylon and Xanadu but not just yet, a little more time please. I am not a god! sheesh, lol.

Jerry[:D]

mdnd

  • Newbie
  • *
  • Posts: 27
    • View Profile
    • http://wm-energie.com
Ultra-Hal in French
« Reply #5 on: February 28, 2010, 02:54:01 am »
Ma version 5. en francais tourne bien en modifiant un peut les codes.
Il ne manque que le Halbrain.dll pour le corriger et l'affaire est jouer.
 

spydaz

  • Hero Member
  • *****
  • Posts: 670
    • View Profile
    • http://www.spydazweb.co.uk/
Ultra-Hal in French
« Reply #6 on: March 04, 2010, 03:33:14 pm »
My hal 5 french plugin worked fine... too. works on the Corrections function / process substitutions

funeraldoom

  • Newbie
  • *
  • Posts: 1
    • View Profile
Ultra-Hal in French
« Reply #7 on: May 05, 2010, 11:22:32 am »
Hello all.

I'm new to this forum, but know Ultra Hal for some time now, when i first tried the demo version. I was pleasantly surprised by the conversational capabilities of the program. BUT...what prevented me from buying Ultra Hal at the time was the fact that I do not want to communicate with in writing, but by the voice. Unfortunately when talking in English, my French accent is so bad That the recognition software can not understand a single word of what i'm saying [:I]

After all this time, I come of curiosity to see the project's progress, and falling on this subject I would like to ask ask if it would be possible to get help from those who managed to get Hal in French: Is a french brain of Hal is made available ? I do not found one unfortunately. It is clear that if i can get my Hal in French, I absolutely would reconsider its purchase, and buy it right now, but absolutely know nothing about doing it by myself.

To those who have accomplished this : Is your french version, or at least his basics is available somewhere, or will it remain a personal project?

Good luck.