import type { AutoModeClassifyInput } from "./auto-mode.js"; import type { Message } from "../internal/llm.js"; /** The sentinel a deployment puts INSIDE a rule list to splice the CC default rules back in at that * position (CC `XYt = "$defaults"`). Without it, a non-empty user list REPLACES the default section. */ export declare const AUTO_MODE_DEFAULTS_SENTINEL = "$defaults"; /** Deployment-authored rule overrides for the four paired sections of the permissions document. * Each entry is ONE rule (rendered as a `- ` bullet); omit a field (or pass an empty array) to keep * the CC default rules for that section verbatim. */ export interface AutoModeRules { allow?: readonly string[]; softDeny?: readonly string[]; hardDeny?: readonly string[]; environment?: readonly string[]; } export interface BuildAutoModePromptOptions { rules?: AutoModeRules; /** Settings-plane deny rules (tool[/argument-pattern] strings) — rendered into the * `` slot as the CC circumvention-catching paragraph. */ settingsDenyRules?: readonly string[]; /** Extra session-context facts (e.g. the CC user-identity line) — appended as a * `## Session Context` bullet block after the assembled document. */ sessionContext?: readonly string[]; } /** * Assemble the classifier SYSTEM prompt (CC `KRg`, content-equivalent single string — CC splits the * session-context tail into a second uncached block purely as a prompt-cache optimization). * Every `.replace` uses the CALLBACK form: the assets and user rules are full of `$`-patterns * (`$USER/...`) that a string replacement would corrupt via `$&`/`$'` substitution (CC does the same). */ export declare function buildAutoModePrompt(options?: BuildAutoModePromptOptions): string; export interface AutoModeWindowOptions { /** Newest transcript entries included (default 40). */ maxEntries?: number; /** Per-entry excerpt cap in characters (default 2_000 — tool results and long turns are truncated * head-first with a `[… N chars truncated]` marker; the classifier weighs shape over bulk). */ maxCharsPerEntry?: number; } /** * Render the transcript window half of the classifier's user prompt: the newest `maxEntries` messages, * oldest→newest, each labeled by lane. Plain data — see the module header for the declared v1 gap vs * CC's entry-formatter stack. */ export declare function renderAutoModeWindow(messages: readonly Message[], options?: AutoModeWindowOptions): string; /** * Render the pending action (the classify subject). The 207 process's step 1 keys on "the last tool * call in the transcript" — this block IS that entry for our assembly, placed last in the user prompt. */ export declare function renderAutoModeAction(input: AutoModeClassifyInput): string; //# sourceMappingURL=auto-mode-prompt.d.ts.map