Instapy: Optimal number of interactions per day

Created on 8 Nov 2017  路  21Comments  路  Source: timgrossmann/InstaPy

Hey everybody!

I've been trying to do some commits here and there, but still didn't make any pull requests. I've been using this script since June and the results are pretty awesome. I've moved from Digital Ocean to running it on my laptop since Instagram doesn't restrict that much from the known ips.
So, I'd like to propose a feature with something like "optimal interactions per day". I mean that we could make an algorithm which creates the maximum amount of interactions (and followers), depending on the account (previous number of posts, age of account, current followers and following etc). And it would be cool if you could suggest some metrics and possible properties, which we could use to make the best possible strategy automatically.
I really need some fresh insights on Instagram behavior regarding bots to combine rapid grow and to avoid bans for some inexperienced users.

Expected Behavior

InstaPy runs with best possible strategy. We could suggest and set number of hashtags/followers/likes/follows/comments and all the other variations which are important for any given account. And we could also add some points like "are you running it at home or at some cloud?" which as we know is also important to this bot

Current Behavior

InstaPy needs a lot of tweaking and very dependent on the user input, which could lead to slow grow or ban/problems etc.

Possible Solution (optional)

Create a module "optimizer", which brings this behavior to life and use some kind of (if possible) mathematical functions to calculate the optimal strategy for most cases, which could make bot run better.

InstaPy configuration

I run it on 1.3k follower account from my mac with about 300-800 likes per day and 10% to comment and 25% to follow. Also i use randomizer to make these amounts not constant and I also scroll with some randomness.

discussion enhancement wontfix

Most helpful comment

@blakemmw I'm interested in your setup as well, sounds like you've done some great research into the instagram limitations. What have you found to be the optimal setup for you thus far?

All 21 comments

thats cool. what do you think about #859 ?

Hey, sounds cool. I think the way it works currently, with passing on inappropriate post but adding to the total works well as no day is the same.

In regards to growth and bans. I studied Instagram pretty intensely and I found out that the number of likes a day should NOT be a spike, it should be a gradual increase - kinda like a steroid lol. So start with 18 per tag, 24 per tag, 30 per tag, 45 per tag, etc ( i capped at 44) I spread those little increases across about 1 per week.
I know that Insta looks at how many followers you have and compares that to how many posts you're liking a day, so it should always be within the accounts means. Nothing too aggressive. I've also decided to make multiple versions of the scripts that have different numbers assigned to actions as well as different comments and tags. The computer picks one at random a day so the accounts actions are actually quite randomised.

What would be good @converge @timgrossmann - is if there was a way to randomise the order of tags interacted with so it's even less linear. and a way to do a comments pair by array index.

