<commit_before># Bruxism
A chat bot for YouTube, Discord and IRC.

[![GoDoc](https://godoc.org/github.com/iopred/bruxism?status.svg)](https://godoc.org/github.com/iopred/bruxism)
[![Go report](http://goreportcard.com/badge/iopred/bruxism)](http://goreportcard.com/report/iopred/bruxism)
[![Build Status](https://travis-ci.org/iopred/bruxism.svg?branch=master)](https://travis-ci.org/iopred/bruxism)

## Current plugin support:

Commands are prefixed with `!` on YouTube and IRC, and `@BotName ` on Discord.

* `comic [<1-6>]` - Creates a comic from recent messages.
* `customcomic [<id>:] <text> | [<id>:] <text>` - Creates a custom comic.
* `customcomicsimple [<id>:] <text> | [<id>:] <text>` - Creates a simple custom comic.
* `emoji <emoji>` - Returns a big version of an emoji.
* `help [<topic>]` - Returns generic help or help for a specific topic. Available topics: `comic,remind`
* `invite <id>` - Provides invite URL for the bot.
* `mtg <cardname>` - Returns information about a Magic: The Gathering card.
* `numbertrivia [<number>]` - Returns trivia for a random number or a specified number if provided.
* `playing` - Set which game the bot is playing on Discord. Only enabled for bot owner.
* `reminder <time> | <reminder>` - Sets a reminder.
* `stats` - Lists bot statistics.
* `streamer <streamername|streamerid>` - Grabs details about a YouTube streamer.
* `topstreamers` - List the current top streamers on YouTube Gaming.

Also supports direct invites on Discord and support for announcing streamers going live on YouTube Gaming.

## Usage:

### Installation:

`go get github.com/iopred/bruxism/cmd/bruxism`

`go install github.com/iopred/bruxism/cmd/bruxism`

`cd $GOPATH/bin`

### Setup

You must first generate a YouTube Oauth token in the [Google Developer Console](https://console.developers.google.com/).

Go to Credentials and download the JSON config file and save it in `$GOPATH/bin` as `youtubeoauth2config.json`

`bruxism -youtubeurl`

You will then be given a URL (and copied to clipboard), visit that URL and copy the code, then run:

`bruxism -youtubeauth <AUTH CODE>`

Now the bot can be run:

`bruxism`

### Run as a Discord bot

`bruxism -discordemail <discord email> -discordpassword <discord password>`

Discord has recently rolled out Bot accounts. To run Bruxism as a Bot:

`bruxism -discordtoken <discord token>`

It is suggested that you set `-discordapplicationclientid` if you are running a bot account, this will make `inviteplugin` function correctly.

It is suggested that you set `-discordowneruserid` as this prevents anyone from calling `playingplugin`.

### Run as an IRC bot

`bruxism -ircserver <irc server> -ircusername <irc username>` -ircchannels <#channel1,#channel2>`

## Arguments:
<commit_msg>Update readme.<commit_after># Bruxism
A chat bot for YouTube, Discord and IRC.

[![GoDoc](https://godoc.org/github.com/iopred/bruxism?status.svg)](https://godoc.org/github.com/iopred/bruxism)
[![Go report](http://goreportcard.com/badge/iopred/bruxism)](http://goreportcard.com/report/iopred/bruxism)
[![Build Status](https://travis-ci.org/iopred/bruxism.svg?branch=master)](https://travis-ci.org/iopred/bruxism)

## Current plugin support:

Commands are prefixed with `!` on YouTube and IRC, and `@BotName ` on Discord.

* `comic [<1-6>]` - Creates a comic from recent messages.
* `customcomic [<id>:] <text> | [<id>:] <text>` - Creates a custom comic.
* `customcomicsimple [<id>:] <text> | [<id>:] <text>` - Creates a simple custom comic.
* `emoji <emoji>` - Returns a big version of an emoji.
* `help [<topic>]` - Returns generic help or help for a specific topic. Available topics: `comic,remind`
* `invite <id>` - Provides invite URL for the bot.
* `mtg <cardname>` - Returns information about a Magic: The Gathering card.
* `numbertrivia [<number>]` - Returns trivia for a random number or a specified number if provided.
* `playing` - Set which game the bot is playing on Discord. Only enabled for bot owner.
* `reminder <time> | <reminder>` - Sets a reminder.
* `stats` - Lists bot statistics.
* `streamer <streamername|streamerid>` - Grabs details about a YouTube streamer.
* `topstreamers` - List the current top streamers on YouTube Gaming.

Also supports direct invites on Discord and support for announcing streamers going live on YouTube Gaming.

## Usage:

### Installation:

`go get github.com/iopred/bruxism/cmd/bruxism`

`go install github.com/iopred/bruxism/cmd/bruxism`

`cd $GOPATH/bin`

### Setup

You must first generate a YouTube Oauth token in the [Google Developer Console](https://console.developers.google.com/).

Go to Credentials and download the JSON config file and save it in `$GOPATH/bin` as `youtubeoauth2config.json`

`bruxism -youtubeurl`

You will then be given a URL (and copied to clipboard), visit that URL and copy the code, then run:

`bruxism -youtubeauth <AUTH CODE>`

Now the bot can be run:

`bruxism`

### Run as a Discord bot

`bruxism -discordemail <discord email> -discordpassword <discord password>`

Discord has recently rolled out Bot accounts. To run Bruxism as a Bot:

`bruxism -discordtoken <discord token>`

It is suggested that you set `-discordapplicationclientid` if you are running a bot account, this will make `inviteplugin` function correctly.

It is suggested that you set `-discordowneruserid` as this prevents anyone from calling `playingplugin`.

### Run as an IRC bot

`bruxism -ircserver <irc server> -ircusername <irc username> -ircchannels <#channel1,#channel2>`

## Arguments:

{'fraction_non_alphanumeric': 0.12254545454545454, 'fraction_numerical': 0.0018181818181818182, 'mean_word_length': 4.596134282807731, 'pattern_counts': {'":': 0, '<': 51, '<?xml version=': 0, '>': 51, 'https://': 10, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '846368', 'n_tokens_mistral': 1838, 'n_tokens_neox': 1750, 'n_words': 643}