chatbot 0.0.3

An extensible chatbot
docs.rs failed to build chatbot-0.0.3
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build: chatbot-0.0.2

chatbot

An extensible chatbot written in rust.

Circle CI

About

The construction is inspired by Hubot's extensibility. There is an ever-growing list of service adapters and message handlers as part of the project.

To get started, you might make a main function that looks like the following. Once you get that running, check out the documentation to add more packaged message handlers or write your own.

extern crate chatbot;

use chatbot::Chatbot;
use chatbot::adapter::CliAdapter;
use chatbot::handler::EchoHandler;

fn main() {
    let mut bot = Chatbot::new();

    bot.add_adapter(Box::new(CliAdapter::new()));
    bot.add_handler(Box::new(EchoHandler::new()));

    bot.run();
}

Plans

My immediate priority list looks something like the following.

  1. Implement basic slack adapter
  2. Clean up slack adapter implementation
  3. Get off of rust nightlies. The project was started using the Select API manually, but it is marked as unstable. mio may be the correct answer for this.
  4. Add a RobotBrain trait a RedisBrain implementation, and some sort of structured text (json/toml/yaml? tbd). The brain will be passed into to the handlers' handle method.
  5. Add more message handlers.
    • GitHub issue poster
    • trout slap
    • countdowns
    • simple key-value store for remembering things in chat
    • others
  6. IRC Chat Adapter

There are some other miscellaneous items in the issue tracker as well.

I can imagine a time when the handlers should get moved out into their own repository so their development can continue independently. The API needs to stabilize before that's possible.

Contributing

Contributions are very welcome on this project. To get started, fork the repo and clone it locally. You should be able to just do cargo run (assuming you're on the nightlies) and get a working echo handler on the command line. If you want to run the test program using the Slack adapter, do cargo run -- --adapter slack.