/** * Rejects @file references that resolve outside the working directory. * * The Gemini CLI inlines the contents of any `@path` token it finds in the * prompt. Because prompt text can originate from untrusted input, an * unrestricted reference such as `@/etc/passwd`, `@~/.ssh/id_rsa` or * `@../../secret` would let that input exfiltrate arbitrary local files * (CVE-2026-0755). Constraining references to the project root preserves the * legitimate `@file` feature while removing the exfiltration primitive. */ export declare function assertSafeFileReferences(prompt: string, root?: string): void; /** * Wraps a user request in the changeMode instruction template that makes the * model emit machine-applicable OLD/NEW edit blocks. The format is model- and * CLI-agnostic, so both the gemini and agy backends share this builder. */ export declare function buildChangeModePrompt(userRequest: string): string; /** * changeMode preprocessing shared by both backends: rewrite `file:foo` -> `@foo` * so the inlining/guard path treats them as file refs, then wrap the request in * the OLD/NEW template. One implementation so gemini and agy cannot drift. */ export declare function prepareChangeModePrompt(prompt: string): string; /** * Replaces every in-project `@path` reference with the file's contents inlined * in a delimited block. The Gemini CLI does this inlining itself; the agy * backend does NOT reliably inline `@file` (it is agent-first and decides to * read files via its own tools), so for agy we inline ourselves to keep both * determinism and the CVE-2026-0755 project-root guard in the data path. */ export declare function inlineFileReferences(prompt: string, root?: string): string; export declare function executeGeminiCLI(prompt: string, model?: string, sandbox?: boolean, changeMode?: boolean, onProgress?: (newOutput: string) => void): Promise; export declare function processChangeModeOutput(rawResult: string, chunkIndex?: number, chunkCacheKey?: string, prompt?: string): Promise; //# sourceMappingURL=geminiExecutor.d.ts.map