LogoAIAny
Icon for item

garak

Scans LLMs for security and safety failures — probing for hallucination, data leakage, prompt injection, jailbreaks, toxicity, and misinformation. A CLI red‑teaming kit that runs static, dynamic and adaptive probes across many providers and outputs structured JSONL reports.

Introduction

Most LLM assessments focus on performance or cost; garak takes the opposite approach: treat models like services you must adversarially test. Its core insight is that broad, repeatable red‑teaming — combining many small probes and detectors — reveals practical failure modes (injection, leakage, hallucination, toxicity) that single-shot tests miss. This makes it a practical toolkit for continuous safety checks and pre‑deployment audits.

What Sets It Apart
  • Focus on adversarial probing, not benchmarking. garak stitches together static, dynamic and adaptive probes (encoding attacks, prompt injection, DAN-style prompts, data‑replay checks, malware/code generation probes) so you get a diverse threat surface instead of a single metric — so what? you find classes of failure that realistic attackers might chain together.
  • Provider‑agnostic generator layer. Supports local and API models (Hugging Face, replicate, OpenAI, AWS Bedrock, gguf/llama.cpp, and REST endpoints) — so what? you can test the exact runtime stack you plan to deploy, not just a proxy model.
  • Structured, reproducible output and tooling. Runs as a CLI, logs detailed JSONL run reports and hit logs, and includes detectors/evaluators to triage results — so what? makes automated regression testing and audit trails straightforward for security teams.
  • Extensible plugin model. Probes, detectors, generators and harnesses are modular — so what? teams can add domain‑specific probes (e.g., industry prompts, private data patterns) without forking the core.
Who It's For and Trade-offs

Great fit if you are a security engineer, ML safety researcher, or dev team that needs repeatable red‑teaming of a deployed or prototype LLM. It’s particularly useful when you must test multiple providers or run continuous scans as part of CI/CD. Look elsewhere if you need a turnkey GUI product, a hosted SaaS with managed scans, or a lightweight unit test harness — garak is a command‑line, research‑oriented kit that expects integration effort and security expertise to interpret and act on findings.

Where It Fits

Use garak as part of pre‑deployment safety checks, CI gates, or periodic security audits. It complements adversarial training, prompt engineering, and guardrails by exposing concrete weaknesses you can prioritize and fix. While it surfaces many classes of failure, remediation still requires model/provider controls, prompt hardening, or engineering changes downstream.

Information

  • Websitegithub.com
  • AuthorsLeon Derczynski, Erick Galinkin, Jeffrey Martin, Subho Majumdar, Nanna Inie, NVIDIA
  • Published date2023/05/10

Categories