Beyond Façade: Pattern Matching for Natural Language Applications
Bruce Wilcox [2011]
Following my recent post about a cool game: Façade, it was brought to my attention this paper, which is an amazing explanation of the technology used for natural language recognition from A.L.I.C.E. to ChatScript, Façade being somewhere in the middle.
First, the author describes AIML (the technology used to create A.L.I.C.E.) and states all it's shortcomings. Specially, he says that AIML is extremely hard to read and to program, because of the intricate XML style and recursive pattern recognition. That doesn't mean that the system is bad, it's just hard to work with.
AIML example:
< 'category '>
<'pattern '> * I LOVE YOU < /pattern >
<'template '> Whatever < /template >
< /category>
(Ignore the ' . It's a patch to force blogger to show the tags)
The last code will match the string "I love you" if found at the end of the sentence.
Next, he speaks about Façade. With this games, their creators made a big improvement over the traditional AIML system. They implemented 'Discourse Acts'. This means that a reaction can be mapped to one of these acts instead of mapping it to a text, which allows the programmer to generalize many possible sentences into a single act.
The system used in the game was easier to work with than AIML, but it was still hard to read and do complex stuff.
Façade's system example:
(defrule positional_is
(template (tor am are is seem seems sound sounds look looks))
=> (assert (iIs ?startpos ?endpos)))
The last code defines the rules for the discourse act "praise".
Enter ChatScript, a system created by the author to make it easier to read and work with natural language processing. ChatScript aims to pattern-match on general meaning, so it tries to detect equivalence. With ChatScript, he managed to create a bot that fooled one of the four judges in the Loebner Competition into thinking it was human.
ChatScript example:
concept: ~meat (bacon ham beef meat flesh veal lamb chicken pork steak cow pig)
s: (I love ~meat) Do you really? I am a vegan.
The last code associates some words to the general term 'meat' and responds to sentence "I love *" where * is some kind of meat with the answer "Do you really? I am vegan".
ChatScript is a gigantic improvement in the natural language processing field and it can be used to create some interesting applications. ChatScript has many features like memory and conversation topics which are described in the original paper.
Wilcox, Bruce, (2011) Beyond Faade: Pattern Matching for Natural Language Applications. Retrieved March 17, 2011 from Gamasutra.com: www.gamasutra.com/view/feature/6305/beyond_façade_pattern_matching_.php?page=1
0 comentarios:
Publicar un comentario