A Twitter bot that describes food images
- Clone the repository
git clone https://github.com/sqrg/foodDescriptionBot.git - Install the required packages with pip
pip install -r requirements.txt - Create a
database.dbfile and leave it empty - Create a
credentials.pyfile and add the following lines (replaceabc123with your own keys)
# Reddit credentials
CLIENT_ID = 'abc123'
CLIENT_SECRET = 'abc123'
# Azure credentials
SUBSCRIPTION_KEY = 'abc123'
# Azure URL
AZURE_URL = 'https://brazilsouth.api.cognitive.microsoft.com/vision/v1.0/analyze'
# Twitter credentials
CONSUMER_KEY = 'abc123'
CONSUMER_SECRET = 'abc123'
ACCESS_TOKEN = 'abc123'
ACCESS_TOKEN_SECRET = 'abc123'
(You can also use a different AZURE_URL)
- Then just do
python main.pyand the bot will start working
- Add some kind of logging
- Support URLs that don't end with '.jpg' or '.png'