-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
animal.aiml
69 lines (69 loc) · 3.56 KB
/
animal.aiml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<?xml version="1.0" encoding="UTF-8"?>
<aiml>
<category><pattern>SINGULAR <set>animals</set></pattern>
<template><uniq><subj>?singular</subj><pred>hasPlural</pred><obj><star/></obj></uniq></template>
</category>
<category><pattern>PLURAL <set>animal</set></pattern>
<template><uniq><subj><star/></subj><pred>hasPlural</pred><obj>?plural</obj></uniq></template>
</category>
<category><pattern><set>animals</set></pattern>
<template><star/> is the plural of <uniq><subj>?subj</subj><pred>hasPlural</pred><obj><star/></obj></uniq>.</template>
</category>
<category><pattern>SOUND <set>animal</set></pattern>
<template><star/> says <uniq><subj><star/></subj><pred>sound</pred><obj>?sound</obj></uniq>.</template>
</category>
<category><pattern>COLLECTIVE <set>animal</set></pattern>
<template>A group of <star/> is called <uniq><subj><star/></subj><pred>collective</pred><obj>?collective</obj></uniq>.</template>
</category>
<category><pattern>LEGS <set>animal</set></pattern>
<template>A <star/> has <uniq><subj><star/></subj><pred>legs</pred><obj>?sound</obj></uniq> legs.</template>
</category>
<category><pattern>WHAT DOES A <set>animal</set> SAY ^</pattern>
<template><srai>SOUND <star/></srai></template>
</category>
<category><pattern>WHAT DO <set>animals</set> SAY ^</pattern>
<template><srai>SOUND <srai>SINGULAR <star/></srai></srai></template>
</category>
<category><pattern>WHAT SOUND DOES # <set>animal</set> ^</pattern>
<template><srai>SOUND <star index="2"/></srai></template>
</category>
<category><pattern>WHAT SOUND DO # <set>animal</set> ^</pattern>
<template><srai>SOUND <srai>SINGULAR <star index="2"/></srai></srai></template>
</category>
<category><pattern>HOW DOES # <set>animal</set> ^</pattern>
<template><srai>SOUND <star index="2"/></srai></template>
</category>
<category><pattern>HOW MANY LEGS ^ <set>animal</set> #</pattern>
<template><srai>LEGS <star index="2"/></srai></template>
</category>
<category><pattern>HOW MANY LEGS ^ <set>animals</set> #</pattern>
<template><srai>LEGS <srai>SINGULAR <star index="2"/></srai></srai></template>
</category>
<category><pattern>HOW MANY LEGS # <set>number</set> <set>animals</set> # <set>number</set> <set>animals</set> ^</pattern>
<template><think>
<set var="number1"><star index="2"/></set>
<set var="animal1"><srai>SINGULAR <star index="3"/></srai></set>
<set var="legs1"><uniq><subj><get var="animal1"/></subj><pred>legs</pred><obj>?legs1</obj></uniq></set>
<set var="number2"><star index="5"/></set>
<set var="animal2"><srai>SINGULAR <star index="6"/></srai></set>
<set var="legs2"><uniq><subj><get var="animal2"/></subj><pred>legs</pred><obj>?legs2</obj></uniq></set>
<set var="formula"><get var="number1"/>*<get var="legs1"/>+<get var="number2"/>*<get var="legs2"/></set>
</think>
<srai>ROUND <srai>WHAT IS <get var="formula"/></srai></srai> legs.</template>
</category>
<category><pattern>HOW MANY LEGS # <set>number</set> <set>animals</set> ^</pattern>
<template><think>
<set var="number1"><star index="2"/></set>
<set var="animal1"><srai>SINGULAR <star index="3"/></srai></set>
<set var="legs1"><uniq><subj><get var="animal1"/></subj><pred>legs</pred><obj>?legs1</obj></uniq></set>
<set var="formula"><get var="number1"/>*<get var="legs1"/></set>
</think>
<srai>ROUND <srai>WHAT IS <get var="formula"/></srai></srai> legs.</template>
</category>
<category><pattern>_ 1 <set>animal</set> *</pattern>
<template><srai><star/> 1 <srai>PLURAL <star index="2"/></srai> <star index="3"/></srai></template>
</category>
<category><pattern>_ 1 <set>animal</set></pattern>
<template><srai><star/> 1 <srai>PLURAL <star index="2"/></srai></srai></template>
</category>
</aiml>