How to use from the
Use from the
Transformers library
# Use a pipeline as a high-level helper
from transformers import pipeline

pipe = pipeline("fill-mask", model="kornosk/polibertweet-political-twitter-roberta-mlm-small")
# pip install -U transformers accelerate
# Load model directly
from transformers import AutoTokenizer, AutoModelForMaskedLM

tokenizer = AutoTokenizer.from_pretrained("kornosk/polibertweet-political-twitter-roberta-mlm-small")
model = AutoModelForMaskedLM.from_pretrained("kornosk/polibertweet-political-twitter-roberta-mlm-small", device_map="auto")
Quick Links

This version is trained on a smaller data set.

See the full-size version at PoliBERTweet.

Citation

@inproceedings{kawintiranon2022polibertweet,
  title     = {PoliBERTweet: A Pre-trained Language Model for Analyzing Political Content on Twitter},
  author    = {Kawintiranon, Kornraphop and Singh, Lisa},
  booktitle = {Proceedings of the Language Resources and Evaluation Conference},
  year      = {2022},
  publisher = {European Language Resources Association}
}
Downloads last month
8
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support