import type { Context, Message, Tool } from "@pk-nerdsaver-ai/pi-ai";
import type { SessionContext } from "../session/session-context";
export interface SecretEntry {
    type: "plain" | "regex";
    content: string;
    mode?: "obfuscate" | "replace";
    replacement?: string;
    flags?: string;
}
export declare class SecretObfuscator {
    #private;
    constructor(entries: SecretEntry[]);
    hasSecrets(): boolean;
    /** Obfuscate all secrets in text. Bidirectional placeholders for obfuscate mode, one-way for replace. */
    obfuscate(text: string): string;
    /** Deobfuscate obfuscate-mode placeholders back to original secrets. Replace-mode is NOT reversed. */
    deobfuscate(text: string): string;
    /** Deep-walk an object, deobfuscating all string values. */
    deobfuscateObject<T>(obj: T): T;
    /** Deep-walk an object, obfuscating all string values. */
    obfuscateObject<T>(obj: T): T;
}
export declare function deobfuscateSessionContext(sessionContext: SessionContext, obfuscator: SecretObfuscator | undefined): SessionContext;
/** Obfuscate all string content in LLM messages (for outbound interception). */
export declare function obfuscateMessages(obfuscator: SecretObfuscator, messages: Message[]): Message[];
/** Obfuscate provider request context without walking live tool schema instances. */
export declare function obfuscateProviderContext(obfuscator: SecretObfuscator | undefined, context: Context): Context;
/** Convert tool schemas to wire JSON Schema before obfuscating provider-visible strings. */
export declare function obfuscateProviderTools(obfuscator: SecretObfuscator | undefined, tools: Tool[] | undefined): Tool[] | undefined;
