Instructions to use launch/POLITICS with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use launch/POLITICS with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="launch/POLITICS")# Load model directly from transformers import AutoTokenizer, AutoModelForMaskedLM tokenizer = AutoTokenizer.from_pretrained("launch/POLITICS") model = AutoModelForMaskedLM.from_pretrained("launch/POLITICS") - Notebooks
- Google Colab
- Kaggle
| language: | |
| - en | |
| tags: | |
| - politics | |
| - roberta | |
| license: | |
| - cc-by-nc-sa-4.0 | |
| ## POLITICS | |
| POLITICS, a pretrained model on English news articles of politics, is produced via continued training on RoBERTa, based on a **P**retraining **O**bjective **L**everaging **I**nter-article **T**riplet-loss using **I**deological **C**ontent and **S**tory. | |
| **ALERT:** POLITICS is a pre-trained **language model** that specializes in comprehending news articles and understanding ideological content. However, POLITICS cannot be used **out-of-the-box** on downstream tasks such as predicting ideological leanings and discerning stances expressed in texts. To perform predictions on downstream tasks, you are advised to **fine-tune** POLITICS on your own dataset first. | |
| Details of our proposed training objectives (i.e., Ideology-driven Pretraining Objectives) and experimental results of POLITICS can be found in our NAACL-2022 Findings [paper](https://aclanthology.org/2022.findings-naacl.101.pdf) and GitHub [Repo](https://github.com/launchnlp/POLITICS). | |
| Together with POLITICS, we also release our curated large-scale dataset (i.e., BIGNEWS) for pretraining, consisting of more than 3.6M political news articles. This asset can be requested [here](https://forms.gle/yRx5ANHKNuj1kgBDA). | |
| ## Citation | |
| Please cite our paper if you use the **POLITICS** model: | |
| ``` | |
| @inproceedings{liu-etal-2022-POLITICS, | |
| title = "POLITICS: Pretraining with Same-story Article Comparison for Ideology Prediction and Stance Detection", | |
| author = "Liu, Yujian and | |
| Zhang, Xinliang Frederick and | |
| Wegsman, David and | |
| Beauchamp, Nicholas and | |
| Wang, Lu" | |
| booktitle = "Findings of the Association for Computational Linguistics: NAACL 2022", | |
| year = "2022", | |
| ``` |