Hi, I’m trying to use pipelines for natural-language inference, but can’t figure out how to pass a pair of strings properly. This is what I’m trying:
from transformers import pipeline
pipe = pipeline("text-classification", model="typeform/distilbert-base-uncased-mnli")
but I think it’s just running individual samples through the model in some incorrect way (as opposed to combining them into a (premise, hypothesis) pair):
pipe(["This man is walking in a park", "the man is not in the park"], padding=True)
[{'label': 'CONTRADICTION', 'score': 0.9903815388679504},
{'label': 'ENTAILMENT', 'score': 0.9158636927604675}]