---
title: "AI Privacy & Capture"
description: "Control AI trace capture, exclusions, and limits so Blyp records only the content you explicitly allow."
canonical_url: "https://www.blyp.dev/docs/ai/privacy-and-capture"
markdown_url: "https://www.blyp.dev/docs/ai/privacy-and-capture.md"
last_updated: "1970-01-01"
x_farming_labs_generated_preamble: true
---

# AI Privacy & Capture
URL: /docs/ai/privacy-and-capture
LLM index: /llms.txt
Description: Control AI trace capture, exclusions, and limits so Blyp records only the content you explicitly allow.

# AI Privacy & Capture

Blyp AI tracing is intentionally conservative by default.

For native Cloudflare Agents events, use the [Cloudflare-specific capture controls](/docs/ai/cloudflare#capture-exclusions-and-redaction). That connector uses `capture.payload` and per-value byte limits; the model tracing options below apply to the other AI adapters.

Prompt text, outputs, reasoning, tool payloads, raw provider payloads, and detailed stream data are opt-in. The default trace focuses on provider, model, operation, usage, finish reason, timing, and best-effort tool metadata.

## Capture controls

Use `capture` to explicitly enable content recording:

```ts
import OpenAI from "openai";
import { wrapOpenAI } from "@blyp/core/ai/openai";

const openai = wrapOpenAI(
  new OpenAI({ apiKey: process.env.OPENAI_API_KEY }),
  {
    operation: "review_patch",
    capture: {
      input: true,
      output: true,
      toolInputs: false,
      toolOutputs: false,
      reasoning: false,
      streamEvents: false,
      streamChunks: false,
      rawProviderPayload: false,
    },
  }
);
```

Supported `capture` options:

- `capture.input`
- `capture.output`
- `capture.toolInputs`
- `capture.toolOutputs`
- `capture.reasoning`
- `capture.streamEvents`
- `capture.streamChunks`
- `capture.rawProviderPayload`

## Exclusions

Use `exclude` to remove selected fields even when capture is enabled:

```ts
const client = wrapOpenAI(new OpenAI({ apiKey: process.env.OPENAI_API_KEY }), {
  operation: "review_patch",
  capture: {
    input: true,
    output: true,
  },
  exclude: {
    providerOptions: true,
    requestPaths: ["input.0.content"],
    responsePaths: ["output_text"],
    metadataPaths: ["tenant.secret"],
    toolNames: ["internalAdminTool"],
  },
});
```

Supported `exclude` options:

- `exclude.providerOptions`
- `exclude.requestPaths`
- `exclude.responsePaths`
- `exclude.metadataPaths`
- `exclude.toolNames`

## Size and event limits

Use `limits` to bound what Blyp records:

```ts
const client = wrapOpenAI(new OpenAI({ apiKey: process.env.OPENAI_API_KEY }), {
  operation: "review_patch",
  limits: {
    maxContentBytes: 16_384,
    maxEvents: 100,
    maxToolCalls: 20,
  },
});
```

Supported `limits` options:

- `limits.maxContentBytes`
- `limits.maxEvents`
- `limits.maxToolCalls`

## Redaction still applies

Blyp redaction still runs across emitted log output, including AI traces. That helps with known sensitive keys and pattern scanning, but it is not a reason to over-capture prompts or model outputs.

Recommended default:

- keep AI content capture off unless a debugging workflow truly needs it
- enable only the specific fields needed for that workflow
- pair AI capture with `redact.keys`, `redact.paths`, or `redact.patterns` when your metadata contains tenant-specific secrets

See [Configuration](/docs/configuration) for the global `redact` config.

## Eve durable capture

[Eve tracing](/docs/ai/eve#privacy-and-durable-state) applies redaction, exclusions, and bounds before enabled content enters Eve's durable session state, then sanitizes it again for log emission. Content remains in that state until the turn ends and follows Eve's storage and retention policies. Raw provider payload capture is unavailable for the Eve hook.

## Sitemap

See the full [sitemap](/sitemap.md) for all pages.
Docs-scoped sitemap: [/docs/sitemap.md](/docs/sitemap.md).
Well-known sitemap: [/.well-known/sitemap.md](/.well-known/sitemap.md).
