Skip to content

Statistics bot and reblog with review bot for mastodon

Notifications You must be signed in to change notification settings

BreakDimbo/mastodon-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Feature

This is a bot colletion for mastodon. It will be extended as needed. Now there are 2 kinds of bot:

  • intelbot
  • firebot

intelbot

Intelbot is a bot which collects and analyzes the toots. It will show the following items daily and weekly

  • keywords of top five
  • total count of toots in local timeline
  • total count of users who tooted in local timeline
  • the top 3 users who like toot most in local timeline
  • the top 1 user who like toot most in home

firebot

Firebot is a bot for reblogging the toot with review in local timeline. Reply the toot with review and @firebot.

Install

  1. install golang
  2. clone the project
git clone [email protected]:BreakDimbo/cmx_bot.git
  1. change to working directory
cd cmx_bot
  1. install dependency
make get
make deps
  1. build the binary file
make bot
make fbot
  1. install elastic search 6.3.0 (maybe you need install java runtime env)
  2. create the log file
sudo touch /var/log/mastodon_bot
sudo chown ${your_current_user} /var/log/mastodon_bot
  1. set the config file in config/development.toml according to config/development.demo.toml

Usage

  1. run elasticsearch
  2. run intelbot
#{working_directory}/bin/bot
  1. run firebot
#{working_directory}/bin/fbot
  1. there are xxx.service files for systemd usage in dir config

Preview

preview

TODO

  • set config.yml
  • follow & unfflow automatically
  • post weekly and daily
  • collect local toots of followers
  • refactor the structure
  • log
  • remove config.toml file
  • readme
  • show the favourited plus reblogged most toot daily
  • generate graph about toots count everyday
  • cache info in nsq when es connect down
  • fix the way of reading dict file