Giter Site home page Giter Site logo

k-time / decision-bot Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 0.0 77 KB

Reddit bot that retrieves and posts MMA decision scorecards on r/mma.

Home Page: https://www.reddit.com/user/DecisionBot

Shell 1.81% Python 97.81% Makefile 0.38%
reddit-bot reddit mma

decision-bot's Introduction

DecisionBot

DecisionBot is a Reddit bot that retrieves and posts mixed martial arts scorecards on-demand. Users summon the bot by commenting in any r/mma thread with the fighters' names. It has been live on r/mma since February 2017.

Usage example

  • User leaves comment: decisionbot mcgregor vs diaz

  • DecisionBot replies:

    UFC 202: Diaz vs. McGregor 2 — August 20, 2016

    ROUND McGregor Diaz McGregor Diaz McGregor Diaz
    1 10 9 10 9 10 9
    2 10 9 10 9 10 9
    3 9 10 9 10 8 10
    4 10 9 10 9 10 9
    5 9 10 9 10 9 10
    TOTAL 48 47 48 47 47 47

    Judges, in order: Derek Cleary, Jeff Mullen, Glenn Trowbridge.

    MEDIA MEMBER SCORES

    • 1/19 people scored it 49-47 McGregor.
    • 12/19 people scored it 48-47 McGregor.
    • 1/19 people scored it 47-46 McGregor.
    • 4/19 people scored it 47-47 DRAW.
    • 1/19 people scored it 47-48 Diaz.

    2215 fan scores1426 (64%) McGregor, 483 (22%) Diaz, 306 (14%) Draw.

Features

  • You can use v / v. / vs / vs. / versus, or leave it out and the bot will figure the names out.
  • Handles rematches (include the rematch number in the comment, or leave it out and the bot posts all fights).
  • Handles many fighter nicknames and common name misspellings.
  • Supports returning "certainty of victory" confidence level based on media scorecards.
  • Banters and has many easter eggs.

How to Run

  • Run make to run in foreground.
  • Run make start-background to run in background, and make stop to stop the background process.

Files

File Description
fight_finder.py Searches and pulls fight data from mmadecisions.com using BeautifulSoup.
decision_bot.py Runs the bot on Reddit.
notify_account.py Notifies my personal account of DecisionBot's status.
config.yaml Bot configs.
commented.txt List of recent comment ids that triggered the bot.
nicknames.txt List of common nicknames and name misspellings.
rematches.txt Correctly adjusted rematch numbers (if there was a finished fight, the rematch numbers need to be adjusted).

Praise

decision-bot's People

Contributors

k-time avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

decision-bot's Issues

Discord bot

This bot is amazing, it would be cool if it was a discord bot.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.