How are chatbots like Cleverbot programmed?


How are chatbots like Cleverbot programmed?

For details, see my Quora answers to:
· How does Cleverbot work?
· How does the chatbot jabberwacky work?
· What’s the techonology behind Korean chat bot simsimi?