So: session.clarifai_check_img_for(['fruit', 'healthy', 'blueberry'],
comment=True, comments=['Looks so yum!', 'Looks so nice!', 'Yummm',

Looks so yum! = fruit,
Looks so nice! = healthy,
Yummm - blueberry

@blakemmw So your saying its best to only have max 44 per tag

@wizarduk no not at all, I'm just playing it safe. The account has just over 3000 followers.

In order to be extra careful, I've tried to randomize as many things as i can to avoid any sort of pattern.

The way i look at it is this:
Is an actual human being going to comment/view more than 400 posts a day? NO WAY. I'm sure you can use instaPy more aggressively. I'm just trying to keep it as real as i can. Im not looking for a growth hack, im just trying to make it interact with external accounts so i can focus on more important tasks in my startup. If instaPy can save me sitting on my phone for 2-3 hours a day liking and commenting on random posts, im happy.

@blakemmw very true we are trying a few methods

@blakemmw actually, some people spend hours liking posts. I've got a friend who even got herself a temporary liking ban by liking too many on her fresh art account :)
What are your growth rate? Mine is about 20-40 new followers per day. Since October I got 500+ (from 800 to 1300) new followers, and I feel I'm playing it safe with many randomized things and many comment and hashtag variations. But I know that my experience is pretty specific, so it's nice to hear other stories.

@wizarduk just some stats:

Current followers: 3041
Currently following: 2470 ( i dump 60 every second day, to grow my "currently following" proportionately to my current followers)

Last run
liked: 307
already liked: 20
inappropriate: 146
commented: 104
Followed: 45

So im running a quite a bit of tags, but im keeping the overall view / interact under 500 posts.

Instagram looks at the amount of posts you like vs amount of posts viewed, as well as how long you view them and in addition they actually look at your interactivity before and after a post. So, after ever upload I run a LikeFeed.py file which goes through 77 of my current feed and likes their stuff or unfollows if irrelevant. Hope this info helps.

@blakemmw Yes we are running 16 tags set at 60 which is doing well but i think i need to lower that amount as had comments set at 50% problem is it keeps commenting on the same picture which doesnt help...

@diveu My best mate at universities job is to sit on his phone and like stuff!!!! hahaha. I get you.

when i was using instaPy aggressively, in the beginning, we went from 1500 - 2000 3 weeks. in the past month i think on average we have gone up 10-20 per day. However, when i post something we can go anywhere from 30-80 a day. We got 120 in one day once, was awesome!

@wizarduk yeah i'd be careful. Also look at the tags you use.

Check this out: https://austenallred.com/the-growth-hackers-guide-to-instagram-3f084d7d2d0a

I'm thinking about using some machine learning algorithms here for better scaling etc. We could probably get something working here, but it could make this bot a bit too large and complex :)
For example: choosing the best comment with random forest depending on the content of image or getting the like amounts via linear models like regressions etc.

@converge I'll look into #859 and write my opinion here, thx!

Hey @diveu I'm interested in the results you're finding on your account.
Would it be possible for you to share the .py file you use to run that's giving you those results?

I'd like to compare it with mine. I'm not sure if the settings I've made are very effective.

Could you please share your quickstart script with me so I can see how you randomize it? Im new to this, thanks!

I'm running the script every night, liking 1300 posts each session (4 tags, 350 likes each) - still no problems :)

@diveu I'm interested in seeing your quickstart.py setup, && would be down to help you with the ML/regressions for finding optimal hyperparameters!

@blakemmw I'm interested in your setup as well, sounds like you've done some great research into the instagram limitations. What have you found to be the optimal setup for you thus far?

@michalsurynt How did you speed up your following/liking interactions?

wouldn't it be easier to have a modified quickstart.py that has already been configured with optimal settings based most likely on growth hacks? then all one had to do was pull it, study and implement it on their own version. it could be named optimal.py and be put in the examples folder along with multi-account.py.
the benefits i see is

  • fewer people using the bot get banned or spook Instagram
  • easy version controlled way to get fastest settings!!

Hey guys, just in regard to this, what I have done for one of my accounts 馃憤

This makes it super random with what it interacts with every day, and the script runs at random times too. Im finding that this works, and by importing random the scripts working with different amounts every action that it does. :)

@Areahints an optimal script would be good tho. Gone are the days of waking up to 80 followers per day. I feel like the bot is less effective now.

import random

"TAG POOL"

"TAG DELCARATION"
group_of_items = {'#fitness','#yoga','#yogapants','#women','#tights','#leggings','#gym','#fit','#workout','#fitfam','#health','#bodybuilding','#fitspo','#weightloss',
'#cleaneating','#muscle','#exercise','#healthyfood','#strength''#gains','#fitlife','#healthyeating','#healthylifestyle','#healthyliving','#weightlossjourney','#shredded','#transformation','#gymrat','#transformationtuesday',
'#bodybuilder','#gymtime','#cleaneats,''#gymflow','#fatloss','#cleanfood','#weightlossmotivation','#fitfamily','#bodybuildingmotivation','#workoutmotivation','#bodygoals',
'#workouts','#weightlosstransformation','#fattofit','#gymselfie','#bodytransformation','#strongbody','#strongerthanyesterday','#bodybuilderlifestyle','#exercising','#fatlossjourney',
'#healthydiet','#strongissexy','#gymjunkie','#cleanliving','#fitfreak','#fat2fit','#fatburn','#musclefood','#fitfriends','#fitinspiration','#workoutflow','#strongisthenewsexy','#bodyunderconstruction','#swolelife',
'#cleaneatingjourney','#cleaneatingaddict','#fattofitjourney''#gainscity','#cleaneatingforlife','#musclemass','#gyminspiration','#workoutlife','#cleanbulk','#workouthard','#fitfamlife','#cleaneater','#swoleandflexy',
'#gainsfordays','#shreddedlife','#shrednation','#swolefie','#rippedbody','#fitfaminstagram','#transformationjourney','#rippedfreak','#stronglife','#gainsongains','#shredzville','#gainsgainsgains','#transformationstory',
'#rippedabs','#transformationpic','#shredfat','#exerciseforlife','#gainsallday','#swolefam','#swoleoclock','#gainsovereverything','#swolefamily','#swolecity','#swoleteam6','#gainslife','#fitfamnation'}               # TAG POOL
num_to_select = 20                           # set the number to select here.
list_of_random_items = random.sample(group_of_items, num_to_select)
first_random_item = list_of_random_items[0]
second_random_item = list_of_random_items[1]
third_random_item = list_of_random_items[2]
fourth_random_item = list_of_random_items[3]
fifth_random_item = list_of_random_items[4]
sixth_random_item = list_of_random_items[5]
seventh_random_item = list_of_random_items[6]
eighth_random_item = list_of_random_items[7]
ninth_random_item = list_of_random_items[8]
tenth_random_item = list_of_random_items[9]
eleventh_random_item = list_of_random_items[10]
twelvth_random_item = list_of_random_items[11]
thirteenth_random_item = list_of_random_items[12]
fourteenth_random_item = list_of_random_items[13]
fifteenth_random_item = list_of_random_items[14]
sixteenth_random_item = list_of_random_items[15]
seventeenth_random_item = list_of_random_items[16]
eighteenth_random_item = list_of_random_items[17]
nineteenth_random_item = list_of_random_items[18]
twentieth_random_item = list_of_random_items[19]


for x in range(1):
  myRandomFeed = random.randint(5,18)

session.like_by_feed(amount=myRandomFeed, randomize=True) # WILL INTERACT WITH USER FEED (LIKES ONLY) based on the no. that the var has been assigned 


# LIKE BY TAG
# Creates var, picks random number declared range and returns to var:

for x in range(1):
  myRandomLike = random.randint(35,45)

session.like_by_tags([first_random_item,second_random_item,third_random_item, fourth_random_item,fifth_random_item,sixth_random_item,seventh_random_item,eighth_random_item,ninth_random_item,tenth_random_item], amount=myRandomLike)

# LIKE BY TAG
# Creates var, picks random number declared range and returns to var:

for x in range(1):
  myRandomLike = random.randint(35,45)

session.like_by_tags([eleventh_random_item,twelvth_random_item,thirteenth_random_item,fourteenth_random_item,fifteenth_random_item,sixteenth_random_item,eighteenth_random_item,nineteenth_random_item,twentieth_random_item], amount=myRandomLike) #LIKE BY TAGS WITH NEW VAR no.

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. > If this problem still occurs, please open a new issue

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lairdep23 picture lairdep23  路  47Comments

cormo1990 picture cormo1990  路  48Comments

GreatTimeBand picture GreatTimeBand  路  114Comments

CamiloB picture CamiloB  路  316Comments

fgisslen picture fgisslen  路  48Comments