/** * Detect commands that are likely long-running servers, listeners, or * watch processes. These should be started as background jobs rather * than blocking the REPL. */ export declare function looksLikeOneShotScaffolder(command: string): boolean; /** * Returns true if the command appears to be a long-running process that * should not block the foreground shell. This is a heuristic — false * negatives are safer than false positives. */ export declare function looksLongRunning(command: string): boolean; export declare function looksLikeLongFiniteCommand(command: string): boolean; /** * Cost signals that make a finite command worth running as a durable job. * The binary name alone is NOT enough: `nmap -p22 host`, `sqlmap --version`, * and `find . -name '*.ts'` all finish in seconds and their output is needed in * the same turn, while `nmap -p- 10.0.0.0/24`, `ffuf -w big.txt`, and * `find / -name id_rsa` genuinely take minutes. Decisions are made from parsed * argv (flags, port specs, target shape), never from prompt wording. */ export declare function longFiniteCommandCost(command: string): { reason: string | undefined; }; export interface ShellExecBackgroundPolicy { readonly backgroundMode: "auto" | "never" | "always"; readonly costReason: string | undefined; readonly persistent: boolean; readonly wantsBackground: boolean; readonly responder: boolean; } /** Single ownership policy shared by pre-dispatch planning and tool runtime. */ export declare function resolveShellExecBackgroundPolicy(input: { command: string; background?: unknown; responder?: unknown; }): ShellExecBackgroundPolicy;