Text Classification
Transformers
Safetensors
qwen3
content-safety
prompt-injection
multi-label-classification
safety
multilingual
hikmaai
Instructions to use HikmaAI/HikmaGuard with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use HikmaAI/HikmaGuard with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="HikmaAI/HikmaGuard")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("HikmaAI/HikmaGuard") model = AutoModelForSequenceClassification.from_pretrained("HikmaAI/HikmaGuard", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download config.json from HikmaAI/HikmaGuard: direct link, hf CLI and curl.
- Browser
- Download file 2.16 kB
-
https://huggingface.co/HikmaAI/HikmaGuard/resolve/main/config.json
- Command line
-
hf download hf://HikmaAI/HikmaGuard/config.json
-
curl -L -o config.json https://huggingface.co/HikmaAI/HikmaGuard/resolve/main/config.json
2.16 kB
| { | |
| "architectures": [ | |
| "Qwen3ForSequenceClassification" | |
| ], | |
| "attention_bias": false, | |
| "attention_dropout": 0.0, | |
| "bos_token_id": 151643, | |
| "dtype": "bfloat16", | |
| "eos_token_id": 151645, | |
| "head_dim": 128, | |
| "hidden_act": "silu", | |
| "hidden_size": 2560, | |
| "hikma_artifact_id": "d21042f88a814cc19011421f0cf972be", | |
| "id2label": { | |
| "0": "hate", | |
| "1": "abuse", | |
| "2": "violence", | |
| "3": "self_harm", | |
| "4": "sexual_harm", | |
| "5": "misconduct", | |
| "6": "dangerous_capability", | |
| "7": "prompt_injection", | |
| "8": "indirect_prompt_injection" | |
| }, | |
| "initializer_range": 0.02, | |
| "intermediate_size": 9728, | |
| "label2id": { | |
| "abuse": 1, | |
| "dangerous_capability": 6, | |
| "hate": 0, | |
| "indirect_prompt_injection": 8, | |
| "misconduct": 5, | |
| "prompt_injection": 7, | |
| "self_harm": 3, | |
| "sexual_harm": 4, | |
| "violence": 2 | |
| }, | |
| "layer_types": [ | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention", | |
| "full_attention" | |
| ], | |
| "max_position_embeddings": 32768, | |
| "max_window_layers": 36, | |
| "model_type": "qwen3", | |
| "num_attention_heads": 32, | |
| "num_hidden_layers": 36, | |
| "num_key_value_heads": 8, | |
| "pad_token_id": 151643, | |
| "problem_type": "multi_label_classification", | |
| "rms_norm_eps": 1e-06, | |
| "rope_scaling": null, | |
| "rope_theta": 1000000, | |
| "sliding_window": null, | |
| "tie_word_embeddings": true, | |
| "transformers_version": "4.57.6", | |
| "use_cache": false, | |
| "use_sliding_window": false, | |
| "vocab_size": 151936 | |
| } | |