Toolverse
All skills

llamaguard

by davila7

Meta's 7-8B specialized moderation model for LLM input/output filtering. 6 safety categories - violence/hate, sexual content, weapons, substances, self-harm, criminal planning. 94-95% accuracy. Deploy with vLLM, HuggingFace, Sagemaker. Integrates with NeMo Guardrails.

Installation

Pick a client and clone the repository into its skills directory.

Installation

Quick info

Author
davila7
Category
Security
Views
2

About this skill

Meta's 7-8B specialized moderation model for LLM input/output filtering. 6 safety categories - violence/hate, sexual content, weapons, substances, self-harm, criminal planning. 94-95% accuracy. Deploy with vLLM, HuggingFace, Sagemaker. Integrates with NeMo Guardrails.

How to use

  1. Zainstaluj wymagane biblioteki: uruchom pip install transformers torch, a następnie zaloguj się do HuggingFace za pomocą huggingface-cli login – dostęp do modelu Meta wymaga autoryzacji.

  2. Zaimportuj model i tokenizer w swoim skrypcie Pythona: użyj AutoTokenizer i AutoModelForCausalLM z biblioteki transformers, wskazując model-id "meta-llama/LlamaGuard-7b" i ustawiając device_map="auto" dla automatycznego przydzielenia GPU.

  3. Zdefiniuj funkcję moderacji, która przyjmuje wiadomość użytkownika, konwertuje ją do tokenów za pomocą apply_chat_template, generuje klasyfikację modelem i dekoduje wynik – model zwraca "unsafe" lub "safe" wraz z kodem kategorii (np. "S3" dla planowania przestępstw).

  4. Sprawdzaj bezpieczeństwo wejścia przed wysłaniem do głównego chatbota: wywołaj funkcję moderacji na wiadomości użytkownika, a jeśli wynik zaczyna się od "unsafe", zablokuj żądanie i zwróć błąd – w przeciwnym razie pozwól na przetworzenie.

  5. Opcjonalnie zintegruj z NeMo Guardrails, aby osadzić LlamaGuard w szerszym systemie bezpieczeństwa i automatyzować przepływ kontroli treści w całej aplikacji.

Related skills

qmd

by tobi

Search personal markdown knowledge bases, notes, meeting transcripts, and documentation using QMD - a local hybrid search engine. Combines BM25 keyword search, vector semantic search, and LLM re-ranking. Use when users ask to search notes, find documents, look up information in

Security
1951

senior-security

by davila7

Comprehensive security engineering skill for application security, penetration testing, security architecture, and compliance auditing. Includes security assessment tools, threat modeling, crypto implementation, and security automation. Use when designing security architecture,

Security
2482

youtube-watcher

by openclaw

Fetch and read transcripts from YouTube videos. Use when you need to summarize a video, answer questions about its content, or extract information from it.

Security
2231

1password

by openclaw

Set up and use 1Password CLI (op). Use when installing the CLI, enabling desktop app integration, signing in (single or multi-account), or reading/injecting/running secrets via op.

Security
1174

llama-cpp

by zechenzhangAGI

Runs LLM inference on CPU, Apple Silicon, and consumer GPUs without NVIDIA hardware. Use for edge deployment, M1/M2/M3 Macs, AMD/Intel GPUs, or when CUDA is unavailable. Supports GGUF quantization (1.5-8 bit) for reduced memory and 4-10× speedup vs PyTorch on CPU.

Security
11252

backend-security-coder

by sickn33

Expert in secure backend coding practices specializing in input validation, authentication, and API security. Use PROACTIVELY for backend security implementations or security code reviews.

Security
1133