Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/bot/alisochka/dev-examples.aiml
blob: 40b533274e4ebe319f4acebdc71287f12921b86c (plain)
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
<?xml version="1.0" encoding="ISO-8859-1"?>

<aiml version="1.0.1" xmlns="http://alicebot.org/2001/AIML-1.0.1"
      xmlns:html="http://www.w3.org/1999/xhtml"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:schemaLocation="http://alicebot.org/2001/AIML-1.0.1 http://aitools.org/aiml/schema/AIML.xsd">

<!-- Free software (c) 2001 ALICE AI Foundation -->
<!-- This program is open source code released under -->
<!-- the terms of the GNU General Public License -->
<!-- as published by the Free Software Foundation. -->


<category>
<pattern>BOT HOW MUCH IS *</pattern>
<template>
<random>
<li>The answer is <javascript><![CDATA[<star/>]]></javascript>.</li>
<li><javascript><![CDATA[<star/>]]></javascript> I think.</li>
<li>I think it's <javascript><![CDATA[<star/>]]></javascript></li>
<li>Let me check.  It's <javascript><![CDATA[<star/>]]></javascript></li>
</random>
</template>
</category>

<category>
<pattern>EVALUATE *</pattern>
<template>
<javascript><![CDATA[<star/>]]></javascript>
</template>
</category>

<category>
<pattern>TEST GET</pattern>
<template>
Your favorite color is <get name="favoritecolor"/> and <get name="favoritecolor"/>.
</template>
</category>

<category>
<pattern>TEST SET</pattern>
<template>
Thanks for telling me. <set name="favoriteperson">Michele Censullo</set>
</template>
</category>

<category>
<pattern>TEST JAVASCRIPT</pattern>
<template>
Sending back some Javascript to browser <html:script language="javascript"><![CDATA[document.location="mailto:jonbaer@digitalanywhere.com";]]></html:script>
</template>
</category>

<category>
<pattern>WHAT IS THE INACTIVITY COUNT</pattern>
<template>
The inactivity count is now <javascript><![CDATA[inactivityCount]]></javascript>.
</template>
</category>

<category>
<pattern>INCREASE INACTIVITY COUNT</pattern>
<template>
OK. <think><javascript><![CDATA[inactivityCount++]]></javascript></think>
</template>
</category>

<category>
<pattern>DECREASE INACTIVITY COUNT</pattern>
<template>
OK. <think><javascript><![CDATA[inactivityCount--]]></javascript></think>
</template>
</category>

<category>
<pattern>TEST INACTIVITY</pattern>
<template>
<condition name="inactivitycount" value="1">
     The inactivity is at one.
</condition>
<condition name="inactivitycount" value="2">
     The inactivity is at two.
</condition>
</template>
</category>

<category>
<pattern>MY FAVORITE FOOD IS *</pattern>
<template>
OK. <think><javascript><![CDATA[setValue('<id/>','favoritefood', '<star/>')]]></javascript></think>
</template>
</category>

<category>
<pattern>WHAT IS MY FAVORITE FOOD</pattern>
<template>
Your favorite food is <javascript><![CDATA[getValue('<id/>','favoritefood')]]></javascript>.
</template>
</category>

<category>
<pattern>PRINT THIS PAGE</pattern>
<template>
<javascript><![CDATA[printPage()]]></javascript>
</template>
</category>

<category>
<pattern>ADD A NEW PERSON</pattern>
<template>
What is the name of the person?
</template>
</category>

<category>
<pattern>*</pattern>
<that>WHAT IS THE NAME OF THE PERSON</that>
<template>
<think><set name="person"><star/></set></think>What is the address of the person?
</template>
</category>

<category>
<pattern>*</pattern>
<that>WHAT IS THE ADDRESS OF THE PERSON</that>
<template>
<think><set name="address"><star/></set></think>Cool, everything was entered.
</template>
</category>

<category>
<pattern>WHAT IS THE NAME OF THE NEW PERSON</pattern>
<template>
The new person is <get name="person"/>
</template>
</category>

<category>
<pattern>WHAT IS THE ADDRESS OF THE NEW PERSON</pattern>
<template>
The new person address is <get name="address"/>
</template>
</category>

<!--<category>
<pattern>DO IF EXIST TEST</pattern>
<template>
<if name="somepredicatethatdoesnotexist" exists="true">
It does exist
</condition>
</template>
</category>-->

<!--<category>
<pattern>* IS ONE OF MY KIDS</pattern>
<template>
<star/> was added to your kids list.
<think><add_kids><star/></add_kids></think>
</template>
</category>-->

<category>
<pattern>WHO ARE MY KIDS</pattern>
<template>
Your kids are <get name="kids"/>.
</template>
</category>

<category>
<pattern>YOU ARE PRETTY COOL</pattern>
<template>
<gossip><get name="name"/> said I was pretty cool.</gossip>Thanks.
</template>
</category>

<category>
<pattern>SPILL GOSSIP</pattern>
<template>
<get name="gossip"/>
</template>
</category>

<category>
<pattern>GET A QUOTE FOR ORACLE</pattern>
<template>
<javascript><![CDATA[getStockQuote('orcl')]]></javascript>
</template>
</category>

<category>
<pattern>GET A QUOTE FOR MICROSOFT</pattern>
<template>
<javascript><![CDATA[getStockQuote('msft')]]></javascript>
</template>
</category>

<category>
<pattern>GET A QUOTE FOR NUANCE</pattern>
<template>
<javascript><![CDATA[getStockQuote('nuan')]]></javascript>
</template>
</category>

<category>
<pattern>GET A QUOTE FOR *</pattern>
<template>
<javascript><![CDATA[getStockQuote('<star/>')]]></javascript>
</template>
</category>

<category>
<pattern>GET A CHART FOR *</pattern>
<template>
<javascript><![CDATA[getStockChart('<star/>')]]></javascript>
</template>
</category>

<category>
<pattern>WHAT IS AN EGG</pattern>
<template>
An egg is an egg, I think.
</template>
</category>

<category>
<pattern>LEARN IT</pattern>
<template>
<learn>Egg.aiml</learn>
</template>
</category>

<category>
<pattern>SHOW ME SLASHDOT</pattern>
<template>
Here is where we do a display of some kind.
<html:script language="javascript"><![CDATA[window.open('http://www.slashdot.com', '_blank');]]></html:script>
Can you see it?
</template>
</category>

<!--<category>
<pattern>START TIMER</pattern>
<template>
<timer value="5000">LEARN SOMETHING</timer>
The timer has been started.
</template>
</category>-->

<!--<category>
<pattern>KILL TIMER</pattern>
<template>
<timer value="0">LEARN SOMETHING</timer>
The timer has been killed.
</template>
</category>-->

<category>
<pattern>LEARN SOMETHING</pattern>
<template>
<learn>Something.aiml</learn>
</template>
</category>

<category>
<pattern>SHOW ME A WINDOW</pattern>
<template>
<html:script language="javascript"><![CDATA[window.open('http://www.alicebot.net', '_blank');]]></html:script>
OK.
</template>
</category>

<category>
<pattern>YES</pattern>
<that>FOOBAR</that>
<template>You said yes</template>
</category>


</aiml>