Markov: trying a simpler form of shut up check

This commit is contained in:
Brian S. Stephan 2011-05-03 22:13:49 -05:00
parent c55852129a
commit 90be2d1855
1 changed files with 2 additions and 2 deletions

View File

@ -284,9 +284,9 @@ class Markov(Module):
if rdelta.years == 0 and rdelta.months == 0 and rdelta.days == 0 and rdelta.hours == 0 and rdelta.minutes == 0 and rdelta.seconds <= 29:
last_30_sec_lines.append((nick,then))
if len(last_30_sec_lines) >= 20:
if len(last_30_sec_lines) >= 15:
lines_i_said = len(filter(lambda (a,b): a == '.self.said.', last_30_sec_lines))
if lines_i_said * 100 / len(last_30_sec_lines) >= 45:
if lines_i_said >= 8:
self.shut_up = True
targets = self._get_chatter_targets()
for t in targets: