# confident-ai/deepteam — AlpLab Radar Static Code Audit

- Ring: `trial`
- Category: `ai-models`
- Overall score: `3.6/5`
- Implementation check: `verified`
- Maturity: `mature`
- Audited commit: `850a147a4083` (read-only; nothing from the repository was executed)
- Reviewed at: 2026-12-02T10:04:29Z
- Repository: https://github.com/confident-ai/deepteam
- Radar entry: https://radar.alplab.co/#repo/confident-ai/deepteam
- License: `Apache-2.0`
- CI workflows: `.github/workflows`
- Tags: `llm-security`, `red-teaming`, `ai-evaluation`, `guardrails`, `prompt-injection`, `deepeval`

## Summary

LLM red-teaming framework: 20+ attack techniques vs 40+ vulnerability types, LLM-judge scoring, OWASP/NIST/MITRE mapping, guardrails, CLI and code scanner.

## Implementation Check

Claims match code: `RedTeamer.red_team`/`a_red_team` drive real attack simulation and judging; 41 vulnerabilities and 30+ attacks exist; only `deepteam login` (cli/main.py) is a stub.

## When to Use

Use to probe chatbots, agents and RAG pipelines for jailbreaks, PII leakage and injection before release, and to guard production I/O. For new projects prefer its successor deepeval.red_team (deprecated 2027-01-30).

## Sub-scores

| Dimension | Score |
|---|---|
| quality | 4.0/5 |
| usability | 4.0/5 |
| reliability | 3.0/5 |
| security | 3.0/5 |
| integration | 4.0/5 |

## Code Evidence

- deepteam/red_teamer/red_teamer.py `RedTeamer.red_team`/`a_red_team` simulate attacks, judge via metrics, aggregate CVSS risk assessments
- deepteam/vulnerabilities/__init__.py exports 41 vulnerability classes; attacks/ implements 26 single-turn and 5 multi-turn attacks
- deepteam/guardrails/guardrails.py `Guardrails.guard_input/guard_output` run 7 guards with deterministic sampling and breach verdicts
- deepteam/frameworks/utils.py `_get_owasp_vulnerabilities` maps OWASP/NIST/MITRE categories to concrete vulnerability and attack objects
- tests/test_guardrails/test_guardrails.py `TestSampleRateAccuracy` verifies 1000-request sampling math across 11 parametrized rates
- deepteam/cli/main.py typer `run`/`scan` commands support YAML configs, SARIF/JSON/markdown reports and git-diff scanning

## Issues Found

- deepteam/telemetry.py enables PostHog telemetry with a persistent UUID by default; opt-out only via DEEPTEAM_TELEMETRY_OPT_OUT=YES
- deepteam/cli/main.py `login()` is a stub printing a beta notice, though README and output prompts direct users to `deepteam login`
- Debug script a.py and deepteam/.DS_Store committed at repo root

## Key Risks

- Deprecated: package merges into deepeval.red_team and is scheduled for removal on 2027-01-30 (README warning banner)
- Needs an LLM API key (OpenAI by default); attack generation and all verdicts are LLM-as-judge, so results vary between runs
- 12 GitHub Actions pinned only to major tags (checkout@v3, setup-python@v4) across the three test workflows
- Risk assessments auto-upload to Confident AI and open a browser when logged in (red_teamer.py `_post_risk_assessment`)

## Reviewed Files

- `README.md`
- `pyproject.toml`
- `a.py`
- `deepteam/__init__.py`
- `deepteam/telemetry.py`
- `deepteam/red_team.py`
- `deepteam/red_teamer/red_teamer.py`
- `deepteam/vulnerabilities/__init__.py`
- `deepteam/metrics/__init__.py`
- `deepteam/guardrails/guardrails.py`
- `deepteam/guardrails/guards/base_guard.py`
- `deepteam/frameworks/utils.py`
- `deepteam/confident/api.py`
- `deepteam/cli/main.py`
- `deepteam/code_scanner/code_scanner.py`
- `deepteam/code_scanner/collect/git.py`
- `deepteam/orchestration/__init__.py`
- `deepteam/orchestration/orchestration_agent.py`
- `deepteam/orchestration/agentic_red_teamer.py`
- `deepteam/attacks/attack_engine/attack_engine.py`
- `tests/test_core/test_red_teaming.py`
- `tests/test_guardrails/test_guardrails.py`
