Created
April 11, 2017 18:05
-
-
Save myano/2c64ab55f8af032c56951e91cb4843e9 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
def lovelike(jenni, input): | |
if input.sender in ['#reddit-baseball']: | |
return | |
if random.random() <= 0.25: | |
verb = input.group(1) | |
obj = input.group(2) | |
if len(obj) >= 100: | |
obj = obj[:100] + ' [...]' | |
out = 'I ' | |
out += verb | |
out += ' ' | |
out += obj | |
out += ', too!' | |
jenni.say(out) | |
lovelike.rule = r'(?i)i\s(love|like|hate)\s(.*)' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment