Skip to main content
Version: 0.21.0

Function: createStepGate()

function createStepGate(
runDir,
isActive?,
selfAskingTools?
): HookCallback;

Defined in: core/hooks/stepGate.ts:17

PreToolUse hook for "interactive" mode: pauses before every action and asks for confirmation (by keyboard or by file, see humanInput.ts), like reviewing a plan step by step.

isActive lets one session switch between "guided" and "interactive" while it runs (see session.ts's ModeControl): the hook stays registered and, while inactive, gives no decision at all, so the tool call goes on exactly as if the hook weren't there.

Parameters​

ParameterTypeDefault value
runDirstringundefined
isActive() => boolean...
selfAskingToolsreadonly string[][]

Returns​

HookCallback