/ai-tweepic

The AI tweet generator based on images for the creatively lazy folks.

Primary LanguageHTMLMIT LicenseMIT

AI-Tweepic logo

version 1.1 PRs Welcome License MIT

Open Source Love

Twitter Tweet Twitter Follow

The AI tweet generator based on images for the creatively lazy folks.

AI-Tweepic is a native desktop app (available for Windows, Mac & Linux) that generates tweets (Twitter status updates) based on a given input image. The app does not use any text generator for pictures (currently developed by only few premium AI agents).

NOTE: 
* Almost all opertaional errors encountered till now are due to slow fetching of tweets in bulk. If you are having some trouble, just try after some time and you won't be disappointed.
* The results obtained are very graphic and uses strong language as I ended up training it on raw twitter data. If you are offended by violence or slangs then please step back.
* The output is definitely not very impressive at this stage. In fact the model hardly generates meaningful words let alone sentences. But with more compute power or longer training or more impressive algorithms much more meaningful results can be obtained. Check [Ryan Kiros'](https://github.com/ryankiros) magnificient [work](https://github.com/ryankiros/neural-storyteller) for a demo. (This work is not it's fork in anyway)

Get Started

* Download build for your respective OS from release-builds/ (No need to clone whole repo.)
* Double-click & run!
* Upload an image
* Hit upload
* Voila!

The code for the API used in backend hosted here can be found here.

HowTo's & Scope for Improvement:

  • The LSTM model is pretrained on my GPU-less local machine for about an hour. The results can be drastically improved by training on free cloud engines. FloydHub is the easiest to get started.

  • The transfer learning for new tweets is done by my Flask app deployed on Heroku. The compute power provided by a free heroku account is pretty low to obtain decent results quickly. Hence the results don't seem very "customized". Some limitations include:

    • The compute power of heroku dynos varies according to a lot of factors as Heroku runs on top of AWS.
    • Dynos sleep after some time of inactivity.
    • Requests time out easily. Can't train for long.

Credits & Sources:

  • The LSTM model was pretrained with a corpus of tweets downloaded from this webpage. It contains a csv file for training of sentiment analysis of tweets.

  • A very "quick and dirty" implementation of LSTM was inspired from this blog by Trung Tran. It uses the Keras builtin LSTM model.

License

MIT

Certain resources(icons, images, etc) require attribution.

Copyright (c) 2018-present, armag-pro.