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

pipe = pipeline("text-classification", model="MattStammers/Covid19_Text_Model")
# Load model directly
from transformers import AutoTokenizer, AutoModelForSequenceClassification

tokenizer = AutoTokenizer.from_pretrained("MattStammers/Covid19_Text_Model")
model = AutoModelForSequenceClassification.from_pretrained("MattStammers/Covid19_Text_Model")
Quick Links

This is a basic inference BERT model which has been fine-tuned to discriminate between covid19 and non-covid-19 relevant texts.

Unlike past models I have created this one raw and uploaded it as a standalone git repo to experiment with upload options. Not as streamlined as using the Huggingface card generation system but definitely simpler to do.

This is also my first experiment with ONNX.

Training data can be obtained as follows:

import pandas as pd

training_data = pd.read_csv("https://thigm85.github.io/data/cord19/cord19-query-title-label.csv")
training_data.head()

Please do not use this for any clinical/applied purpose. It is a toy app only.

Downloads last month
2
Inference Examples
Examples
Covid-19-article
0.600
Non-Covid-19-article
0.400
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support