Announcing DelegatorBot 1.1.7 ~ Many New Features!

in #utopian-io5 years ago (edited)

Repository

https://github.com/artolabs/delegatorbot


delegator_bot_1.1.7_logo.png

DelegatorBot 1.1.7

DelegatorBot is a community based delegation bot that grants upvotes to delegators. It also replies, resteems and generates a daily report detailing a list of all its delegators and how much they've delegated, as well as a list of all the posts it has upvoted in the last 24 hours along with the exact vote weight used when upvoting each post.

This bot is designed to be more of a "community uplift bot" rather than a strictly capitalistic endeavor. In some other delegation-type bots, a delegator may be granted a higher upvote for a larger delegation. However, DelegatorBot 1.1.7 is more egalitarian and tries to grant a fair and balanced upvote for all members of the group regardless of how much they delegated. People who wish to delegate more than the minimum amount are akin to philanthropists who wish to help uplift the entire group. That doesn't meant that it can't be profitable. All delegators that delegate the minimum delegation will receive upvotes much larger than they could have generated if they had tried to used the same amount of SP to upvote themselves. It's truly a win-win for all those who wish to participate.

Please see DelegatorBot 1.0 Intro post for more information.

Installation

Please see the installation instructions.

New Features

Based on user feedback, DelegatorBot has a whole slew of new features that enable the bot owner to better regulate the bot's behavior. There are also some additional perks like adding a personalized message to the reply as well as a VIP and NVIP list granting higher (and lower) votes for those on the list.

VIP and NVIP lists

DelegatorBot 1.1.7 now features both a VIP list and NVIP (Not-VIP) list along with relative vote weights. The bot owner may add as many account names to either list and the bot will attempt to upvote at the designated vote weight.

NOTE: However the bot still takes into account the amount of time between posts, so even VIP accounts may not always get a maximum upvote if they post too often.

The NVIP list is simply given a low vote weight every time. This may be used to follow accounts and grant upvotes to non-delegators.

# List of VIP accounts that always get a higher upvote
self.vip_accounts = [None]

# The percentage (1 to 100) to use if an account is in the VIP list
self.vip_vote_weight = 100

# List of NVIP accounts that always get a much lower upvote
self.nvip_accounts = [None]

# The percentage (1 to 100) to use if an account is in the NVIP list
self.nvip_vote_weight = 3

Run Multiple Bots From One Command

Now, one command can be issued to multiple bots simultaneously, making automation more efficient. Runtime conflicts not entirely solved using a cronlock file can arise while running multiple bots. To solve this, multiple bots can be added to any command, which will then be executed on each bot in turn. This is done by simply appending each additional bot name to the end of the command.

runbot run botname1 botname2 botname3


# If no bot name was given use the default settings

if len(sys.argv) == 2:
    commander("settings", command)
    # Iterate through a list of bot names and 
    # execute the same command for each
    else:
        for i in range(2, len(sys.argv)):
            commander(str(sys.argv[i]), command)


runbot_multiple_bots.gif

Algorithm Scale Setting

The vote weight the algorithm returns can be scaled using a number between just above zero and 1, 1 being full weight. This is calculated after the weight is already adjusted based on the bot's voting history, but before it's adjusted based on time of post. Adjusting this setting can help as the delegator list starts to become too long. It also helps even out cycles of major and minor voting activity. For example, Many votes may happen during the day, but not at night. When the algorithm scale is at 1 and there are a lot posts throughout the day the bot's vote power becomes very depleted. In the morning, the first person to post will get a much higher vote value than then last person to post in the evening. However, if it becomes apparent that the bot is constantly upvoting at an average of 60%, the the scale can be adjusted so that even after a full nights power up the first person gets an "averaged" vote weight which in turn helps to prevent depleting the bot's vote power in the morning and thus helping the person at the end of the day receive a more fair upvote.

# 3 days of vote power would be 3000% of vote weight
# To account for new users and surges in use the 3000 is
# is multiplied by a user defined number between just above 
# zero and 1

self. cfg.algorithm_scale = 0.6    #  60%

adj = ((3000 * self.cfg.algorithm_scale) / total_vote_weight_used * 100)

Max Vote Weight Setting

This is a cutoff setting. If any vote weights calculated by the algorithm are higher than this cutoff than the vote weight is set to the cutoff value. This should be used in conjunction with the algorithm scale setting to ensure balanced vote weights throughout the day and during surges of vote activity.

