NAME

Bot::Net - run your very own IRC bot net

SYNOPSIS

If you're just using a Bot::Net:

  cd MyBotNet
  bin/botnet run --server Main
  bin/botnet run --bot SomeBot

To create a new Bot::Net application:

  bin/botnet net --name MyBotNet

TODO XXX FIXME Document automatic creation of new bots and servers...

If you're developing a new bot or something, you might find these useful:

  Bot::Net->log->debug("Debug message.");
  Bot::Net->log->error("Error message.");

  my $value = Bot::Net->config->bot('MyBot')->{'config'}{'value'};

DESCRIPTION

EXPERIMENTAL: This module has just barely left the proof-of-concept phase. Much of the API is fluid and changing. If you're interested in contributing, please contact me at my email address at the bottom.

A nice way to create bots, networks of bots, and servers that run them. Currently, this system only provides tools for building IRC bots, but additional protocols could be added in the future. The aim is not to tie the system to any one architecture for the bots, but provide an easy way to build them and verify that they do what you want.

GOALS

The aim of this system is to provide a tool for creating a botnet for handling parallel tasks with communication primarily happening over IRC. The eventual goals of the system include:

  • Provide easy to build and easy to understand mechanisms for building semi-autonomous agent-based systems (bots).

  • Automatically build the scaffolding for a Bot::Net application, automatically create stubs for bots and servers, and generally give you some tools to get started quickly.

  • Provide a declarative syntax for creating bots and bot components.

  • Tools for initializing and managing the lifecycle of all your bots.

  • A server environment for helping you run your bots on one or more hosts that can communicate with one another.

  • A verification system for telling you whether or not your bots will talk to each other without getting confused or fail.

WHY?

First, because breaking certain tasks into small hunks that can be handled by semi-autonomous agentsis a handy way to think about some problems.

The original problem I wrote this system for is to handle the synchronization of data between lots of hosts. I had bots for pulling bits of data from each host, other bots for pushing bits of data back to each host, bots for pulling data from one host and pushing to another, bots for filtering the data so that it's in the correct format, etc.

It quickly became a pain, so I built this to take away the pain.

Previously, I wrote another system, FleetConf, to handle a very similar task. However, I am not very happy with how that turned out, so learning from my work there, I've built this system.

THIS OBJECT

This is the central singleton providing some basic services used by just about everything in the Bot::Net system.

METHODS

bot_net

Returns the singleton object. Usually, you don't need to call this directly since all the Bot::Net methods call this internally.

config

Return the configuration data for this application instance. See Bot::Net::Config for additioanl details.

log NAME

Retrieves a logger object for this application. If given a name, it will return a specific named logger. Otherwise, it returns the application default logger, named "Bot::Net".

See Bot::Net::Log.

net_class NAMES

Given a list of names, it creates a class name for the current Bot::Net application.

  # Find the name of the Chatbot::Eliza bot in the local app
  my $class = Bot::Net->net_class('Bot', 'Chatbot', 'Eliza');

short_name_for_bot CLASS

Returns the name of the bot.

short_name_for_server CLASS

Returns the name of the server.

AUTHORS

Andrew Sterling Hanenkamp <hanenkamp@cpan.org>

COPYRIGHT AND LICENSE

Copyright 2007 Boomer Consulting, Inc. All Rights Reserved.

This program is free software and may be modified and distributed under the same terms as Perl itself.