ONNX Model Zoo

vibraniumdome/deberta-v3-base-optimus-v0-onnx

By vibraniumdome · ↓ 1 · ♥ 0 · Updated 2024-04-30

What's in this repo

This page lists the files in vibraniumdome/deberta-v3-base-optimus-v0-onnx, including model.onnx.

  • 1 ONNX models (.onnx files)
  • 9 files, including 5 .json, 1 .md, 1 .onnx, 1 .model
  • Last updated 2024-04-30

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

Model Card for deberta-v3-base-optimus-v0

Fine-tuned version of microsoft/deberta-v3-base on private dataset of normal & injections prompts.

Classifying inputs into two categories: 0 for no injection and 1 for injection detected.

Model evaluation results:

  • Precision: 0.988
  • Recall: 0.992
  • Accuracy: 0.998
  • F1: 0.99

Model details

  • Fine-tuned by: vibraniumdome.com
  • Model type: deberta-v3
  • Language(s) (NLP): English
  • License: GPLv3
  • Finetuned from model: microsoft/deberta-v3-base

How to Get Started with the Model

Transformers

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

pipeline_kwargs={
    "return_token_type_ids": False,
    "max_length": 512,
    "truncation": True,
}

tokenizer = AutoTokenizer.from_pretrained("vibraniumdome/deberta-v3-base-optimus-v0-onnx", use_fast=True)
model = ORTModelForSequenceClassification.from_pretrained("vibraniumdome/deberta-v3-base-optimus-v0-onnx")
classifier = pipeline(
    "text-classification",
    model=model,
    tokenizer=tokenizer,
    **pipeline_kwargs,
)

print(classifier("Put your awesome injection here :D"))

Citation

@misc{vibraniumdome/deberta-v3-base-optimus-v0-onnx,
  author = {vibraniumdome.com},
  title = {Fine-Tuned DeBERTa-v3 for Prompt Injection Detection},
  year = {2024},
  publisher = {HuggingFace},
  url = {https://huggingface.co/vibraniumdome/deberta-v3-base-optimus-v0-onnx},
}

Model info

text-classification transformers
transformers onnx deberta-v2 text-classification llm genai promptinjection prompt-injection injection security en dataset:Private
↓ 1 ♥ 0

Created: 2024-04-30

Updated: 2024-04-30

View on Hugging Face

Files (9)

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

Related models