# Sets the maximum vote weight allowed if not the owner or VIP. Must be a number between 1 and 100
        
self.vote_weight_max = 100

Below Threshold Vote Weight

A setting now exists that allows adjustment of the vote weight given out if the bot's vote power dips below the vote power threshold setting. For example, in the settings configuration below, if the bot's vote power dips below 70% all upvotes will be given with a vote weight of 10% until vote power returns to above 70%.

# When the bot's vote power goes lower than 
# this all upvotes are only 3%

self.vote_power_threshold = 70

# The vote weight percentage (1 to 100) the bot will give 
# every post if the vote power threshold is crossed

self.below_threshold_vote_weight = 10

Reduced Vote Wait Time & Reduced Vote Weight

If a delegator makes two posts in quick succession of each other within the time limit set by the reduced vote wait time setting, the bot gives a vote weight as set by the reduced vote weight setting. This is obviously to prevent one person from "gaming" the system and trying to get more upvotes than the rest of the delegators. As explained in the 1.0 Introduction post, the vote weight is calculated based on the amount of time since their last upvote, granting the highest possible value at 24 hours. This new setting "flatlines" the upward slope for a set amount of time immediately after the post. In the case of the example code below, Any post made within three hours of the last post made will get a flat-rate upvote of 3%. Posts made after 3 hours will be calculated based on the amount of time since the post.

# The number of hours after a delegator makes a post 
# during which they can only receive the reduced vote weight
     
self.reduced_vote_wait_time = 3        # 3 hours

# The reduced vote weight percentage (1 to 100) as given if a 
# post is made immediately after another post
        
self.reduced_vote_weight = 3           # 3%

Reply Alert Message

Individually tailored messages can now be attached to the reply message the bot posts giving a way for the bot to send alerts and notifications to it's delegators. To add a customized message the bot owner simply appends a quoted string to the settings file.

# An alert message placed onto every reply

self.alert_message = '''
NOTICE: This is a customized message that will only be 
displayed on the reply messages left by this particular bot. 
<p>HTML is allowed.</p>
'''

artturtle_reply.png

Technology Stack

DelegatorBot 1.0 is written in Python 3.5 and uses MySQL
Complete list of dependencies

Roadmap

Still working on a more rugged exception system. There may be more settings in the future plus a tutorial. If anyone is interested in setting up DelegatorBot for themselves feel free to reach out to me on my Discord server if you need any help.

Contact

Please contact Mike (Mike-A) on Discord
https://discord.gg/hTfBZS3

GitHub Account

https://github.com/artolabs

Sort:  

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Chat with us on Discord.

[utopian-moderator]

Thank you for your review, @helo! Keep up the good work!

3 bot comments 3 satisfied customers

Hi @learnelectronics!

Your post was upvoted by @steem-ua, new Steem dApp, using UserAuthority for algorithmic post curation!
Your post is eligible for our upvote, thanks to our collaboration with @utopian-io!
Feel free to join our @steem-ua Discord server

Hey, @learnelectronics!

Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Get higher incentives and support Utopian.io!
Simply set @utopian.pay as a 5% (or higher) payout beneficiary on your contribution post (via SteemPlus or Steeditor).

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

Thank you learnelectronics! You've just received an upvote of 100% by thejollyroger!


Learn how I will upvote each and every one of your posts



Please come visit me to see my daily report detailing my current upvote power and how much I'm currently upvoting.

Thank you learnelectronics! You've just received an upvote of 94% by tommyknockers!


Learn how I will upvote each and every one of your posts



Please come visit me to see my daily report detailing my current upvote power and how much I'm currently upvoting.

Thank you learnelectronics! You've just received an upvote of 37% by artturtle!


Learn how I will upvote each and every one of your posts



Please come visit me to see my daily report detailing my current upvote power and how much I'm currently upvoting.


ANNOUNCING 2 MORE DELEGATION BOTS! Hey guys, if you like getting a constant supply of upvotes from @artturtle, you should definitely check out @tommyknockers and @thejollyroger for even more! Both these bots run on the same technology as @artturtle and so work the exact same way. Currently @tommyknockers grants up to $0.10 upvotes and @thejollyroger will add another $0.01 on top of that. These bots just launched so newcomers are getting 100% upvotes. Check them out and start growing your posts today!