C:\trane\logicagent>ruby logicbot.rb Hello I have loaded C:/trane/logicagent/logicagent-api.yaml. C:/trane/logicagent/graph.yaml loaded. > reset graph Okay, I have reset the graph. > logicbot: if input =~ /(.*) (is a parent of) (.*)/ then self.send("#{$1} is an ancestor of #{$3}") end Okay I have added if input =~ /(.*) (is a parent of) (.*)/ then self.send("#{$1} is an ancestor of #{$3}") end . > John is a parent of Jack. Okay, John is a parent of Jack. > Jack is a parent of Jill. Okay, Jack is a parent of Jill. > is John a parent of Jill? I have no knowledge that John a parent of Jill. > is John an ancestor of Jill? Yes, John is an ancestor of Jill. > why is John an ancestor of Jill? John an ancestor of Jill because: john is an ancestor of jack, and jack is an ancestor of jill >