From f7f6583008cbaead6aca2608bea2cbbc3f5055b2 Mon Sep 17 00:00:00 2001 From: Al Beano Date: Mon, 4 Jul 2016 22:17:20 +0100 Subject: [PATCH] add documentation --- README.md | 49 ++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 48 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 1de2d19..7f5b629 100644 --- a/README.md +++ b/README.md @@ -2,4 +2,51 @@ next generation markov chain irc shitposting bot -documentation coming soon! +### The problem +The original shithead uses far too much ram and is badly implemented. + +### The solution +Let's reimplement it and get redis to do all the heavy lifting. + +## Getting Started +A brainfile is simply an irc log with all joins, parts, timestamps and nicknames stripped. In other words, it contains only what was said. + +```bash +# if you have an old brainfile, import it into redis +perl import-brain.pl /home/you/brainfile +# this can take a long time (about ten minutes for me), so be patient +``` + +```bash +# now, you need a config file +cp config.default.yml config.yml +# edit the values in config.yml to your choosing +``` + +Now, just run `perl MarkovBot.pl`. + +## Commands + +* .shitposting - controls the % of messages the bot will reply to +``` +< user> .shitposting 1.5 +< shithead-ng> OK +``` + +* .ignore - make the bot totally ignore a user (useful for bots) +``` +< user> .ignore bot +< shithead-ng> Now ignoring bot. +``` + +* .unignore - removes a user from the ignore list +``` +< user> .unignore bot +< shithead-ng> No longer ignoring bot. +``` + +* .ping - check that shithead-ng is still alive +``` +< user> .ping +< shithead-ng> Pong! +```