|
View:
New views
8 Messages
—
Rating Filter:
Alert me
|
|
|
|
|
|
|
|
|
Re: AIML conflict solving--- "Dr. Rich Wallace" <drwallace@...> escreveu:
> <category> > <pattern>* WENT TO *</pattern> > <template>first </template> > </category> > <category> > <pattern>* TO *</pattern> > <template>second</template> > </category> > <category> > <pattern>*</pattern> > <template>none</template> > </category> > > gives 'second'. > > My first impression is that ProgramQ is behaving > correctly since there's nothing in the spec > that permits to resolve such a conflict (by > forbidding "greedy-matching" for instance). > > What do you think guys? This behaviour might not be "wrong" (that is, in violation of the spec), but it's not very convenient either. It's a basic assumption that, when several rules apply to a given input, the "more specific" one will be favoured. This is not only more intutive but also more useful, as it allows botmasters to create category hierarchies where progressively more generic patterns return progressivaley more general responses. Also, remember that the description of the "*" wildcard says that it only matches an input element when there would be no way to match it with a (1) "_" wildcard or (2) non-wildcard element. This may leave the first example open to discussion, but in the second case it seems clear to me that the category that leaves less elements to the wildcard (that is, the more specific one) should be favoured. -- Ja mata ne. Helio _______________________________________________________ VocĂȘ quer respostas para suas perguntas? Ou vocĂȘ sabe muito e quer compartilhar seu conhecimento? Experimente o Yahoo! Respostas ! http://br.answers.yahoo.com/ _______________________________________________ This is the alicebot-general mailing list Reply to alicebot-general@... Unsubscribe and change preferences at http://list.alicebot.org/mailman/listinfo/alicebot-general Learn netiquette at http://www.dtcc.edu/cs/rfc1855.html Learn to read at http://www.literacy.org/ |
|
|
Re: Fwd: AIML conflict solving> A good approach when in doubt of the spec is to check out programD's behavior since Noel co-authored the specification and wrote that interpreter.
Actually I wrote the first Java interpreters (program B and D), including the Graphmaster matching algorithm. Noel took over program D and made a lot of changes, but I don't think he changed the matching methods. Rich _______________________________________________ This is the alicebot-general mailing list Reply to alicebot-general@... Unsubscribe and change preferences at http://list.alicebot.org/mailman/listinfo/alicebot-general Learn netiquette at http://www.dtcc.edu/cs/rfc1855.html Learn to read at http://www.literacy.org/ |
|
|
|
|
|
|
|
|
Re: Fwd: AIML conflict solvingDr. Rich Wallace wrote:
>> A good approach when in doubt of the spec is to check out programD's behavior since Noel co-authored the specification and wrote that interpreter. > > Actually I wrote the first Java interpreters (program B and D), > including the Graphmaster matching algorithm. Noel took over program > D and made a lot of changes, but I don't think he changed the matching > methods. Yes, I didn't change any of the matching methods. I did rewrite virtually every line of code (including the matching methods), in some cases several times, and overhauled the architecture in major ways, but the program should still be following the specification exactly. Over the past few years a few issues have come up that are not clearly handled by the specification, and for these Program D may have its own solution, but this is as arbitrary, bound to change, and non-authoritative as any other solution. I would not promote the idea that Program D's approach to an undefined issue carries any more weight than any other approach, although I do still have the impression that Program D still implements the specification more completely than any other implementation (but this may just be some egotistic hallucination on my part). Noel _______________________________________________ This is the alicebot-general mailing list Reply to alicebot-general@... Unsubscribe and change preferences at http://list.alicebot.org/mailman/listinfo/alicebot-general Learn netiquette at http://www.dtcc.edu/cs/rfc1855.html Learn to read at http://www.literacy.org/ |
|
|
Re: Fwd: Fwd: AIML conflict solving> From: Houssem BDIOUI <houssem.bdioui@...>
> Date: Sep 22, 2006 4:36 PM > Subject: Re: [alicebot-general] Fwd: AIML conflict solving > To: Alicebot and AIML General Discussion <alicebot-general@... > > > > Mehri, > > Thanks for your quick answer. The point is that when running the above algorithm > ProgramQ matches the "* But *" pattern just because 'But' word comes > first in the nodemapper list > (before 'IS'), probably because of alphabetic sorting. And probably > that's the error: I should not do > an alphabetic sort of the words. isn't it? However you sort the words shouldn't matter. What matters is whether you do this: A1. match "programq" to "*" A2. match "is" to "IS" or this: B1. match "programq" to "*" B2. match "is" to the same "*" <--- why? B3. match "cool" to the same "*" B4. match "but" to "BUT" The (B) scenario is wrong. You should be matching "is" to "IS". The spec effectively describes a non-greedy scenario, as Mehri pointed out, even though it doesn't say so. And in your second example, the output "second" is also wrong, for the same reason. You should match "went" to "WENT". The point is that AIML pattern matching doesn't incorporate any looking ahead. This avoids the need for any scoring of matches to say that one pattern "matches better" than another. A match scoring approach can seem appealing at first, but in the long run it makes behavior a lot more difficult to predict. The great thing about the AIML pattern matching algorithm is that it is very predictable. Even if it doesn't seem as convenient at first, you can always find a way to work with it, and your AIML sets will scale better because you don't have to try to account for complex interactions of a bunch of rules. Noel _______________________________________________ This is the alicebot-general mailing list Reply to alicebot-general@... Unsubscribe and change preferences at http://list.alicebot.org/mailman/listinfo/alicebot-general Learn netiquette at http://www.dtcc.edu/cs/rfc1855.html Learn to read at http://www.literacy.org/ |
| Free Forum Powered by Nabble | Forum Help |