{"repo":"carbonfive/socrates","free":true,"listed":false,"github":"https://github.com/carbonfive/socrates","clone":"git clone https://github.com/carbonfive/socrates.git","description":"Socrates is a microframework for building stateful conversational interfaces for Slack in Ruby.","language":"Ruby","stars":19,"topics":["bot-framework","slack-bot","ruby","conversational-interface"],"license":null,"category":"workflow-automation","readme_excerpt":"Socrates Socrates is a micro-framework for building stateful conversational interfaces. It provides straight-forward state management, a clear pattern for modeling the states and conversational flow (transitions), and some helpers. It's designed for building conversational Slack bots, but is designed in such a way that other adapters could be written. It ships with a Console adapter for testing locally in the terminal as well as a Memory adapter for use in automated tests. Disclaimer: This framework is still in its early stages. It's been used for one production bot for the last year or so, but might see some changes as other folks use it and provide feedback. Conceptually, a conversation is a sequence of asking and listening actions. As a conversation progresses, information is gathered and at some point, acted upon by the system. Conversational state is captured either in memory (development and testing) or in Redis. This too is pluggable so that other storage backends could be used. Here is a simple example, asking for one's name, birth date, and then responding with the current age. Installation Add this line to your application's Gemfile: And then execute: $ bundle Or install it yourself as: $ gem install socrates Usage Socrates is intended to be used programmatically from your application. However, it's easy to see a sample conversation run in either the console or on Slack. To see socrates in action in the console: $ socrates run And on Slack: $ SLACK API TOKEN= socrat","default_branch":null,"files":null,"tree":[],"storefront":"/r/carbonfive","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/carbonfive/socrates/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}