Promptfoo Studio
Continuous LLM vulnerability scanning with pre-built configurations for every SafeAI use case. Install once, run on every model update, runbook change, or system prompt revision.
Promptfoo covers 50+ vulnerability types — RAG poisoning, agentic trajectory assertions, MCP testing, and CI/CD-native regression baselines. Findings map automatically to OWASP LLM Top 10, NIST AI RMF, and EU AI Act. This page gives you ready-to-run configurations grounded in your TIVM framework.
Where Promptfoo fits alongside ALIGN and SafeAI
Risk quantification
TIVM model scores L × I × E. Promptfoo's bypass rates feed the Likelihood (L) variable — keeping the score current between manual ALIGN runs.
Deep adversarial testing
PAIR loop iterative attacks, interpretable chains, agent endpoint support. Manual, deliberate, audit-ready. Run on milestones.
Continuous assurance
Runs automatically in CI/CD. Catches regressions on every model update, tool change, or prompt revision. No manual trigger needed.
Your book's argument, operationalised
Red-teaming done quarterly is not behind — it is blind. Promptfoo is the engineering answer: scheduled scans that keep the TIVM Likelihood variable current between ALIGN sessions, so your risk score reflects today's model behaviour, not last month's manual test.
Install and initialise in three steps
Install Promptfoo
Set your API key
Pick a config below, save as promptfooconfig.yaml, then run
Pre-built configs for every SafeAI use case
Each config is tuned to the specific threat model. Replace YOUR_MODEL and the system prompt with your actual values. All configs use Claude as the judge for TIVM-aligned scoring.
AIOps agent configuration
Targets an AIOps agent that receives operational telemetry and can invoke infrastructure tools. Covers the highest-risk attack surfaces: RAG poisoning via log injection, SSRF via tool abuse, goal misalignment, and approval bypass.
Staging only
Point provider.config.url at your staging AIOps endpoint. Never run against production.
General LLM configuration
Broad coverage scan for any internal LLM deployment — copilots, knowledge assistants, drafting tools. Matches your SafeAI Risk Calculator's SL1–SL3 range. Fast to run, suitable for weekly CI/CD scheduling.
RAG system configuration
Targets systems that retrieve from a knowledge base before generating. The primary threat is poisoned documents producing authoritative-looking but malicious outputs. Run after every knowledge base update.
Trigger condition
Schedule this scan on every merge to your knowledge base repository, not just on model changes. A document update can introduce a new injection vector without touching the model at all.
Agentic system configuration
For any agent with tool access — MCP servers, API integrations, file system access. Uses Promptfoo's agent tracing to evaluate tool call trajectories, not just text output. Maps to L3–L5 of the ALIGN registry.
CI/CD pipeline configuration
Lightweight fast-running config designed for integration into GitHub Actions, GitLab CI, or any pipeline. Fails the build on UNSAFE verdicts. Produces OWASP/NIST compliance artifacts automatically.
Feeding Promptfoo results into SafeAI Risk Calculator
Promptfoo produces a JSON results file after every run. Extract these values and enter them into the SafeAI Risk Calculator to keep your TIVM score current.
Overall bypass rate from Promptfoo results. If 8 of 30 tests produced UNSAFE or BORDERLINE verdicts, set L input = 0.27.
Average TIVM-I score from judge verdicts across UNSAFE results. Promptfoo's Claude judge produces I scores directly when you use the TIVM rubric prompt.
Highest TIVM-E score across all results. The most exploitable finding defines your Exploitability variable — not the average.
Workflow: monthly ALIGN + weekly Promptfoo
Run ALIGN manually once a month for deep PAIR-loop adversarial testing and a full audit trail. Run Promptfoo automatically every week (or on every model/prompt change) to keep the TIVM L variable current. Feed both into the SafeAI Risk Calculator. Your risk score then reflects both deliberate red-teaming and continuous monitoring — which is what your book's assurance cycle prescribes.
Complete the SafeAI workbench
Assessment Workbench
Run the full TIVM risk score with your Promptfoo results as inputs.
SBOM Analysis
Inventory every model, dataset, and dependency before scanning.
ALIGN
Deep PAIR-loop adversarial testing with the 31-class Agent Risk Registry.
SL5 Compliance
Map scan results to SL0–SL5 control requirements and generate the gap report.