Skip to content
Branch: master
Find file History
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
configs Fixed model path May 19, 2019
model Initialize bot May 18, 2019
moderator_bot Resize image, fix link, remove env vars from travis May 22, 2019
tests Added tests to ci May 19, 2019
.editorconfig Initialize bot May 18, 2019
.gitattributes Initialize bot May 18, 2019
.gitignore Initialize bot May 18, 2019
Pipfile Initialize bot May 18, 2019
Pipfile.lock Initialize bot May 18, 2019
README.md Resize image, fix link, remove env vars from travis May 22, 2019
requirements-dev.txt Better readme, minor polish May 18, 2019

README.md

moderator_bot

aiohttp demo for simple Slack bot that moderate toxic messages. It uses Events API.

Model reused from Moderator AI project.

Image of Application

Requirements

Prerequisites

Before running bot, you need to setup slack app for it and obtain SLACK_BOT_TOKEN. You can read detailed guide on how to do it here https://api.slack.com/bot-users.

Also you need GIPHY_API_KEY that you can get here https://developers.giphy.com/.

Starting bot

Clone the repo and after do

$ cd moderator_bot
$ pip install -r requirements-dev.txt

With credentials from previous section provide proper environment variables

$ set -x SLACK_BOT_TOKEN xxx-xxx
$ set -x GIPHY_API_KEY xxx-xxx

Start app

$ python -m moderator_bot

Testing

$ pytest -s tests/
You can’t perform that action at this time.