The ai-blackteam sweep command runs every registered attack against every provider that has an API key configured. One command, complete coverage.

Running a sweep

ai-blackteam auto-detects which providers have API keys set (either in config or environment variables) and runs all attacks against each one.

What it does

  1. Checks which providers have API keys configured
  2. For each provider, runs every registered attack technique
  3. Shows per-provider results as they complete
  4. Prints a summary table at the end

Example output

Options

Auto-detection

ai-blackteam looks at your config file (~/.ai-blackteam/config.yaml) for providers with API keys. It also checks for ollama which doesn’t need a key. If no providers are configured:

Exit codes

  • 0 - all attacks blocked across all providers
  • 1 - at least one attack bypassed on any provider
  • 2 - no providers configured

When to use sweep vs benchmark

Sweep runs the same attacks with the same target against all providers. It’s a quick comparison - “how do these models handle this specific target?” Benchmark runs a curated set of targets across multiple harm categories and produces a scored evaluation. It’s more comprehensive and gives you a per-category breakdown. Use sweep for quick comparisons. Use benchmark for formal evaluations.