How can i use loop in aiml pandorabots for countries population?

137 Views Asked by At

i am creating a chat bot with aiml in pandorabots who knows the population of all countries and cities . How can i ask the chat bot "tell me the 10 countries with the largest population"?

I have created a map file with the countries and the population but i don't understand how to read questions like "tell me 20(or 52,or any number countries with the largest/smallest population") https://i.stack.imgur.com/8gUuX.png

1

There are 1 best solutions below

0
On

Basically, you need to assign each entry in the map, a unique number and then go down the numbers. Rather than trying to explain it here, I made a tutorial:

https://www.youtube.com/watch?v=RpF2dL80ASA

The files I use are here:
http://www.square-bear.co.uk/aiml/country.aiml
http://www.square-bear.co.uk/aiml/country2num.map
http://www.square-bear.co.uk/aiml/num2country.map