The Agree operation as a fold over the goal sequence #
This file defines the Agree operation of [Dea25a]'s interaction/satisfaction theory as a fold over an ordered goal sequence. The probe inspects the goals in order; from every goal that interacts with it, it copies, and flags the goal as a goal of the probe; the first goal that satisfies it is flagged as its satisfier and ends the search. The state the fold threads is whatever the probe accumulates, so the operation is generic over what copying means, and a probe specification over a feature type instantiates it with feature sets, copying the goal's features that lie in the interaction specification.
The single-goal search of Probe/Basic.lean is the special case in which every interacting goal
satisfies the probe (run_goals_eq_agree), Multiple Agree is the insatiable case
(insatiable_run_goals), and a probe that finds no interacting goal leaves the state unchanged,
Agree failing without penalty ([Pre14]). The satisfier of the fold is always the goal
Probe.search finds (run_halt). Goal flagging, which [Dea25a] keeps distinct from
valuation, is the list of interacting goals together with the satisfier.
Main definitions #
Minimalist.Probe.run: the Agree operation, a fold over the goal sequence returning aMinimalist.Probe.Result, the state, the flagged goals and the satisfier.Minimalist.Probe.inspected: the goals up to and including the first satisfier.Minimalist.Probe.Spec: an interaction and a satisfaction feature set, denoting a probe over goals exposing feature sets byMinimalist.Probe.Spec.toProbeand run byMinimalist.Probe.Spec.run.
Main results #
Minimalist.Probe.run_halt,Minimalist.Probe.run_goals,Minimalist.Probe.run_stateMinimalist.Probe.run_goals_eq_agree,Minimalist.Probe.insatiable_run_goalsMinimalist.Probe.Spec.run_state_eq_biUnion
References #
The result of running a probe over a goal sequence, the state after copying from every interacting goal, the goals flagged as interacting, in search order, and the goal flagged as the satisfier, if any.
- state : σ
The state after copying from every interacting goal.
- goals : List α
The goals the probe interacted with, in search order.
- halt : Option α
The goal that satisfied the probe, if the search was satisfied.
Instances For
The Agree operation over an ordered goal sequence. Each goal in turn is copied from and flagged if it interacts, and ends the search if it satisfies.
Equations
Instances For
An inspected goal is a member of the sequence.
A relativized probe flags the goal it finds.
An insatiable probe flags every interacting goal, Multiple Agree ([Hir01]).
Feature specifications #
A probe specification over a feature type, the features the probe interacts with and the
features that satisfy it, [INT:int, SAT:sat] in [Dea25a]'s notation.
- int : Finset F
The features the probe copies.
- sat : Finset F
The features that halt the probe's search.
Instances For
The probe a specification denotes over goals exposing feature sets, interacting with a goal iff it bears a feature of the interaction specification and satisfied iff it bears one of the satisfaction specification.
Equations
Instances For
Copying from a goal adds its features that lie in the interaction specification.
Instances For
The Agree operation of a specification over a goal sequence, starting from no features.
Instances For
The copied features are the interaction-specified features of the flagged goals.