Giter Site home page Giter Site logo

markov-bot's Introduction

markov-bot

A Discord bot designed in python. Generates new messages using Markov chains from user message history

Markov chains are cool, and so is this russian man who impersonates your friends. Paste the private code for your Discord bot in a file called "token.txt" directly. It should look like this:

T1bAcYNlVgqOHnbT6PbCgqOH.yVzxJ.wMHZ-pb2HXESAeiv0mUcXXak5_M

(^^ This is a randomly generated one)

User Commands

  • !mk, !markov [USER]... [OPTION]...
    • Basic syntax
  • -s, --startswith [STR]
    • Chain starting word
  • -l, --length [INT]
    • Chain length - Random length between 1 - 14 by default, Max: 100
  • !mkjson
    • Update personal JSON list since last refresh

Examples:

!markov -s Heiroglyph
Generates a chain for you, beginning with word "Heiroglyph"

!mk PaulAtreides --limit 15
Generates a chain for user "PaulAtreides", limiting the markov chain to 15 words, and searching through 15,000 messages.

This is an example of the bot constructing Markov chains, using paragraphs pasted out of the Fellowship of the Ring. This was cut short by the default chain length:

markov-bot test with LOTR paragraphs

Admin Commands

These are set in the code - sorry but as of current there is no easy way to configure this

  • !mkjson createchannel [MSGCOUNT]...
    • Create JSON Markov Dictionaries for the current channel. This takes a very long time (you have been warned)
  • !mkjson createuser [USER]...
    • Create a JSON Markov Dictionary for the stated user
  • !mkjson updateuser [USER]...
    • Updates the JSON Markov Dictionary for the stated user

Examples:

!mkjson createchannel
Generates Markov dictionaires for each user, assigned to the channel you post this in

!mkjson createuser PaulAtreides
Generates a chain for user 'PaulAtreides', assigned to the channel you post this in

!mkjson updateuser PaulAtreides
Updates an existing chain for user 'PaulAtreides', with messages sent since the JSON Dictionary was created/last updated

markov-bot's People

Contributors

whambulance avatar

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.