Instructions to use SummerSigh/Safety-Policy-MiniLM with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use SummerSigh/Safety-Policy-MiniLM with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="SummerSigh/Safety-Policy-MiniLM")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("SummerSigh/Safety-Policy-MiniLM") model = AutoModelForSequenceClassification.from_pretrained("SummerSigh/Safety-Policy-MiniLM", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download tokenizer_config.json from SummerSigh/Safety-Policy-MiniLM: direct link, hf CLI and curl.
- Browser
- Download file 684 Bytes
-
https://huggingface.co/SummerSigh/Safety-Policy-MiniLM/resolve/main/tokenizer_config.json
- Command line
-
hf download hf://SummerSigh/Safety-Policy-MiniLM/tokenizer_config.json
-
curl -L -o tokenizer_config.json https://huggingface.co/SummerSigh/Safety-Policy-MiniLM/resolve/main/tokenizer_config.json
684 Bytes
| { | |
| "bos_token": "<s>", | |
| "cls_token": "<s>", | |
| "eos_token": "</s>", | |
| "mask_token": { | |
| "__type": "AddedToken", | |
| "content": "<mask>", | |
| "lstrip": true, | |
| "normalized": true, | |
| "rstrip": false, | |
| "single_word": false | |
| }, | |
| "max_length": 512, | |
| "model_max_length": 512, | |
| "name_or_path": "microsoft/Multilingual-MiniLM-L12-H384", | |
| "pad_token": "<pad>", | |
| "sep_token": "</s>", | |
| "sp_model_kwargs": {}, | |
| "special_tokens_map_file": "/root/.cache/huggingface/transformers/8ed73a1ab9ef4e90a9451497bf96cfc38d34354352838a143f2dda1c81aed5ca.0dc5b1041f62041ebbd23b1297f2f573769d5c97d8b7c28180ec86b8f6185aa8", | |
| "tokenizer_class": "XLMRobertaTokenizer", | |
| "unk_token": "<unk>" | |
| } | |