@code-yeongyu/senpi
Version:
Coding agent CLI with read, bash, edit, write tools and session management
27 lines • 1.13 kB
TypeScript
import type { KillGuardVerdict, ProcessView } from "./types.ts";
/** A check a kernel sends over the codemode bridge: a shell string, a spawn argv, or a signal call. */
export type KillGuardRequest = {
readonly kind: "command";
readonly command: string;
readonly vantagePid?: number;
} | {
readonly kind: "argv";
readonly argv: readonly string[];
readonly vantagePid?: number;
} | {
readonly kind: "signal";
readonly target: number;
readonly group: boolean;
readonly signal: number | string | null;
readonly vantagePid?: number;
};
export interface KillGuardRequestOptions {
readonly agentPid: number;
readonly agentPpid?: number;
readonly platform?: string;
/** Defaults to the production view (`/proc` or `ps`, and `pgrep` for dry runs). */
readonly view?: () => ProcessView | undefined;
}
/** The host side of the kernel bridge's kill-guard check (E7, E8): decides one request from its kernel's vantage. */
export declare function decideKillGuardRequest(value: unknown, options: KillGuardRequestOptions): KillGuardVerdict;
//# sourceMappingURL=request.d.ts.map