/** * Byte budgets for every untrusted input injected into the system prompt or * tool definitions (fx-pattern). Skills, MCP tool descriptions and promoted * MCP schemas are attacker-controllable content a hostile skill file or MCP * server can bloat without limit; these caps bound both per-request token cost * and the prompt-injection surface. All values are user-tunable via the * `contextLimits` setting. */ export interface ContextLimits { /** One skill's `description` as listed in the prompt / skill tool. */ skillDescriptionBytes: number; /** Whole rendered skills list (prompt section + skill tool description). */ skillCatalogBytes: number; /** One MCP tool's `description` while it sits in the deferred catalog. */ mcpToolDescriptionBytes: number; /** A promoted MCP tool's serialized input schema. Oversized = refused. */ mcpToolSchemaBytes: number; /** Combined project instruction files (AGENTS.md etc.) — Codex default. */ projectContextBytes: number; /** Emergency ceiling on the fully assembled system prompt. */ systemPromptCeilingBytes: number; } export declare const CONTEXT_LIMITS: ContextLimits; export declare function resolveContextLimits(overrides?: Partial): ContextLimits; export interface ClampedText { text: string; truncated: boolean; originalBytes: number; } /** * Cut `text` to at most `maxBytes` of UTF-8 on a codepoint boundary (never * splits a surrogate pair), appending an ellipsis when truncation happened. */ export declare function clampToBytes(text: string, maxBytes: number): ClampedText; //# sourceMappingURL=context-limits.d.ts.map