Skip to content
docsv0.17.1

Ask

A human decides here — the gate, declared where the graph is read. The options are the cases of `$options`, which is the SAME source the {@see Route}s leaving this gate come from, so the surface and the transitions cannot drift apart. What this compiles to is the gate the engine already has, which means the whole posture comes along: the decision is an event in an append-only log, the run parks instead of blocking, and the principal that OPENED the gate cannot resolve it — so the agent that produced the work structurally cannot approve it.

Ask::__construct()

public function __construct(string $options, string $of, string $because, Milpa\Workflow\Enums\ApprovalPolicy $policy = Milpa\Workflow\Enums\ApprovalPolicy::SINGLE, array $evidence = [], bool $waivable = true):

Parameters

Parameters of __construct()
NameTypeDescription
$optionsclass-stringThe enum whose cases are the offered decisions.
$ofstringThe role that may answer.
$becausestringWhy a human is being asked — the text the decision surface shows.
$policyMilpa\Workflow\Enums\ApprovalPolicy
$evidencelist<string>Evidence types the answer must carry.
$waivableboolWhether this gate may be skipped at all.