Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/bartekpog/instacat

Instagram bot that posts fake cat images
https://github.com/bartekpog/instacat

Last synced: 17 days ago
JSON representation

Instagram bot that posts fake cat images

Awesome Lists containing this project

README

        

# InstaCat

Cats rule the internet, so why can't we rule the cats? This repository contains a script that posts fake cat images with computer generated description on Instagram.

You can see at what it can do [here](https://www.instagram.com/suspiciouskitties/).

![cat screenshot](https://github.com/BartekPog/InstaCat/blob/master/images/screen.jpg)

## How does it work

This project is a fusion of [This cat does not exist](https://thiscatdoesnotexist.com/) and [Online GPT-2 text generator](https://deepai.org/machine-learning-model/text-generator). It takes a cat image generated by [Nvidia StyleGan2](https://github.com/NVlabs/stylegan2) and combines it with a cat realted text generated by the GPT-2 DeepAI model, adds some hashtags and posts it on instagram via [instabot](https://github.com/instagrambot/instabot) library.

## Setup

Currently the repository aims for **Ubuntu** users, because of all the system paths and integration with bash.

To setup **Python enviroment** run:

```bash
virtualenv .env
source .env/bin/activate
pip install instabot
```

Then to add **credentials** add file `credentials.py`. It's content shall look like this:

```python
username = "INSTAGRAM_USERNAME"
password = "INSTAGRAM_PASSWORD"
api_key = "DeepAI_API_KEY"
```

After that to **setup automatic** posting run `crontab -e` and add the following line to your _crontab_:

```
0 */4 * * * PATH_TO_REPOSITORY/run_upload.sh >> PATH_TO_REPOSITORY/logs.txt 2>&1
```

This will make your system run `run_upload.sh` script every 4 hours and save the logs in `logs.txt`. Note that the _crontab_ will run the script **only if** the system is on, so the frequency of posting shall be tuned to computer usage.

## Important

This repository **has not been authorized** by Facebook, DeepAI or Nvidia. Keep that in mind when trying out. Use at **own risk**. Just do not harm any kittens.