Most of TweetNLP stems from previous research projects summarised below and described in the following article:

“TweetNLP: Cutting-Edge Natural Language Processing for Social Media” (arXiv)

If you use TweetNLP in your own projects, we would ask you to cite the reference paper above and/or any of the most relevant projects below.

TweetNLP Python library:

This website is powered by TweetNLP , a very simple Python library that enables us to use cutting-edge NLP models specialised on social media with a single line of code!

First, install the library with:

pip install tweetnlp

Then, predict the sentiment of a given sentence/tweet as simple as:

import tweetnlp
                        model = tweetnlp.load('sentiment')
                        model.sentiment("How many more days until opening day? 😩")
                    

For more details, go to the github repo or the tutorial section that includes more detailed Colab Notebooks with many examples.

Github repositories and references:

For more details about individual resources comprising TweetNLP, please check out the following research projects:

  • XLM-T: Multilingual language models and sentiment analysis benchmark. Published in LREC 2022.

  • TimeLMs: Language models that have been trained on social media for different time periods since 2019. Published in ACL Demo 2022.

  • T-NER: Easy-to-use library for transformer-based named entity recognition. Published in EACL Demo 2021.

NLP Models:

TweetNLP is powered by last-generation transformer-based language models. All language models used in this website are stored in the Cardiff NLP Hugging Face hub. In particular, these are the direct link to the task-specific NLP models in Hugging Face:

Word Embedding Models: NLP Datasets: Funding:

This project was partially funded by the UKRI Future Leaders Fellowship of Jose Camacho Collados, Snap and an “Innovation for All” scheme at Cardiff University.