Spaces:
Running
on
Zero
Running
on
Zero
Lord-Raven
commited on
Commit
·
55d9b22
1
Parent(s):
c44bdaf
Experimenting with few-shot classification.
Browse files
app.py
CHANGED
@@ -60,9 +60,9 @@ class OnnxSetFitModel:
|
|
60 |
# "Xenova/distilbert-base-uncased-mnli" "typeform/distilbert-base-uncased-mnli" Bad answers
|
61 |
# "Xenova/deBERTa-v3-base-mnli" "MoritzLaurer/DeBERTa-v3-base-mnli" Still a bit slow and not great answers
|
62 |
# "xenova/nli-deberta-v3-small" "cross-encoder/nli-deberta-v3-small" Was using this for a good while and it was...okay
|
63 |
-
model_name = "MoritzLaurer/
|
64 |
file_name = "onnx/model.onnx"
|
65 |
-
tokenizer_name = "MoritzLaurer/
|
66 |
model = ORTModelForSequenceClassification.from_pretrained(model_name, file_name=file_name)
|
67 |
tokenizer = AutoTokenizer.from_pretrained(tokenizer_name, model_max_length=512)
|
68 |
classifier = pipeline(task="zero-shot-classification", model=model, tokenizer=tokenizer)
|
|
|
60 |
# "Xenova/distilbert-base-uncased-mnli" "typeform/distilbert-base-uncased-mnli" Bad answers
|
61 |
# "Xenova/deBERTa-v3-base-mnli" "MoritzLaurer/DeBERTa-v3-base-mnli" Still a bit slow and not great answers
|
62 |
# "xenova/nli-deberta-v3-small" "cross-encoder/nli-deberta-v3-small" Was using this for a good while and it was...okay
|
63 |
+
model_name = "MoritzLaurer/deberta-v3-base-zeroshot-v2.0"
|
64 |
file_name = "onnx/model.onnx"
|
65 |
+
tokenizer_name = "MoritzLaurer/deberta-v3-base-zeroshot-v2.0"
|
66 |
model = ORTModelForSequenceClassification.from_pretrained(model_name, file_name=file_name)
|
67 |
tokenizer = AutoTokenizer.from_pretrained(tokenizer_name, model_max_length=512)
|
68 |
classifier = pipeline(task="zero-shot-classification", model=model, tokenizer=tokenizer)
|