Files
wehub-resource-sync 0d3cb498a3
CI / Shell Format Check (push) Has been cancelled
CI / Check Ruby (3.4) (push) Has been cancelled
CI / CI Config (push) Has been cancelled
CI / Test on Node ${{ matrix.node }} and ${{ matrix.os }}${{ matrix.shard && format(' (shard {0}/3)', matrix.shard) || '' }} (push) Has been cancelled
CI / Build on Node ${{ matrix.node }} (push) Has been cancelled
CI / Style Check (push) Has been cancelled
CI / Generate Assets (push) Has been cancelled
CI / Check Python (3.14) (push) Has been cancelled
CI / Check Python (3.9) (push) Has been cancelled
CI / Build Docs (push) Has been cancelled
CI / Code Scan Action (push) Has been cancelled
CI / Site tests (push) Has been cancelled
CI / webui tests (push) Has been cancelled
CI / Run Integration Tests (push) Has been cancelled
CI / Run Smoke Tests (push) Has been cancelled
CI / Go Tests (push) Has been cancelled
CI / Share Test (push) Has been cancelled
CI / Redteam (Production API) (push) Has been cancelled
CI / Redteam (Staging API) (push) Has been cancelled
CI / GitHub Actions Lint (push) Has been cancelled
CI / Check Ruby (3.0) (push) Has been cancelled
release-please / release-please (push) Has been cancelled
release-please / build (push) Has been cancelled
release-please / publish-npm (push) Has been cancelled
release-please / publish-npm-backfill (push) Has been cancelled
release-please / docker (push) Has been cancelled
release-please / publish-code-scan-action (push) Has been cancelled
release-please / attest-code-scan-action (push) Has been cancelled
Deploy local.promptfoo.app / Deploy to Cloudflare Pages (push) Has been cancelled
Test and Publish Multi-arch Docker Image / test (push) Has been cancelled
Test and Publish Multi-arch Docker Image / build-docker-and-push-digests (map[digest-suffix:linux-amd64 platform:linux/amd64 runner:ubuntu-latest]) (push) Has been cancelled
Test and Publish Multi-arch Docker Image / build-docker-and-push-digests (map[digest-suffix:linux-arm64 platform:linux/arm64 runner:ubuntu-24.04-arm]) (push) Has been cancelled
Test and Publish Multi-arch Docker Image / merge-docker-digests (push) Has been cancelled
Test and Publish Multi-arch Docker Image / Attest Multi-arch Image (push) Has been cancelled
Validate Renovate Config / Validate Renovate Configuration (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 13:24:08 +08:00

8.0 KiB

title, sidebar_label, description
title sidebar_label description
Data Handling and Privacy Data handling Understand what data promptfoo transmits during red team testing and how to configure privacy settings.

Data Handling and Privacy

This page explains what data leaves your machine during red team testing and how to control it.

Data Flow Overview

Red team testing involves three distinct operations, each with different data requirements:

Operation What Runs Data Sent Externally
Target evaluation Always local Only to your configured LLM provider
Test generation Local or remote Depends on configuration (see below)
Result grading Local or remote Depends on configuration (see below)

Your target model is always evaluated locally. Promptfoo receives target responses only when you use a hosted flow that requires them, such as remote grading or red team target discovery.

Default Behavior (No API Key)

Without an OPENAI_API_KEY or a usable Codex/ChatGPT login, Promptfoo uses hosted inference for test generation and grading. The following data is sent to api.promptfoo.app:

For test generation:

  • Application purpose (from your config's purpose field)
  • Plugin configuration and settings
  • Complete document contents and the requested goal when using promptfoo redteam poison — this command always uses hosted generation, even when your own API key is configured
  • Red team target/provider setup details, including request examples, target URLs, and auth headers entered into setup or test forms
  • Your email (for usage tracking)

For grading:

  • The prompt sent to your target
  • Your target's response
  • Grading criteria

Not sent by default during generation/grading:

  • API keys or credentials stored in local environment variables
  • Model weights or training data
  • Files from your filesystem (unless explicitly configured in prompts)

Credentials, authorization headers, provider config fields, and request examples are sent if you paste them into red team target/provider setup or test forms, sharing, Cloud sync, or other Cloud-backed features. Don't enter real secrets into those flows. See the security policy for the full hosted-feature list.

With Your Own API Key

Setting OPENAI_API_KEY routes generation and grading through your OpenAI account instead of Promptfoo servers:

export OPENAI_API_KEY=sk-...

Or configure a different provider for grading:

redteam:
  provider: anthropic:messages:claude-sonnet-4-20250514

With this configuration, Promptfoo servers usually receive only telemetry unless you use red team target/provider setup helpers, red team target/provider test requests, sharing, Cloud sync, hosted reports, or other Cloud-backed features.

With Your ChatGPT Subscription

If Codex is installed and signed in with ChatGPT, Promptfoo can use openai:codex-sdk locally for default text generation and grading when no higher-priority API credentials are configured. Remote-only plugins still use hosted inference, and embedding/moderation assertions still require a provider override with API credentials.

Remote-Only Plugins

Some plugins require Promptfoo's hosted inference and cannot run locally. These are marked with 🌐 in the plugin documentation.

Remote-only plugins include:

  • Harmful content plugins (harmful:*)
  • Bias plugins
  • Domain-specific plugins (medical, financial, insurance, pharmacy, ecommerce)
  • Security plugins: ssrf, bola, bfla, indirect-prompt-injection, ascii-smuggling
  • Others: competitors, hijacking, off-topic, system-prompt-override

Remote-only strategies include: audio, citation, gcg, goat, jailbreak:composite, jailbreak:hydra, jailbreak:likert, jailbreak:meta

Disabling Remote Generation

To prefer local generation:

export PROMPTFOO_DISABLE_REMOTE_GENERATION=true

This disables supported remote-generation fallbacks for red team generation paths, including red team target/provider setup helpers that rely on remote generation. It is not a network isolation guarantee and does not disable telemetry, account/license checks, sharing, Cloud sync, red team target/provider test requests, red team target/provider setup helpers that do not rely on remote generation, or explicitly configured providers. You must provide your own OPENAI_API_KEY or configure a local model for generation and grading.

For red-team-specific control (keeps SimulatedUser remote generation enabled):

export PROMPTFOO_DISABLE_REDTEAM_REMOTE_GENERATION=true

See Configuring Inference for detailed setup.

Telemetry

Promptfoo collects usage telemetry:

  • Commands run (redteam generate, redteam run, etc.)
  • Plugin and strategy types used (not content)
  • Assertion types

Hosted telemetry may include package version, CI status, promptfoo user ID, email address, cloud login status, and authentication method when those values are present in the local promptfoo config. Prompt content, model responses, generated test cases, provider API keys, and full configuration files are not included.

To disable:

export PROMPTFOO_DISABLE_TELEMETRY=1

See Telemetry Configuration for details.

Network Requirements

When using remote generation, Promptfoo requires access to:

Domain Purpose
api.promptfoo.app Test generation and grading
api.promptfoo.dev Consent tracking for harmful plugins
a.promptfoo.app Telemetry (PostHog)

If blocked by your firewall, see Remote Generation Troubleshooting.

Enterprise Deployment

For organizations requiring complete network isolation:

Promptfoo Enterprise On-Prem provides:

  • Dedicated runner within your network perimeter
  • Full air-gapped operation
  • Self-hosted inference for all plugins
  • No data transmission to external servers

See the Enterprise Overview for deployment options.

Configuration Summary

Requirement Configuration
No data to Promptfoo servers Use API-key/local providers for every generation, grading, embedding, and moderation path; avoid remote-only plugins, red team target/provider setup helpers, and red team target/provider test requests; disable telemetry; avoid Cloud sync and sharing
Local generation only Set PROMPTFOO_DISABLE_REMOTE_GENERATION=true + configure local providers for supported generation paths
Air-gapped deployment Use Enterprise On-Prem