Collaboration optimize

Let Isaac help you build IRC bots










> droll 5x05




> gem install isaac


> rbx gem install isaac

Actually writing my first IRC bot, called "drollbot", took about five or 10 minutes of cumulative time. Later work has refined the tool, but an initial working IRC bot took less time than it is likely to take to read this article. Isaac abstracts away the low-level heavy lifting for creating an automated IRC client -- a bot -- and allows you to focus on what kind of input you want it to recognize, and what kind of response you want it to give.


require 'rubygems'

require 'isaac'

configure do |c|

c.nick = 'hello_bot'

# c.password = 'password'

c.server = ''

# c.port = 7000

# c.ssl = true

c.verbose = true


on :connect do

join '#botwar'


on :channel, /^hello_bot/ do

msg channel, "Hello, #{nick}!"







> ruby hellobot.rb


16:56 <@apotheon> hello_bot: hi there

16:56 <@hello_bot> Hello apotheon!







There are many Ruby bot frameworks out there, most of them have one thing in common: They aren't really active anymore if they ever were. I started with isaac a while ago and had to change/fix many things on my own. There are many pending tickets and even more forks. All updates so far were mostly pull requests and I would say the project is frozen or dead. I switched to cinch ( then, a really active and new framework. It uses a similar DSL like isaac, a plugin interface and proper threading. This allows to run many different plugins and prevents the bot from crashing, when some plugin does something nasty. There is also a plugin repository, that gets new plugins every day. Isaac was a really nice idea, but still lacks many things. If you really want to play with Ruby and IRC bots, I suggest to give cinch a try too.


Many years ago, In the early days of broadband, I got infected by a Iroffer bot and had someone fill my pc up full of films and music that i hadn't even requested or asked for,This of course was a nasty trojan that was using iroffer on IRC. This in turn made me curious about what Iroffer was, and what IRC was. Iroffer is a fileserver that is used on irc that takes commands via dcc, So yes someone was actually controlling something on my pc without me knowing remotely, but Iroffer isn't built for nasty stuff like this, Its main job is to be a legit bit of software that is used as a fileserver on IRC. This then got me into using IRC on a regular basis, not for downloading films/music etc but to start and run a network using unrealircd/neostats/services and a bunch of other stuff including other bots like eggdrop. That was over 5 yrs ago, I didn't keep the server going for long as It was time consuming keeping it up to date and botnet free, but the time I was on there I did learn a lot from a lot of people. Anyone who has a question about anything will find a channel on IRC that has someone Interested In it, And I mean anything. I do pop on there now and again to see what going on and whats new and believe me when i say this, Its pretty much the same as it was when i first went on there, except now people are more tech savvy.


What would you recommend for Ruby 1.8 compatibility? Cinch is 1.9+ only. edit: Also . . . Isaac is far from a dead project. The link to the GitHub project page included in the article leads to an active project, with several commits this year.


I think that writing IRC bots can serve as one of the best simple introductory paths to learning more about programming. Programming is all about automation, and robot scripts are more directly about automation than many other forms of programming. Further, thanks to the proliferation of easy to use frameworks for IRC bot development in popular high-level languages, it's an extremely easy field of development to get into. You just need an idea for something you'd like an IRC bot to do for you.


I would suggest to switch to 1.9 and let 1.8 finally die. There is no reason to keep it artificially alive. Six commits so far this year and all are related to pull requests. This is pretty much dead for me.


The way developers are backporting is kind of haphazard and, generally, a bad idea. There should have been a more clean split. The result of the current policy of feature backports for minor version updates of 1.8 appears to be increasing danger of legacy code breakage in a manner that is not reasonably expected from minor version updates. I applaud security fixes being applied to 1.8, though. It would be more accurate to say that YARV is faster than MRI. Execution speed is a function of the implementation, and not of the language definition version (even when the definition is manifest in a reference implementation). By the way, actual completeness would suggest that there should be less movement in core development, not more -- so the suggestion that pull requests making up the lion's share of changes means it's not "complete" is exactly backwards. In any case, such a state of affairs might mean nothing more than that the process of selecting people to give direct commit access is being overrun by enthusiasm from outside contributors, which would *also* suggest that the project is quite the opposite of "dead". Your evidence of project death does not support your conclusion without some kind of additional evidence or context.


I really would like to get rid of 1.8. Keeping 1.8 alive binds developers to stupid tasks like backporting features of 1.9 or security fixes. It was an upstream decision to make 1.8 and 1.9 not compatible to each other after all. Not to mention that 1.9 is just faster. For me, the lack of own contributions and only reactions on pull requests shows, that the original author has no time to continue the project and it's obviously far away from being complete.


Portability is important. Why would I want to intentionally write nonportable code by using a library that provides nothing for which I have any use above and beyond the library I'm using? I'm not keeping 1.8 artificially alive; I'm just keeping my software portable between 1.8 and 1.9 implementations of Ruby when there is no reason to do otherwise other than your disdain for portability. > Six commits so far this year and all are related to pull requests. This is pretty much dead for me. I guess it's a good thing the whole world doesn't live by your standards, then.