Instructions to use LibrAI/longformer-harmful-ro with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use LibrAI/longformer-harmful-ro with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="LibrAI/longformer-harmful-ro")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("LibrAI/longformer-harmful-ro") model = AutoModelForSequenceClassification.from_pretrained("LibrAI/longformer-harmful-ro") - Notebooks
- Google Colab
- Kaggle
Instruction-response formatting missing
Hi! The ablation study in the original paper proposing this classifier (https://arxiv.org/pdf/2308.13387) describes the performance gains from adding instruction to the classifier input (E Ablation Study Results), but doesn't describe the format used for joining instruction and response. What is the formatting used to acquire such gains described in this ablation study?
Moreover, the classifier seems to be trained on instruction-response pairs (Section 6.1: "Specifically, we fine-tune a PLM classifier over human annotations for each instruction–response pair, and use its predictions as the evaluation score."). Is the formatting of this pair identical to that used in the ablation study, and if not, what is its format?
Thanks in advance!
i also have the question