examples/redteam-ollama/README.md
You can run this example with:
npx promptfoo@latest init --example redteam-ollama
cd redteam-ollama
This example shows how to red team an Ollama model using promptfoo. For a detailed walkthrough, see the blog post.
# On macOS/Linux
ollama serve
# On Windows
# Run Ollama from the installed application
ollama pull llama3.2
# Verify the model is working:
ollama run llama3.2 "Hello, how are you?"
npx promptfoo@latest redteam run
npx promptfoo@latest redteam report
The report will show vulnerability categories discovered, severity levels, specific test cases that exposed issues, and suggested mitigations. See the blog post for example reports and screenshots.
The promptfooconfig.yaml file configures:
This example tests for various vulnerabilities (see full list):
Based on your test results, consider:
For more details, see: