import { type HookGuardResult } from '../cli/commands/sub-agent-dispatch-guard.js'; /** * Read the prompt size from the LLM platform's hook stdin. Different * LLMs send different payload shapes; we accept the most common: * - Claude Code: `{"tool_name": "Bash", "tool_input": {"command": "..."}}` * - Trae: `{"tool_name": "terminal", "tool_input": {"command": "..."}}` * * The hook reads the `command` (or `prompt`) field and computes the * byte length. If neither field is present, returns 0 (always passes). */ export declare function readPromptSizeFromHookStdin(stdin: unknown): number; /** * Execute the hook guard via spawnSync. Returns the parsed result or * a fallback (allow: true) on subprocess failure. * * Prefer the in-process `evaluateHookGuard` (no subprocess) when the * hook is called from a TypeScript context. Use `runHookGuardSubprocess` * only when the hook needs to be invoked from a non-TypeScript caller * (e.g. a shell script that wraps the peaks CLI). */ export declare function runHookGuardSubprocess(prompt: string): HookGuardResult; /** * Main entry point for the hook. Reads the LLM platform's stdin, * computes the prompt size, and returns the guard result. Used by * the LLM platform's hook JSON to decide whether to allow the tool * call. */ export declare function runHookGuard(stdin: unknown): HookGuardResult;