breuerfelix / jinsta

javascript + instagram + algorithms
MIT License
60 stars 13 forks source link

Explanation for constants.ts #5

Open GaWr26 opened 4 years ago

GaWr26 commented 4 years ago

Hey Felix,

I had it running for the first time last night and it already liked some posts which is great. I even got some likes back. After watching it for a while, I though if I use Instagram manually, I like a lot more in a faster pace. Think about scrolling through Instagram and double tapping on posts you like. I assume I would do around 10 likes in 30 seconds on my feed. As my feed is tailored to my liking, most pictures should be "likeable".

I've set quite some keywords:

'travelcouples', 'travelcommunity', 'passionpassport',
                'travelingcouple',
                'backpackerlife', 'travelguide', 'travelbloggers',
                'travelblog', 'letsgoeverywhere',
                'travelislife', 'stayandwander', 'beautifuldestinations',
                'moodygrams',
                'ourplanetdaily', 'travelgram', 'sunsetporn',
                'lonelyplanet',
                'igtravel', 'instapassport', 'travelling', 'instatraveling',
                'travelingram',
                'mytravelgram', 'skyporn', 'traveler', 'sunrise',
                'sunsetlovers', 'travelblog',
                'sunset_pics', 'visiting', 'ilovetravel',
                'photographyoftheday', 'sunsetphotography',
                'explorenature', 'landscapeporn', 'exploring_shotz',
                'landscapehunter', 'colors_of_day',
                'earthfocus', 'ig_shotz', 'ig_nature', 'discoverearth',
                'thegreatoutdoors', 'shotonmoment'

How should interest_inc be modified in this case? Increase or decrease the value? How much change should be done? Can base_interest be modified or should I leave it alone? I set like_chance = 2 but still feel it likes not many pictures.

Maybe you could give a detailed explanation of these properties and their effect in the Readme?

Also if an Image is liked, it would be great to output the URL so we can take a look at what the Bot is doing. Well, statistics and surveillance is a huge different topic.

Regarding speed I would again compare to how I use IG manually. Imagine using it twice a day on a commute. Half an hour each way. in this time I would really interact a lot. Maybe follow 100 people, like 200 posts and comments. During the day I might check in for 5 minutes while having a smoke. What I'm trying to say and what confused me with InstaPy and other systems is the fact that they were running all day or even just 8 hours continuously which a human would not do.

I know it's very early but these are the initial thoughts and questions that came to my mind.

More to come. Thanks Felix!

Edit: Running again now and I set like_chance = 50; which results in much more likes than before but looks like a decent like/skip ratio to me.

Edit2: The script finished as expected after 50 likes in around 45 minutes! I like it!

breuerfelix commented 4 years ago

first of all, thanks for your amazing review and time for testing ! awesome!!

so i will extract the following info:

1) the bot should interact more in less time cause a user also interacts like that
2) better logging

i will try to explain the constants a little bit more (but i bet they will get changed really soon anyways :D)

the bot is calculating the base interest of a post with base_inc + (number of matching keywords * interest_inc)

with this rating it will choose if its interacting with the media or not.
if yes, it will take the like rating and calculate if its liking the picture or not. btw all values are only between 0 and 1, so 1 is 100% and 0 is 0%.

for example a 1 in base interest and .5 in like would like every second photo. a .5 in base interest and .5 in like chance would like every fourth picture since the overall rating is 0.5 * 0.5 ...

yeah its complicated thats why i will probably change it :D

enrifer commented 4 years ago

Hey, first thank you Felix for the effort your putting into this ๐Ÿ™๐Ÿ™๐Ÿ™ I installed it this morning with the advanced configuration and it works great so far. I experienced the same like gawr26, it's a bit too slow in my opinion.

I'm new to javascript, where can I find the constants.ts file on my laptop to change the parameters?

Thanks a lot ๐Ÿ‘

GaWr26 commented 4 years ago

@enrifer please take a look at the advanced configuration in the readme