agentskit.js

ObserverRedactionMode

Auto-generated API reference for ObserverRedactionMode.

Type Alias: ObserverRedactionMode

ObserverRedactionMode = "redact" | "tokenize"

Defined in: observability/src/redaction.ts:26

Wrap any Observer so PII is redacted (or tokenized) in event payloads before they hit the underlying sink. Without this, even with send-side redaction in place, sensitive data leaks through Langfuse / Braintrust / local trace storage / replay snapshots.

The wrapper edits content fields only (llm:end.content, tool:start.args, tool:end.result, agent:delegate:end.result). It deliberately does NOT touch numeric / structural fields like usage, durationMs, messageCount, latencyMs, step β€” those carry no PII risk and breaking their numeric type would corrupt downstream dashboards.

Closes issue #792.

Explore nearby

✎ Edit this page on GitHubΒ·Found a problem? Open an issue β†’Β·How to contribute β†’

On this page