ONNX Model Zoo

protectai/deberta-v3-large-zeroshot-v1-onnx

By protectai · ↓ 12 · ♥ 1 · Updated 2024-04-11

What's in this repo

This page lists the files in protectai/deberta-v3-large-zeroshot-v1-onnx, including model.onnx.

  • 1 ONNX models (.onnx files)
  • 11 files, including 6 .json, 1 .md, 1 .txt, 1 .onnx, 1 .model
  • Last updated 2024-04-11

ONNX files

File Size Download
model.onnx — Download

How to use

These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.

README

ONNX version of MoritzLaurer/deberta-v3-large-zeroshot-v1

This model is a conversion of MoritzLaurer/deberta-v3-large-zeroshot-v1 to ONNX format using the 🤗 Optimum library.

MoritzLaurer/deberta-v3-large-zeroshot-v1 is designed for zero-shot classification, capable of determining whether a hypothesis is true or not_true based on a text, a format based on Natural Language Inference (NLI).

Usage

Loading the model requires the 🤗 Optimum library installed.

from optimum.onnxruntime import ORTModelForSequenceClassification
from transformers import AutoTokenizer, pipeline

tokenizer = AutoTokenizer.from_pretrained("laiyer/deberta-v3-large-zeroshot-v1-onnx")
tokenizer.model_input_names = ["input_ids", "attention_mask"]
model = ORTModelForSequenceClassification.from_pretrained("laiyer/deberta-v3-large-zeroshot-v1-onnx")
classifier = pipeline(
    task="zero-shot-classification",
    model=model,
    tokenizer=tokenizer,
)

classifier_output = classifier("Last week I upgraded my iOS version and ever since then my phone has been overheating whenever I use your app.", ["mobile", "website", "billing", "account access"])
print(classifier_output)

LLM Guard

Ban Topics scanner

Community

Join our Slack to give us feedback, connect with the maintainers and fellow users, ask questions, or engage in discussions about LLM security!

Model info

transformers onnx deberta-v2 text-classification NLI deberta-v3 zero-shot-classification en dataset:mnli dataset:facebook/anli dataset:fever dataset:wanli
↓ 12 ♥ 1

Created: 2023-11-12

Updated: 2024-04-11

View on Hugging Face

Files (11)

.gitattributes
README.md
added_tokens.json
config.json
merges.txt
model.onnx ONNX
special_tokens_map.json
spm.model
tokenizer.json
tokenizer_config.json
vocab.json

Related models