promptfoo/promptfoo
Test your prompts, agents, and RAGs. Red teaming/pentesting/vulnerability scanning for AI. Compare performance of GPT, Claude, Gemini, DeepSeek, and more. Simple declarative configs with command line and CI/CD integration. Used by OpenAI and Anthropic.
What it solves
它取代了开发 LLM 应用时的试错方法,提供系统化的方式评估 Prompt 表现,并在上线前识别安全漏洞。
How it works
Promptfoo 是一个 CLI 与库,允许开发者运行自动化评估和红队演练。它支持对不同 Prompt 和模型(如 OpenAI、Anthropic、Azure、Bedrock、Ollama)进行并排比较,并可集成到 CI/CD 流程中,实现自动检查和代码扫描,以发现安全与合规问题。
Who it’s for
构建 LLM 驱动应用的开发者,需要确保 AI 应用在模型选择和 Prompt 工程上安全、可靠且数据驱动。
Highlights
- Automated Evaluations: 系统化测试 Prompt 与模型。
- Red Teaming: 扫描漏洞以保护 LLM 应用。
- Model Comparison: 并排比较多个 LLM 提供商。
- Developer-First: 包含实时重载、缓存和本地执行等隐私功能。
- CI/CD Integration: 通过代码扫描自动化检查并审查 Pull Request。