--- license: mit pipeline_tag: text-classification --- # Roberta-Fact-Check Model The Roberta-Fact-Check Model is a deep learning model that uses the Roberta architecture for text classification. It is designed to classify claims as either supported or refuted based on the provided evidence. ## Model Training The model was trained using the Adam optimizer with a learning rate of 2-4e, epsilon of 1-8, and weight decay of 2-8e. The training dataset mainly consisted of the FEVER and Hover datasets, along with a small sample of manually created data. ## Input and Output The model takes a claim and corresponding evidence as input and returns a label indicating whether the evidence supports or refutes the claim. The two possible labels are: - 0: Supports - 1: Refutes ## Usage To use the Roberta-Fact-Check Model, you can simply pass in a claim and evidence as input to the model and receive a label indicating whether the evidence supports or refutes the claim. The model can be integrated into various applications for fact-checking and misinformation detection. ```python import torch from transformers import RobertaTokenizer, RobertaForSequenceClassification # Load the tokenizer and model tokenizer = RobertaTokenizer.from_pretrained('Dzeniks/roberta-fact-check') model = RobertaForSequenceClassification.from_pretrained('Dzeniks/roberta-fact-check') # Define the claim with evidence to classify claim = "Albert Einstein work in the field of computer science" evidence = "Albert Einstein was a German-born theoretical physicist, widely acknowledged to be one of the greatest and most influential physicists of all time." # Tokenize the claim with evidence x = tokenizer.encode_plus(claim, evidence, return_tensors="pt") model.eval() with torch.no_grad(): prediction = model(**x) label = torch.argmax(prediction[0]).item() print(f"Label: {label}") ``` ## Acknowledgements This model was developed using the Hugging Face transformers library and trained on the FEVER and Hover datasets. We would like to thank the developers of these datasets for their contributions to the community. ## Disclaimer While the Roberta-Fact-Check Model has been trained on a large dataset and can provide accurate results in many cases, it may not always provide correct results. Users should always exercise caution when making decisions based on the output of any machine learning model.