From c844125355a9e807917cff925a4a497f420209a9 Mon Sep 17 00:00:00 2001 From: Luke Slater Date: Tue, 14 Feb 2012 18:15:59 +0000 Subject: [PATCH] rtrain to add raw date --- modules/drama.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/modules/drama.js b/modules/drama.js index 6a9b1ff..d679594 100644 --- a/modules/drama.js +++ b/modules/drama.js @@ -30,6 +30,15 @@ var drama = function(dbot) { dbot.say(data.channel, 'Last thing ' + params[2] + ' said in ' + params[1] + ' classified as \'' + params[3] + '\''); } + }, + + '~rtrain': function(data, params) { + if(data.user == dbot.admin) { + params.splice(0, 2); + var msg = params.join(' '); + bayes.train(msg, params[1]); + dbot.say(data.channel, '\'' + msg + '\' classified as \'' + params[1] + '\''); + } } }