Deterministic prompt verification.
Summary
Functions
Returns the contract clauses the verifier evaluates.
The contract actually enforced for a prompt: the packet's, plus every amendment recorded for it.
Whether report contains any item whose check could not run.
A one-line description of a faulted item, naming the command and its cwd.
The items in report whose check could not run.
Types
Functions
@spec contract_keys() :: [String.t()]
Returns the contract clauses the verifier evaluates.
Anything else under verify: is parsed, stored, and never evaluated, which
is what mix prompt_runner packet lint reads this list to detect.
@spec enforced_contract(PromptRunner.Plan.t(), map(), keyword()) :: map()
The contract actually enforced for a prompt: the packet's, plus every amendment recorded for it.
The packet's own contract is never mutated. It is read fresh each time and the amendments are applied on top, so a re-run from clean state — with no amendment log — enforces exactly what the packet says.
Whether report contains any item whose check could not run.
A one-line description of a faulted item, naming the command and its cwd.
The items in report whose check could not run.
A fault is not a verification failure. The contract said nothing about the work because it never got to look, so a caller must neither pass the prompt nor spend an attempt trying to repair it — it has to stop and say what could not run.
@spec verify( PromptRunner.Plan.t(), keyword() ) :: {:ok, [report()]}
@spec verify_prompt(PromptRunner.Plan.t(), map(), keyword()) :: report()