Text Classification
Transformers
Safetensors
English
distilbert
jailbreak-detection
prompt-safety
llm-security
classification
text-embeddings-inference
Instructions to use tech5/my-model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use tech5/my-model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="tech5/my-model")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("tech5/my-model") model = AutoModelForSequenceClassification.from_pretrained("tech5/my-model", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Upload DistilBertForSequenceClassification
Browse files- config.json +8 -0
config.json
CHANGED
|
@@ -10,7 +10,15 @@
|
|
| 10 |
"dtype": "float32",
|
| 11 |
"eos_token_id": null,
|
| 12 |
"hidden_dim": 3072,
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
"initializer_range": 0.02,
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
"max_position_embeddings": 512,
|
| 15 |
"model_type": "distilbert",
|
| 16 |
"n_heads": 12,
|
|
|
|
| 10 |
"dtype": "float32",
|
| 11 |
"eos_token_id": null,
|
| 12 |
"hidden_dim": 3072,
|
| 13 |
+
"id2label": {
|
| 14 |
+
"0": "benign",
|
| 15 |
+
"1": "jailbreak"
|
| 16 |
+
},
|
| 17 |
"initializer_range": 0.02,
|
| 18 |
+
"label2id": {
|
| 19 |
+
"benign": 0,
|
| 20 |
+
"jailbreak": 1
|
| 21 |
+
},
|
| 22 |
"max_position_embeddings": 512,
|
| 23 |
"model_type": "distilbert",
|
| 24 |
"n_heads": 12,
|