Skip to content

isNegotiatingRung

isNegotiatingRung(rung): boolean

Defined in: _worktrees/docs-release/gaunt-sloth/packages/core/src/config/shell-policy.ts:794

[[EXT-29]] (§5) — the rung at which a destructive rating opens a negotiation with the rater instead of going to the human: the agent may revise the command or justify it, the rater re-rates with the exchange in view, and only a spent bound reaches a person.

This is the one predicate that separates auto from assisted, and it is deliberately ONE. Three places have to agree about it — the decision mapping (import(‘../core/shell/rater.js’).mapVerdictToAction, which returns reject here and escalate at assisted), the rating prompt (§5.2’s wording rules are addressed to the agent, so they are turned on by this and not by whether a transcript happens to exist yet), and the runner that counts the rounds. Two of them agreeing and the third not is exactly how the two rated rungs would drift back into being the same posture with different names.

It answers about the RUNG, never about a particular call. [[EXT-106]] §3 withholds the negotiation from a command §4.6’s deterministic preflight floors — one that cannot reach approve however the agent argues — and both the decision and the prompt read that through import(‘../core/shell/rater.js’).isNegotiableCall, which composes this predicate with the preflight. Anything asking “may the agent argue about THIS call” wants that function; this one is a fact about the ladder and stays free of the shell module.

[[EXT-171]] — and isNegotiableCall is not the only thing that can withhold a negotiation. The decision also escalates when the gate never obtained a rating at all — the rater module’s RaterDecisionOptions.failClosedCause — which is a fact about the CALL rather than about the command, so no function over the command text could carry it. A reader looking for “why did this destructive not open a round at auto?” has two answers to check, not one.

Written as a === 'auto' test rather than as “rated but not assisted” so that a sixth rung has to be classified deliberately rather than inheriting a negotiation by omission.

"manual" | "write" | "assisted" | "auto" | "bypass"

boolean