hate-speech / textclassifier.py
yohannesdesta's picture
setup
7d63c90
raw
history blame contribute delete
250 Bytes
class TextClassifier:
def __init__(self, model) -> None:
self.text_classifier = model
def classify(self,text):
data = self.text_classifier(text)[0]
print("response from hugging \n", data)
return data