Tweet Generation with Huggingface
Create in 5 minutes a tweet generator based on your favorite Tweeter
I developed HuggingTweets to try to predict Elon Musk's next breakthrough 😉
This project fine-tunes a pre-trained neural network on a user's tweets using HuggingFace Transformers, an awesome open source library for Natural Language Processing. The resulting model can then generate new tweets for you!
To test the demo, click on below link and share your predictions!
You can also use it locally by installing the dependencies with
My favorite sample is definitely on Andrej Karpathy, start of sentence "I don't like":
I don't like this :) 9:20am: Forget this little low code and preprocessor optimization. Even if it's neat, for top-level projects. 9:27am: Other useful code examples? It's not kind of best code, :) 9:37am: Python drawing bug like crazy, restarts regular web browsing ;) 9:46am: Okay, I don't mind. Maybe I should try that out! I'll investigate it :) 10:00am: I think I should try Shigemitsu's imgur page. Or the minimalist website if you're after 10/10 results :) Also maybe Google ImageNet on "Yelp" instead :) 10:05am: Looking forward to watching it talk!
I had a lot of fun running predictions on other people too!
To understand how the model was developed, check my W&B report.
Required files to run W&B sweeps are in
I still have more research to do:
Built by Boris Dayma
My main goals with this project are:
For more details, visit the project repository.
Disclaimer: this project is not to be used to publish any false generated information but to perform research on Natural Language Generation.
Does this project pose a risk of being used for disinformation?
Large NLP models can be misused to publish false data. OpenAI performed a staged release of GPT-2 to study any potential misuse of their models.
I want to ensure latest AI technologies are accessible to everyone to ensure fairness and prevent social inequality.
HuggingTweets shall not be used for creating innapropriate content, nor for any illicit or unethical purposes. Any generated text from other users tweets must explicitly be referenced as such and cannot be published with the intent of hiding their origin. No generated content can be published against a person unwilling to have their data used as such.
Why is the demo in colab instead of being a real independent web app?
However training such large neural networks requires GPU (not available on Binder, and not cheap) and I wanted to make HuggingTweets accessible to everybody. Google Colab generously offers free GPU so is the perfect place to host the demo.
If you have any questions about using W&B to track your model performance and predictions, please reach out to the slack community.
I was able to make the first version of this program in just a few days.
It would not have been possible without these people and these open-source tools: