/** * redactRationale — scrub PII / secrets from judge rationale strings before * persistence. * * SLICE-101 (FEAT-183 S5b). Judges occasionally echo input fixtures back * into rationale text. When those fixtures contain secrets (API keys, * tokens, emails), the rationale leaks them into the trial corpus. This * helper applies a conservative pattern-set BEFORE the trial is written * to the store. * * Patterns intentionally tuned for high precision (avoid corrupting valid * rationale prose). Recall is secondary — the goal is to catch * obvious-shape leaks like `sk-...`, `ghp_...`, `eyJ...` JWTs, base64 * blobs over 40 chars, etc. Operators wanting stricter scrubbing supply * extra patterns via opts. */ export interface RedactRationaleOpts { /** Additional regex patterns to redact. Applied AFTER the built-ins. */ additional?: RegExp[]; /** Replacement string for matches. Default: "[REDACTED]". */ replacement?: string; } /** * Apply scrubbing patterns to `text` and return the redacted string. Pure * function — no side effects. Empty input returns empty string. */ export declare function redactRationale(text: string, opts?: RedactRationaleOpts): string; /** * Quick check: does the text appear to contain any secret-shape token? * Useful for asserting in tests that a fixture is clean before commit. */ export declare function containsSecretShape(text: string): boolean; //# sourceMappingURL=redact-rationale.d.ts.map