Oh, that’s cool, reminds me of my introductory classes with NLP and Bayes.
I also remember a term-based search topic matching system in “Event[0]”, although they said it also counted extra words to identify if player was typing “politely” or not (with the hilarious effect that the AI will complain if you speak like a robot).