Skip to content
spion edited this page Jul 15, 2012 · 2 revisions

Introduction

Thanks for downloading Triplie, an 6th order Markov chains based chatter bot. It is probably better than MegaHAL and I believe you will find it funny to use. It's interface is directly on IRC, so no need to load TCL scripts or wrappers to MegaHAL - you just configure it and run it.

Compiling

Triplie needs the libraries libsqlite3 and libpthread, so make sure they are installed. Additionally, feedtrplie uses libboost_regex. To compile, unpack and type:

make

The generated binaries will be called "triplie" and "cmdtriplie". triplie is the IRC version and cmdtriplie is the command line version. Additional binaries feedtriplie and worktriplie can be also generated using make complete. You don't need to use/have these.

Configure the bot as explained below before running!

Configuration

If running the bot for the first time (there is no database file) you should type:

make bootstrap

to create the initial database file in botdata/triplie.db

triplie.conf

First thing to edit is triplie.conf. Here is what it must contain:

server irc.freenode.net 6667
nick triplie
ident triplie
name Triplie Diplie
chan #triplie #otherchan
sleep min max
char !
  • The first line specifies the server here. This line MUST contain 3 words:

    server hostname portnumber

  • The second line is in the format "nick yourbotsnick" If the nickname is in use, this simple version will not try another nick. It should however try to reconnect after a while, using the same nick.

  • The third line is what will appear as the username of the bot if no identd is installed on the machine.

  • The fourth line specifies the real name of the bot.

  • The fifth line specifies the default channels. Whenever it connects, triplie will try to join these channels first. The channel names are separated with space.

  • Sleep specifies minimum/maximum pause time between request and answer, in seconds. For example, this will make the bot wait between 2 and 7 seconds before answering:

    sleep 2 7

  • char ? - specifies the command char prefix.

Note that these lines can be handled in any order, but it is important that there are no missing parameters in any of them. Also, all the starting words of those lines MUST be lowercase (server, nick, ident, name, chan, sleep, char)

admins.dat / ignores.dat

admins.dat is a simple file which lists all nick!user@hosts with admin access. Admins can join or part the bot, get stats for the database, use op/deop/voice and devoice commands, change a channel topic using the bot, etc.

Choose your admin hosts carefully. On Undernet I recommend using

*!*@youruser.users.undernet.org 

for better security. On freenode the unaffiliated/affiliated hostmasks are a good choice. At the end it should look something like this:

mynick*!*myident@myvhost.myisp.com
*!*@myxuser.users.undernet.org
*!*@unaffiliated/adminnickname

You can have as many lines as you want in this file, and every line should be a hostmask like the 2 above. You can also have only 1 line.

Obviously, ignores.dat lists ignore hosts. They are in the same format. Its recommended that triplie ignores other triplies

triplie.db

This is not a configuration file. Its best left intact.

However you should check if this file is present in the botdata directory before running the bot for the first time. If its not, type

make bootstrap

to create it.

It contains all the data that the bot has learned so far.

= Commands =

List of triplie's commands:

  • !join #channel - makes the bot join the specified channel. At the present moment, the bot does not remember the channel after shutdown.
  • !part #channel
  • !quit quitmsg - the bot will quit IRC.
  • !die quitmsg - the bot qill quit IRC and the triplie process will end.
  • !op nick1 nick2 ... nick6 - ops specified nicknames in the current channel. The other commands. !deop !vo !devo work similar to !op but are for deop, voice and devoice.
  • !topic some topic - changes the topic of the current channel. Note that some characters are removed and the topic is converted to lowercase
  • !db stats - triplie will output database statistics

Notes

triplie has been tested on Ubuntu Linux, Gentoo Linux and FreeBSD. Please let me know if your nix system is unable to compile the bot.

This is an beta release, it could contain bugs and have unoptimised resource usage. I'm hoping to improve that in next versions