This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
loop do | |
search "medbotqna SGUL finals" do |tweet| | |
txt = tweet[:text] | |
if txt =~ /001/ | |
reply "#{tweet_user(tweet)} Here is your question - SGUL finals", tweet | |
reply "#{tweet_user(tweet)} Mrs Jones is a 68 year old life long smoker who has an operation next week. To continue please reply with SGUL finals 002", tweet | |
elsif txt =~ /002/ | |
# stuff to handle 002 here | |
elsif txt =~ /003/ | |
# stuff to handle 003 here |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$LOAD_PATH.unshift File.dirname(__FILE__) + "/lib" | |
require 'chatterbot/dsl' | |
require 'pokerthing' | |
exclude "http://" # block spam tweet | |
blacklist "jerkface, assbutt" # block jerks or self | |
#debug_mode true |