AbilityContracts¶
Complete selected asymmetric reference profile. Definitions and supplied fixtures are distinct from the three teaching specializations; review and qualification are stated in the bound evidence and release.
Package reference-profile, input revision 2. Exact prepared source; CC0 1.0.
This is a definition inventory. Start with the learning chapters for the contract and its assumptions.
o · operator
reference-profile · input revision 2 · CC0 1.0
o == objects[ability.source.object]Exact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
next · operator
reference-profile · input revision 2 · CC0 1.0
next == IF actualReturn.attempt=0 THEN "ProcedureCode687f72772ab1" ELSE "ProcedureCodeaa0828fbf852"Exact module download · Source bundle and reproduction instructions
archive · operator
reference-profile · input revision 2 · CC0 1.0
archive == ReplacementOverlay99(before.ancestryArchive,ReplacementOverlay99(before.state.ancestry,nextState.ancestry))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
newIds · operator
reference-profile · input revision 2 · CC0 1.0
newIds == DOMAIN nextState.effectsExact module download · Source bundle and reproduction instructions
oldIds · operator
reference-profile · input revision 2 · CC0 1.0
oldIds == DOMAIN before.state.effectsExact module download · Source bundle and reproduction instructions
preview · operator
reference-profile · input revision 2 · CC0 1.0
preview == SimultaneousPreview912(before,id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousPreview912
view · operator
reference-profile · input revision 2 · CC0 1.0
view == SimultaneousView912(before,id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousView912
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == after.present \ before.presentExact module download · Source bundle and reproduction instructions
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == before.present \ after.presentExact module download · Source bundle and reproduction instructions
step · operator
reference-profile · input revision 2 · CC0 1.0
step == after.history[Len(after.history)]Exact module download · Source bundle and reproduction instructions
id · operator
reference-profile · input revision 2 · CC0 1.0
id == operation.effectIdExact module download · Source bundle and reproduction instructions
Resolved project definitions: operation
modification · operator
reference-profile · input revision 2 · CC0 1.0
modification == context.modifications[index]Exact module download · Source bundle and reproduction instructions
operation · operator
reference-profile · input revision 2 · CC0 1.0
operation == modification.operationExact module download · Source bundle and reproduction instructions
Resolved project definitions: modification
ability · operator
reference-profile · input revision 2 · CC0 1.0
ability == [call.before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [p.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,!.detached=TRUE]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [p.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,!.detached=TRUE]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == before.technique.definitionExact module download · Source bundle and reproduction instructions
id · operator
reference-profile · input revision 2 · CC0 1.0
id == before.idExact module download · Source bundle and reproduction instructions
context · operator
reference-profile · input revision 2 · CC0 1.0
context == NewExpectedContext99(id,entry.id,origin,world,description,initial,owner)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewExpectedContext99
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
context · operator
reference-profile · input revision 2 · CC0 1.0
context == NewExpectedContext99(id,entry.id,origin,world,description,initial,owner)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewExpectedContext99
a · operator
reference-profile · input revision 2 · CC0 1.0
a == OpenAbilityResolution9(instance,"Play",before.source,"Play",d.instructions,before.playId)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, OpenAbilityResolution9
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == CurrentPlayDefinition97(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPlayDefinition97
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [a EXCEPT !.phase="Imminent",!.firstImminent=TRUE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a
context · operator
reference-profile · input revision 2 · CC0 1.0
context == NewExpectedContext99(id,entry.id,origin,world,description,initial,owner)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewExpectedContext99
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == {id \in beforeStack[i].pending \cap DOMAIN before.instances : candidate.instances[id].status # "Pending"}Exact module download · Source bundle and reproduction instructions
a · operator
reference-profile · input revision 2 · CC0 1.0
a == IF plan.cursor=Len(plan.steps)
THEN IF beforeP.ability.cursor=Len(beforeP.ability.instructions)
THEN [beforeP.ability EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [beforeP.ability EXCEPT !.phase="Between"] ELSE beforeP.abilityExact module download · Source bundle and reproduction instructions
changed · operator
reference-profile · input revision 2 · CC0 1.0
changed == [before.instances EXCEPT ![beforeP.id].status=IF last THEN "Complete" ELSE "Resolving"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: last
effects · operator
reference-profile · input revision 2 · CC0 1.0
effects == IF last THEN EffectsAfterConditionalResolution96(before.effects,beforeP.definition) ELSE before.effectsExact module download · Source bundle and reproduction instructions
Resolved project definitions: last, EffectsAfterConditionalResolution96
expired · operator
reference-profile · input revision 2 · CC0 1.0
expired == {ConditionalKey96(before.effects[id].definition) : id \in DOMAIN before.effects \ DOMAIN effects}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effects, ConditionalKey96
last · operator
reference-profile · input revision 2 · CC0 1.0
last == a.lastFinishedExact module download · Source bundle and reproduction instructions
Resolved project definitions: a
throttle · operator
reference-profile · input revision 2 · CC0 1.0
throttle == last /\ beforeP.definition.primaryKind="Static" /\ ConditionalExpectedEmpty96(before.instances[beforeP.id],beforeP.ability.instructions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: last, ConditionalExpectedEmpty96
a · operator
reference-profile · input revision 2 · CC0 1.0
a == IF plan.cursor=Len(plan.steps)
THEN IF before.ability.cursor=Len(before.ability.instructions)
THEN [before.ability EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [before.ability EXCEPT !.phase="Between"]
ELSE before.abilityExact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
cards · operator
reference-profile · input revision 2 · CC0 1.0
cards == due \ countersExact module download · Source bundle and reproduction instructions
counters · operator
reference-profile · input revision 2 · CC0 1.0
counters == {id \in due : BankPhysicalToken4(beforeObjects[id])}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: due, BankPhysicalToken4
due · operator
reference-profile · input revision 2 · CC0 1.0
due == PaidCleanupIds95(p,beforeObjects,beforeTransits,stage)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidCleanupIds95
new · operator
reference-profile · input revision 2 · CC0 1.0
new == successors[id]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [beforeOrigin.procedure EXCEPT !.payload=payload,!.ability.instructions=payload.instructions,!.prevented=prevented]Exact module download · Source bundle and reproduction instructions
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
ready · operator
reference-profile · input revision 2 · CC0 1.0
ready == [p EXCEPT !.phase="FirstTargets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [beforeOrigin.procedure EXCEPT !.payload=payload,!.ability.instructions=payload.instructions,!.prevented=prevented]Exact module download · Source bundle and reproduction instructions
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
ready · operator
reference-profile · input revision 2 · CC0 1.0
ready == [p EXCEPT !.phase="FirstTargets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
a · operator
reference-profile · input revision 2 · CC0 1.0
a == [before.ability EXCEPT !.detached=TRUE]Exact module download · Source bundle and reproduction instructions
used · operator
reference-profile · input revision 2 · CC0 1.0
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> before.id,source |-> before.ability.source,player |-> before.definition.syntax.controller]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [before.metadata.sourceEntry.after EXCEPT !.ability=before.ability]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [before.sourceEntry.after EXCEPT !.ability=before.ability]Exact module download · Source bundle and reproduction instructions
idle · operator
reference-profile · input revision 2 · CC0 1.0
idle == [w EXCEPT !.busy = NoPriorityOption9,!.busyTransaction = 0,!.previousPass = FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NoPriorityOption9
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {id \in DOMAIN ledger.instances : ledger.instances[id].checkpointId=checkpointId /\ ~ledger.instances[id].member.interrupt}Exact module download · Source bundle and reproduction instructions
windows · operator
reference-profile · input revision 2 · CC0 1.0
windows == {ledger.instances[id].member.windowId : id \in ids}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ids
i · operator
reference-profile · input revision 2 · CC0 1.0
i == ledger.instances[r.id]Exact module download · Source bundle and reproduction instructions
i · operator
reference-profile · input revision 2 · CC0 1.0
i == w.members[option.instance]Exact module download · Source bundle and reproduction instructions
instance · operator
reference-profile · input revision 2 · CC0 1.0
instance == ledger.instances[p.id]Exact module download · Source bundle and reproduction instructions
i · operator
reference-profile · input revision 2 · CC0 1.0
i == ledger.instances[r.id]Exact module download · Source bundle and reproduction instructions
applications · operator
reference-profile · input revision 2 · CC0 1.0
applications == [id \in {grant.id} |-> grant]Exact module download · Source bundle and reproduction instructions
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == {copies[id] : id \in DOMAIN copies}Exact module download · Source bundle and reproduction instructions
present · operator
reference-profile · input revision 2 · CC0 1.0
present == before.present \cup gainedExact module download · Source bundle and reproduction instructions
Resolved project definitions: gained
rows · operator
reference-profile · input revision 2 · CC0 1.0
rows == [id \in gained |-> LET parent == CHOOSE p \in DOMAIN copies : copies[p]=id
IN [definition |-> CopiedBarrierInstructionDefinition98(before.definitions[parent],id),textKey |-> before.provenance[parent].textKey,
effect |-> grant.id,parent |-> parent,printedSlot |-> 0,template |-> 0]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: gained, parent, CopiedBarrierInstructionDefinition98
parent · operator
reference-profile · input revision 2 · CC0 1.0
parent == CHOOSE p \in DOMAIN copies : copies[p]=idExact module download · Source bundle and reproduction instructions
instance · operator
reference-profile · input revision 2 · CC0 1.0
instance == [member |-> ConditionalMember96(id,d,windowId,group),definition |-> ConditionalKey96(d),definitionCopy |-> d,status |-> "Pending",
primaryKind |-> d.primaryKind,activationEpoch |-> snapshot.activationEpoch[ConditionalKey96(d)],checkpointId |-> before.lastCheckpoint,
occurrence |-> prepared.occurrence,hadSnapshot |-> before.lastSnapshot,expected |-> EmptyOrder98,used |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96, ConditionalMember96, EmptyOrder98
instance · operator
reference-profile · input revision 2 · CC0 1.0
instance == [member |-> ConditionalMember96(id,d,windowId,group),definition |-> ConditionalKey96(d),definitionCopy |-> d,status |-> "Pending",
primaryKind |-> d.primaryKind,activationEpoch |-> snapshot.activationEpoch[ConditionalKey96(d)],
checkpointId |-> before.lastCheckpoint,occurrence |-> prepared.occurrence,
hadSnapshot |-> before.lastSnapshot,expected |-> [i \in {} |-> i],used |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96, ConditionalMember96
definition · operator
reference-profile · input revision 2 · CC0 1.0
definition == DelayedDefinition96(template,definitionId,effectId)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DelayedDefinition96
duration · operator
reference-profile · input revision 2 · CC0 1.0
duration == IF actualCreation.association="IfSuccessfulInspection" THEN TimingRef9("SchemaAtom138",traversal.id) ELSE actualCreation.durationExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == [id |-> effectId,definition |-> definition,source |-> plan.source,
policy |-> IF duration=NoTimingRef9 THEN "UntilResolution" ELSE "UntilDurationExpires",
duration |-> duration,triggerStructure |-> trigger,association |-> actualCreation.association,
traversalId |-> IF actualCreation.association="IfSuccessfulInspection" THEN traversal.id ELSE 0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: definition, duration, trigger, NoTimingRef9
trigger · operator
reference-profile · input revision 2 · CC0 1.0
trigger == IF template.thisTraversal THEN TimingRef9("SchemaAtom138",traversal.id) ELSE actualCreation.triggerStructureExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
created · operator
reference-profile · input revision 2 · CC0 1.0
created == [before EXCEPT !.temporaryReplacements=ReplacementOverlay99(@,[id \in {record.id} |-> record])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
replacements · operator
reference-profile · input revision 2 · CC0 1.0
replacements == ActiveReplacementBlueprints99(created,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: created, ActiveReplacementBlueprints99
blueprints · operator
reference-profile · input revision 2 · CC0 1.0
blueprints == actualExecution.blueprintsExact module download · Source bundle and reproduction instructions
created · operator
reference-profile · input revision 2 · CC0 1.0
created == [id \in DOMAIN before.effects \cup ids |->
IF id \in ids THEN NewLingeringEffect910(id,blueprints[id],context,operation,world) ELSE before.effects[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: blueprints, ids, NewLingeringEffect910
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == DOMAIN blueprintsExact module download · Source bundle and reproduction instructions
Resolved project definitions: blueprints
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE key \in cohort : effectIds[key]=idExact module download · Source bundle and reproduction instructions
Resolved project definitions: cohort
base · operator
reference-profile · input revision 2 · CC0 1.0
base == [world EXCEPT !.id=next.id,!.objects=next.objects,!.present=@ \ sourceIds,
!.activity.instances=PersistentInstanceRows912(world.activity.instances,afterLedger)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next, sourceIds, world, PersistentInstanceRows912
cohort · operator
reference-profile · input revision 2 · CC0 1.0
cohort == PersistentBirthCohort912(inventory,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: world, PersistentBirthCohort912
created · operator
reference-profile · input revision 2 · CC0 1.0
created == [beforeRegistry EXCEPT !.persistent=ReplacementOverlay99(@,records),!.effects=ReplacementOverlay99(@,effects),
!.usedEffects=@ \cup DOMAIN effects,!.creations=@ \cup {effects[id].creation : id \in DOMAIN effects},!.persistentRetireIds=@ \cup {trash.id}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effects, records, ReplacementOverlay99
effects · operator
reference-profile · input revision 2 · CC0 1.0
effects == [id \in {effectIds[key] : key \in cohort} |->
LET key == CHOOSE key \in cohort : effectIds[key]=id
IN PersistentEffect912(id,inventory.definitions[key],inventory.lexemes[key],trash,trash.itemInspection.traversalId,world)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key, cohort, world, PersistentEffect912
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualObjectTransition",id |-> trash.id,snapshotId |-> next.id,source |-> RuleAbilitySource9("ProcedureCode17f2a65162fb"),trash |-> trash]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next, RuleAbilitySource9
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
records · operator
reference-profile · input revision 2 · CC0 1.0
records == [key \in cohort |-> PersistentRecord912(inventory.definitions[key],inventory.lexemes[key],effectIds[key],trash,world)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: cohort, world, PersistentRecord912
sourceIds · operator
reference-profile · input revision 2 · CC0 1.0
sourceIds == {inventory.definitions[key].syntax.id : key \in DOMAIN inventory.definitions}Exact module download · Source bundle and reproduction instructions
world · operator
reference-profile · input revision 2 · CC0 1.0
world == beforeAuthority.currentExact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA ref : ref \in current.liveDurationsExact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
c · operator
reference-profile · input revision 2 · CC0 1.0
c == world.paidContexts[key]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == CurrentInterruptDefinitions99(world)[key]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentInterruptDefinitions99
instance · operator
reference-profile · input revision 2 · CC0 1.0
instance == grants[id].instanceExact module download · Source bundle and reproduction instructions
instance · operator
reference-profile · input revision 2 · CC0 1.0
instance == ledger.instances[id]Exact module download · Source bundle and reproduction instructions
key · operator
reference-profile · input revision 2 · CC0 1.0
key == instance.definitionExact module download · Source bundle and reproduction instructions
Resolved project definitions: instance
default · operator
reference-profile · input revision 2 · CC0 1.0
default == IF source.kind="Object" /\ source.object \in DOMAIN world.objects
THEN world.cardActivity[source.object] ELSE FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: source
source · operator
reference-profile · input revision 2 · CC0 1.0
source == d.syntax.sourceExact module download · Source bundle and reproduction instructions
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == {key \in DOMAIN before.persistent : before.persistent[key].phase="Persisting" /\ before.persistent[key].traversalId=afterEnd.traversal.id}Exact module download · Source bundle and reproduction instructions
feasible · operator
reference-profile · input revision 2 · CC0 1.0
feasible == MustFullyResolvable912(before.declaration,world,feasibility)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: MustFullyResolvable912
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == {id \in stack[i].pending \cap DOMAIN beforeLedger.instances : coreLedger.instances[id].status # "Pending"}Exact module download · Source bundle and reproduction instructions
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == ledger.effects[d.delayedEffect]Exact module download · Source bundle and reproduction instructions
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {allocation[[definition |-> ConditionalKey96(d),occurrence |-> event]] : event \in matched}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: matched, ConditionalKey96
matched · operator
reference-profile · input revision 2 · CC0 1.0
matched == DepartureMatchedEvents96(d,cp,conditions,departure)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DepartureMatchedEvents96
new · operator
reference-profile · input revision 2 · CC0 1.0
new == departure.newObjectExact module download · Source bundle and reproduction instructions
old · operator
reference-profile · input revision 2 · CC0 1.0
old == departure.oldObjectExact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \notin e.barrierInstructionSuppressedExact module download · Source bundle and reproduction instructions
active · operator
reference-profile · input revision 2 · CC0 1.0
active == ActiveExampleFamily062Sources98(sources,objects,present,context,points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveExampleFamily062Sources98
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [before.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,!.detached=TRUE]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [before EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
base · operator
reference-profile · input revision 2 · CC0 1.0
base == NewBarrierInstructionBarrierInstruction98(id,actualEffect.barrierInstruction,d,
[id |-> actualEffect.encounter,barrierCard |-> actualEffect.barrierCard],owner,objects[actualEffect.barrierCard].zone)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, NewBarrierInstructionBarrierInstruction98
d · operator
reference-profile · input revision 2 · CC0 1.0
d == orderState.definitions[actualEffect.barrierInstruction]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.targets=actualTargets.targets,!.announced=TRUE]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [before.ability EXCEPT !.phase="Imminent",!.cursor=@+1]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [before EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
a · operator
reference-profile · input revision 2 · CC0 1.0
a == IF before.ability.phase="Ready"
THEN [before.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE]
ELSE [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.targets=actualTargets.targets,!.announced=TRUE]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [before EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]Exact module download · Source bundle and reproduction instructions
first · operator
reference-profile · input revision 2 · CC0 1.0
first == before.visited= <<>>Exact module download · Source bundle and reproduction instructions
imminent · operator
reference-profile · input revision 2 · CC0 1.0
imminent == IF first THEN [before.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,
!.detached=@ \/ before.ability.kind="Conditional"]
ELSE [before.ability EXCEPT !.phase="Imminent",!.cursor=@+1]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: first
d · operator
reference-profile · input revision 2 · CC0 1.0
d == sources[key]Exact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA g : Len(g.nodes)>0Exact module download · Source bundle and reproduction instructions
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == context.state.effects[id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: id
id · operator
reference-profile · input revision 2 · CC0 1.0
id == CHOOSE i \in DOMAIN context.state.effects : TRUEExact module download · Source bundle and reproduction instructions
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == {id \in beforeStack[i].pending \cap DOMAIN before.instances : candidate.instances[id].status # "Pending"}Exact module download · Source bundle and reproduction instructions
expired · operator
reference-profile · input revision 2 · CC0 1.0
expired == {id \in DOMAIN before.effects : before.effects[id].policy="UntilDurationExpires" /\ before.effects[id].duration \in actualExpiry.expiredDurations}Exact module download · Source bundle and reproduction instructions
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == {ConditionalKey96(before.effects[id].definition) : id \in expired}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: expired, ConditionalKey96
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == {id \in beforeStack[i].pending \cap DOMAIN before.instances : candidate.instances[id].status # "Pending"}Exact module download · Source bundle and reproduction instructions
expired · operator
reference-profile · input revision 2 · CC0 1.0
expired == {id \in DOMAIN before.effects : before.effects[id].policy="UntilDurationExpires" /\ before.effects[id].duration=actualEnd.structure}Exact module download · Source bundle and reproduction instructions
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == {ConditionalKey96(before.effects[id].definition) : id \in expired}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: expired, ConditionalKey96
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "CurrentCharacteristicsEvaluation",id |-> cp.id,snapshotId |-> afterAuthority.current.id,
source |-> RuleAbilitySource9("ProcedureCode17f2a65162fb"),noWindow |-> clearance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: RuleAbilitySource9
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == {key \in PersistentEndWindows912(beforeRegistry,0) : beforeRegistry.persistent[key].endCheckpoint=cp.id}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentEndWindows912
top · operator
reference-profile · input revision 2 · CC0 1.0
top == before[Len(before)]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == before.technique.definitionExact module download · Source bundle and reproduction instructions
expected · operator
reference-profile · input revision 2 · CC0 1.0
expected == beforeLedger.instances[before.id].expectedExact module download · Source bundle and reproduction instructions
last · operator
reference-profile · input revision 2 · CC0 1.0
last == after.current=0Exact module download · Source bundle and reproduction instructions
throttle · operator
reference-profile · input revision 2 · CC0 1.0
throttle == last /\ d.primaryKind="Static" /\ DOMAIN expected=1..Len(after.trace) /\ \A i \in DOMAIN expected : expected[i].effects={}Exact module download · Source bundle and reproduction instructions
returned · operator
reference-profile · input revision 2 · CC0 1.0
returned == [before.ability EXCEPT !.returned=TRUE]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == before.technique.definitionExact module download · Source bundle and reproduction instructions
expected · operator
reference-profile · input revision 2 · CC0 1.0
expected == beforeLedger.instances[before.id].expectedExact module download · Source bundle and reproduction instructions
last · operator
reference-profile · input revision 2 · CC0 1.0
last == after.pc=0Exact module download · Source bundle and reproduction instructions
throttle · operator
reference-profile · input revision 2 · CC0 1.0
throttle == last /\ d.primaryKind="Static" /\ DOMAIN expected=1..Len(after.visited) /\ \A i \in DOMAIN expected : expected[i].effects={}Exact module download · Source bundle and reproduction instructions
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
acknowledgement · operator
reference-profile · input revision 2 · CC0 1.0
acknowledgement == DelayedRuntimePublicationAck911(call.actualReturn,mid.authority.current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DelayedRuntimePublicationAck911
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualDelayedReturn",id |-> call.context.id,snapshotId |-> next.id,
source |-> call.before.ability.source,instruction |-> call.context.currentRef,return |-> acknowledgement]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: acknowledgement, next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [after.registry EXCEPT !.frontier=mid.registry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == after.authority.currentExact module download · Source bundle and reproduction instructions
acknowledgement · operator
reference-profile · input revision 2 · CC0 1.0
acknowledgement == DelayedRuntimePublicationAck911(call.actualReturn,mid.authority.current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DelayedRuntimePublicationAck911
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualDelayedReturn",id |-> call.context.id,snapshotId |-> next.id,
source |-> call.before.ability.source,instruction |-> call.context.currentRef,return |-> acknowledgement]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: acknowledgement, next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [after.registry EXCEPT !.frontier=mid.registry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == after.authority.currentExact module download · Source bundle and reproduction instructions
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualDelayedReturn",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> beforeOrigin.plan.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
continuation · operator
reference-profile · input revision 2 · CC0 1.0
continuation == OccurrenceContinuation912(before,control,capture)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrenceContinuation912
finished · operator
reference-profile · input revision 2 · CC0 1.0
finished == IF next=0 THEN [projected EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [projected EXCEPT !.phase="Between",!.lastFinished=FALSE,!.complete=FALSE]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == continuation.sourceNodeExact module download · Source bundle and reproduction instructions
Resolved project definitions: continuation
paid · operator
reference-profile · input revision 2 · CC0 1.0
paid == payment.tag="CompletedInstructionCost"Exact module download · Source bundle and reproduction instructions
projected · operator
reference-profile · input revision 2 · CC0 1.0
projected == [before.ability EXCEPT !.instructions=IF next=0 THEN trace ELSE Append(trace,nextId)]Exact module download · Source bundle and reproduction instructions
trace · operator
reference-profile · input revision 2 · CC0 1.0
trace == Append(before.trace,before.current)Exact module download · Source bundle and reproduction instructions
resolved · operator
reference-profile · input revision 2 · CC0 1.0
resolved == [before.ability EXCEPT !.returned=TRUE]Exact module download · Source bundle and reproduction instructions
a · operator
reference-profile · input revision 2 · CC0 1.0
a == [before.ability EXCEPT !.returned=TRUE]Exact module download · Source bundle and reproduction instructions
choices · operator
reference-profile · input revision 2 · CC0 1.0
choices == IF before.technique.nodes[before.pc].kind \in {"Choice","NestedCost"}
THEN ReplacementOverlay99(before.choices,[i \in {Len(before.visited)+1} |-> control]) ELSE before.choicesExact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
finished · operator
reference-profile · input revision 2 · CC0 1.0
finished == IF next=0 THEN [projected EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [projected EXCEPT !.phase="Between"]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == RuntimeNext911(before,control)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: RuntimeNext911
paid · operator
reference-profile · input revision 2 · CC0 1.0
paid == payment.tag="CompletedInstructionCost"Exact module download · Source bundle and reproduction instructions
projected · operator
reference-profile · input revision 2 · CC0 1.0
projected == RuntimeFinishFrame911(before,next)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next, RuntimeFinishFrame911
positions · operator
reference-profile · input revision 2 · CC0 1.0
positions == {i \in 1..Len(history.evidence) : history.evidence[i].group=key /\
period \in history.evidence[i].periods /\ ExpectedWouldCriterionMatches99(history.evidence[i].descriptor,criterion)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedWouldCriterionMatches99
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == DOMAIN rowsExact module download · Source bundle and reproduction instructions
kind · operator
reference-profile · input revision 2 · CC0 1.0
kind == IF \E g \in DOMAIN grants : grants[g].mode="SideAChoice" THEN "SideADeclaredGain" ELSE "OrdinaryGain"Exact module download · Source bundle and reproduction instructions
present · operator
reference-profile · input revision 2 · CC0 1.0
present == before.present \cup gainedExact module download · Source bundle and reproduction instructions
Resolved project definitions: gained
result · operator
reference-profile · input revision 2 · CC0 1.0
result == OrderChangedState98(before,rows,grants,present,spine,decision,kind,{},"Grant")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: kind, present, OrderChangedState98
r · operator
reference-profile · input revision 2 · CC0 1.0
r == world.extenders[id]Exact module download · Source bundle and reproduction instructions
u · operator
reference-profile · input revision 2 · CC0 1.0
u == CHOOSE id \in g.units : TRUEExact module download · Source bundle and reproduction instructions
instructions · operator
reference-profile · input revision 2 · CC0 1.0
instructions == TextUnitIds93(a.units,"Instruction")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TextUnitIds93
primaries · operator
reference-profile · input revision 2 · CC0 1.0
primaries == PrimaryConditions93(a.units)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PrimaryConditions93
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA effect : effect \in DOMAIN context.initialEffectsExact module download · Source bundle and reproduction instructions
announced · operator
reference-profile · input revision 2 · CC0 1.0
announced == [entry.beforePlan EXCEPT !.announced=TRUE,!.targets=entry.targets.targets]Exact module download · Source bundle and reproduction instructions
u · operator
reference-profile · input revision 2 · CC0 1.0
u == CHOOSE id \in g.units : TRUEExact module download · Source bundle and reproduction instructions
unit · operator
reference-profile · input revision 2 · CC0 1.0
unit == p.units[u]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: u
u · operator
reference-profile · input revision 2 · CC0 1.0
u == CHOOSE id \in g.units : TRUEExact module download · Source bundle and reproduction instructions
unit · operator
reference-profile · input revision 2 · CC0 1.0
unit == p.units[u]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: u
u · operator
reference-profile · input revision 2 · CC0 1.0
u == CHOOSE id \in g.units : TRUEExact module download · Source bundle and reproduction instructions
body · operator
reference-profile · input revision 2 · CC0 1.0
body == unit.optionInstructions[choice]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: unit
control · operator
reference-profile · input revision 2 · CC0 1.0
control == p.nodes[Head(g.nodes)]Exact module download · Source bundle and reproduction instructions
primary · operator
reference-profile · input revision 2 · CC0 1.0
primary == CHOOSE u \in g.units : UnitShape911(p.units[u])="SearchAndAct"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: UnitShape911
groups · operator
reference-profile · input revision 2 · CC0 1.0
groups == ExecutableInstructionGroups911(p)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExecutableInstructionGroups911
n · operator
reference-profile · input revision 2 · CC0 1.0
n == p.nodes[id]Exact module download · Source bundle and reproduction instructions
c · operator
reference-profile · input revision 2 · CC0 1.0
c == capabilities.clauses[id]Exact module download · Source bundle and reproduction instructions
order · operator
reference-profile · input revision 2 · CC0 1.0
order == SubSeq(a.order,1,position)Exact module download · Source bundle and reproduction instructions
row · operator
reference-profile · input revision 2 · CC0 1.0
row == feasibility.options[option]Exact module download · Source bundle and reproduction instructions
step · operator
reference-profile · input revision 2 · CC0 1.0
step == after.history[Len(after.history)]Exact module download · Source bundle and reproduction instructions
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(stack,site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(stack,site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
raw · operator
reference-profile · input revision 2 · CC0 1.0
raw == [tag |-> "PlayResolved",object |-> afterCleanup.object,kind |-> afterCleanup.kind,actor |-> afterCleanup.actor,playId |-> afterCleanup.id]Exact module download · Source bundle and reproduction instructions
due · operator
reference-profile · input revision 2 · CC0 1.0
due == PaidConvertedAsideIds95(p,beforeObjects,beforeTransits)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidConvertedAsideIds95
new · operator
reference-profile · input revision 2 · CC0 1.0
new == successors[id]Exact module download · Source bundle and reproduction instructions
result · operator
reference-profile · input revision 2 · CC0 1.0
result == IF ~supported THEN 0 ELSE
(IF setters={} THEN default ELSE CHOOSE value \in setters : TRUE)
+SumSimultaneous912({[id |-> m.id,amount |-> m.value] : m \in {m \in modifiers : m.operation="Increase"}})
-SumSimultaneous912({[id |-> m.id,amount |-> m.value] : m \in {m \in modifiers : m.operation="SchemaAtom100"}})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: setters, supported, SumSimultaneous912
setters · operator
reference-profile · input revision 2 · CC0 1.0
setters == {m.value : m \in {m \in modifiers : m.operation="Set"}}Exact module download · Source bundle and reproduction instructions
supported · operator
reference-profile · input revision 2 · CC0 1.0
supported == Cardinality(setters)<=1 /\ \A m \in modifiers : IRField911(m,"known",TRUE)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: setters, IRField911
epochs · operator
reference-profile · input revision 2 · CC0 1.0
epochs == [key \in keys |-> (IF key \in DOMAIN before.activationEpoch THEN before.activationEpoch[key] ELSE 0)+(IF key \in lost THEN 1 ELSE 0)]Exact module download · Source bundle and reproduction instructions
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == DOMAIN before.activationEpoch \cup DOMAIN beforeSnapshot.definitions \cup DOMAIN afterSnapshot.definitionsExact module download · Source bundle and reproduction instructions
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == ConditionalActivityLosses96(beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityLosses96
observed · operator
reference-profile · input revision 2 · CC0 1.0
observed == [candidate EXCEPT !.activationEpoch=epochs,!.activationSerial=serial]Exact module download · Source bundle and reproduction instructions
serial · operator
reference-profile · input revision 2 · CC0 1.0
serial == before.activationSerial+(IF lost={} THEN 0 ELSE 1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost
base · operator
reference-profile · input revision 2 · CC0 1.0
base == [id \in DOMAIN actualReplacement.base |-> actualReplacement.base[id]]Exact module download · Source bundle and reproduction instructions
originalActive · operator
reference-profile · input revision 2 · CC0 1.0
originalActive == ContinuousStaticActive99(original.definition,original.syntax,current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ContinuousStaticActive99
replacementActive · operator
reference-profile · input revision 2 · CC0 1.0
replacementActive == ContinuousStaticActive99(replacement.definition,replacement.syntax,current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ContinuousStaticActive99
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
due · operator
reference-profile · input revision 2 · CC0 1.0
due == ContinuousOriginalPresent99(original,current) /\ ~CurrentBoostAlive99(effective,current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effective, ContinuousOriginalPresent99, CurrentBoostAlive99
effective · operator
reference-profile · input revision 2 · CC0 1.0
effective == EffectiveSpecimen0100Boost99(original,replacement,current,comparison)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EffectiveSpecimen0100Boost99
key · operator
reference-profile · input revision 2 · CC0 1.0
key == opening.imminenceIdExact module download · Source bundle and reproduction instructions
record · operator
reference-profile · input revision 2 · CC0 1.0
record == [id |-> opening.id,imminenceId |-> key,context |-> opening.context,snapshotId |-> opening.snapshotId,periods |-> periods,roots |-> {rows[id].root : id \in DOMAIN rows}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key
original · operator
reference-profile · input revision 2 · CC0 1.0
original == before.openings[outcome.imminenceId]Exact module download · Source bundle and reproduction instructions
original · operator
reference-profile · input revision 2 · CC0 1.0
original == before.openings[revision.imminenceId]Exact module download · Source bundle and reproduction instructions
matches · operator
reference-profile · input revision 2 · CC0 1.0
matches == {occurrence \in SubIds6(r.trace) \cap DOMAIN r.choices :
/\ r.occurrences[occurrence].sourceNode=m.commitment.node /\ r.occurrences[occurrence].pass=r.repeat.pass
/\ r.choices[occurrence].tag="ResolvedInstructionControl" /\ r.choices[occurrence].instance=r.id
/\ r.choices[occurrence].node=m.commitment.node
/\ r.choices[occurrence].instruction.id=occurrence /\ r.choices[occurrence].instruction.source=r.ability.source
/\ r.choices[occurrence].instruction.abilityInstance=r.id
/\ r.choices[occurrence].mode="Selected" /\ r.choices[occurrence].option \in DOMAIN m.commitment.quotaByOption}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
occurrence · operator
reference-profile · input revision 2 · CC0 1.0
occurrence == CHOOSE id \in matches : TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: matches
quota · operator
reference-profile · input revision 2 · CC0 1.0
quota == m.commitment.quotaByOption[r.choices[occurrence].option]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: occurrence
again · operator
reference-profile · input revision 2 · CC0 1.0
again == within=0 /\ (IF r.specification.repeat.kind="Unbounded" THEN requested
ELSE r.specification.repeat.kind="Fixed" /\ (r.repeat.captured \/ firstFixed) /\ available>0)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: available, firstFixed, requested, within
available · operator
reference-profile · input revision 2 · CC0 1.0
available == IF firstFixed THEN total ELSE r.repeat.remainingExact module download · Source bundle and reproduction instructions
Resolved project definitions: firstFixed, total
firstFixed · operator
reference-profile · input revision 2 · CC0 1.0
firstFixed == within=0 /\ r.specification.repeat.kind="Fixed" /\ ~r.repeat.captured /\ requestedExact module download · Source bundle and reproduction instructions
rep · operator
reference-profile · input revision 2 · CC0 1.0
rep == [r.repeat EXCEPT !.requested=IF again THEN FALSE ELSE requested,
!.captured=@ \/ firstFixed,!.total=total,!.remaining=IF again /\ r.specification.repeat.kind="Fixed" THEN available-1 ELSE available,
!.pass=IF again THEN @+1 ELSE @]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: again, available, firstFixed, requested, total
requested · operator
reference-profile · input revision 2 · CC0 1.0
requested == OccurrenceRepeatRequested912(r,control)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrenceRepeatRequested912
total · operator
reference-profile · input revision 2 · CC0 1.0
total == IF firstFixed THEN capture.count ELSE r.repeat.totalExact module download · Source bundle and reproduction instructions
Resolved project definitions: firstFixed
within · operator
reference-profile · input revision 2 · CC0 1.0
within == OccurrencePassNext912(r,control)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrencePassNext912
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == r.technique.definition.delayedEffectExact module download · Source bundle and reproduction instructions
m · operator
reference-profile · input revision 2 · CC0 1.0
m == r.specification.modal[r.pc]Exact module download · Source bundle and reproduction instructions
maximum · operator
reference-profile · input revision 2 · CC0 1.0
maximum == IF old.latched THEN old.maximum ELSE control.maximumExact module download · Source bundle and reproduction instructions
Resolved project definitions: old
old · operator
reference-profile · input revision 2 · CC0 1.0
old == r.modal[r.pc]Exact module download · Source bundle and reproduction instructions
upTo · operator
reference-profile · input revision 2 · CC0 1.0
upTo == IF old.latched THEN old.upTo ELSE control.upToExact module download · Source bundle and reproduction instructions
Resolved project definitions: old
committed · operator
reference-profile · input revision 2 · CC0 1.0
committed == IF m.quotaPolicy="Committed" THEN OccurrenceCommittedQuota912(r,m) ELSE [supported |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: m, OccurrenceCommittedQuota912
m · operator
reference-profile · input revision 2 · CC0 1.0
m == r.specification.modal[r.pc]Exact module download · Source bundle and reproduction instructions
old · operator
reference-profile · input revision 2 · CC0 1.0
old == r.modal[r.pc]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == [old EXCEPT !.currentMode=IF selected THEN control.option ELSE 0,
!.resolved=IF selected THEN Append(@,control.option) ELSE @,
!.maximum=IF @=0 /\ ~old.latched /\ control.mode="Selected" THEN control.maximum ELSE @,
!.upTo=IF ~old.latched /\ control.mode="Selected" THEN control.upTo ELSE @,!.latched=TRUE]Exact module download · Source bundle and reproduction instructions
old · operator
reference-profile · input revision 2 · CC0 1.0
old == r.modal[r.pc]Exact module download · Source bundle and reproduction instructions
selected · operator
reference-profile · input revision 2 · CC0 1.0
selected == control.mode="Selected" /\ control.option#0Exact module download · Source bundle and reproduction instructions
owner · operator
reference-profile · input revision 2 · CC0 1.0
owner == a.current.activity.instances[r.id].ownerExact module download · Source bundle and reproduction instructions
body · operator
reference-profile · input revision 2 · CC0 1.0
body == UNION {SubIds6(m.bodies[mode]) : mode \in DOMAIN m.bodies}Exact module download · Source bundle and reproduction instructions
m · operator
reference-profile · input revision 2 · CC0 1.0
m == spec.modal[selector]Exact module download · Source bundle and reproduction instructions
m · operator
reference-profile · input revision 2 · CC0 1.0
m == spec.modal[selector]Exact module download · Source bundle and reproduction instructions
completing · operator
reference-profile · input revision 2 · CC0 1.0
completing == {selector \in DOMAIN r.modal : r.modal[selector].currentMode#0 /\
r.pc=r.specification.modal[selector].bodies[r.modal[selector].currentMode][Len(r.specification.modal[selector].bodies[r.modal[selector].currentMode])]}Exact module download · Source bundle and reproduction instructions
m · operator
reference-profile · input revision 2 · CC0 1.0
m == r.modal[selector]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: selector
selector · operator
reference-profile · input revision 2 · CC0 1.0
selector == CHOOSE s \in completing : TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: completing
players · operator
reference-profile · input revision 2 · CC0 1.0
players == {rows[id].chooser : id \in DOMAIN rows}Exact module download · Source bundle and reproduction instructions
base · operator
reference-profile · input revision 2 · CC0 1.0
base == ReplacementOverlay99(NewLingeringRegistry910,[frontier |-> LifetimeFrontier910(authority,1)])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeFrontier910, NewLingeringRegistry910, ReplacementOverlay99
members · operator
reference-profile · input revision 2 · CC0 1.0
members == ConditionalWindowMembers96(ledger.instances,windowId)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalWindowMembers96
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(beforeContext.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,site),beforeContext.openingMembers,
beforeContext.group,NoTimingRef9,beforeContext.openingRef,beforeContext.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
proposed · operator
reference-profile · input revision 2 · CC0 1.0
proposed == NewPriorityWindow9(beforeContext.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,site),beforeContext.openingMembers,
beforeContext.group,NoTimingRef9,beforeContext.openingRef,beforeContext.openingRef.revision+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9
maintained · operator
reference-profile · input revision 2 · CC0 1.0
maintained == lifetimes.effects[effects[id].lifetimeId]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == world.conditional.definitions[key]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == world.paidDefinitions[key]Exact module download · Source bundle and reproduction instructions
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == DOMAIN rowsExact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in SubIds6(before)Exact module download · Source bundle and reproduction instructions
ca · operator
reference-profile · input revision 2 · CC0 1.0
ca == SubOriginCategory98(state,a)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubOriginCategory98
cb · operator
reference-profile · input revision 2 · CC0 1.0
cb == SubOriginCategory98(state,b)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubOriginCategory98
pa · operator
reference-profile · input revision 2 · CC0 1.0
pa == state.provenance[a]Exact module download · Source bundle and reproduction instructions
pb · operator
reference-profile · input revision 2 · CC0 1.0
pb == state.provenance[b]Exact module download · Source bundle and reproduction instructions
ta · operator
reference-profile · input revision 2 · CC0 1.0
ta == state.applications[pa.effect].clockExact module download · Source bundle and reproduction instructions
Resolved project definitions: pa
tb · operator
reference-profile · input revision 2 · CC0 1.0
tb == state.applications[pb.effect].clockExact module download · Source bundle and reproduction instructions
Resolved project definitions: pb
base · operator
reference-profile · input revision 2 · CC0 1.0
base == SetAsideExitView4(transit,queryAbility,own,FALSE,destination)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: own, SetAsideExitView4
own · operator
reference-profile · input revision 2 · CC0 1.0
own == queryAbility=p.id /\ p.phase \in {"Targets","Imminent","Resolve"} /\ PaidProtectionAlive95(p)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidProtectionAlive95
hosted · operator
reference-profile · input revision 2 · CC0 1.0
hosted == IF p.ability.source.kind="Object" THEN PaidPhysicalHosted95(beforeObjects,source) ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: source, PaidPhysicalHosted95
new · operator
reference-profile · input revision 2 · CC0 1.0
new == successors[old]Exact module download · Source bundle and reproduction instructions
protect · operator
reference-profile · input revision 2 · CC0 1.0
protect == (actualPayment.sourceUninstalled \/ actualPayment.sourceForfeited) /\ p.definition.refersHostedExact module download · Source bundle and reproduction instructions
selected · operator
reference-profile · input revision 2 · CC0 1.0
selected == IF protect THEN hosted ELSE {}Exact module download · Source bundle and reproduction instructions
source · operator
reference-profile · input revision 2 · CC0 1.0
source == p.ability.source.objectExact module download · Source bundle and reproduction instructions
barrierCard · operator
reference-profile · input revision 2 · CC0 1.0
barrierCard == c.encounter.barrierCardExact module download · Source bundle and reproduction instructions
source · operator
reference-profile · input revision 2 · CC0 1.0
source == d.syntax.source.objectExact module download · Source bundle and reproduction instructions
source · operator
reference-profile · input revision 2 · CC0 1.0
source == p.ability.source.objectExact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
witness · operator
reference-profile · input revision 2 · CC0 1.0
witness == c.references[reference]Exact module download · Source bundle and reproduction instructions
required · operator
reference-profile · input revision 2 · CC0 1.0
required == PaidRequiredWindows95(d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidRequiredWindows95
required · operator
reference-profile · input revision 2 · CC0 1.0
required == PaidRequiredWindows99(d,lex)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidRequiredWindows99
info · operator
reference-profile · input revision 2 · CC0 1.0
info == IF site.active = "SideA" THEN SideAStepInfo5(site.step) ELSE SideBStepInfo5(site.step)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SideAStepInfo5, SideBStepInfo5
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
closed · operator
reference-profile · input revision 2 · CC0 1.0
closed == WindowTop9(candidateStack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "CurrentCharacteristicsEvaluation",id |-> w.id,snapshotId |-> afterAuthority.current.id,
source |-> RuleAbilitySource9("ProcedureCode17f2a65162fb"),closedWindow |-> IF closed.open THEN 0 ELSE closed.id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: closed, w, RuleAbilitySource9
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == IF w.kind="Reaction" /\ w.open /\ ~closed.open THEN PersistentEndWindows912(beforeRegistry,w.id) ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: closed, w, PersistentEndWindows912
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(beforeStack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == [w EXCEPT !.pending = @ \ optional,!.lostPending = @ \cup optional]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: optional
optional · operator
reference-profile · input revision 2 · CC0 1.0
optional == PendingOwned9(w,w.priority,FALSE)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PendingOwned9
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
used · operator
reference-profile · input revision 2 · CC0 1.0
used == [a EXCEPT !.midUsed=TRUE,!.midResolving=TRUE]Exact module download · Source bundle and reproduction instructions
key · operator
reference-profile · input revision 2 · CC0 1.0
key == AbilityKey99(d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
row · operator
reference-profile · input revision 2 · CC0 1.0
row == registry.persistent[key]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key
row · operator
reference-profile · input revision 2 · CC0 1.0
row == registry.persistent[key]Exact module download · Source bundle and reproduction instructions
seen · operator
reference-profile · input revision 2 · CC0 1.0
seen == {id \in DOMAIN ledger.checkpoints : ledger.checkpoints[id].caller=PersistentTraversalEndCaller912(row.traversalId)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: row, PersistentTraversalEndCaller912
owners · operator
reference-profile · input revision 2 · CC0 1.0
owners == {key \in DOMAIN registry.persistent : registry.persistent[key].definition.syntax.id=d.syntax.id}Exact module download · Source bundle and reproduction instructions
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == PersistentGeneratedIds912(ledger,cpId)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentGeneratedIds912
d · operator
reference-profile · input revision 2 · CC0 1.0
d == inventory.definitions[key]Exact module download · Source bundle and reproduction instructions
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == registry.effects[row.effectId]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: row
row · operator
reference-profile · input revision 2 · CC0 1.0
row == registry.persistent[key]Exact module download · Source bundle and reproduction instructions
observation · operator
reference-profile · input revision 2 · CC0 1.0
observation == world.statedDurations[row.effectId]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: row
row · operator
reference-profile · input revision 2 · CC0 1.0
row == registry.persistent[key]Exact module download · Source bundle and reproduction instructions
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {registry.persistent[key].effectId : key \in DOMAIN registry.persistent}Exact module download · Source bundle and reproduction instructions
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE key \in DOMAIN registry.persistent : registry.persistent[key].effectId=idExact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == CurrentPlayDefinition97(c)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPlayDefinition97
d · operator
reference-profile · input revision 2 · CC0 1.0
d == text.definitions[id]Exact module download · Source bundle and reproduction instructions
rest · operator
reference-profile · input revision 2 · CC0 1.0
rest == SubSeq(before,1,Len(before)-1)Exact module download · Source bundle and reproduction instructions
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE k \in candidates : allocation[k]=idExact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
additions · operator
reference-profile · input revision 2 · CC0 1.0
additions == [id \in ids |-> LET key == CHOOSE k \in candidates : allocation[k]=id
IN NewOpeningInterruptInstance99(id,world.conditional.definitions[key],world.conditional,beforeLedger,beforeContext,windowId,group)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key, ids, NewOpeningInterruptInstance99
candidates · operator
reference-profile · input revision 2 · CC0 1.0
candidates == OpeningConditionalKeys99(beforeContext,world,history,beforeLedger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpeningConditionalKeys99
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {allocation[key] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
recognitions · operator
reference-profile · input revision 2 · CC0 1.0
recognitions == {[definition |-> key,occurrence |-> beforeContext.imminenceId] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE k \in candidates : allocation[k]=idExact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
additions · operator
reference-profile · input revision 2 · CC0 1.0
additions == [id \in ids |-> LET key == CHOOSE k \in candidates : allocation[k]=id
IN NewOpeningInterruptInstance99(id,world.conditional.definitions[key],world.conditional,beforeLedger,beforeContext,windowId,group)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key, ids, NewOpeningInterruptInstance99
candidates · operator
reference-profile · input revision 2 · CC0 1.0
candidates == {key \in OpeningConditionalKeys99(beforeContext,world,history,beforeLedger) :
PersistentGenerationAllowed912(registry,world.conditional.definitions[key],world.traversalControl.traversal.id)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpeningConditionalKeys99, PersistentGenerationAllowed912
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {allocation[key] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
recognitions · operator
reference-profile · input revision 2 · CC0 1.0
recognitions == {[definition |-> key,occurrence |-> beforeContext.imminenceId] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
remaining · operator
reference-profile · input revision 2 · CC0 1.0
remaining == IF id \notin DOMAIN after THEN 0
ELSE IF after[id].kind # before[id].kind THEN 0 ELSE MaxOf(0,after[id].value)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: MaxOf
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : text.definitions[id].syntax.kind="Play"Exact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
candidates · operator
reference-profile · input revision 2 · CC0 1.0
candidates == CheckpointCandidates96(definitions,stable,cp,conditions) \cup DepartureCandidates96(definitions,cp,conditions,departures)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: stable, CheckpointCandidates96, DepartureCandidates96
d · operator
reference-profile · input revision 2 · CC0 1.0
d == definitions[key.definition]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key
departureKeys · operator
reference-profile · input revision 2 · CC0 1.0
departureKeys == {key.definition : key \in DepartureCandidates96(definitions,cp,conditions,departures)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DepartureCandidates96
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {allocation[key] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE k \in candidates : allocation[k]=idExact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
stable · operator
reference-profile · input revision 2 · CC0 1.0
stable == ConditionalActivityLedger96(before,definitions,cp.processingSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityLedger96
candidates · operator
reference-profile · input revision 2 · CC0 1.0
candidates == CheckpointCandidates99(definitions,lexemes,stable,cp,conditions) \cup DepartureCandidates99(definitions,lexemes,cp,conditions,departures)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: stable, CheckpointCandidates99, DepartureCandidates99
d · operator
reference-profile · input revision 2 · CC0 1.0
d == definitions[key.definition]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key
departureKeys · operator
reference-profile · input revision 2 · CC0 1.0
departureKeys == {key.definition : key \in DepartureCandidates99(definitions,lexemes,cp,conditions,departures)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DepartureCandidates99
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {allocation[key] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE k \in candidates : allocation[k]=idExact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
stable · operator
reference-profile · input revision 2 · CC0 1.0
stable == ConditionalActivityLedger96(before,definitions,cp.processingSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityLedger96
candidates · operator
reference-profile · input revision 2 · CC0 1.0
candidates == ordinary \cup departingExact module download · Source bundle and reproduction instructions
departing · operator
reference-profile · input revision 2 · CC0 1.0
departing == {candidate \in DepartureCandidates99(definitions,lexemes,cp,conditions,departures) :
PersistentCandidateAllowed912(registry,definitions[candidate.definition],cp,candidate.occurrence,scope)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DepartureCandidates99, PersistentCandidateAllowed912
departureKeys · operator
reference-profile · input revision 2 · CC0 1.0
departureKeys == {key.definition : key \in departing}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: departing
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {allocation[key] : key \in candidates}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
key · operator
reference-profile · input revision 2 · CC0 1.0
key == CHOOSE k \in candidates : allocation[k]=idExact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates
ordinary · operator
reference-profile · input revision 2 · CC0 1.0
ordinary == PersistentCheckpointCandidates912(registry,definitions,lexemes,stable,cp,conditions,scope)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: stable, PersistentCheckpointCandidates912
stable · operator
reference-profile · input revision 2 · CC0 1.0
stable == ConditionalActivityLedger96(before,definitions,cp.processingSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityLedger96
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {id \in DOMAIN registry.effects : registry.effects[id].kind="Replacement"}Exact module download · Source bundle and reproduction instructions
base · operator
reference-profile · input revision 2 · CC0 1.0
base == SetAsideTransit4(current,oldObject.zone,oldObject.loc,p.transaction,p.id,TRUE,forfeited)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SetAsideTransit4
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == afterOrder.present \ beforeOrder.presentExact module download · Source bundle and reproduction instructions
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [after EXCEPT !.frontier=before.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == NextLifetimeWorld910(before,a)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NextLifetimeWorld910
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == NextLifetimeWorld910(beforeRegistry,a)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NextLifetimeWorld910
execution · operator
reference-profile · input revision 2 · CC0 1.0
execution == [tag |-> "CurrentCharacteristicsEvaluation",id |-> beforeContext.id,snapshotId |-> next.id,source |-> RuleAbilitySource9("ProcedureCode29f759d7ea55")]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next, RuleAbilitySource9
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
base · operator
reference-profile · input revision 2 · CC0 1.0
base == [beforeAuthority.current EXCEPT !.id=next.id,!.activity.instances=PersistentInstanceRows912(@,afterLedger)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next, PersistentInstanceRows912
changed · operator
reference-profile · input revision 2 · CC0 1.0
changed == PersistentExpirationRegistry912(beforeRegistry,keys)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentExpirationRegistry912
local · operator
reference-profile · input revision 2 · CC0 1.0
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]Exact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == afterAuthority.currentExact module download · Source bundle and reproduction instructions
selections · operator
reference-profile · input revision 2 · CC0 1.0
selections == IF "interruptSelections" \in DOMAIN beforeWorld THEN beforeWorld.interruptSelections ELSE [key \in {} |-> key]Exact module download · Source bundle and reproduction instructions
include · operator
reference-profile · input revision 2 · CC0 1.0
include == IF aggregated THEN QuantityTotal912(g,part)>0 ELSE index#0 \/ g.parts[part].basePresentExact module download · Source bundle and reproduction instructions
Resolved project definitions: part, QuantityTotal912
part · operator
reference-profile · input revision 2 · CC0 1.0
part == Head(parts)Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == g.parts[part]Exact module download · Source bundle and reproduction instructions
sideA · operator
reference-profile · input revision 2 · CC0 1.0
sideA == {id \in batch.members : beforeObjects[id].side="SideA"}Exact module download · Source bundle and reproduction instructions
values · operator
reference-profile · input revision 2 · CC0 1.0
values == {ids.perCard[id] : id \in DOMAIN ids.perCard}Exact module download · Source bundle and reproduction instructions
anchor · operator
reference-profile · input revision 2 · CC0 1.0
anchor == exampleFamily075Definition.syntax.source.objectExact module download · Source bundle and reproduction instructions
batchEvent · operator
reference-profile · input revision 2 · CC0 1.0
batchEvent == [tag |-> "ConditionalOccurrence",id |-> ids.batch,kind |-> "AtLeastOneRetireed",object |-> anchor,
actor |-> batch.actor,side |-> "SchemaAtom016",snapshot |-> beforeSnapshot,effectId |-> batch.id,
scopeKind |-> "Ability",scopeDefinition |-> ConditionalKey96(exampleFamily075Definition),members |-> relevant,
structure |-> NoTimingRef9,step |-> "NoValue",traversal |-> NoTraversal6,siteInspection |-> [traversalId |-> 0,origin |-> "NoValue"],
movement |-> IF anchor \in DOMAIN successors THEN [tag |-> "SourceZoneChange",oldObject |-> anchor,newObject |-> successors[anchor],beforeSnapshot |-> beforeSnapshot]
ELSE [tag |-> "NoValue",oldObject |-> 0,newObject |-> 0,beforeSnapshot |-> beforeSnapshot]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: anchor, relevant, ConditionalKey96, NoTimingRef9, NoTraversal6
perCard · operator
reference-profile · input revision 2 · CC0 1.0
perCard == [id \in sideA |-> [tag |-> "ConditionalOccurrence",id |-> ids.perCard[id],kind |-> "Retireed",object |-> id,
actor |-> batch.actor,side |-> "SideA",snapshot |-> beforeSnapshot,effectId |-> batch.id,
scopeKind |-> "Global",scopeDefinition |-> [ability |-> 0,source |-> RuleAbilitySource9("NoValue")],
structure |-> NoTimingRef9,step |-> "NoValue",traversal |-> NoTraversal6,siteInspection |-> [traversalId |-> 0,origin |-> "NoValue"],movement |-> [tag |-> "SourceZoneChange",oldObject |-> id,newObject |-> successors[id],beforeSnapshot |-> beforeSnapshot]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: sideA, NoTimingRef9, RuleAbilitySource9, NoTraversal6
relevant · operator
reference-profile · input revision 2 · CC0 1.0
relevant == ExampleFamily075BatchMembers912(batch,beforeSnapshot.objects,targetSite)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExampleFamily075BatchMembers912
sideA · operator
reference-profile · input revision 2 · CC0 1.0
sideA == {id \in batch.members : beforeSnapshot.objects[id].side="SideA"}Exact module download · Source bundle and reproduction instructions
entry · operator
reference-profile · input revision 2 · CC0 1.0
entry == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> abilityInstance,source |-> source,player |-> player]Exact module download · Source bundle and reproduction instructions
first · operator
reference-profile · input revision 2 · CC0 1.0
first == optional # {} /\ ~before.instances[p.id].usedExact module download · Source bundle and reproduction instructions
Resolved project definitions: optional
optional · operator
reference-profile · input revision 2 · CC0 1.0
optional == actualExecution.partIds \cap ConditionalUseOptionalParts96(p.definition)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalUseOptionalParts96
used · operator
reference-profile · input revision 2 · CC0 1.0
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> p.id,source |-> p.ability.source,player |-> p.definition.syntax.controller]Exact module download · Source bundle and reproduction instructions
d · operator
reference-profile · input revision 2 · CC0 1.0
d == r.technique.definitionExact module download · Source bundle and reproduction instructions
first · operator
reference-profile · input revision 2 · CC0 1.0
first == optional#{} /\ ~before.instances[r.id].usedExact module download · Source bundle and reproduction instructions
Resolved project definitions: optional
optional · operator
reference-profile · input revision 2 · CC0 1.0
optional == execution.partIds \cap ConditionalUseOptionalParts96(d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, ConditionalUseOptionalParts96
used · operator
reference-profile · input revision 2 · CC0 1.0
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> r.id,source |-> r.ability.source,player |-> d.syntax.controller]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d
d · operator
reference-profile · input revision 2 · CC0 1.0
d == r.technique.definitionExact module download · Source bundle and reproduction instructions
first · operator
reference-profile · input revision 2 · CC0 1.0
first == optional#{} /\ ~before.instances[r.id].usedExact module download · Source bundle and reproduction instructions
Resolved project definitions: optional
optional · operator
reference-profile · input revision 2 · CC0 1.0
optional == execution.partIds \cap ConditionalUseOptionalParts96(d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, ConditionalUseOptionalParts96
used · operator
reference-profile · input revision 2 · CC0 1.0
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> r.id,source |-> r.ability.source,player |-> d.syntax.controller]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d
keys · operator
reference-profile · input revision 2 · CC0 1.0
keys == {groups[id] : id \in DOMAIN groups}Exact module download · Source bundle and reproduction instructions
observed · operator
reference-profile · input revision 2 · CC0 1.0
observed == [i \in 1..Len(order) |-> [group |-> groups[order[i]],descriptor |-> WouldDescriptor99(effects[order[i]]),
periods |-> periods,serial |-> before.serial+i,reference |-> ref,snapshotId |-> worldId]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldDescriptor99
owner · operator
reference-profile · input revision 2 · CC0 1.0
owner == [imminenceId |-> imminence,context |-> WouldContextKey99(ref)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldContextKey99
payload · operator
reference-profile · input revision 2 · CC0 1.0
payload == [before.definition EXCEPT !.instructions=actualReplacement.payload.instructions]Exact module download · Source bundle and reproduction instructions
ancestry · operator
reference-profile · input revision 2 · CC0 1.0
ancestry == ReplacementOverlay99([id \in DOMAIN state.ancestry \ {effectId} |-> state.ancestry[id]],
[id \in DOMAIN outputs |-> state.ancestry[effectId] \cup {chosen}])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: outputs, ReplacementOverlay99
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == state.effects[effectId]Exact module download · Source bundle and reproduction instructions
effects · operator
reference-profile · input revision 2 · CC0 1.0
effects == ReplacementOverlay99([id \in DOMAIN state.effects \ {effectId} |-> state.effects[id]],outputs)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: outputs, ReplacementOverlay99
outputs · operator
reference-profile · input revision 2 · CC0 1.0
outputs == ReplacementOutputs99(effect,replacements[chosen],resultIds)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effect, ReplacementOutputs99
r · operator
reference-profile · input revision 2 · CC0 1.0
r == ReplacementRecords99(context,world)[id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementRecords99
additions · operator
reference-profile · input revision 2 · CC0 1.0
additions == [id \in ids |-> IF policy="Preserve" THEN groups[input] ELSE Append(groups[input],id)]Exact module download · Source bundle and reproduction instructions
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == SubIds6(step.resultIds)Exact module download · Source bundle and reproduction instructions
input · operator
reference-profile · input revision 2 · CC0 1.0
input == Head(steps).effectIdExact module download · Source bundle and reproduction instructions
next · operator
reference-profile · input revision 2 · CC0 1.0
next == ReplacementOverlay99([id \in DOMAIN groups \ {input} |-> groups[id]],additions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: additions, input, ReplacementOverlay99
policy · operator
reference-profile · input revision 2 · CC0 1.0
policy == replacements[step.chosen].wouldGroupingExact module download · Source bundle and reproduction instructions
Resolved project definitions: step
step · operator
reference-profile · input revision 2 · CC0 1.0
step == Head(steps).decisionExact module download · Source bundle and reproduction instructions
key · operator
reference-profile · input revision 2 · CC0 1.0
key == AbilityKey99(d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(beforeStack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
key · operator
reference-profile · input revision 2 · CC0 1.0
key == AbilityKey99(d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(beforeStack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
count · operator
reference-profile · input revision 2 · CC0 1.0
count == actualCount.countExact module download · Source bundle and reproduction instructions
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == DOMAIN rowsExact module download · Source bundle and reproduction instructions
grant · operator
reference-profile · input revision 2 · CC0 1.0
grant == before.applications[application].definitionExact module download · Source bundle and reproduction instructions
keep · operator
reference-profile · input revision 2 · CC0 1.0
keep == SubSeq(old,1,IF count<Len(old) THEN count ELSE Len(old))Exact module download · Source bundle and reproduction instructions
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == SubIds6(old) \ SubIds6(keep)Exact module download · Source bundle and reproduction instructions
old · operator
reference-profile · input revision 2 · CC0 1.0
old == SubRowsFromEffect98(before,application)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubRowsFromEffect98
present · operator
reference-profile · input revision 2 · CC0 1.0
present == (before.present \ lost) \cup gainedExact module download · Source bundle and reproduction instructions
result · operator
reference-profile · input revision 2 · CC0 1.0
result == OrderChangedState98(before,rows,EmptyOrder98,present,spine,decision,"SelfStaticResize",lost,"Grant")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost, present, EmptyOrder98, OrderChangedState98
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in RemainingBarrierInstructions98(loop,e)Exact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in loop.initialEligibleExact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in RemainingBarrierInstructions98(loop,e)Exact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \notin loop.initialEligibleExact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in RemainingBarrierInstructions98(loop,e) \ loop.initialEligibleExact module download · Source bundle and reproduction instructions
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [beforeP.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
observed · operator
reference-profile · input revision 2 · CC0 1.0
observed == [beforeLedger EXCEPT !.instances[beforeP.id].expected=[i \in DOMAIN @ \cup {plan.index} |->
IF i=plan.index THEN [instruction |-> InstructionWindowRef93(plan),effects |-> actualExpected.effects] ELSE @[i]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [beforeP.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
row · operator
reference-profile · input revision 2 · CC0 1.0
row == rows[id]Exact module download · Source bundle and reproduction instructions
a · operator
reference-profile · input revision 2 · CC0 1.0
a == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
subs · operator
reference-profile · input revision 2 · CC0 1.0
subs == IF actualEffect.operation="NoEffects" THEN {}
ELSE CASE intent.classification.mode="All" -> CurrentUnsuppressedBarrierInstructions98(before)
[] intent.classification.mode="Hook" -> CurrentUnsuppressedBarrierInstructions98(before) \ selection.targets
[] OTHER -> SuppressInstructionOrdinaryCandidates98(before,intent.classification) \cap selection.targetsExact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentUnsuppressedBarrierInstructions98, SuppressInstructionOrdinaryCandidates98
a · operator
reference-profile · input revision 2 · CC0 1.0
a == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
resolving · operator
reference-profile · input revision 2 · CC0 1.0
resolving == [before.ability EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
returned · operator
reference-profile · input revision 2 · CC0 1.0
returned == [before.ability EXCEPT !.returned=TRUE]Exact module download · Source bundle and reproduction instructions
returned · operator
reference-profile · input revision 2 · CC0 1.0
returned == [before.ability EXCEPT !.returned=TRUE]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == r.metadata.sourceEntry.afterExact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == r.sourceEntry.afterExact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(before)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [r.metadata.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [r.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == r.metadata.sourceEntry.afterExact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == r.sourceEntry.afterExact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [r.metadata.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]Exact module download · Source bundle and reproduction instructions
p · operator
reference-profile · input revision 2 · CC0 1.0
p == [r.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]Exact module download · Source bundle and reproduction instructions
ids · operator
reference-profile · input revision 2 · CC0 1.0
ids == {id \in DOMAIN rows : rows[id].effect=application}Exact module download · Source bundle and reproduction instructions
ordered · operator
reference-profile · input revision 2 · CC0 1.0
ordered == SelectSeq(gainOrder,LAMBDA id : id \in ids)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in idsExact module download · Source bundle and reproduction instructions
effect · operator
reference-profile · input revision 2 · CC0 1.0
effect == r.technique.definition.delayedEffectExact module download · Source bundle and reproduction instructions
grant · operator
reference-profile · input revision 2 · CC0 1.0
grant == grants[id]Exact module download · Source bundle and reproduction instructions
owner · operator
reference-profile · input revision 2 · CC0 1.0
owner == owners[grant.instance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: grant
d · operator
reference-profile · input revision 2 · CC0 1.0
d == orderState.definitions[sub]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: sub
sub · operator
reference-profile · input revision 2 · CC0 1.0
sub == actualOrder.order[1]Exact module download · Source bundle and reproduction instructions
w · operator
reference-profile · input revision 2 · CC0 1.0
w == WindowTop9(stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : before.provenance[id].kind="Printed"Exact module download · Source bundle and reproduction instructions
count · operator
reference-profile · input revision 2 · CC0 1.0
count == actualCount.countExact module download · Source bundle and reproduction instructions
gained · operator
reference-profile · input revision 2 · CC0 1.0
gained == DOMAIN rowsExact module download · Source bundle and reproduction instructions
keep · operator
reference-profile · input revision 2 · CC0 1.0
keep == SubSeq(old,1,IF count<Len(old) THEN count ELSE Len(old))Exact module download · Source bundle and reproduction instructions
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == SubIds6(old) \ SubIds6(keep)Exact module download · Source bundle and reproduction instructions
old · operator
reference-profile · input revision 2 · CC0 1.0
old == SelectSeq(before.order,LAMBDA id : before.provenance[id].kind="Printed")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
present · operator
reference-profile · input revision 2 · CC0 1.0
present == (before.present \ lost) \cup gainedExact module download · Source bundle and reproduction instructions
result · operator
reference-profile · input revision 2 · CC0 1.0
result == OrderChangedState98(before,rows,EmptyOrder98,present,spine,decision,"PrintedResize",lost,"Printed")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost, present, EmptyOrder98, OrderChangedState98
raw · operator
reference-profile · input revision 2 · CC0 1.0
raw == SimultaneousRawDependencies912(s)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousRawDependencies912
child · operator
reference-profile · input revision 2 · CC0 1.0
child == s.effects[edge.dependent].sourceExact module download · Source bundle and reproduction instructions
host · operator
reference-profile · input revision 2 · CC0 1.0
host == s.effects[edge.prerequisite].sourceExact module download · Source bundle and reproduction instructions
outputs · operator
reference-profile · input revision 2 · CC0 1.0
outputs == ReplacementOverlay99(s.outputs,[key \in {id} |-> view.actions])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: view, ReplacementOverlay99
view · operator
reference-profile · input revision 2 · CC0 1.0
view == SimultaneousView912(s,id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousView912
abilities · operator
reference-profile · input revision 2 · CC0 1.0
abilities == IF lossAll THEN {} ELSE IF lossExcept THEN row.abilities \cap s.printed[target].printedBarrierInstructions ELSE row.abilitiesExact module download · Source bundle and reproduction instructions
Resolved project definitions: lossAll, lossExcept, row
all · operator
reference-profile · input revision 2 · CC0 1.0
all == SimultaneousAllActions912(outputs)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousAllActions912
blocked · operator
reference-profile · input revision 2 · CC0 1.0
blocked == row.cannotGain \/ lossAll \/ lossExceptExact module download · Source bundle and reproduction instructions
Resolved project definitions: lossAll, lossExcept, row
local · operator
reference-profile · input revision 2 · CC0 1.0
local == {a \in actions : a.target=target}Exact module download · Source bundle and reproduction instructions
lossAll · operator
reference-profile · input revision 2 · CC0 1.0
lossAll == \E a \in local : a.kind="LoseAllAbilities"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: local
lossExcept · operator
reference-profile · input revision 2 · CC0 1.0
lossExcept == \E a \in local : a.kind="LoseExceptPrintedBarrierInstructions"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: local
numeric · operator
reference-profile · input revision 2 · CC0 1.0
numeric == {a \in all : a.target=target /\ a.kind="Numeric"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: all
row · operator
reference-profile · input revision 2 · CC0 1.0
row == s.chars[target]Exact module download · Source bundle and reproduction instructions
subtype · operator
reference-profile · input revision 2 · CC0 1.0
subtype == {a \in all : a.target=target /\ a.kind="Subtype"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: all
pairs · operator
reference-profile · input revision 2 · CC0 1.0
pairs == {[dependent |-> b,prerequisite |-> a] : b \in s.waiting,a \in s.waiting}Exact module download · Source bundle and reproduction instructions
e · operator
reference-profile · input revision 2 · CC0 1.0
e == s.effects[id]Exact module download · Source bundle and reproduction instructions
enabled · operator
reference-profile · input revision 2 · CC0 1.0
enabled == SimultaneousEnabled912(s,e)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: e, SimultaneousEnabled912
targets · operator
reference-profile · input revision 2 · CC0 1.0
targets == IF enabled THEN SimultaneousTargets912(s,e) ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: e, enabled, SimultaneousTargets912
source · operator
reference-profile · input revision 2 · CC0 1.0
source == definition.source.objectExact module download · Source bundle and reproduction instructions
host · operator
reference-profile · input revision 2 · CC0 1.0
host == objects[Specimen0203].hostExact module download · Source bundle and reproduction instructions
host · operator
reference-profile · input revision 2 · CC0 1.0
host == objects[Specimen0203].hostExact module download · Source bundle and reproduction instructions
selected · operator
reference-profile · input revision 2 · CC0 1.0
selected == Specimen0219RootCards912(world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: Specimen0219RootCards912
unit · operator
reference-profile · input revision 2 · CC0 1.0
unit == a.units[CHOOSE i \in 1..Len(a.units) : a.units[i].id=id]Exact module download · Source bundle and reproduction instructions
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : state.provenance[id].kind="Grant" /\ state.provenance[id].effect=applicationExact module download · Source bundle and reproduction instructions
r · operator
reference-profile · input revision 2 · CC0 1.0
r == CHOOSE r \in rows : TRUEExact module download · Source bundle and reproduction instructions
available · operator
reference-profile · input revision 2 · CC0 1.0
available == SuppressInstructionOrdinaryCandidates98(e,intent.classification)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SuppressInstructionOrdinaryCandidates98
minimum · operator
reference-profile · input revision 2 · CC0 1.0
minimum == IF Cardinality(available)<intent.classification.minimumTargets THEN Cardinality(available) ELSE intent.classification.minimumTargetsExact module download · Source bundle and reproduction instructions
Resolved project definitions: available
lost · operator
reference-profile · input revision 2 · CC0 1.0
lost == {id \in before[i].pending \cap DOMAIN beforeLedger.instances : afterLedger.instances[id].status # "Pending"}Exact module download · Source bundle and reproduction instructions
invocation · operator
reference-profile · input revision 2 · CC0 1.0
invocation == world.ruleInvocations[entry.ruleInvocation]Exact module download · Source bundle and reproduction instructions
marked · operator
reference-profile · input revision 2 · CC0 1.0
marked == [w EXCEPT !.site.traversalEnding=TRUE]Exact module download · Source bundle and reproduction instructions
info · operator
reference-profile · input revision 2 · CC0 1.0
info == IF turn.owner = "SideA" THEN SideAStepInfo5(step) ELSE SideBStepInfo5(step)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SideAStepInfo5, SideBStepInfo5
steps · operator
reference-profile · input revision 2 · CC0 1.0
steps == IF turn.owner = "SideA" THEN SetupRange(SideASteps5) ELSE SetupRange(SideBSteps5)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SetupRange, SideASteps5, SideBSteps5
LAMBDA · operator
reference-profile · input revision 2 · CC0 1.0
LAMBDA id : id \in presentExact module download · Source bundle and reproduction instructions
AbilityActive9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityActive9(ability,objects,effectivePresentIds,actualDefaultCardActive,context) ==
IF ability.id \notin effectivePresentIds THEN FALSE
ELSE IF ability.provider = "Lingering" THEN ability.id \in context.lingeringAbilities
ELSE IF ability.source.kind = "Rule" THEN ability.source.rule \in context.activeRules
ELSE IF ability.source.object \notin DOMAIN objects THEN FALSE
ELSE LET o == objects[ability.source.object]
IN IF o.form = "Counter" THEN TRUE
ELSE IF SideBFacedown8(o) THEN FALSE
ELSE actualDefaultCardActive \/
(ability.kind="Conditional" /\ ability.sourceItemInspection) \/
o.zone \in ability.statedZones \cup ability.rulesOnlyZones \/
ability.ownPermissionModifier \/ ability.ownCostModifier \/ ability.ownProgressRequirement \/
ability.ownClaimObjectiveAdditionalCost \/ (ability.allowsProgress /\ ActivationStatus8(o)="Dormant") \/
(IF ability.id \in DOMAIN context.departureHolds
THEN DepartureHoldLive9(context.departureHolds[ability.id],ability,objects,context.instances) ELSE FALSE) \/
(ability.kind="BarrierInstruction" /\ ~o.deployed /\ context.encounterLive /\ context.encounteredObject=ability.source.object) \/
ability.id \in context.persistentAbilitiesExact module download · Source bundle and reproduction instructions
Resolved project definitions: o, DepartureHoldLive9, ActivationStatus8, SideBFacedown8
AbilityDefinition9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityDefinition9(id,kind,source,provider) ==
[id |-> id,kind |-> kind,source |-> source,provider |-> provider,sourceItemInspection |-> FALSE,
statedZones |-> {},rulesOnlyZones |-> {},ownPermissionModifier |-> FALSE,ownCostModifier |-> FALSE,
ownProgressRequirement |-> FALSE,ownClaimObjectiveAdditionalCost |-> FALSE,allowsProgress |-> FALSE]Exact module download · Source bundle and reproduction instructions
AbilityFlagKinds93 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityFlagKinds93 == {"ItemInspection","Interface","Interrupt","Persistent","Threat","OncePerTurn"}Exact module download · Source bundle and reproduction instructions
AbilityInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityInterrupt99(d,lex) ==
d.syntax.kind \in {"Paid","Conditional"} /\
(FlagPresent93(d.syntax.units,"Interrupt") \/ {"prevent","avoid","would"} \cap OperativeInterruptWords99(d,lex) # {})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93, OperativeInterruptWords99
AbilityIsInterrupt9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityIsInterrupt9(actualInterruptFlag,actualInstructionContainsWould) ==
actualInterruptFlag \/ actualInstructionContainsWouldExact module download · Source bundle and reproduction instructions
AbilityIsResolving9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityIsResolving9(f) == f.firstImminent /\ ~f.lastFinishedExact module download · Source bundle and reproduction instructions
AbilityKey99 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityKey99(d) == [ability |-> d.syntax.id,source |-> d.syntax.source]Exact module download · Source bundle and reproduction instructions
AbilityKinds9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityKinds9 == {"Static","Paid","Conditional","Play","BarrierInstruction"}Exact module download · Source bundle and reproduction instructions
AbilityLexemesValid99 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityLexemesValid99(d,lex,objects,cardFacts) ==
/\ lex.tag="NormalizedAbilityLexemes" /\ lex.definition=d /\ lex.source=d.syntax.source
/\ lex.origin.tag="AbilityTextOrigin" /\ lex.origin.recipientSource=d.syntax.source /\ lex.origin.provider=d.activity.provider
/\ \A id \in DOMAIN lex.mentions : id \in Nat \ {0} /\ AbilityMentionValid99(d,lex.mentions[id])
/\ (IF "instructionHasWould" \in DOMAIN d THEN d.instructionHasWould => "would" \in OperativeInterruptWords99(d,lex) ELSE TRUE)
/\ IF d.syntax.source.kind="Rule" THEN
/\ lex.card="NoValue" /\ lex.origin.rule=d.syntax.source.rule
/\ lex.sourceSHA="0186148ecd6da8170b6555aa90d3f0115a8d5150d807078b75ac2339a2a1421e"
ELSE /\ lex.card \in DOMAIN cardFacts /\ lex.sourceSHA=cardFacts[lex.card].sourceSHA
/\ lex.origin.card=lex.card /\ lex.origin.sourceSHA=lex.sourceSHA
/\ IF d.activity.provider="Printed" /\ d.syntax.source.object \in DOMAIN objects
THEN objects[d.syntax.source.object].card=lex.card ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityMentionValid99, OperativeInterruptWords99
AbilityMentionValid99 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityMentionValid99(d,mention) ==
/\ mention.unit \in 1..Len(d.syntax.units)
/\ mention.role \in {"EffectOperator","ImminentTrigger","ActualOccurrenceTrigger","OtherOwnText","OtherAbility","StaticDeclaration"}
/\ (mention.owner=AbilityKey99(d))=(mention.role # "OtherAbility")
/\ mention.role="EffectOperator" => d.syntax.units[mention.unit].category="Instruction"
/\ mention.role \in {"ImminentTrigger","ActualOccurrenceTrigger"} =>
d.syntax.units[mention.unit].category="SchemaAtom043" /\ d.syntax.units[mention.unit].primary
/\ mention.role="ImminentTrigger" => mention.word="would"
/\ mention.role="StaticDeclaration" => d.syntax.units[mention.unit].category="Declaration"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
AbilityOwnWords99 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityOwnWords99(d,lex) ==
{lex.mentions[id].word : id \in {t \in DOMAIN lex.mentions : lex.mentions[t].owner=AbilityKey99(d)}}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
AbilityShape9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityShape9(kind,instructions) ==
kind \in AbilityKinds9 /\ IF kind = "Static" THEN Len(instructions) = 0 ELSE Len(instructions) > 0Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKinds9
AbilitySource9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilitySource9(origin,printedObject,recipient,effectCreator,rule) ==
CASE origin = "Printed" -> ObjectAbilitySource9(printedObject)
[] origin = "Granted" -> ObjectAbilitySource9(recipient)
[] origin = "Lingering" -> ObjectAbilitySource9(effectCreator)
[] origin = "Rule" -> RuleAbilitySource9(rule)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObjectAbilitySource9, RuleAbilitySource9
AbilitySourceItemInspectionMatches9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilitySourceItemInspectionMatches9(ability,event) ==
/\ ability.kind = "Conditional" /\ ability.sourceItemInspection /\ ability.source.kind = "Object"
/\ event.tag = "ItemInspectionCard" /\ event.object = ability.source.objectExact module download · Source bundle and reproduction instructions
AbilityTextPartition9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityTextPartition9(tokenCount,units) ==
/\ tokenCount \in Nat
/\ UNION {units[id].tokens : id \in DOMAIN units} = 1..tokenCount
/\ \A a,b \in DOMAIN units : a # b => units[a].tokens \cap units[b].tokens = {}
/\ \A id \in DOMAIN units : AbilityShape9(units[id].kind,units[id].instructions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityShape9
AbilityTextValid93 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityTextValid93(a) ==
/\ TextUnitsValid93(a.units) /\ FlagPrefixValid93(a.units,a.arrowAfterFlags)
/\ a.kind \in AbilityKinds9 /\ InferredAbilityKind93(a)=a.kind
/\ AbilityShape9(a.kind,IF TextUnitIds93(a.units,"Instruction")={} THEN <<>> ELSE <<1>>)
/\ a.kind="Static" \/ TextUnitIds93(a.units,"Declaration")={}
/\ ~a.barrierInstructionPrefix \/ ~a.paidPrefix.present
/\ \A i \in {j \in 1..Len(a.units) : a.units[j].category="AbilityFlag"} :
CASE a.units[i].subtype="ItemInspection" -> a.kind="Paid" /\ a.side="SideB"
[] a.units[i].subtype="Interface" -> a.kind="Paid" /\ a.side="SideB"
[] a.units[i].subtype="Interrupt" -> a.kind \in {"Paid","Conditional"}
[] a.units[i].subtype="Persistent" -> a.side="SideA"
[] a.units[i].subtype="Threat" -> a.units[i].value \in Nat
[] a.units[i].subtype="OncePerTurn" -> a.kind \in {"Paid","Conditional"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKinds9, AbilityShape9, FlagPrefixValid93, InferredAbilityKind93, TextUnitIds93, TextUnitsValid93
AbilityUseDue9 · operator
reference-profile · input revision 2 · CC0 1.0
AbilityUseDue9(kind,entirelyMandatory,actualTriggerCostPaid,actualOptionalEffectsResolved,actualOtherOptionalChoiceComplete) ==
CASE kind = "Paid" -> actualTriggerCostPaid
[] kind = "Conditional" -> ~entirelyMandatory /\ actualOptionalEffectsResolved
[] OTHER -> ~entirelyMandatory /\ actualOtherOptionalChoiceCompleteExact module download · Source bundle and reproduction instructions
ActionablePriority9 · operator
reference-profile · input revision 2 · CC0 1.0
ActionablePriority9(stack) ==
IF Len(stack) = 0 THEN {}
ELSE LET w == WindowTop9(stack)
IN IF w.open /\ w.stage = "Ready" /\ w.checkpoint # 0 /\ w.busy.id = 0 /\ w.priority \in SetupPlayers
THEN {w.priority} ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, SetupPlayers
ActiveExampleFamily062Sources98 · operator
reference-profile · input revision 2 · CC0 1.0
ActiveExampleFamily062Sources98(sources,objects,present,context,points) ==
{id \in DOMAIN sources :
BarrierInstructionCurrentActive98(sources[id],objects,present,context,points)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionCurrentActive98
ActiveLingeringIds910 · operator
reference-profile · input revision 2 · CC0 1.0
ActiveLingeringIds910(registry,world) ==
{id \in DOMAIN registry.effects : registry.effects[id].status="Active" /\ LingeringWantsActive910(registry.effects[id],registry.effects,world)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringWantsActive910
ActivePlayer9 · operator
reference-profile · input revision 2 · CC0 1.0
ActivePlayer9(turn) == TurnActivePlayer5(turn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TurnActivePlayer5
ActiveReplacementBlueprints99 · operator
reference-profile · input revision 2 · CC0 1.0
ActiveReplacementBlueprints99(context,world) ==
[id \in {r \in DOMAIN ReplacementRecords99(context,world) : ReplacementRecordActive99(ReplacementRecords99(context,world)[r],context,world)} |->
ReplacementRecords99(context,world)[id].blueprint]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementRecordActive99, ReplacementRecords99
ActivityContext9 · operator
reference-profile · input revision 2 · CC0 1.0
ActivityContext9 ==
[inspectedItemObject |-> 0,encounteredObject |-> 0,encounterLive |-> FALSE,
departureHolds |-> [id \in {} |-> id],instances |-> [id \in {} |-> id],
persistentAbilities |-> {},lingeringAbilities |-> {},activeRules |-> {}]Exact module download · Source bundle and reproduction instructions
ActualExpectedEffects99 · operator
reference-profile · input revision 2 · CC0 1.0
ActualExpectedEffects99(effects) ==
[id \in {effect \in DOMAIN effects : effects[effect].kind \notin {"Damage","ExposureMarkers"} \/ effects[effect].value>0} |->
IF effects[id].kind="Cost" THEN [effects[id] EXCEPT !.value=ModifiedCost(@,<<>>,<<>>)] ELSE effects[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ModifiedCost
ActualImminenceEntry99 · operator
reference-profile · input revision 2 · CC0 1.0
ActualImminenceEntry99(entry,origin,world,cardFacts) ==
/\ ExpectedWorldValid99(world)
/\ entry.id \in DOMAIN world.entries /\ world.entries[entry.id]=entry
/\ IF origin.kind="BarrierInstruction" THEN BarrierInstructionCallerEntry99(entry,world,cardFacts) /\ origin.procedure=entry.procedure
ELSE InstructionCallerEntry99(entry,world,cardFacts) /\ InstructionEntryOrigin99(entry,origin)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionCallerEntry99, ExpectedWorldValid99, InstructionCallerEntry99, InstructionEntryOrigin99
ActualOccurrenceEntry912 · operator
reference-profile · input revision 2 · CC0 1.0
ActualOccurrenceEntry912(entry,origin,world,lifetimes,authority) ==
/\ entry.tag="ActualOccurrenceInstructionEntry" /\ entry.id \in Nat \ {0} /\ entry.snapshotId=world.id
/\ entry.id \in DOMAIN world.entries /\ world.entries[entry.id]=entry
/\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ origin.kind="Instruction" /\ origin.ruleStep="NoValue" /\ origin.plan=entry.afterPlan /\ origin.parent=entry.after.ability
/\ entry.owner=OccurrencePriorityOwner912(entry.after) /\ entry.stackBefore=entry.stackAfter
/\ IF entry.before.metadata.kind="Conditional" THEN
/\ ConditionalOccurrenceBound912(entry.beforeLedger,entry.before)
/\ ConditionalSnapshotBound96(world.conditional,entry.afterLedger)
/\ entry.afterLedger=[entry.beforeLedger EXCEPT !.instances[entry.before.id].status="Imminent"]
/\ entry.beforeLedger.instances[entry.before.id].status="Resolving"
/\ EnterNextOccurrence912(entry.before,entry.after,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,
entry.beforeLedger,entry.stackBefore,lifetimes,authority)
ELSE /\ SourceOccurrenceBound912(entry.before)
/\ EnterNextOccurrence912(entry.before,entry.after,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,
entry.ledger,entry.stackBefore,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalOccurrenceBound912, ConditionalSnapshotBound96, EnterNextOccurrence912, OccurrencePriorityOwner912, SourceOccurrenceBound912
ActualRuntimeEntry911 · operator
reference-profile · input revision 2 · CC0 1.0
ActualRuntimeEntry911(entry,origin,world,lifetimes,authority,cardFacts) ==
/\ LifetimeReady910(lifetimes,authority) /\ ExpectedWorldValid99(world)
/\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ entry.id \in DOMAIN world.entries /\ world.entries[entry.id]=entry
/\ entry.tag="ActualGraphInstructionEntry" /\ entry.id \in Nat \ {0} /\ entry.snapshotId=world.id
/\ origin.kind="Instruction" /\ origin.ruleStep="NoValue" /\ origin.plan=entry.afterPlan /\ origin.parent=entry.after.ability
/\ entry.owner=IF entry.kind \in {"SourceFirst","SourceNext"} THEN entry.after.sourceOwner
ELSE [windowId |-> entry.after.windowId,option |-> entry.after.option,transaction |-> entry.after.transaction]
/\ BarrierInstructionOwnerAtTop98(entry.owner,entry.stackAfter)
/\ CASE entry.kind="ConditionalFirst" ->
/\ ConditionalSnapshotBound96(world.conditional,entry.afterLedger)
/\ ConditionalStartWorld911(entry,world,authority)
/\ IF WindowTop9(entry.stackBefore).kind="Interrupt" THEN
/\ entry.parentWorld.id=world.id /\ entry.parentWorld.objects=world.objects
/\ entry.parentWorld.turn=world.turn /\ entry.parentWorld.traversalControl=world.traversalControl
/\ entry.parentWorld.conditional=SnapshotWithConditionalRegistry96(world.conditional,entry.beforeLedger)
/\ entry.parentWorld.turnUses=world.turnUses
/\ BeginInterruptRuntime911(entry.beforeLedger,entry.afterLedger,entry.stackBefore,entry.stackAfter,entry.before,entry.after,
entry.snapshot,entry.option,entry.legality,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,entry.turnUses,
entry.restrictions,lifetimes,authority,entry.parentContext,entry.parentOrigin,entry.parentWorld,entry.parentHistory,cardFacts)
ELSE BeginConditionalRuntime911(entry.beforeLedger,entry.afterLedger,entry.stackBefore,entry.stackAfter,entry.before,entry.after,
entry.snapshot,entry.option,entry.legality,entry.currentEffect,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,
entry.turnUses,entry.restrictions,lifetimes,authority,cardFacts)
[] entry.kind="ConditionalNext" ->
/\ ConditionalSnapshotBound96(world.conditional,entry.afterLedger)
/\ entry.stackBefore=entry.stackAfter
/\ EnterNextConditionalRuntime911(entry.beforeLedger,entry.afterLedger,entry.stackBefore,entry.before,entry.after,
entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,lifetimes,authority)
[] entry.kind="SourceFirst" ->
/\ entry.owner=entry.after.sourceOwner
/\ AdoptSourceRuntime911(entry.after,entry.after.technique,entry.sourceEntry,entry.sourceOrigin,world,lifetimes,authority,cardFacts)
/\ entry.afterPlan=entry.sourceEntry.afterPlan /\ entry.stackAfter=entry.sourceEntry.stackAfter
[] entry.kind="SourceNext" ->
/\ entry.owner=entry.after.sourceOwner /\ entry.stackBefore=entry.stackAfter
/\ EnterNextSourceRuntime911(entry.before,entry.after,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,
entry.ledger,entry.stackBefore,lifetimes,authority)
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: AdoptSourceRuntime911, BarrierInstructionOwnerAtTop98, BeginConditionalRuntime911, BeginInterruptRuntime911, ConditionalSnapshotBound96, ConditionalStartWorld911, EnterNextConditionalRuntime911, EnterNextSourceRuntime911, ExpectedWorldValid99, LifetimeReady910, SnapshotWithConditionalRegistry96, WindowTop9
ActualWouldMembership99 · operator
reference-profile · input revision 2 · CC0 1.0
ActualWouldMembership99(opening,world,periods) ==
/\ ExpectedWorldValid99(world) /\ DOMAIN periods=ActualWouldPeriods99(world)
/\ \A ref \in DOMAIN periods :
/\ WouldPeriodMembership99(opening,ref,periods[ref])
/\ CASE ref.kind="Turn" -> periods[ref].frame=world.turn
[] ref.kind="SchemaAtom138" -> periods[ref].frame=world.traversalControl.traversal
[] OTHER -> periods[ref].frame=world.activePeriods[ref]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActualWouldPeriods99, ExpectedWorldValid99, WouldPeriodMembership99
ActualWouldPeriods99 · operator
reference-profile · input revision 2 · CC0 1.0
ActualWouldPeriods99(world) ==
{TimingRef9("Turn",world.turn.id)} \cup
(IF DuringTraversal6(world.traversalControl.traversal) THEN {TimingRef9("SchemaAtom138",world.traversalControl.traversal.id)} ELSE {}) \cup DOMAIN world.activePeriodsExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9, DuringTraversal6
AdoptOccurrenceRuntime912 · operator
reference-profile · input revision 2 · CC0 1.0
AdoptOccurrenceRuntime912(before,after,spec,context,origin,ledger,world,lifetimes,authority,cardFacts) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(before,authority)
/\ OccurrenceSpecificationValid912(spec,before.technique,world.objects,cardFacts)
/\ before.visited= <<>> /\ before.pc=before.technique.entry /\ before.phase="Resolve"
/\ context.phase="Resolving" /\ context.currentWorld=world.id /\ world.id=authority.current.id
/\ origin.kind="Instruction" /\ origin.ruleStep="NoValue"
/\ ConditionalCreationInstruction96(origin.plan,origin.parent,origin.ruleStep)
/\ context.currentRef=InstructionWindowRef93(origin.plan) /\ origin.parent=before.ability /\ RuntimeCurrentPlan911(before,origin.plan)
/\ IF before.ability.kind="Conditional" THEN ConditionalRuntimeBound911(ledger,before) /\ ledger.instances[before.id].status="Resolving"
ELSE SourceRuntimeBound911(before)
/\ after=NewOccurrenceRuntime912(before,spec)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCreationInstruction96, ConditionalRuntimeBound911, InstructionWindowRef93, LifetimeReady910, NewOccurrenceRuntime912, OccurrenceSpecificationValid912, RuntimeCurrentPlan911, RuntimeOwnerCurrent911, SourceRuntimeBound911
AdoptSourceRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
AdoptSourceRuntime911(r,technique,entry,sourceOrigin,world,lifetimes,authority,cardFacts) ==
/\ LifetimeReady910(lifetimes,authority) /\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ entry.kind \in {"Paid","PlayFirst","BarrierInstructionFirst","NestedBarrierInstructionFirst"}
/\ ActualImminenceEntry99(entry,sourceOrigin,world,cardFacts)
/\ entry.after.ability.firstImminent /\ entry.after.ability.cursor=1 /\ entry.beforePlan.index=1
/\ CompiledInstructionTechnique911(technique,world.objects,cardFacts)
/\ technique.definition=SourceEntryDefinition911(entry) /\ technique.entry=entry.afterPlan.id
/\ r=AdoptedRuntimeValue911(technique,entry) /\ RuntimeCurrentPlan911(r,entry.afterPlan)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActualImminenceEntry99, AdoptedRuntimeValue911, CompiledInstructionTechnique911, LifetimeReady910, RuntimeCurrentPlan911, SourceEntryDefinition911
AdoptedRuntimeValue911 · operator
reference-profile · input revision 2 · CC0 1.0
AdoptedRuntimeValue911(technique,entry) ==
ReplacementOverlay99(NewInstructionRuntime911(entry.after.id,technique,entry.after.ability.kind,entry.after.ability.sourceZone,entry.after.ability.caller),
[ability |-> [entry.after.ability EXCEPT !.instructions= <<technique.entry>>],phase |-> "Imminent",
sourceEntry |-> entry,sourceOwner |-> SourceEntryOwner911(entry)])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewInstructionRuntime911, ReplacementOverlay99, SourceEntryOwner911
AdvanceBarrierInstructionStep98 · operator
reference-profile · input revision 2 · CC0 1.0
AdvanceBarrierInstructionStep98(loop,before,after,e,forcedStep,afterForcedStep,actualReturn) ==
/\ BarrierInstructionLoopMatches98(loop,e) /\ loop.current=0 /\ BarrierInstructionStep98(e,before,forcedStep)
/\ actualReturn.tag="BarrierInstructionLoopStepReturn" /\ actualReturn.encounter=e.id /\ actualReturn.complete /\ actualReturn.normalCheckpointAndReactionsDrained
/\ actualReturn.history=loop.history
/\ actualReturn.attempt \in Nat
/\ IF actualReturn.attempt=0 THEN RemainingBarrierInstructions98(loop,e)={}
ELSE Len(loop.history)>0 /\ loop.history[Len(loop.history)].instance=actualReturn.attempt
/\ LET next == IF actualReturn.attempt=0 THEN "ProcedureCode687f72772ab1" ELSE "ProcedureCodeaa0828fbf852"
IN /\ IF e.forced THEN after=before /\ afterForcedStep=next
ELSE after=[before EXCEPT !.traversal.step=next] /\ afterForcedStep=nextExact module download · Source bundle and reproduction instructions
Resolved project definitions: next, BarrierInstructionLoopMatches98, BarrierInstructionStep98, RemainingBarrierInstructions98
AdvanceConditionalTraversalStep96 · operator
reference-profile · input revision 2 · CC0 1.0
AdvanceConditionalTraversalStep96(before,after,beforeControl,afterControl,layout,activated,e,m,work,newPhaseId,actualComplete,actualCheckpointDrained,actualStep) ==
/\ AdvanceNormalTraversalStep6(beforeControl,afterControl,layout,activated,e,m,work,newPhaseId,actualComplete,actualCheckpointDrained,{})
/\ actualStep.structure=TimingRef9("TraversalPhase",beforeControl.traversal.phaseId) /\ actualStep.procedureId=beforeControl.traversal.id
/\ actualStep.step=beforeControl.traversal.step
/\ ObserveConditionalTimingStep96(before,after,actualStep)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveConditionalTimingStep96, TimingRef9, AdvanceNormalTraversalStep6
AdvanceImminentOrigin99 · operator
reference-profile · input revision 2 · CC0 1.0
AdvanceImminentOrigin99(before,after) ==
/\ ImminentOrigin99(before)
/\ IF before.kind="BarrierInstruction" THEN after=[before EXCEPT !.procedure.revision=@+1]
ELSE after=[before EXCEPT !.plan.revision=@+1]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ImminentOrigin99
AggregatedOperations912 · operator
reference-profile · input revision 2 · CC0 1.0
AggregatedOperations912 ==
{"GainResourceUnits","LoseResourceUnits","SpendResourceUnits","GainActionPoints","LoseActionPoints","SpendActionPoints",
"TakeExposureMarkers","RemoveExposureMarkers","PreventExposureMarkers","TakeLiabilityMarker","RemoveLiabilityMarker","PreventLiabilityMarker",
"LookAtCards","RevealCards","Draw","RetireCards","Damage","ShuffleDiscardIntoDeck"}Exact module download · Source bundle and reproduction instructions
AllSetSatisfied912 · operator
reference-profile · input revision 2 · CC0 1.0
AllSetSatisfied912(items,matching,actualPoint,earliestPoint) ==
/\ TimingRefValid9(actualPoint.structure) /\ actualPoint.structure=earliestPoint.structure /\ actualPoint.ordinal>=earliestPoint.ordinal
/\ items \subseteq matchingExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRefValid9
AlterAbilityInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
AlterAbilityInstruction93(ability,before,after,actualModification) ==
/\ ability.phase="Imminent" /\ InstructionPlanMatches93(before,ability,ability.cursor)
/\ AlterImminentInstruction93(before,after,actualModification)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AlterImminentInstruction93, InstructionPlanMatches93
AlterImminentInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
AlterImminentInstruction93(before,after,actualModification) ==
/\ before.phase="Imminent" /\ actualModification.tag="InstructionModification"
/\ actualModification.instruction=before.id /\ actualModification.revision=before.revision
/\ actualModification.authorized /\ Len(actualModification.steps)>0
/\ after=[before EXCEPT !.steps=actualModification.steps,!.revision=@+1]Exact module download · Source bundle and reproduction instructions
AnnounceInstructionTargets93 · operator
reference-profile · input revision 2 · CC0 1.0
AnnounceInstructionTargets93(before,after,actualTargets,abilityFrame,actualRuleStep) ==
/\ before.phase="Planning" /\ actualTargets.tag="InstructionTargets" /\ actualTargets.instruction=before.id
/\ actualTargets.abilityInstance=before.abilityInstance /\ actualTargets.valid
/\ actualTargets.source=before.source /\ actualTargets.sourceZone=before.sourceZone /\ actualTargets.index=before.index
/\ IF before.origin="Ability" THEN PreImminentAbilityPlan93(before,abilityFrame) ELSE RuleInstructionPlan93(before,actualRuleStep)
/\ after=[before EXCEPT !.targets=actualTargets.targets,!.announced=TRUE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PreImminentAbilityPlan93, RuleInstructionPlan93
AnnounceSuppressInstructionInstructionTargets98 · operator
reference-profile · input revision 2 · CC0 1.0
AnnounceSuppressInstructionInstructionTargets98(before,announced,parent,ruleStep,classification,intent,e,control,targets,selection) ==
/\ InstructionSuppressInstructionClassification98(before,classification)
/\ intent=NewInstructionSuppressInstructionIntent98(before,e,classification)
/\ SuppressInstructionTargetsValid98(intent,e,control,targets.targets)
/\ AnnounceInstructionTargets93(before,announced,targets,parent,ruleStep)
/\ selection=NewSuppressInstructionSelection98(intent,announced,targets.targets)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AnnounceInstructionTargets93, InstructionSuppressInstructionClassification98, NewInstructionSuppressInstructionIntent98, NewSuppressInstructionSelection98, SuppressInstructionTargetsValid98
AppendLifetimeTransitionCore910 · operator
reference-profile · input revision 2 · CC0 1.0
AppendLifetimeTransitionCore910(before,after,transition) ==
/\ LifetimeAuthorityValid910(before) /\ LifetimeTransitionValid910(transition)
/\ transition.before=before.current /\ transition.after.id \notin DOMAIN before.worlds
/\ after=LifetimeAuthorityAfter910(before,transition)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeAuthorityAfter910, LifetimeAuthorityValid910, LifetimeTransitionValid910
AppliedReplacementContext99 · operator
reference-profile · input revision 2 · CC0 1.0
AppliedReplacementContext99(before,after,beforeOrigin,afterOrigin,world,nextState,count) ==
/\ OriginAfterRevisions99(beforeOrigin,afterOrigin,count)
/\ LET oldIds == DOMAIN before.state.effects
newIds == DOMAIN nextState.effects
archive == ReplacementOverlay99(before.ancestryArchive,ReplacementOverlay99(before.state.ancestry,nextState.ancestry))
IN after=[before EXCEPT !.state=nextState,!.currentRef=OriginReference99(afterOrigin),!.currentWorld=world.id,
!.templates=ReplacementOverlay99(@,nextState.effects),!.ancestryArchive=archive,
!.retiredEffects=@ \cup (oldIds \ newIds),!.wouldGroups=after.wouldGroups]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: archive, newIds, oldIds, OriginAfterRevisions99, OriginReference99, ReplacementOverlay99
ApplyAutomaticReplacements99 · operator
reference-profile · input revision 2 · CC0 1.0
ApplyAutomaticReplacements99(before,after,beforeOrigin,afterOrigin,world,states,steps,cardFacts,history) ==
/\ InitialWouldCaptured99(before,history)
/\ before.phase="Replacing" /\ ExpectedContextOrigin99(before,beforeOrigin) /\ ExpectedContextWorld99(before,world)
/\ ReplacementSourcesBound99(before,world,cardFacts)
/\ PrepareReplacementEffects99(before.state,states[Len(states)],ActiveReplacementBlueprints99(before,world),
[id |-> world.id,controllers |-> world.controllers],states,steps)
/\ AppliedReplacementContext99(before,after,beforeOrigin,afterOrigin,world,states[Len(states)],Len(steps))
/\ after.wouldGroups=ReplacementWouldGroups99(before.wouldGroups,states,steps,ActiveReplacementBlueprints99(before,world))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveReplacementBlueprints99, AppliedReplacementContext99, ExpectedContextOrigin99, ExpectedContextWorld99, InitialWouldCaptured99, PrepareReplacementEffects99, ReplacementSourcesBound99, ReplacementWouldGroups99
ApplyConditionalTraversalEndPolicy96 · operator
reference-profile · input revision 2 · CC0 1.0
ApplyConditionalTraversalEndPolicy96(before,candidate,after,beforeStack,candidateStack,afterStack,cleanupId,actualCleanup,beforeSnapshot,afterSnapshot) ==
/\ ApplyTraversalEndWindowPolicy9(beforeStack,candidateStack,cleanupId,actualCleanup)
/\ candidate=ConditionalPendingAfterWindows96(before,candidateStack)
/\ ObserveConditionalActivity96(before,candidate,after,candidateStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ApplyTraversalEndWindowPolicy9, ConditionalPendingAfterWindows96, ObserveConditionalActivity96
ApplyCreatedReplacementImmediately99 · operator
reference-profile · input revision 2 · CC0 1.0
ApplyCreatedReplacementImmediately99(before,after,replacements,newId,world,states,steps) ==
/\ newId \in DOMAIN replacements
/\ PrepareReplacementEffects99(before,after,replacements,world,states,steps)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PrepareReplacementEffects99
ApplyExpectedControlCore99 · operator
reference-profile · input revision 2 · CC0 1.0
ApplyExpectedControlCore99(before,after,beforeOrigin,afterOrigin,modifier,plan,operation,world,afterEffects) ==
/\ ExpectedContextOrigin99(before,beforeOrigin) /\ before.phase="WindowOpen" /\ ExpectedContextWorld99(before,world)
/\ ExpectedControlBound99(before,modifier,plan,operation)
/\ operation.operationId \in (Nat \ {0}) \ before.modificationIds
/\ IF ExpectedControlApplies99(before.state.effects,operation)
THEN ExpectedControlStep99(before.state.effects,afterEffects,operation)
ELSE afterEffects=before.state.effects
/\ AdvanceImminentOrigin99(beforeOrigin,afterOrigin)
/\ after=[before EXCEPT !.currentRef=OriginReference99(afterOrigin),!.state.effects=afterEffects,
!.state.ancestry=[id \in DOMAIN afterEffects |-> before.state.ancestry[id]],
!.ancestryArchive=ReplacementOverlay99(@,before.state.ancestry),
!.removedEffects=@ \cup (DOMAIN before.state.effects \ DOMAIN afterEffects),!.modificationIds=@ \cup {operation.operationId},
!.modifications=Append(@,[kind |-> operation.kind,operation |-> operation,modifier |-> modifier.currentRef,
beforeEffects |-> before.state.effects,afterEffects |-> afterEffects,from |-> before.currentRef,to |-> OriginReference99(afterOrigin)])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AdvanceImminentOrigin99, ExpectedContextOrigin99, ExpectedContextWorld99, ExpectedControlApplies99, ExpectedControlBound99, ExpectedControlStep99, OriginReference99, ReplacementOverlay99
ApplyReplacementStep99 · operator
reference-profile · input revision 2 · CC0 1.0
ApplyReplacementStep99(before,after,effectId,replacements,world,decision) ==
/\ ReplacementStateValid99(before) /\ ReplacementBlueprintsValid99(replacements)
/\ world.id \in Nat \ {0} /\ (\A card \in DOMAIN world.controllers : world.controllers[card] \in SetupPlayers)
/\ effectId \in DOMAIN before.effects
/\ (before.effects[effectId].targeted => before.effects[effectId].targetCard \in DOMAIN world.controllers)
/\ decision.chosen \in EligibleReplacements99(before,effectId,replacements)
/\ decision=ReplacementDecision99(before,effectId,replacements,world,decision.chosen,decision.resultIds)
/\ ReplacementOutputIdsValid99(before,before.effects[effectId],replacements[decision.chosen],decision.resultIds)
/\ after=ReplacementNextState99(before,effectId,replacements,decision.chosen,decision.resultIds,decision)
/\ ReplacementStateValid99(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EligibleReplacements99, ReplacementBlueprintsValid99, ReplacementDecision99, ReplacementNextState99, ReplacementOutputIdsValid99, ReplacementStateValid99, SetupPlayers
ApplySimultaneousEffect912 · operator
reference-profile · input revision 2 · CC0 1.0
ApplySimultaneousEffect912(before,after,id,receipt) ==
/\ before.tag="SimultaneousCharacteristics" /\ id \in before.waiting /\ id \in SimultaneousEligible912(before)
/\ LET view == SimultaneousView912(before,id)
preview == SimultaneousPreview912(before,id)
IN /\ \A target \in DOMAIN preview.chars : preview.chars[target].unresolved={}
/\ receipt=[tag |-> "AppliedCharacteristicEffect",worldId |-> before.world.id,effect |-> id,
source |-> before.effects[id].source,before |-> before.chars,view |-> view,dependencies |-> SimultaneousDependencies912(before)]
/\ after=[preview EXCEPT !.waiting=@ \ {id},!.applied=IF view.enabled THEN Append(@,id) ELSE @,
!.skipped=IF view.enabled THEN @ ELSE @ \cup {id},!.trace=Append(@,receipt)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: preview, view, SimultaneousDependencies912, SimultaneousEligible912
ApplyTraversalEndWindowPolicy9 · operator
reference-profile · input revision 2 · CC0 1.0
ApplyTraversalEndWindowPolicy9(before,after,cleanupId,actualCleanup) ==
/\ TraversalEndCleanupReceiptMatches9(before,cleanupId,actualCleanup)
/\ after = [i \in 1..Len(before) |->
IF before[i].id \in actualCleanup.windowIds THEN TraversalEndCleanupFrame9(before[i]) ELSE before[i]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TraversalEndCleanupFrame9, TraversalEndCleanupReceiptMatches9
AtomicAbilityCaller99 · operator
reference-profile · input revision 2 · CC0 1.0
AtomicAbilityCaller99(context,origin,world,ledger,stack,call) ==
/\ origin.kind="Instruction" /\ origin.plan.origin="Ability" /\ call.before.phase="Imminent"
/\ call.before=context.entry.after /\ call.kind=call.before.ability.kind
/\ call.before.ability=origin.parent /\ call.before.ability.phase="Imminent"
/\ CASE call.kind="Paid" -> PaidProcedureAtTop95(stack,call.before) /\ call.before.costPaid
[] call.kind="Conditional" ->
/\ ConditionalAtTop96(stack,call.before) /\ ConditionalProcedureBound96(ledger,call.before)
/\ ledger.instances[call.before.id].status="Imminent" /\ ContextInitialObservationBound99(ledger,call.before,context)
[] call.kind="Play" -> PlayOwnerAtTop97(call.before,call.play,stack) /\ PlayAbilityBound97(call.before)
[] call.kind="BarrierInstruction" -> BarrierInstructionOwnerAtTop98(call.before.owner,stack) /\ BarrierInstructionBarrierInstructionBound98(call.before)
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, ConditionalAtTop96, ConditionalProcedureBound96, ContextInitialObservationBound99, PaidProcedureAtTop95, PlayAbilityBound97, PlayOwnerAtTop97
BarrierInstructionBarrierInstructionBound98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionBarrierInstructionBound98(p) ==
/\ BarrierInstructionDefinitionValid98(p.definition,p.barrierInstruction,p.barrierCard) /\ BarrierInstructionDefinitionValid98(p.payload,p.barrierInstruction,p.barrierCard)
/\ p.id \in Nat \ {0} /\ p.ability.id=p.id /\ p.ability.kind="BarrierInstruction"
/\ p.ability.source=ObjectAbilitySource9(p.barrierCard) /\ p.ability.caller=p.caller
/\ p.definition.syntax.id=p.barrierInstruction /\ p.definition.syntax.source=p.ability.source
/\ p.payload.syntax.source=p.ability.source /\ p.payload.syntax.kind="BarrierInstruction"
/\ p.ability.instructions=p.payload.instructionsExact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionDefinitionValid98, ObjectAbilitySource9
BarrierInstructionCallerEntry99 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionCallerEntry99(entry,world,cardFacts) ==
/\ entry.tag="ActualBarrierInstructionEntry" /\ entry.id \in Nat \ {0} /\ entry.snapshotId=world.id
/\ entry.stackAfter=entry.stackBefore /\ entry.owner=entry.procedure.owner
/\ CASE entry.kind="EncounterSelection" ->
SelectNextBarrierInstruction98(entry.beforeLoop,entry.afterLoop,entry.procedure,entry.encounter,world.traversalControl,entry.step,entry.orderState,
entry.currentOrder,entry.instance,entry.usedInstances,world.objects,entry.present,entry.activity,entry.points,entry.stackBefore)
[] entry.kind="InstructionInvocation" ->
EnterInstructionBarrierInstruction98(entry.beforeCalls,entry.afterCalls,entry.procedure,entry.parentPlan,entry.parentAbility,entry.ruleStep,
entry.effect,entry.orderState,entry.instance,entry.usedInstances,entry.owner,entry.stackBefore,world.objects,entry.present,entry.activity,entry.points,cardFacts)
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: EnterInstructionBarrierInstruction98, SelectNextBarrierInstruction98
BarrierInstructionContextClearance99 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionContextClearance99(context,windowId,p) ==
[tag |-> "BarrierInstructionInterruptReturn",barrierInstruction |-> BarrierInstructionWindowRef98(p),windowId |-> windowId,
openingRevision |-> context.openingRef.revision,complete |-> TRUE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionWindowRef98
BarrierInstructionCurrentActive98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionCurrentActive98(d,objects,present,activity,points) ==
/\ activity.tag="CurrentBarrierInstructionActivity" /\ activity.objects=objects /\ activity.present=present
/\ d.syntax.id \in DOMAIN activity.ordinary
/\ FlagActivity93(d.syntax,present,AbilityActive9(d.activity,objects,present,activity.ordinary[d.syntax.id],activity.context),activity.context.persistentAbilities,points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityActive9, FlagActivity93
BarrierInstructionDefinitionValid98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionDefinitionValid98(d,id,barrierCard) ==
/\ id \in Nat \ {0} /\ d.syntax.id=id /\ d.activity.id=id
/\ d.syntax.kind="BarrierInstruction" /\ d.syntax.cardKind="Barrier" /\ d.syntax.source=ObjectAbilitySource9(barrierCard)
/\ d.activity.kind="BarrierInstruction" /\ d.activity.source=d.syntax.source
/\ AbilityTextValid93(d.syntax) /\ Len(d.instructions)>0Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityTextValid93, ObjectAbilitySource9
BarrierInstructionEncounterCurrent98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionEncounterCurrent98(e,control) ==
/\ EncounterTimingLive95(e,control) /\ control.encounter=e.idExact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterTimingLive95
BarrierInstructionGrantValid98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionGrantValid98(grant,barrierCard,objects,cardFacts) ==
/\ grant.tag="NormalizedBarrierInstructionGrant" /\ grant.id \in Nat \ {0} /\ grant.target=barrierCard
/\ barrierCard \in DOMAIN objects /\ objects[barrierCard].kind="Barrier" /\ grant.ability.syntax.source.kind="Object"
/\ grant.ability.syntax.source.object \in Nat \ {0} /\ grant.ability.syntax.id \in Nat \ {0}
/\ grant.origin.tag="NormalizedBarrierInstructionGrantOrigin" /\ grant.origin.ability=grant.ability.syntax.id
/\ grant.origin.source=grant.ability.syntax.source /\ grant.origin.card=grant.card /\ grant.origin.sourceSHA=grant.sourceSHA
/\ grant.origin.kind \in {"Ability","MaintainedEffect"}
/\ grant.ability.syntax.kind="Static" => grant.origin.kind="Ability"
/\ grant.sourceSHA=cardFacts[grant.card].sourceSHA
/\ grant.ability.syntax.cardKind=cardFacts[grant.card].kind /\ grant.ability.syntax.side=cardFacts[grant.card].side
/\ AbilityTextValid93(grant.ability.syntax)
/\ grant.ability.activity.id=grant.ability.syntax.id /\ grant.ability.activity.source=grant.ability.syntax.source
/\ grant.ability.activity.kind=grant.ability.syntax.kind
/\ grant.placement \in {"Before","After","Unspecified"} /\ grant.mode \in {"Default","SideAChoice","TLDR"}
/\ grant.specified \in BOOLEAN /\ (grant.mode # "TLDR" => Len(grant.templates)>0)
/\ \A i \in 1..Len(grant.templates) : BarrierInstructionDefinitionValid98(grant.templates[i].definition,grant.templates[i].definition.syntax.id,barrierCard)
/\ SelfStaticGrant98(grant,barrierCard) => grant.mode="Default" /\ Len(grant.templates)=1Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityTextValid93, BarrierInstructionDefinitionValid98, SelfStaticGrant98
BarrierInstructionImminent98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionImminent98(p) ==
/\ BarrierInstructionBarrierInstructionBound98(p) /\ p.phase="BarrierInstructionImminent" /\ p.ability.phase="Ready"
/\ ~p.ability.firstImminent /\ ~p.ability.detachedExact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98
BarrierInstructionInstructionCaller98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionInstructionCaller98(p) ==
[kind |-> "BarrierInstructionInstruction",encounter |-> p.encounter,barrierInstruction |-> p.barrierInstruction,abilityInstance |-> p.id,
source |-> p.ability.source,instruction |-> p.ability.instructions[p.ability.cursor],index |-> p.ability.cursor,windowId |-> p.owner.windowId]Exact module download · Source bundle and reproduction instructions
BarrierInstructionInstructionCheckpoint98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionInstructionCheckpoint98(before,after,stack,ledger,r) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="InstructionCheckpoint" /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ r.tag="BarrierInstructionInstructionCheckpoint" /\ r.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[r.id].caller=BarrierInstructionInstructionCaller98(before) /\ ConditionalCheckpointDrained96(ledger,stack,r.id)
/\ r.caller=BarrierInstructionInstructionCaller98(before) /\ r.complete /\ r.allNewerChainsComplete
/\ after=[before EXCEPT !.checkpoint=r.id,!.phase=IF before.ability.lastFinished THEN "AbilityComplete" ELSE "Targets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionInstructionCaller98, BarrierInstructionOwnerAtTop98, ConditionalCheckpointDrained96
BarrierInstructionInterruptReturnBound98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionInterruptReturnBound98(p,r) ==
/\ r.tag="BarrierInstructionInterruptReturn" /\ r.barrierInstruction=BarrierInstructionWindowRef98(p) /\ r.complete
/\ r.windowId \in Nat /\ r.openingRevision \in Nat /\ r.openingRevision<=p.revisionExact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionWindowRef98
BarrierInstructionLoopMatches98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionLoopMatches98(loop,e) ==
/\ loop.encounter=e.id /\ loop.barrierCard=e.barrierCard /\ loop.resolved=e.resolved
/\ loop.handled=loop.resolved \cup loop.prevented /\ loop.resolved \cap loop.prevented={}Exact module download · Source bundle and reproduction instructions
BarrierInstructionModifierAtTop98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionModifierAtTop98(p,stack,plan,parent) ==
/\ Len(stack)>0 /\ BarrierInstructionImminent98(p)
/\ LET w == WindowTop9(stack)
IN /\ w.kind="Interrupt" /\ w.stage="Resolving" /\ w.busy.id # 0
/\ w.instruction.origin="BarrierInstruction" /\ w.instruction.id=p.id
/\ w.instruction.encounter=p.encounter /\ w.instruction.barrierInstruction=p.barrierInstruction /\ w.instruction.source=p.ability.source
/\ parent.caller=w.id /\ parent.source=w.busy.source
/\ (w.busy.kind="ConditionalInterrupt" => parent.id=w.busy.instance)
/\ ConditionalCreationInstruction96(plan,parent,"NoValue")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, BarrierInstructionImminent98, ConditionalCreationInstruction96
BarrierInstructionOrderPublicationStep98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionOrderPublicationStep98(before,after) ==
/\ BarrierInstructionOrderValid98(before) /\ BarrierInstructionOrderValid98(after)
/\ SelfCategoryIdentical98(after) /\ after.barrierCard=before.barrierCard /\ after.clock=before.clock+1
/\ Len(after.history)=Len(before.history)+1 /\ SubSeq(after.history,1,Len(before.history))=before.history
/\ before.usedIds \subseteq after.usedIds /\ OrderPreserves98(after.spine,before.spine)
/\ after.printedText=before.printedText
/\ \A id \in before.usedIds : after.definitions[id]=before.definitions[id] /\ after.provenance[id]=before.provenance[id]
/\ \A id \in DOMAIN before.applications : id \in DOMAIN after.applications /\ after.applications[id]=before.applications[id]
/\ LET step == after.history[Len(after.history)]
gained == after.present \ before.present
lost == before.present \ after.present
IN /\ step.kind \in {"OrdinaryGain","SideADeclaredGain","SelfStaticResize","PrintedResize","TLDRCopy","Loss"}
/\ step.clock=after.clock /\ step.gained=gained /\ step.lost=lost
/\ after.usedIds=before.usedIds \cup gained /\ gained \cap before.usedIds={}
/\ step.decision \notin DOMAIN before.decisions /\ DOMAIN after.decisions=DOMAIN before.decisions \cup {step.decision}
/\ \A id \in DOMAIN before.decisions : after.decisions[id]=before.decisions[id]
/\ IF step.kind="Loss" THEN
/\ DOMAIN after.applications=DOMAIN before.applications /\ step.applications \subseteq before.activeApplications
/\ after.activeApplications=before.activeApplications \ step.applications
ELSE /\ DOMAIN after.applications=DOMAIN before.applications \cup step.applications
/\ DOMAIN before.applications \cap step.applications={}
/\ after.activeApplications=before.activeApplications \cup step.applications
/\ \A id \in step.applications : after.applications[id].clock=after.clockExact module download · Source bundle and reproduction instructions
Resolved project definitions: gained, lost, step, BarrierInstructionOrderValid98, OrderPreserves98, SelfCategoryIdentical98
BarrierInstructionOrderValid98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionOrderValid98(state) ==
/\ state.barrierCard \in Nat \ {0} /\ DeckSequenceValid4(state.spine)
/\ state.usedIds=SubIds6(state.spine) /\ state.present \subseteq state.usedIds
/\ state.order=VisibleSubOrder98(state.spine,state.present)
/\ DOMAIN state.definitions=state.usedIds /\ DOMAIN state.provenance=state.usedIds
/\ \A id \in state.usedIds : BarrierInstructionDefinitionValid98(state.definitions[id],id,state.barrierCard)
/\ state.activeApplications \subseteq DOMAIN state.applications
/\ state.clock \in NatExact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionDefinitionValid98, VisibleSubOrder98, DeckSequenceValid4, SubIds6
BarrierInstructionOwnerAtTop98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionOwnerAtTop98(owner,stack) ==
IF owner.windowId=0 THEN Len(stack)=0 /\ owner.option=NoPriorityOption9 /\ owner.transaction=0
ELSE /\ Len(stack)>0 /\ WindowTop9(stack).id=owner.windowId
/\ WindowTop9(stack).busy=owner.option /\ owner.option.id # 0
/\ WindowTop9(stack).busyTransaction=owner.transactionExact module download · Source bundle and reproduction instructions
Resolved project definitions: NoPriorityOption9, WindowTop9
BarrierInstructionStep98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionStep98(e,control,step) ==
/\ BarrierInstructionEncounterCurrent98(e,control) /\ e.stage="BarrierInstructions" /\ step="ProcedureCodef1914978bb8e"
/\ IF e.forced THEN TRUE ELSE control.traversal.phase="Encounter" /\ control.traversal.phaseId=e.id /\ control.traversal.step=stepExact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionEncounterCurrent98
BarrierInstructionWasPrevented99 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionWasPrevented99(context,p) ==
\E index \in 1..Len(context.modifications) :
LET modification == context.modifications[index]
IN IF modification.kind # "PreventWhole" THEN FALSE
ELSE LET operation == modification.operation
id == operation.effectId
IN /\ operation.kind="PreventWhole" /\ operation.parentContextId=context.id
/\ operation.parentImminenceId=context.imminenceId /\ operation.parentReference=WouldContextKey99(context.initialRef)
/\ id \in DOMAIN modification.beforeEffects /\ id \notin DOMAIN modification.afterEffects
/\ modification.beforeEffects[id].kind="BarrierInstruction" /\ modification.beforeEffects[id].barrierInstruction=p.barrierInstruction
/\ modification.beforeEffects[id].baseOrigin=p.ability.source /\ WouldContextValid99(modification.modifier)
/\ modification.modifier.origin="Ability"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: id, modification, operation, WouldContextKey99, WouldContextValid99
BarrierInstructionWindowRef98 · operator
reference-profile · input revision 2 · CC0 1.0
BarrierInstructionWindowRef98(p) ==
[origin |-> "BarrierInstruction",id |-> p.id,abilityInstance |-> p.id,index |-> 0,barrierInstruction |-> p.barrierInstruction,encounter |-> p.encounter,
source |-> p.ability.source,sourceZone |-> p.ability.sourceZone,ruleStep |-> "NoValue",revision |-> p.revision]Exact module download · Source bundle and reproduction instructions
BeginAbilityInstructionAtomic93 · operator
reference-profile · input revision 2 · CC0 1.0
BeginAbilityInstructionAtomic93(beforeAbility,afterAbility,before,after,actualInterruptReturn) ==
/\ InstructionPlanMatches93(before,beforeAbility,beforeAbility.cursor)
/\ InstructionInterruptReturnMatches93(before,actualInterruptReturn)
/\ BeginAtomicInstruction93(before,after,actualInterruptReturn)
/\ ResolveCurrentInstruction9(beforeAbility,afterAbility,actualInterruptReturn.complete)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginAtomicInstruction93, InstructionInterruptReturnMatches93, InstructionPlanMatches93, ResolveCurrentInstruction9
BeginAbilityInstructions9 · operator
reference-profile · input revision 2 · CC0 1.0
BeginAbilityInstructions9(before,after,actualSchedulerAllows,actualSourceEligible) ==
/\ before.phase = "Ready" /\ ~before.firstImminent /\ ~before.complete
/\ before.id \in Nat \ {0} /\ before.kind \in AbilityKinds9 \ {"Static"}
/\ Len(before.instructions) > 0 /\ actualSchedulerAllows
/\ IF before.kind = "Paid" THEN before.detached ELSE actualSourceEligible
/\ after = [before EXCEPT !.phase = "Imminent",!.firstImminent = TRUE,
!.detached = @ \/ before.kind \in {"Conditional","BarrierInstruction"}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKinds9
BeginAtomicInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
BeginAtomicInstruction93(before,after,actualInterruptReturn) ==
/\ before.phase="Imminent" /\ actualInterruptReturn.tag="InstructionInterruptReturn"
/\ actualInterruptReturn.instruction=before.id /\ actualInterruptReturn.revision=before.revision /\ actualInterruptReturn.complete
/\ after=[before EXCEPT !.phase="Resolving"]Exact module download · Source bundle and reproduction instructions
BeginChapterExpected912 · operator
reference-profile · input revision 2 · CC0 1.0
BeginChapterExpected912(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation,ledger,registry,authority) ==
/\ ChapterExpectedWorld912(registry,world,ledger,authority,cardFacts)
/\ CASE entry.tag="ActualOccurrenceInstructionEntry" ->
BeginOccurrenceExpected912(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation,registry,authority)
[] entry.tag="ActualGraphInstructionEntry" ->
BeginRuntimeExpectedContext911(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation,registry,authority)
[] OTHER -> BeginExpectedContext99(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginExpectedContext99, BeginOccurrenceExpected912, BeginRuntimeExpectedContext911, ChapterExpectedWorld912
BeginClearedAbilityInstruction99 · operator
reference-profile · input revision 2 · CC0 1.0
BeginClearedAbilityInstruction99(before,after,beforeOrigin,afterOrigin,world,beforeLedger,afterLedger,stack,call,clearance,afterPlan) ==
/\ before.phase="InstructionCleared" /\ ExpectedContextOrigin99(before,beforeOrigin) /\ ExpectedContextWorld99(before,world)
/\ AtomicAbilityCaller99(before,beforeOrigin,world,beforeLedger,stack,call)
/\ clearance=before.clearance
/\ LET ability == [call.before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(call.before.ability,ability,beforeOrigin.plan,afterPlan,clearance)
/\ call.after=[call.before EXCEPT !.ability=ability,!.phase="Resolve"]
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan,!.parent=ability]
/\ IF call.kind="Conditional" THEN afterLedger=[beforeLedger EXCEPT !.instances[call.before.id].status="Resolving"] ELSE afterLedger=beforeLedger
/\ after=[before EXCEPT !.phase="Resolving",!.actualEffects=ActualExpectedEffects99(before.state.effects)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ability, ActualExpectedEffects99, AtomicAbilityCaller99, BeginAbilityInstructionAtomic93, ExpectedContextOrigin99, ExpectedContextWorld99
BeginClearedRuleInstruction99 · operator
reference-profile · input revision 2 · CC0 1.0
BeginClearedRuleInstruction99(before,after,beforeOrigin,afterOrigin,world,stack,clearance,afterPlan) ==
/\ before.phase="InstructionCleared" /\ ExpectedContextOrigin99(before,beforeOrigin) /\ ExpectedContextWorld99(before,world)
/\ beforeOrigin.kind="Instruction" /\ beforeOrigin.plan.origin="Rule"
/\ before.entry.ruleInvocation \in DOMAIN world.ruleInvocations /\ ~world.ruleInvocations[before.entry.ruleInvocation].returned
/\ world.ruleInvocations[before.entry.ruleInvocation].step=beforeOrigin.ruleStep
/\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ clearance=before.clearance
/\ BeginRuleInstructionAtomic93(beforeOrigin.plan,afterPlan,beforeOrigin.ruleStep,clearance)
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan]
/\ after=[before EXCEPT !.phase="Resolving",!.actualEffects=ActualExpectedEffects99(before.state.effects)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActualExpectedEffects99, BarrierInstructionOwnerAtTop98, BeginRuleInstructionAtomic93, ExpectedContextOrigin99, ExpectedContextWorld99
BeginConditionalOccurrenceAtomic912 · operator
reference-profile · input revision 2 · CC0 1.0
BeginConditionalOccurrenceAtomic912(beforeLedger,afterLedger,before,after,plan,afterPlan,context,origin,clearance,world,stack,lifetimes,authority) ==
/\ ConditionalOccurrenceBound912(beforeLedger,before) /\ beforeLedger.instances[before.id].status="Imminent"
/\ OccurrenceAtTop912(stack,before) /\ plan.index \in DOMAIN beforeLedger.instances[before.id].expected
/\ beforeLedger.instances[before.id].expected[plan.index].instruction=context.initialRef
/\ beforeLedger.instances[before.id].expected[plan.index].effects=ExpectedObservationSet99(context.initialEffects)
/\ BeginOccurrenceAtomic912(before,after,plan,afterPlan,context,origin,clearance,world,stack,lifetimes,authority)
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status="Resolving"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginOccurrenceAtomic912, ConditionalOccurrenceBound912, ExpectedObservationSet99, OccurrenceAtTop912
BeginConditionalResolution96 · operator
reference-profile · input revision 2 · CC0 1.0
BeginConditionalResolution96(beforeLedger,afterLedger,beforeStack,afterStack,p,afterP,d,snapshot,id,option,legality,currentEffect,plan,afterPlan,targets,entry,turnUses,restrictions) ==
/\ ConditionalSnapshotBound96(snapshot,beforeLedger)
/\ ConditionalDefinitionValid96(d) /\ id \in DOMAIN beforeLedger.instances
/\ beforeLedger.instances[id].status="Pending" /\ beforeLedger.instances[id].definition=ConditionalKey96(d)
/\ ConditionalKey96(d) \in DOMAIN snapshot.definitions /\ snapshot.definitions[ConditionalKey96(d)]=d
/\ beforeLedger.instances[id].definitionCopy=d
/\ ConditionalInstanceCurrent96(beforeLedger.instances[id],[key \in {ConditionalKey96(d)} |-> d],snapshot)
/\ Len(beforeStack)>0 /\ WindowTop9(beforeStack).kind=ConditionalWindowKind96(d)
/\ id \in DOMAIN WindowTop9(beforeStack).members
/\ WindowTop9(beforeStack).members[id]=beforeLedger.instances[id].member
/\ option.instance=id /\ option.ability=d.syntax.id /\ option.source=d.syntax.source
/\ option.kind=IF ConditionalInterrupt96(d) THEN "ConditionalInterrupt" ELSE "Conditional"
/\ WholeAbilityRestrictionGate93(d.syntax,restrictions) /\ OncePerTurnAllowed93(d.syntax,WindowTop9(beforeStack).site.turnId,turnUses)
/\ BeginPriorityOption9(beforeStack,afterStack,option,snapshot.objects,legality,currentEffect)
/\ p=OpenConditionalProcedure96(id,d,WindowTop9(beforeStack),option,legality.transactionId,
IF d.syntax.source.kind="Rule" THEN "Rule" ELSE IF d.syntax.source.object \in DOMAIN snapshot.objects THEN snapshot.objects[d.syntax.source.object].zone ELSE "NoValue")
/\ ~plan.announced /\ entry.sourceEligible=ConditionalActive96(d,snapshot)
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [p.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,!.detached=TRUE]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,p.ability,"NoValue")
/\ EnterFirstAbilityInstruction93(p.ability,imminent,announced,afterPlan,entry)
/\ afterP=[p EXCEPT !.ability=imminent,!.phase="Imminent"]
/\ afterLedger=[beforeLedger EXCEPT !.instances[id].status="Imminent"]
/\ ConditionalProcedureBound96(afterLedger,afterP)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AnnounceInstructionTargets93, BeginPriorityOption9, ConditionalActive96, ConditionalDefinitionValid96, ConditionalInstanceCurrent96, ConditionalInterrupt96, ConditionalKey96, ConditionalProcedureBound96, ConditionalSnapshotBound96, ConditionalWindowKind96, EnterFirstAbilityInstruction93, OncePerTurnAllowed93, OpenConditionalProcedure96, WholeAbilityRestrictionGate93, WindowTop9
BeginConditionalResolutionCore99 · operator
reference-profile · input revision 2 · CC0 1.0
BeginConditionalResolutionCore99(beforeLedger,afterLedger,beforeStack,afterStack,p,afterP,d,lex,snapshot,id,option,legality,currentEffect,plan,afterPlan,targets,entry,turnUses,restrictions,cardFacts) ==
/\ AbilityLexemesValid99(d,lex,snapshot.objects,cardFacts)
/\ ConditionalSnapshotBound96(snapshot,beforeLedger)
/\ ConditionalDefinitionValid96(d) /\ id \in DOMAIN beforeLedger.instances
/\ beforeLedger.instances[id].status="Pending" /\ beforeLedger.instances[id].definition=ConditionalKey96(d)
/\ ConditionalKey96(d) \in DOMAIN snapshot.definitions /\ snapshot.definitions[ConditionalKey96(d)]=d
/\ beforeLedger.instances[id].definitionCopy=d
/\ ConditionalInstanceCurrent96(beforeLedger.instances[id],[key \in {ConditionalKey96(d)} |-> d],snapshot)
/\ Len(beforeStack)>0 /\ WindowTop9(beforeStack).kind=(IF AbilityInterrupt99(d,lex) THEN "Interrupt" ELSE "Reaction")
/\ id \in DOMAIN WindowTop9(beforeStack).members
/\ WindowTop9(beforeStack).members[id]=beforeLedger.instances[id].member
/\ option.instance=id /\ option.ability=d.syntax.id /\ option.source=d.syntax.source
/\ option.kind=IF AbilityInterrupt99(d,lex) THEN "ConditionalInterrupt" ELSE "Conditional"
/\ WholeAbilityRestrictionGate93(d.syntax,restrictions) /\ OncePerTurnAllowed93(d.syntax,WindowTop9(beforeStack).site.turnId,turnUses)
/\ BeginPriorityOption9(beforeStack,afterStack,option,snapshot.objects,legality,currentEffect)
/\ p=OpenConditionalProcedure96(id,d,WindowTop9(beforeStack),option,legality.transactionId,
IF d.syntax.source.kind="Rule" THEN "Rule" ELSE IF d.syntax.source.object \in DOMAIN snapshot.objects THEN snapshot.objects[d.syntax.source.object].zone ELSE "NoValue")
/\ ~plan.announced /\ entry.sourceEligible=ConditionalActive96(d,snapshot)
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [p.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,!.detached=TRUE]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,p.ability,"NoValue")
/\ EnterFirstAbilityInstruction93(p.ability,imminent,announced,afterPlan,entry)
/\ afterP=[p EXCEPT !.ability=imminent,!.phase="Imminent"]
/\ afterLedger=[beforeLedger EXCEPT !.instances[id].status="Imminent"]
/\ ConditionalProcedureBound96(afterLedger,afterP)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AbilityInterrupt99, AbilityLexemesValid99, AnnounceInstructionTargets93, BeginPriorityOption9, ConditionalActive96, ConditionalDefinitionValid96, ConditionalInstanceCurrent96, ConditionalKey96, ConditionalProcedureBound96, ConditionalSnapshotBound96, EnterFirstAbilityInstruction93, OncePerTurnAllowed93, OpenConditionalProcedure96, WholeAbilityRestrictionGate93, WindowTop9
BeginConditionalRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginConditionalRuntime911(beforeLedger,afterLedger,beforeStack,afterStack,before,after,snapshot,option,legality,currentEffect,
plan,afterPlan,targets,entry,turnUses,restrictions,lifetimes,authority,cardFacts) ==
/\ Len(beforeStack)>0 /\ WindowTop9(beforeStack).kind="Reaction"
/\ BeginConditionalRuntimeCore911(beforeLedger,afterLedger,beforeStack,afterStack,before,after,snapshot,option,legality,currentEffect,
plan,afterPlan,targets,entry,turnUses,restrictions,lifetimes,authority,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginConditionalRuntimeCore911, WindowTop9
BeginConditionalRuntimeAtomic911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginConditionalRuntimeAtomic911(beforeLedger,afterLedger,before,after,plan,afterPlan,context,origin,clearance,world,lifetimes,authority,stack) ==
/\ ConditionalRuntimeBound911(beforeLedger,before) /\ beforeLedger.instances[before.id].status="Imminent"
/\ ConditionalAtTop96(stack,before) /\ plan.index \in DOMAIN beforeLedger.instances[before.id].expected
/\ beforeLedger.instances[before.id].expected[plan.index].instruction=context.initialRef
/\ beforeLedger.instances[before.id].expected[plan.index].effects=ExpectedObservationSet99(context.initialEffects)
/\ BeginRuntimeInstructionAtomic911(before,after,plan,afterPlan,context,origin,clearance,world,lifetimes,authority)
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status="Resolving"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginRuntimeInstructionAtomic911, ConditionalAtTop96, ConditionalRuntimeBound911, ExpectedObservationSet99
BeginConditionalRuntimeCore911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginConditionalRuntimeCore911(beforeLedger,afterLedger,beforeStack,afterStack,before,after,snapshot,option,legality,currentEffect,
plan,afterPlan,targets,entry,turnUses,restrictions,lifetimes,authority,cardFacts) ==
/\ LifetimeReady910(lifetimes,authority) /\ snapshot.objects=authority.current.objects
/\ ConditionalSnapshotBound96(snapshot,beforeLedger)
/\ CompiledInstructionTechnique911(before.technique,snapshot.objects,cardFacts)
/\ LET d == before.technique.definition
id == before.id
IN /\ ConditionalDefinitionValid96(d) /\ id \in DOMAIN beforeLedger.instances
/\ beforeLedger.instances[id].status="Pending" /\ beforeLedger.instances[id].definitionCopy=d
/\ ConditionalKey96(d) \in DOMAIN snapshot.definitions /\ snapshot.definitions[ConditionalKey96(d)]=d
/\ ConditionalInstanceCurrent96(beforeLedger.instances[id],snapshot.definitions,snapshot)
/\ Len(beforeStack)>0
/\ WindowTop9(beforeStack).kind=(IF AbilityInterrupt99(d,before.technique.lexemes) THEN "Interrupt" ELSE "Reaction")
/\ id \in DOMAIN WindowTop9(beforeStack).members /\ WindowTop9(beforeStack).members[id]=beforeLedger.instances[id].member
/\ option.instance=id /\ option.ability=d.syntax.id /\ option.source=d.syntax.source
/\ option.kind=IF AbilityInterrupt99(d,before.technique.lexemes) THEN "ConditionalInterrupt" ELSE "Conditional"
/\ WholeAbilityRestrictionGate93(d.syntax,restrictions) /\ OncePerTurnAllowed93(d.syntax,WindowTop9(beforeStack).site.turnId,turnUses)
/\ BeginPriorityOption9(beforeStack,afterStack,option,snapshot.objects,legality,currentEffect)
/\ before=OpenConditionalRuntime911(id,before.technique,WindowTop9(beforeStack),option,legality.transactionId,
IF d.syntax.source.kind="Rule" THEN "Rule" ELSE IF d.syntax.source.object \in DOMAIN snapshot.objects THEN snapshot.objects[d.syntax.source.object].zone ELSE "NoValue")
/\ entry.sourceEligible=ConditionalActive96(d,snapshot)
/\ EnterRuntimeInstructionCore911(before,after,plan,afterPlan,targets,entry,beforeLedger,afterStack,lifetimes,authority)
/\ afterLedger=[beforeLedger EXCEPT !.instances[id].status="Imminent"]
/\ ConditionalRuntimeBound911(afterLedger,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, id, AbilityInterrupt99, BeginPriorityOption9, CompiledInstructionTechnique911, ConditionalActive96, ConditionalDefinitionValid96, ConditionalInstanceCurrent96, ConditionalKey96, ConditionalRuntimeBound911, ConditionalSnapshotBound96, EnterRuntimeInstructionCore911, LifetimeReady910, OncePerTurnAllowed93, OpenConditionalRuntime911, WholeAbilityRestrictionGate93, WindowTop9
BeginCurrentConditionalInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
BeginCurrentConditionalInterrupt99(beforeLedger,afterLedger,beforeStack,afterStack,p,afterP,d,snapshot,id,option,legality,
plan,afterPlan,targets,entry,turnUses,restrictions,context,origin,world,history,cardFacts) ==
/\ CurrentInterruptWorld99(world,beforeLedger,cardFacts) /\ ExpectedContextWorld99(context,world)
/\ ExpectedContextOrigin99(context,origin) /\ WouldViewCurrent99(history,context,world) /\ CurrentInterruptWindow99(context,beforeStack)
/\ snapshot=world.conditional /\ turnUses=world.turnUses /\ id \in context.conditionalIds
/\ id \in CurrentPendingRelevant99(context,world,history,beforeLedger)
/\ BeginConditionalResolutionCore99(beforeLedger,afterLedger,beforeStack,afterStack,p,afterP,d,world.lexemes[AbilityKey99(d)],snapshot,id,
option,legality,CurrentEffectReceipt99(context,world,history,beforeLedger,WindowTop9(beforeStack)),
plan,afterPlan,targets,entry,turnUses,restrictions,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, BeginConditionalResolutionCore99, CurrentEffectReceipt99, CurrentInterruptWindow99, CurrentInterruptWorld99, CurrentPendingRelevant99, ExpectedContextOrigin99, ExpectedContextWorld99, WindowTop9, WouldViewCurrent99
BeginExpectedContext99 · operator
reference-profile · input revision 2 · CC0 1.0
BeginExpectedContext99(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,beforeWould,afterWould,initialObservation) ==
/\ \A prior \in DOMAIN before.contexts : InitialWouldCaptured99(before.contexts[prior],beforeWould)
/\ ActualImminenceEntry99(entry,origin,world,cardFacts)
/\ entry.id \notin before.entryIds /\ id \in (Nat \ {0}) \ before.usedContextIds
/\ ~\E other \in DOMAIN before.contexts : before.contexts[other].phase # "Returned" /\
WouldContextKey99(before.contexts[other].currentRef)=WouldContextKey99(OriginReference99(origin))
/\ owner=entry.owner /\ BarrierInstructionOwnerAtTop98(owner,entry.stackAfter)
/\ InitialExpectedProjection99(origin,world,description,projection,initial)
/\ LET context == NewExpectedContext99(id,entry.id,origin,world,description,initial,owner)
IN /\ initialObservation=InitialWouldObservation99(context,initialObservation.id)
/\ RecordWouldDescriptors99(beforeWould,afterWould,id,entry.id,context.initialRef,world.id,initial,context.initialWouldGroups,
context.initialPeriods,InitialWouldOrder99(context),initialObservation)
/\ after=[before EXCEPT !.entryIds=@ \cup {entry.id},!.usedContextIds=@ \cup {id},
!.contexts=[key \in DOMAIN @ \cup {id} |-> IF key=id THEN context ELSE @[key]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: context, ActualImminenceEntry99, BarrierInstructionOwnerAtTop98, InitialExpectedProjection99, InitialWouldCaptured99, InitialWouldObservation99, InitialWouldOrder99, OriginReference99, RecordWouldDescriptors99, WouldContextKey99
BeginInterruptRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginInterruptRuntime911(beforeLedger,afterLedger,beforeStack,afterStack,before,after,snapshot,option,legality,
plan,afterPlan,targets,entry,turnUses,restrictions,lifetimes,authority,context,origin,world,history,cardFacts) ==
/\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ CurrentInterruptWorld99(world,beforeLedger,cardFacts) /\ ExpectedContextWorld99(context,world)
/\ ExpectedContextOrigin99(context,origin) /\ WouldViewCurrent99(history,context,world) /\ CurrentInterruptWindow99(context,beforeStack)
/\ snapshot=world.conditional /\ turnUses=world.turnUses /\ before.id \in context.conditionalIds
/\ before.id \in CurrentPendingRelevant99(context,world,history,beforeLedger)
/\ before.technique.lexemes=world.lexemes[AbilityKey99(before.technique.definition)]
/\ BeginConditionalRuntimeCore911(beforeLedger,afterLedger,beforeStack,afterStack,before,after,snapshot,option,legality,
CurrentEffectReceipt99(context,world,history,beforeLedger,WindowTop9(beforeStack)),
plan,afterPlan,targets,entry,turnUses,restrictions,lifetimes,authority,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, BeginConditionalRuntimeCore911, CurrentEffectReceipt99, CurrentInterruptWindow99, CurrentInterruptWorld99, CurrentPendingRelevant99, ExpectedContextOrigin99, ExpectedContextWorld99, WindowTop9, WouldViewCurrent99
BeginMidItemInspectionOption9 · operator
reference-profile · input revision 2 · CC0 1.0
BeginMidItemInspectionOption9(before,after,option,objects,actualLegality,a,afterItemInspection,midOption,options,mustRetire,exampleFamily034) ==
/\ Len(before) > 0 /\ WindowTop9(before).kind = "MidItemInspection"
/\ WindowTop9(before).site.structure = TimingRef9("ItemInspection",a.id)
/\ option.target = a.object /\ option.ability = midOption.id
/\ PriorityChoiceValid9(before,option,objects,actualLegality,[x \in {} |-> x])
/\ StillItemInspectioning7(a,objects) /\ a.step="ProcedureCode1dd0e8f05be2" /\ ~a.midUsed /\ ~a.midDone /\ ~a.midResolving
/\ midOption \in PayableMidOptions7(options) /\ midOption.timing="MidItemInspection"
/\ objects[a.object].zone # "SideADiscard" \/ ~midOption.trashesItemInspectioned
/\ MidItemInspectionChoiceAllowed7(midOption.id,options,mustRetire,exampleFamily034)
/\ afterItemInspection = a
/\ after = ReplaceWindowTop9(before,StartPriorityOptionFrame9(WindowTop9(before),option,actualLegality.transactionId))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PriorityChoiceValid9, ReplaceWindowTop9, StartPriorityOptionFrame9, TimingRef9, WindowTop9, MidItemInspectionChoiceAllowed7, PayableMidOptions7, StillItemInspectioning7
BeginOccurrenceAtomic912 · operator
reference-profile · input revision 2 · CC0 1.0
BeginOccurrenceAtomic912(before,after,plan,afterPlan,context,origin,clearance,world,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceRuntimeProfile912(before) /\ before.phase="Imminent"
/\ OccurrencePlan912(before,plan) /\ BarrierInstructionOwnerAtTop98(OccurrencePriorityOwner912(before),stack)
/\ context.phase="InstructionCleared" /\ context.currentRef=InstructionWindowRef93(plan) /\ context.clearance=clearance
/\ origin.kind="Instruction" /\ origin.ruleStep="NoValue" /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ origin.parent=before.ability /\ origin.plan=plan /\ world.id=authority.current.id /\ ExpectedContextWorld99(context,world)
/\ LET resolving == [before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(before.ability,resolving,plan,afterPlan,clearance)
/\ after=[before EXCEPT !.ability=resolving,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BarrierInstructionOwnerAtTop98, BeginAbilityInstructionAtomic93, ExpectedContextWorld99, InstructionWindowRef93, LifetimeReady910, OccurrencePlan912, OccurrencePriorityOwner912, OccurrenceRuntimeProfile912
BeginOccurrenceExpected912 · operator
reference-profile · input revision 2 · CC0 1.0
BeginOccurrenceExpected912(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation,lifetimes,authority) ==
/\ ExpectedWorldValid99(world) /\ ActualOccurrenceEntry912(entry,origin,world,lifetimes,authority)
/\ \A prior \in DOMAIN before.contexts : InitialWouldCaptured99(before.contexts[prior],beforeWould)
/\ entry.id \notin before.entryIds /\ id \in (Nat \ {0}) \ before.usedContextIds
/\ ~\E prior \in DOMAIN before.contexts : WouldContextKey99(before.contexts[prior].initialRef)=WouldContextKey99(OriginReference99(origin))
/\ description.sourceNode=entry.after.pc /\ description.occurrence=entry.after.current
/\ owner=entry.owner /\ InitialExpectedProjection99(origin,world,description,projection,initial)
/\ LET context == NewExpectedContext99(id,entry.id,origin,world,description,initial,owner)
IN /\ observation=InitialWouldObservation99(context,observation.id)
/\ RecordWouldDescriptors99(beforeWould,afterWould,id,entry.id,context.initialRef,world.id,initial,context.initialWouldGroups,
context.initialPeriods,InitialWouldOrder99(context),observation)
/\ after=[before EXCEPT !.entryIds=@ \cup {entry.id},!.usedContextIds=@ \cup {id},
!.contexts=ReplacementOverlay99(@,[key \in {id} |-> context])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: context, ActualOccurrenceEntry912, ExpectedWorldValid99, InitialExpectedProjection99, InitialWouldCaptured99, InitialWouldObservation99, InitialWouldOrder99, OriginReference99, RecordWouldDescriptors99, ReplacementOverlay99, WouldContextKey99
BeginPlayAbility97 · operator
reference-profile · input revision 2 · CC0 1.0
BeginPlayAbility97(before,after,f,stack,objects,present,activity,points,instance,usedInstances,plan,afterPlan,targets,entry,restrictions) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ before.phase="Ready" /\ before.cursor<=Len(before.order)
/\ PlayPresenceValid97(before,objects,present)
/\ instance \in (Nat \ {0}) \ (usedInstances \cup before.usedInstances)
/\ LET d == CurrentPlayDefinition97(before)
a == OpenAbilityResolution9(instance,"Play",before.source,"Play",d.instructions,before.playId)
announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [a EXCEPT !.phase="Imminent",!.firstImminent=TRUE]
IN /\ PlayDefinitionValid97(d) /\ WholeAbilityRestrictionGate93(d.syntax,restrictions)
/\ PlayCurrentActive97(before,f,objects,present,activity,points)
/\ ~plan.announced /\ entry.sourceEligible=PlayCurrentActive97(before,f,objects,present,activity,points)
/\ AnnounceInstructionTargets93(plan,announced,targets,a,"NoValue")
/\ EnterFirstAbilityInstruction93(a,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.id=instance,!.ability=imminent,!.phase="Imminent",!.usedInstances=@ \cup {instance}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, announced, d, imminent, AnnounceInstructionTargets93, EnterFirstAbilityInstruction93, PlayCurrentActive97, PlayDefinitionValid97, PlayOwnerAtTop97, PlayPresenceValid97, WholeAbilityRestrictionGate93
BeginPriorityOption9 · operator
reference-profile · input revision 2 · CC0 1.0
BeginPriorityOption9(before,after,option,objects,actualLegality,actualCurrentEffect) ==
/\ Len(before) > 0 /\ WindowTop9(before).kind # "MidItemInspection"
/\ PriorityChoiceValid9(before,option,objects,actualLegality,actualCurrentEffect)
/\ after = ReplaceWindowTop9(before,StartPriorityOptionFrame9(WindowTop9(before),option,actualLegality.transactionId))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PriorityChoiceValid9, ReplaceWindowTop9, StartPriorityOptionFrame9, WindowTop9
BeginRuleInstructionAtomic93 · operator
reference-profile · input revision 2 · CC0 1.0
BeginRuleInstructionAtomic93(before,after,actualRuleStep,actualInterruptReturn) ==
/\ RuleInstructionPlan93(before,actualRuleStep)
/\ InstructionInterruptReturnMatches93(before,actualInterruptReturn)
/\ BeginAtomicInstruction93(before,after,actualInterruptReturn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginAtomicInstruction93, InstructionInterruptReturnMatches93, RuleInstructionPlan93
BeginRuntimeExpectedContext911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginRuntimeExpectedContext911(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation,lifetimes,authority) ==
/\ \A prior \in DOMAIN before.contexts : InitialWouldCaptured99(before.contexts[prior],beforeWould)
/\ ActualRuntimeEntry911(entry,origin,world,lifetimes,authority,cardFacts)
/\ RuntimeEntryIds911(entry) \cap before.entryIds={} /\ id \in (Nat \ {0}) \ before.usedContextIds
/\ ~\E other \in DOMAIN before.contexts :
WouldContextKey99(before.contexts[other].initialRef)=WouldContextKey99(OriginReference99(origin))
/\ owner=entry.owner /\ InitialExpectedProjection99(origin,world,description,projection,initial)
/\ LET context == NewExpectedContext99(id,entry.id,origin,world,description,initial,owner)
IN /\ observation=InitialWouldObservation99(context,observation.id)
/\ RecordWouldDescriptors99(beforeWould,afterWould,id,entry.id,context.initialRef,world.id,initial,context.initialWouldGroups,
context.initialPeriods,InitialWouldOrder99(context),observation)
/\ after=[before EXCEPT !.entryIds=@ \cup RuntimeEntryIds911(entry),!.usedContextIds=@ \cup {id},
!.contexts=[key \in DOMAIN @ \cup {id} |-> IF key=id THEN context ELSE @[key]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: context, ActualRuntimeEntry911, InitialExpectedProjection99, InitialWouldCaptured99, InitialWouldObservation99, InitialWouldOrder99, OriginReference99, RecordWouldDescriptors99, RuntimeEntryIds911, WouldContextKey99
BeginRuntimeInstructionAtomic911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginRuntimeInstructionAtomic911(before,after,plan,afterPlan,context,origin,clearance,world,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeProfile911(before) /\ before.phase="Imminent"
/\ RuntimeCurrentPlan911(before,plan) /\ context.phase="InstructionCleared" /\ context.currentRef=InstructionWindowRef93(plan)
/\ context.clearance=clearance /\ origin.plan=plan /\ origin.parent=before.ability
/\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ ExpectedContextWorld99(context,world)
/\ LET resolving == [before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(before.ability,resolving,plan,afterPlan,clearance)
/\ after=[before EXCEPT !.ability=resolving,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BeginAbilityInstructionAtomic93, ExpectedContextWorld99, InstructionWindowRef93, LifetimeReady910, RuntimeCurrentPlan911, RuntimeProfile911
BeginSourceRuntimeAtomic911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginSourceRuntimeAtomic911(before,after,plan,afterPlan,context,origin,clearance,world,stack,lifetimes,authority) ==
/\ SourceRuntimeBound911(before) /\ BarrierInstructionOwnerAtTop98(before.sourceOwner,stack)
/\ BeginRuntimeInstructionAtomic911(before,after,plan,afterPlan,context,origin,clearance,world,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOwnerAtTop98, BeginRuntimeInstructionAtomic911, SourceRuntimeBound911
BeginTimingStepExpected911 · operator
reference-profile · input revision 2 · CC0 1.0
BeginTimingStepExpected911(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,
beforeWould,afterWould,observation,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority)
/\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ TimingStepInvocation911(entry,world)
/\ BeginExpectedContext99(before,after,id,origin,world,entry,description,projection,initial,owner,cardFacts,beforeWould,afterWould,observation)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginExpectedContext99, LifetimeReady910, TimingStepInvocation911
BeginningRefAtSite9 · operator
reference-profile · input revision 2 · CC0 1.0
BeginningRefAtSite9(ref,site) ==
ref = NoTimingRef9 \/ ref = site.structure \/ ref = TimingRef9("Turn",site.turnId) \/
(site.traversalId # 0 /\ ref = TimingRef9("SchemaAtom138",site.traversalId))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NoTimingRef9, TimingRef9
BindTimingDuration910 · operator
reference-profile · input revision 2 · CC0 1.0
BindTimingDuration910(requested,world) ==
[kind |-> "Timing",ref |-> IF requested \in LingeringTimingRefs910(world) THEN requested ELSE NoTimingRef9]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringTimingRefs910, NoTimingRef9
CanPassPriority9 · operator
reference-profile · input revision 2 · CC0 1.0
CanPassPriority9(w,actualCurrentEffect) ==
CASE w.kind = "Paid" -> TRUE
[] w.kind = "Reaction" -> PendingOwned9(w,w.priority,TRUE) = {}
[] w.kind = "Interrupt" ->
InterruptEffectMatches9(w,actualCurrentEffect) /\
PendingOwned9(w,w.priority,TRUE) \cap actualCurrentEffect.relevantConditional = {}
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: InterruptEffectMatches9, PendingOwned9
CancelBeginningReactions9 · operator
reference-profile · input revision 2 · CC0 1.0
CancelBeginningReactions9(before,after,actualEnd) ==
/\ actualEnd.tag = "TimingStructureEnded" /\ TimingRefValid9(actualEnd.structure)
/\ after = [i \in 1..Len(before) |->
IF before[i].open /\ before[i].kind = "Reaction" /\ before[i].beginning = actualEnd.structure
THEN ClosePriorityWindow9(before[i]) ELSE before[i]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ClosePriorityWindow9, TimingRefValid9
CancelConditionalBeginning96 · operator
reference-profile · input revision 2 · CC0 1.0
CancelConditionalBeginning96(before,candidate,after,beforeStack,candidateStack,afterStack,actualEnd,beforeSnapshot,afterSnapshot) ==
/\ CancelConditionalBeginningCore96(before,candidate,beforeStack,candidateStack,actualEnd)
/\ ObserveConditionalActivity96(before,candidate,after,candidateStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CancelConditionalBeginningCore96, ObserveConditionalActivity96
CancelConditionalBeginningCore96 · operator
reference-profile · input revision 2 · CC0 1.0
CancelConditionalBeginningCore96(beforeLedger,afterLedger,beforeStack,afterStack,actualEnd) ==
/\ CancelBeginningReactions9(beforeStack,afterStack,actualEnd)
/\ afterLedger=ConditionalPendingAfterWindows96(beforeLedger,afterStack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CancelBeginningReactions9, ConditionalPendingAfterWindows96
CapabilityRelevant99 · operator
reference-profile · input revision 2 · CC0 1.0
CapabilityRelevant99(clause,effect,context,world,history) ==
/\ ReplacementPatternMatches99(clause.pattern,effect)
/\ CASE clause.mode="PreventAmount" -> effect.kind \in {"Damage","ExposureMarkers"} /\ "preventable" \in DOMAIN effect /\ effect.preventable /\ clause.value>0
[] clause.mode="PreventWhole" -> "preventable" \in DOMAIN effect /\ effect.preventable
[] clause.mode="AddValue" -> effect.kind \in ExpectedValueKinds99 /\ clause.value # 0
[] clause.mode="SetValue" -> effect.kind \in ExpectedValueKinds99 /\ clause.value # effect.value
[] clause.mode="CreateReplacement" -> ReplacementPatternMatches99(clause.replacementPattern,effect)
[] clause.mode="WouldTrigger" ->
/\ clause.period \in ActualWouldPeriods99(world)
/\ IF clause.ordinal=0 THEN TRUE
ELSE /\ effect.id \in DOMAIN context.wouldGroups
/\ ExpectedWouldCriterionMatches99(ExpectedAtomDescriptor99(effect),clause.criterion)
/\ WouldOrdinalAtCurrent99(history,context.wouldGroups[effect.id],clause.period,clause.criterion)=clause.ordinal
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: ActualWouldPeriods99, ExpectedAtomDescriptor99, ExpectedValueKinds99, ExpectedWouldCriterionMatches99, ReplacementPatternMatches99, WouldOrdinalAtCurrent99
CarryAbilityInstructionStep93 · operator
reference-profile · input revision 2 · CC0 1.0
CarryAbilityInstructionStep93(beforeAbility,afterAbility,before,after,actualStep) ==
/\ beforeAbility.phase="Resolving" /\ InstructionPlanMatches93(before,beforeAbility,beforeAbility.cursor)
/\ CarryInstructionStep93(before,after,actualStep)
/\ IF before.cursor=Len(before.steps) THEN
FinishAbilityInstruction9(beforeAbility,afterAbility,
[abilityInstance |-> beforeAbility.id,instruction |-> before.id,complete |-> actualStep.complete])
ELSE afterAbility=beforeAbilityExact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryInstructionStep93, FinishAbilityInstruction9, InstructionPlanMatches93
CarryBarrierInstructionChildReturn98 · operator
reference-profile · input revision 2 · CC0 1.0
CarryBarrierInstructionChildReturn98(beforeCalls,afterCalls,before,after,stack,plan,afterPlan,step,beforeChild,afterChild,childReturn) ==
/\ ReturnInstructionBarrierInstruction98(beforeCalls,afterCalls,beforeChild,afterChild,plan,before.ability,"NoValue",stack,childReturn)
/\ step.childReturn=childReturn
/\ CarryBarrierInstructionInstruction98(before,after,stack,plan,afterPlan,step)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryBarrierInstructionInstruction98, ReturnInstructionBarrierInstruction98
CarryBarrierInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
CarryBarrierInstructionInstruction98(before,after,stack,plan,afterPlan,actualStep) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="Resolve" /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ CarryAbilityInstructionStep93(before.ability,after.ability,plan,afterPlan,actualStep)
/\ after=[before EXCEPT !.ability=after.ability,!.checkpoint=0,!.phase=IF afterPlan.phase="Complete" THEN "InstructionCheckpoint" ELSE "Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, CarryAbilityInstructionStep93
CarryConditionalInstruction96 · operator
reference-profile · input revision 2 · CC0 1.0
CarryConditionalInstruction96(before,candidate,after,beforeStack,afterStack,beforeP,afterP,plan,afterPlan,actualStep,beforeSnapshot,afterSnapshot) ==
/\ CarryConditionalInstructionCore96(before,candidate,beforeStack,
[i \in 1..Len(beforeStack) |-> LET lost == {id \in beforeStack[i].pending \cap DOMAIN before.instances : candidate.instances[id].status # "Pending"}
IN [beforeStack[i] EXCEPT !.pending=@ \ lost,!.lostPending=@ \cup lost]],beforeP,afterP,plan,afterPlan,actualStep)
/\ ObserveConditionalActivity96(before,candidate,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost, CarryConditionalInstructionCore96, ObserveConditionalActivity96
CarryConditionalInstructionCore96 · operator
reference-profile · input revision 2 · CC0 1.0
CarryConditionalInstructionCore96(before,after,beforeStack,afterStack,beforeP,afterP,plan,afterPlan,actualStep) ==
/\ ConditionalProcedureBound96(before,beforeP)
/\ ConditionalAtTop96(beforeStack,beforeP) /\ beforeP.phase="Resolve"
/\ before.instances[beforeP.id].status="Resolving" /\ plan.index \in DOMAIN before.instances[beforeP.id].expected
/\ LET a == IF plan.cursor=Len(plan.steps)
THEN IF beforeP.ability.cursor=Len(beforeP.ability.instructions)
THEN [beforeP.ability EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [beforeP.ability EXCEPT !.phase="Between"] ELSE beforeP.ability
last == a.lastFinished
effects == IF last THEN EffectsAfterConditionalResolution96(before.effects,beforeP.definition) ELSE before.effects
expired == {ConditionalKey96(before.effects[id].definition) : id \in DOMAIN before.effects \ DOMAIN effects}
changed == [before.instances EXCEPT ![beforeP.id].status=IF last THEN "Complete" ELSE "Resolving"]
throttle == last /\ beforeP.definition.primaryKind="Static" /\ ConditionalExpectedEmpty96(before.instances[beforeP.id],beforeP.ability.instructions)
IN /\ CarryAbilityInstructionStep93(beforeP.ability,a,plan,afterPlan,actualStep)
/\ last => DOMAIN before.instances[beforeP.id].expected=1..Len(beforeP.ability.instructions)
/\ afterP=[beforeP EXCEPT !.ability=a,!.checkpoint=0,!.phase=IF afterPlan.phase="Complete" THEN "InstructionCheckpoint" ELSE "Resolve"]
/\ after=[before EXCEPT !.instances=LoseConditionalPendingKeys96(changed,expired),!.effects=effects,
!.throttle=IF throttle THEN [key \in DOMAIN @ \cup {ConditionalKey96(beforeP.definition)} |->
IF key=ConditionalKey96(beforeP.definition) THEN before.stepSerial ELSE @[key]] ELSE @]
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, changed, effects, expired, last, throttle, CarryAbilityInstructionStep93, ConditionalAtTop96, ConditionalKey96, ConditionalProcedureBound96, LoseConditionalPendingKeys96, SyncConditionalWindows96
CarryDelayedLingeringInstruction910 · operator
reference-profile · input revision 2 · CC0 1.0
CarryDelayedLingeringInstruction910(beforeRegistry,afterRegistry,beforeLedger,coreLedger,retainedLedger,afterLedger,
beforeStack,afterStack,beforeP,afterP,plan,afterPlan,actualStep,
beforeSnapshot,afterSnapshot,beforeWorld,afterWorld) ==
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ beforeWorld.finishedDelayedEffects \subseteq beforeRegistry.usedEffects
/\ beforeP.definition.delayedEffect \in Nat \ {0}
/\ CarryConditionalInstructionCore96(beforeLedger,coreLedger,beforeStack,DelayedCarryStack910(beforeStack,beforeLedger,coreLedger),
beforeP,afterP,plan,afterPlan,actualStep)
/\ retainedLedger=[coreLedger EXCEPT !.effects=beforeLedger.effects]
/\ afterWorld.id \in Nat \ {0}
/\ afterWorld=[beforeWorld EXCEPT !.id=afterWorld.id,
!.finishedDelayedEffects=@ \cup (DOMAIN beforeLedger.effects \ DOMAIN coreLedger.effects)]
/\ beforeSnapshot.id=beforeWorld.id /\ afterSnapshot.id=afterWorld.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeWorld)
/\ LingeringConditionalWorld910(afterSnapshot,retainedLedger,afterWorld)
/\ ObserveLingering910(beforeRegistry,afterRegistry,afterWorld)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,beforeWorld)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,afterRegistry,retainedLedger,afterWorld)
/\ ObserveConditionalActivity96(beforeLedger,retainedLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)
/\ DelayedLifetimeBound910(afterRegistry,afterLedger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryConditionalInstructionCore96, DelayedCarryStack910, DelayedLifetimeBound910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910
CarryInstructionStep93 · operator
reference-profile · input revision 2 · CC0 1.0
CarryInstructionStep93(before,after,actualStep) ==
/\ before.phase="Resolving" /\ actualStep.tag="InstructionStepReturn" /\ actualStep.instruction=before.id
/\ actualStep.index=before.cursor /\ actualStep.step=before.steps[before.cursor] /\ actualStep.complete
/\ after=[before EXCEPT !.completedSteps=Append(@,before.steps[before.cursor]),!.cursor=@+1,
!.phase=IF before.cursor=Len(before.steps) THEN "Complete" ELSE "Resolving"]Exact module download · Source bundle and reproduction instructions
CarryOccurrenceWorkStep912 · operator
reference-profile · input revision 2 · CC0 1.0
CarryOccurrenceWorkStep912(before,after,plan,afterPlan,context,step,work) ==
/\ OccurrenceRuntimeProfile912(before) /\ before.phase="Resolve" /\ before.pause.id=0
/\ OccurrencePlan912(before,plan) /\ plan.cursor<Len(plan.steps)
/\ context.phase="Resolving" /\ context.currentRef=InstructionWindowRef93(plan)
/\ work.tag="OwnedInstructionWorkReturn" /\ work.instance=before.id /\ work.instruction=context.currentRef
/\ work.index=plan.cursor /\ work.step=plan.steps[plan.cursor] /\ work.complete /\ work.childrenReturned
/\ work.unprocessedCheckpointRequests={}
/\ CarryInstructionStep93(plan,afterPlan,step)
/\ after=beforeExact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryInstructionStep93, InstructionWindowRef93, OccurrencePlan912, OccurrenceRuntimeProfile912
CarryPaidInstruction95 · operator
reference-profile · input revision 2 · CC0 1.0
CarryPaidInstruction95(stack,before,after,plan,afterPlan,actualStep) ==
/\ before.phase="Resolve" /\ PaidProcedureAtTop95(stack,before)
/\ LET a == IF plan.cursor=Len(plan.steps)
THEN IF before.ability.cursor=Len(before.ability.instructions)
THEN [before.ability EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [before.ability EXCEPT !.phase="Between"]
ELSE before.ability
IN /\ CarryAbilityInstructionStep93(before.ability,a,plan,afterPlan,actualStep)
/\ after=[before EXCEPT !.ability=a,!.checkpoint=0,
!.phase=IF afterPlan.phase="Complete" THEN "InstructionCheckpoint" ELSE "Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, CarryAbilityInstructionStep93, PaidProcedureAtTop95
CarryPlayInstruction97 · operator
reference-profile · input revision 2 · CC0 1.0
CarryPlayInstruction97(before,after,f,stack,plan,afterPlan,step) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ PlayAbilityBound97(before) /\ before.phase="Resolve"
/\ CarryAbilityInstructionStep93(before.ability,after.ability,plan,afterPlan,step)
/\ after=[before EXCEPT !.ability=after.ability,!.checkpoint=0,!.phase=IF afterPlan.phase="Complete" THEN "InstructionCheckpoint" ELSE "Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryAbilityInstructionStep93, PlayAbilityBound97, PlayOwnerAtTop97
CarryRuntimeWorkStep911 · operator
reference-profile · input revision 2 · CC0 1.0
CarryRuntimeWorkStep911(before,after,plan,afterPlan,context,step,work) ==
/\ RuntimeProfile911(before) /\ before.phase="Resolve" /\ before.pause.id=0
/\ RuntimeCurrentPlan911(before,plan) /\ plan.cursor<Len(plan.steps)
/\ context.phase="Resolving" /\ context.currentRef=InstructionWindowRef93(plan)
/\ work.tag="OwnedInstructionWorkReturn" /\ work.instance=before.id /\ work.instruction=context.currentRef
/\ work.index=plan.cursor /\ work.step=plan.steps[plan.cursor] /\ work.complete /\ work.childrenReturned
/\ work.unprocessedCheckpointRequests={}
/\ CarryInstructionStep93(plan,afterPlan,step)
/\ after=beforeExact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryInstructionStep93, InstructionWindowRef93, RuntimeCurrentPlan911, RuntimeProfile911
ChapterExpectedWorld912 · operator
reference-profile · input revision 2 · CC0 1.0
ChapterExpectedWorld912(registry,world,ledger,authority,cardFacts) ==
/\ PersistentWorldBound912(registry,world,ledger,authority)
/\ cardFacts=authority.current.cardFacts
/\ CurrentInterruptWorld99(world,ledger,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentInterruptWorld99, PersistentWorldBound912
CharacteristicInitial912 · operator
reference-profile · input revision 2 · CC0 1.0
CharacteristicInitial912(printed) ==
[id \in DOMAIN printed |-> [subtypes |-> printed[id].subtypes,abilities |-> printed[id].abilities,
cannotGain |-> FALSE,values |-> printed[id].values,unresolved |-> {}]]Exact module download · Source bundle and reproduction instructions
CheckpointBatchValid96 · operator
reference-profile · input revision 2 · CC0 1.0
CheckpointBatchValid96(before,cp,candidates,allocation,bindings) ==
/\ cp.tag="ConditionalCheckpoint" /\ cp.point="ProcedureCodee605a78f5d5e" /\ cp.id \in (Nat \ {0}) \ before.checkpointIds
/\ cp.previousCheckpoint=before.lastCheckpoint /\ cp.serial=before.serial+1 /\ cp.previousSnapshot=before.lastSnapshot
/\ cp.processingSnapshot.point="ProcedureCodee605a78f5d5e" /\ cp.processingSnapshot.checkpointId=cp.id
/\ cp.beginSnapshot.checkpointId=cp.id /\ cp.beginSnapshot.point="CheckpointBeginning"
/\ cp.stepSerial=before.stepSerial /\ DOMAIN cp.occurrences \cap before.processed={}
/\ \A id \in DOMAIN cp.occurrences : cp.occurrences[id].id=id /\ id \in Nat \ {0}
/\ DOMAIN allocation=candidates /\ DOMAIN bindings=candidates
/\ {allocation[key] : key \in candidates} \subseteq (Nat \ {0}) \ DOMAIN before.instances
/\ Cardinality({allocation[key] : key \in candidates})=Cardinality(candidates)
/\ Cardinality({bindings[key] : key \in candidates})<=1
/\ \A key \in candidates : bindings[key].kind="Reaction" /\ bindings[key].windowId \in Nat \ {0} /\ bindings[key].group \in Nat \ {0}
/\ bindings[key].checkpointId=cp.idExact module download · Source bundle and reproduction instructions
CheckpointCandidates96 · operator
reference-profile · input revision 2 · CC0 1.0
CheckpointCandidates96(definitions,ledger,cp,conditions) ==
UNION {IF ~ConditionalDefinitionValid96(definitions[key]) \/ ConditionalInterrupt96(definitions[key]) \/ ~ConditionalActive96(definitions[key],cp.processingSnapshot)
THEN {}
ELSE IF definitions[key].primaryKind="Trigger"
THEN {[definition |-> key,occurrence |-> event] : event \in
{id \in DOMAIN cp.occurrences : TriggerPattern96(definitions[key],cp.occurrences[id]) /\ DelayedConditionalEventScope96(definitions[key],ledger,cp.occurrences[id]) /\
TriggerStipulations96(definitions[key],cp.occurrences[id],conditions[key][id])}}
ELSE IF StaticPrimaryTruth96(definitions[key],cp,conditions[key][0]) /\
~ConditionalSibling96(definitions[key],ledger.instances) /\ StaticRetryAllowed96(definitions[key],ledger)
THEN {[definition |-> key,occurrence |-> 0]} ELSE {}
: key \in DOMAIN definitions}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActive96, ConditionalDefinitionValid96, ConditionalInterrupt96, ConditionalSibling96, DelayedConditionalEventScope96, StaticPrimaryTruth96, StaticRetryAllowed96, TriggerPattern96, TriggerStipulations96
CheckpointCandidates99 · operator
reference-profile · input revision 2 · CC0 1.0
CheckpointCandidates99(definitions,lexemes,ledger,cp,conditions) ==
{candidate \in CheckpointCandidates96(definitions,ledger,cp,conditions) : ~AbilityInterrupt99(definitions[candidate.definition],lexemes[candidate.definition])}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, CheckpointCandidates96
CheckpointPriority9 · operator
reference-profile · input revision 2 · CC0 1.0
CheckpointPriority9(before,after,actualCheckpoint) ==
/\ Len(before) > 0
/\ LET w == WindowTop9(before)
IN /\ w.open /\ w.stage = "NeedCheckpoint" /\ w.priority \in SetupPlayers /\ w.busy.id = 0
/\ actualCheckpoint.tag = "NormalPriorityCheckpoint" /\ actualCheckpoint.id \in Nat \ {0}
/\ actualCheckpoint.windowId = w.id /\ actualCheckpoint.reception = w.reception
/\ actualCheckpoint.player = w.priority /\ actualCheckpoint.complete /\ actualCheckpoint.reactionsDrained
/\ after = ReplaceWindowTop9(before,[w EXCEPT !.stage = "Ready",!.checkpoint = actualCheckpoint.id])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, ReplaceWindowTop9, SetupPlayers
CheckpointPriorityWithConditionals96 · operator
reference-profile · input revision 2 · CC0 1.0
CheckpointPriorityWithConditionals96(ledger,before,after,actualCheckpoint) ==
/\ Len(before)>0 /\ actualCheckpoint.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[actualCheckpoint.id].caller=ConditionalPriorityCaller96(WindowTop9(before))
/\ ConditionalCheckpointDrained96(ledger,before,actualCheckpoint.id)
/\ CheckpointPriority9(before,after,actualCheckpoint)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CheckpointPriority9, ConditionalCheckpointDrained96, ConditionalPriorityCaller96, WindowTop9
ChoicePolicy910 · operator
reference-profile · input revision 2 · CC0 1.0
ChoicePolicy910(blueprint) ==
IF blueprint.lingeringConsumers#{} /\ blueprint.otherConsumers={}
THEN "Follow"
ELSE IF blueprint.originKind="Conditional" /\ blueprint.whenYourTurnBegins /\ blueprint.onlyChoice THEN "TurnOrSource"
ELSE "SchemaAtom149"Exact module download · Source bundle and reproduction instructions
CleanupLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
CleanupLingering910(before,after,ledger,world,frame,afterFrame,actualCleanup) ==
/\ OpenLingeringCheckpoint910(ledger,frame.recognition,world,frame)
/\ frame.checkpointId \notin before.cleanupIds /\ ~frame.returned
/\ before.effects=ObserveLingeringEffects910(before.effects,world)
/\ actualCleanup.tag="LingeringCheckpointCleanup" /\ actualCleanup.frame=frame
/\ actualCleanup.expired={id \in DOMAIN before.effects : before.effects[id].status="Expired"}
/\ actualCleanup.complete
/\ after=[before EXCEPT !.effects=[id \in DOMAIN @ \ actualCleanup.expired |-> @[id]],!.cleanupIds=@ \cup {frame.checkpointId}]
/\ afterFrame=[frame EXCEPT !.returned=TRUE,!.point="ProcedureCodeb681cc249a04"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveLingeringEffects910, OpenLingeringCheckpoint910
CleanupLingeringConditionals910 · operator
reference-profile · input revision 2 · CC0 1.0
CleanupLingeringConditionals910(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,world,frame,afterFrame,actualCleanup) ==
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,world)
/\ CleanupLingering910(beforeRegistry,afterRegistry,beforeLedger,world,frame,afterFrame,actualCleanup)
/\ candidateLedger=[beforeLedger EXCEPT !.effects=[id \in DOMAIN @ \ actualCleanup.expired |-> @[id]]]
/\ LingeringConditionalWorld910(afterSnapshot,candidateLedger,world)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,afterRegistry,candidateLedger,world)
/\ ObserveConditionalActivity96(beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CleanupLingering910, DelayedLifetimeBound910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96
CleanupObservedLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
CleanupObservedLingering910(before,after,ledger,a,frame,afterFrame,actualCleanup) ==
/\ LifetimeReady910(before,a)
/\ CleanupLingering910(before,after,ledger,a.current,frame,afterFrame,actualCleanup)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CleanupLingering910, LifetimeReady910
CleanupObservedLingeringConditionals910 · operator
reference-profile · input revision 2 · CC0 1.0
CleanupObservedLingeringConditionals910(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,a,frame,afterFrame,actualCleanup) ==
/\ LifetimeReady910(beforeRegistry,a)
/\ CleanupLingeringConditionals910(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,a.current,frame,afterFrame,actualCleanup)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CleanupLingeringConditionals910, LifetimeReady910
CleanupPaidHeld95 · operator
reference-profile · input revision 2 · CC0 1.0
CleanupPaidHeld95(p,beforeObjects,afterObjects,beforeTransits,afterTransits,stage,successors,usedIds,actualCleanup) ==
LET due == PaidCleanupIds95(p,beforeObjects,beforeTransits,stage)
counters == {id \in due : BankPhysicalToken4(beforeObjects[id])}
cards == due \ counters
IN /\ p.phase="InstructionCheckpoint" /\ p.ability.lastFinished /\ stage \in {"ProcedureCode76ca53ad9dd0","ProcedureCode96bfa1b6a970"}
/\ actualCleanup.tag="PaidHostedCleanup" /\ actualCleanup.abilityInstance=p.id /\ actualCleanup.transactionId=p.transaction
/\ actualCleanup.stage=stage /\ actualCleanup.sources=due /\ actualCleanup.beforeObjects=beforeObjects /\ actualCleanup.afterObjects=afterObjects
/\ actualCleanup.complete /\ actualCleanup.normalRetireAndCounterRules
/\ FreshSuccessors8(cards,successors,usedIds) /\ DOMAIN beforeObjects \subseteq usedIds
/\ DOMAIN afterObjects=(DOMAIN beforeObjects \ due) \cup {successors[id] : id \in cards}
/\ \A id \in DOMAIN beforeObjects \ due : afterObjects[id]=beforeObjects[id]
/\ \A id \in cards :
LET new == successors[id]
IN afterObjects[new].card=beforeObjects[id].card /\ afterObjects[new].zone=actualCleanup.ownerDiscard[id]
/\ actualCleanup.ownerDiscard[id] \in {"SideBDiscard","SideADiscard"}
/\ afterObjects[new].host=0 /\ ~afterObjects[new].deployed
/\ afterTransits=[id \in DOMAIN beforeTransits \ due |-> beforeTransits[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: cards, due, new, FreshSuccessors8
ClearPersistentBarrierInstruction912 · operator
reference-profile · input revision 2 · CC0 1.0
ClearPersistentBarrierInstruction912(registry,before,after,beforeOrigin,afterOrigin,world,history,ledger,beforeStack,afterStack,route,
payload,prevented,clearance,cardFacts,authority) ==
/\ PersistentInterruptWorld912(registry,world,ledger,authority)
/\ beforeOrigin.kind="BarrierInstruction" /\ ExpectedContextOrigin99(before,beforeOrigin) /\ ExpectedContextWorld99(before,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ WouldViewCurrent99(history,before,world)
/\ ExpectedBarrierInstructionProjection99(before,beforeOrigin.procedure,payload,prevented)
/\ LET p == [beforeOrigin.procedure EXCEPT !.payload=payload,!.ability.instructions=payload.instructions,!.prevented=prevented]
ready == [p EXCEPT !.phase="FirstTargets"]
IN /\ route \in {"Window","NoModifiers"}
/\ IF route="Window" THEN
/\ CurrentInterruptWindow99(before,beforeStack)
/\ clearance=BarrierInstructionContextClearance99(before,before.windowId,p)
/\ ReturnBarrierInstructionInterrupt98(p,ready,beforeStack,afterStack,clearance)
/\ \A id \in before.conditionalIds : ledger.instances[id].status \in {"Complete","Lost"}
ELSE /\ before.phase="Cleared" /\ before.conditionalIds={} /\ beforeStack=afterStack
/\ LET proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)
IN PersistentOpeningPaidRelevant912(registry,before,world,history,proposed)={}
/\ clearance=BarrierInstructionContextClearance99(before,0,p)
/\ NoBarrierInstructionInterrupt98(p,ready,beforeStack,
[tag |-> "NoBarrierInstructionInterruptModifiers",barrierInstruction |-> BarrierInstructionWindowRef98(p),conditionalInstances |-> {},paidInterruptAbilities |-> {}],clearance)
/\ afterOrigin=[beforeOrigin EXCEPT !.procedure=ready]
/\ after=[before EXCEPT !.phase="Returned",!.actualEffects=ActualExpectedEffects99(before.state.effects),!.clearance=clearance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, proposed, ready, ActualExpectedEffects99, BarrierInstructionContextClearance99, BarrierInstructionWindowRef98, CurrentInterruptWindow99, CurrentInterruptWorld99, ExpectedBarrierInstructionProjection99, ExpectedContextOrigin99, ExpectedContextWorld99, NoBarrierInstructionInterrupt98, PersistentInterruptWorld912, PersistentOpeningPaidRelevant912, ReturnBarrierInstructionInterrupt98, WouldViewCurrent99
ClearPersistentInstruction912 · operator
reference-profile · input revision 2 · CC0 1.0
ClearPersistentInstruction912(registry,before,after,origin,world,history,ledger,beforeStack,afterStack,route,clearance,cardFacts,authority) ==
/\ PersistentInterruptWorld912(registry,world,ledger,authority)
/\ origin.kind="Instruction" /\ ExpectedContextOrigin99(before,origin) /\ ExpectedContextWorld99(before,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ WouldViewCurrent99(history,before,world)
/\ route \in {"Window","NoModifiers"}
/\ IF route="Window" THEN
/\ CurrentInterruptWindow99(before,beforeStack)
/\ clearance=ContextInstructionClearance99(before,before.windowId)
/\ ReturnInstructionInterrupt93(beforeStack,afterStack,origin.plan,origin.parent,origin.ruleStep,clearance)
/\ \A id \in before.conditionalIds : ledger.instances[id].status \in {"Complete","Lost"}
ELSE /\ before.phase="Cleared" /\ before.conditionalIds={} /\ beforeStack=afterStack
/\ LET proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)
IN PersistentOpeningPaidRelevant912(registry,before,world,history,proposed)={}
/\ clearance=ContextInstructionClearance99(before,0)
/\ NoInstructionInterrupt93(origin.plan,origin.parent,origin.ruleStep,ContextNoModifiers99(before),clearance)
/\ BarrierInstructionOwnerAtTop98(before.owner,afterStack)
/\ after=[before EXCEPT !.phase="InstructionCleared",!.clearance=clearance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: proposed, BarrierInstructionOwnerAtTop98, ContextInstructionClearance99, ContextNoModifiers99, CurrentInterruptWindow99, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, NoInstructionInterrupt93, PersistentInterruptWorld912, PersistentOpeningPaidRelevant912, ReturnInstructionInterrupt93, WouldViewCurrent99
ClearPreparedBarrierInstruction99 · operator
reference-profile · input revision 2 · CC0 1.0
ClearPreparedBarrierInstruction99(before,after,beforeOrigin,afterOrigin,world,history,ledger,beforeStack,afterStack,route,
payload,prevented,clearance,cardFacts) ==
/\ beforeOrigin.kind="BarrierInstruction" /\ ExpectedContextOrigin99(before,beforeOrigin) /\ ExpectedContextWorld99(before,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ WouldViewCurrent99(history,before,world)
/\ ExpectedBarrierInstructionProjection99(before,beforeOrigin.procedure,payload,prevented)
/\ LET p == [beforeOrigin.procedure EXCEPT !.payload=payload,!.ability.instructions=payload.instructions,!.prevented=prevented]
ready == [p EXCEPT !.phase="FirstTargets"]
IN /\ route \in {"Window","NoModifiers"}
/\ IF route="Window" THEN
/\ CurrentInterruptWindow99(before,beforeStack)
/\ clearance=BarrierInstructionContextClearance99(before,before.windowId,p)
/\ ReturnBarrierInstructionInterrupt98(p,ready,beforeStack,afterStack,clearance)
/\ \A id \in before.conditionalIds : ledger.instances[id].status \in {"Complete","Lost"}
ELSE /\ before.phase="Cleared" /\ before.conditionalIds={} /\ beforeStack=afterStack
/\ LET proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)
IN OpeningPaidRelevant99(before,world,history,proposed)={}
/\ clearance=BarrierInstructionContextClearance99(before,0,p)
/\ NoBarrierInstructionInterrupt98(p,ready,beforeStack,
[tag |-> "NoBarrierInstructionInterruptModifiers",barrierInstruction |-> BarrierInstructionWindowRef98(p),conditionalInstances |-> {},paidInterruptAbilities |-> {}],clearance)
/\ afterOrigin=[beforeOrigin EXCEPT !.procedure=ready]
/\ after=[before EXCEPT !.phase="Returned",!.actualEffects=ActualExpectedEffects99(before.state.effects),!.clearance=clearance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, proposed, ready, ActualExpectedEffects99, BarrierInstructionContextClearance99, BarrierInstructionWindowRef98, CurrentInterruptWindow99, CurrentInterruptWorld99, ExpectedBarrierInstructionProjection99, ExpectedContextOrigin99, ExpectedContextWorld99, NoBarrierInstructionInterrupt98, OpeningPaidRelevant99, ReturnBarrierInstructionInterrupt98, WouldViewCurrent99
ClearPreparedInstruction99 · operator
reference-profile · input revision 2 · CC0 1.0
ClearPreparedInstruction99(before,after,origin,world,history,ledger,beforeStack,afterStack,route,clearance,cardFacts) ==
/\ origin.kind="Instruction" /\ ExpectedContextOrigin99(before,origin) /\ ExpectedContextWorld99(before,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ WouldViewCurrent99(history,before,world)
/\ route \in {"Window","NoModifiers"}
/\ IF route="Window" THEN
/\ CurrentInterruptWindow99(before,beforeStack)
/\ clearance=ContextInstructionClearance99(before,before.windowId)
/\ ReturnInstructionInterrupt93(beforeStack,afterStack,origin.plan,origin.parent,origin.ruleStep,clearance)
/\ \A id \in before.conditionalIds : ledger.instances[id].status \in {"Complete","Lost"}
ELSE /\ before.phase="Cleared" /\ before.conditionalIds={} /\ beforeStack=afterStack
/\ LET proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,before.site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)
IN OpeningPaidRelevant99(before,world,history,proposed)={}
/\ clearance=ContextInstructionClearance99(before,0)
/\ NoInstructionInterrupt93(origin.plan,origin.parent,origin.ruleStep,ContextNoModifiers99(before),clearance)
/\ BarrierInstructionOwnerAtTop98(before.owner,afterStack)
/\ after=[before EXCEPT !.phase="InstructionCleared",!.clearance=clearance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: proposed, BarrierInstructionOwnerAtTop98, ContextInstructionClearance99, ContextNoModifiers99, CurrentInterruptWindow99, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, NoInstructionInterrupt93, OpeningPaidRelevant99, ReturnInstructionInterrupt93, WouldViewCurrent99
ClosePriorityWindow9 · operator
reference-profile · input revision 2 · CC0 1.0
ClosePriorityWindow9(w) ==
[w EXCEPT !.open = FALSE,!.stage = "Closed",!.priority = "NoValue",
!.pending = {},!.lostPending = @ \cup w.pending]Exact module download · Source bundle and reproduction instructions
CommitLifetimeFace910 · operator
reference-profile · input revision 2 · CC0 1.0
CommitLifetimeFace910(before,after,afterWorld,object,face,actualEffectAuthorizes,events) ==
AppendLifetimeTransitionCore910(before,after,
LifetimeFaceTransition910(before.current,afterWorld,object,face,actualEffectAuthorizes,events))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AppendLifetimeTransitionCore910, LifetimeFaceTransition910
CommitLifetimeKernelCore910 · operator
reference-profile · input revision 2 · CC0 1.0
CommitLifetimeKernelCore910(before,after,afterWorld,actualExecution) ==
AppendLifetimeTransitionCore910(before,after,LifetimeKernelTransition910(before.current,afterWorld,actualExecution))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AppendLifetimeTransitionCore910, LifetimeKernelTransition910
CommitPaidTrigger95 · operator
reference-profile · input revision 2 · CC0 1.0
CommitPaidTrigger95(stack,before,after,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,actualPayment,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events) ==
/\ PaidProcedureAtTop95(stack,before) /\ PaidPaymentProof95(before,beforeObjects,afterObjects,actualPayment)
/\ PaidHeldTransfer95(before,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,actualPayment)
/\ LET a == [before.ability EXCEPT !.detached=TRUE]
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> before.id,source |-> before.ability.source,player |-> before.definition.syntax.controller]
IN /\ DetachPaidAbility9(before.ability,a,[abilityInstance |-> before.id,allPaid |-> actualPayment.allPaid])
/\ RecordAbilityUse9(beforeUses,afterUses,useId,before.id,before.ability.source,before.definition.syntax.controller,
AbilityUseDue9("Paid",FALSE,actualPayment.allPaid,FALSE,FALSE),{used})
/\ RecordTurnAbilityUse93(beforeTurnUses,afterTurnUses,before.definition.syntax,before.turnId,
[id |-> before.id,ability |-> before.definition.syntax.id,source |-> before.ability.source],used)
/\ OncePerTurnAllowed93(before.definition.syntax,before.turnId,beforeTurnUses)
/\ events={used} \cup actualPayment.publicEvents
/\ after=[before EXCEPT !.ability=a,!.phase="CostCheckpoint",!.costPaid=TRUE,
!.heldSourceIds=DOMAIN successors,!.heldIds={successors[id] : id \in DOMAIN successors},!.sourceForfeited=actualPayment.sourceForfeited]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, used, AbilityUseDue9, DetachPaidAbility9, OncePerTurnAllowed93, PaidHeldTransfer95, PaidPaymentProof95, PaidProcedureAtTop95, RecordAbilityUse9, RecordTurnAbilityUse93
CompiledInstructionTechnique911 · operator
reference-profile · input revision 2 · CC0 1.0
CompiledInstructionTechnique911(p,objects,cardFacts) ==
InstructionTechniqueSource911(p,objects,cardFacts) /\ InstructionPartitionValid911(p)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPartitionValid911, InstructionTechniqueSource911
CompleteBarrierInstructionEncounter98 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteBarrierInstructionEncounter98(loop,e,after,control,step,stack,actualReturn) ==
/\ BarrierInstructionLoopMatches98(loop,e) /\ loop.current=0 /\ BarrierInstructionEncounterCurrent98(e,control) /\ e.stage="BarrierInstructions"
/\ step="ProcedureCode687f72772ab1" /\ (e.forced \/ control.traversal.step=step)
/\ RemainingBarrierInstructions98(loop,e)={} /\ BarrierInstructionOwnerAtTop98(loop.owner,stack)
/\ actualReturn.tag="EncounterBarrierInstructionsReturn" /\ actualReturn.encounter=e.id /\ actualReturn.handled=loop.handled
/\ actualReturn.complete /\ actualReturn.allNewerChainsComplete
/\ after=[e EXCEPT !.stage="Complete"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionEncounterCurrent98, BarrierInstructionLoopMatches98, BarrierInstructionOwnerAtTop98, RemainingBarrierInstructions98
CompleteChosenMust912 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteChosenMust912(before,after,actualReturn,completion) ==
/\ before.phase="Resolving" /\ before.chosen \in DOMAIN before.declaration.options
/\ actualReturn.tag="ExpectedEffectsProcedureReturn"
/\ WouldContextKey99(actualReturn.instruction)=WouldContextKey99(before.result.entry.instruction)
/\ actualReturn.instruction.revision>=before.result.entry.instruction.revision
/\ actualReturn.complete /\ actualReturn.childrenReturned
/\ completion.tag="MustChosenEffectReturn" /\ completion.requirement=before.id /\ completion.decision=before.decision
/\ completion.entry=before.result.entry /\ completion.actualReturn=actualReturn
/\ completion.originalAdditionalDeclines \subseteq before.declaration.options[before.chosen].additionalCosts
/\ before.declaration.form="Choice" => completion.originalAdditionalDeclines={}
/\ after=[before EXCEPT !.phase="Complete",!.result=completion]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldContextKey99
CompleteMidItemInspectionOption9 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteMidItemInspectionOption9(before,after,actualReturn,a,afterItemInspection) ==
/\ Len(before)>0 /\ WindowTop9(before).kind = "MidItemInspection"
/\ WindowTop9(before).site.structure = TimingRef9("ItemInspection",a.id)
/\ PriorityOptionReturnValid9(before,actualReturn) /\ FinishMidItemInspection7(a,afterItemInspection,TRUE)
/\ after = ReplaceWindowTop9(before,CompletePriorityOptionFrame9(WindowTop9(before)))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CompletePriorityOptionFrame9, PriorityOptionReturnValid9, ReplaceWindowTop9, TimingRef9, WindowTop9, FinishMidItemInspection7
CompleteModifierExpectedContext99 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteModifierExpectedContext99(before,after,call,world,actualReturn) ==
/\ before.phase="Resolving" /\ before.currentRef=InstructionWindowRef93(call.beforePlan)
/\ call.afterPlan.phase="Complete"
/\ actualReturn.tag="ExpectedEffectsProcedureReturn" /\ actualReturn.contextId=before.id
/\ actualReturn.instruction=before.currentRef /\ actualReturn.snapshotId=world.id
/\ actualReturn.effects=before.actualEffects /\ actualReturn.complete /\ actualReturn.childrenReturned
/\ call.step.expectedReturn=actualReturn
/\ after=[before EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93
CompleteObservedRuntimeCheckpoint911 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteObservedRuntimeCheckpoint911(before,after,ledger,stack,receipt,lifetimes,authority) ==
/\ RuntimeOwnerCurrent911(before,authority)
/\ CompleteRuntimeCheckpoint911(before,after,ledger,stack,receipt,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CompleteRuntimeCheckpoint911, RuntimeOwnerCurrent911
CompleteOccurrenceCheckpoint912 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteOccurrenceCheckpoint912(before,after,ledger,stack,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(before,authority)
/\ OccurrenceRuntimeProfile912(before) /\ before.phase="Checkpoint"
/\ receipt.tag="OccurrenceInstructionCheckpoint" /\ receipt.instance=before.id /\ receipt.source=before.ability.source
/\ receipt.boundary=before.boundary /\ receipt.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[receipt.id].caller=OccurrenceBoundaryCaller912(before.boundary)
/\ receipt.complete /\ receipt.allNewerChainsComplete /\ ConditionalCheckpointDrained96(ledger,stack,receipt.id)
/\ after=[before EXCEPT !.checkpoint=receipt.id,!.phase=IF before.current=0 THEN "Complete" ELSE "Targets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, LifetimeReady910, OccurrenceBoundaryCaller912, OccurrenceOwnerCurrent912, OccurrenceRuntimeProfile912
CompletePaidOccurrenceCheckpoint912 · operator
reference-profile · input revision 2 · CC0 1.0
CompletePaidOccurrenceCheckpoint912(before,after,ledger,stack,receipt,objects,transits,lifetimes,authority) ==
/\ SourceOccurrenceBound912(before) /\ before.metadata.sourceEntry.kind="Paid" /\ objects=authority.current.objects
/\ SetAsideTrackingValid4(objects,transits) /\ OccurrenceAtTop912(stack,before)
/\ LET p == [before.metadata.sourceEntry.after EXCEPT !.ability=before.ability]
IN /\ PaidConvertedAsideIds95(p,objects,transits)={}
/\ before.current=0 => PaidCleanupIds95(p,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(p,objects,transits,"ProcedureCode96bfa1b6a970")={}
/\ CompleteOccurrenceCheckpoint912(before,after,ledger,stack,receipt,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, CompleteOccurrenceCheckpoint912, OccurrenceAtTop912, PaidCleanupIds95, PaidConvertedAsideIds95, SourceOccurrenceBound912, SetAsideTrackingValid4
CompletePaidRuntimeCheckpoint911 · operator
reference-profile · input revision 2 · CC0 1.0
CompletePaidRuntimeCheckpoint911(before,after,ledger,stack,receipt,objects,transits,lifetimes,authority) ==
/\ SourceRuntimeBound911(before) /\ before.sourceEntry.kind="Paid" /\ objects=authority.current.objects
/\ SetAsideTrackingValid4(objects,transits) /\ BarrierInstructionOwnerAtTop98(before.sourceOwner,stack)
/\ LET p == [before.sourceEntry.after EXCEPT !.ability=before.ability]
IN /\ PaidConvertedAsideIds95(p,objects,transits)={}
/\ before.pc=0 => PaidCleanupIds95(p,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(p,objects,transits,"ProcedureCode96bfa1b6a970")={}
/\ RuntimeOwnerCurrent911(before,authority)
/\ CompleteRuntimeCheckpoint911(before,after,ledger,stack,receipt,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, BarrierInstructionOwnerAtTop98, CompleteRuntimeCheckpoint911, PaidCleanupIds95, PaidConvertedAsideIds95, RuntimeOwnerCurrent911, SourceRuntimeBound911, SetAsideTrackingValid4
CompletePriorityOption9 · operator
reference-profile · input revision 2 · CC0 1.0
CompletePriorityOption9(before,after,actualReturn) ==
/\ Len(before)>0 /\ WindowTop9(before).kind # "MidItemInspection"
/\ PriorityOptionReturnValid9(before,actualReturn)
/\ after = ReplaceWindowTop9(before,CompletePriorityOptionFrame9(WindowTop9(before)))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CompletePriorityOptionFrame9, PriorityOptionReturnValid9, ReplaceWindowTop9, WindowTop9
CompletePriorityOptionFrame9 · operator
reference-profile · input revision 2 · CC0 1.0
CompletePriorityOptionFrame9(w) ==
LET idle == [w EXCEPT !.busy = NoPriorityOption9,!.busyTransaction = 0,!.previousPass = FALSE]
IN IF ~w.open THEN idle
ELSE IF w.kind \in {"NeutralValue00001","MidItemInspection"} THEN ClosePriorityWindow9(idle)
ELSE ReceivePriority9(idle,w.busy.controller)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: idle, ClosePriorityWindow9, ReceivePriority9
CompleteRuntimeCheckpoint911 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteRuntimeCheckpoint911(before,after,ledger,stack,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeProfile911(before) /\ before.phase="Checkpoint"
/\ receipt.tag="GraphInstructionCheckpoint" /\ receipt.instance=before.id /\ receipt.source=before.ability.source
/\ receipt.boundary=before.boundary /\ receipt.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[receipt.id].caller=GraphBoundaryCaller911(before.boundary)
/\ receipt.complete /\ receipt.allNewerChainsComplete /\ ConditionalCheckpointDrained96(ledger,stack,receipt.id)
/\ after=[before EXCEPT !.checkpoint=receipt.id,!.phase=IF before.pc=0 THEN "Complete" ELSE "Targets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, GraphBoundaryCaller911, LifetimeReady910, RuntimeProfile911
CompleteSimultaneousEvaluation912 · operator
reference-profile · input revision 2 · CC0 1.0
CompleteSimultaneousEvaluation912(s,lifetimes,authority,receipt) ==
/\ LifetimeReady910(lifetimes,authority) /\ s.world=authority.current /\ s.lifetimes=lifetimes
/\ s.waiting={} /\ SimultaneousBoundary912(s)="Supported"
/\ DeckSequenceValid4(s.applied) /\ SubIds6(s.applied) \cap s.skipped={}
/\ SubIds6(s.applied) \cup s.skipped=DOMAIN s.effects /\ DOMAIN s.outputs=DOMAIN s.effects
/\ Len(s.trace)=Cardinality(DOMAIN s.effects)
/\ receipt=[tag |-> "CompleteCharacteristicProjection",worldId |-> s.world.id,printed |-> s.printed,effects |-> s.effects,
characteristics |-> s.chars,applied |-> s.applied,skipped |-> s.skipped,trace |-> s.trace]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, SimultaneousBoundary912, DeckSequenceValid4, SubIds6
ConditionKinds93 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionKinds93 == {"Cost","Trigger","Static"}Exact module download · Source bundle and reproduction instructions
ConditionReceiptMatches93 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionReceiptMatches93(unit,ability,actualCondition) ==
/\ unit.category="SchemaAtom043" /\ actualCondition.tag="ConditionEvaluation"
/\ actualCondition.ability=ability /\ actualCondition.unit=unit.id /\ actualCondition.kind=unit.subtype
/\ CASE unit.subtype="Cost" -> actualCondition.paid
[] unit.subtype="Trigger" -> actualCondition.eventOccurred
[] unit.subtype="Static" -> actualCondition.propertyHoldsExact module download · Source bundle and reproduction instructions
ConditionalActive96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalActive96(d,snapshot) ==
/\ d.delayedEffect=0 \/ (d.delayedEffect \in DOMAIN snapshot.effects /\ snapshot.effects[d.delayedEffect].definition=d)
/\ FlagActivity93(d.syntax,snapshot.present,
AbilityActive9(d.activity,snapshot.objects,snapshot.present,snapshot.ordinaryActivity[ConditionalKey96(d)],ConditionalActivityContext96(d,snapshot)),
snapshot.activity.persistentAbilities,snapshot.points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityActive9, ConditionalActivityContext96, ConditionalKey96, FlagActivity93
ConditionalActivityContext96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalActivityContext96(d,snapshot) ==
[snapshot.activity EXCEPT
!.departureHolds=IF ConditionalKey96(d) \in DOMAIN snapshot.holds
THEN [id \in {d.syntax.id} |-> snapshot.holds[ConditionalKey96(d)]] ELSE [id \in {} |-> id],
!.lingeringAbilities=@ \cup {snapshot.effects[id].definition.syntax.id : id \in DOMAIN snapshot.effects}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96
ConditionalActivityLedger96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalActivityLedger96(before,definitions,snapshot) ==
[before EXCEPT !.instances=[id \in DOMAIN @ |->
IF @[id].status="Pending" /\ ~ConditionalInstanceCurrent96(@[id],definitions,snapshot)
THEN [@[id] EXCEPT !.status="Lost"] ELSE @[id]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalInstanceCurrent96
ConditionalActivityLosses96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalActivityLosses96(beforeSnapshot,afterSnapshot) ==
{key \in DOMAIN beforeSnapshot.definitions : ConditionalActive96(beforeSnapshot.definitions[key],beforeSnapshot) /\
(IF key \in DOMAIN afterSnapshot.definitions THEN ~ConditionalActive96(afterSnapshot.definitions[key],afterSnapshot) ELSE TRUE)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActive96
ConditionalActivityRows96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalActivityRows96(instances) ==
[id \in DOMAIN instances |-> [ability |-> instances[id].member.ability,
sourceObject |-> instances[id].member.source.object,status |-> instances[id].status]]Exact module download · Source bundle and reproduction instructions
ConditionalActorMatches96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalActorMatches96(d,actor) ==
d.trigger.actor="SchemaAtom016" \/ actor=(IF d.trigger.actor="Controller" THEN d.syntax.controller ELSE d.trigger.actor)Exact module download · Source bundle and reproduction instructions
ConditionalAtTop96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalAtTop96(stack,p) == PaidProcedureAtTop95(stack,p)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidProcedureAtTop95
ConditionalCheckpointDrained96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalCheckpointDrained96(ledger,stack,checkpointId) ==
/\ checkpointId \in DOMAIN ledger.checkpoints
/\ LET ids == {id \in DOMAIN ledger.instances : ledger.instances[id].checkpointId=checkpointId /\ ~ledger.instances[id].member.interrupt}
windows == {ledger.instances[id].member.windowId : id \in ids}
IN /\ \A id \in ids : ledger.instances[id].status \in {"Complete","Lost"}
/\ \A i \in 1..Len(stack) : stack[i].id \in windows => ~stack[i].open /\ stack[i].busy.id=0Exact module download · Source bundle and reproduction instructions
ConditionalClasses96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalClasses96(d) ==
(IF "EncounterBarrier" \in ConditionalEventKinds96(d) /\ d.trigger.subject="SchemaAtom149" /\ ConditionalActorMatches96(d,"SideB") THEN {"WhenEncountered"} ELSE {}) \cup
(IF "Deployed" \in ConditionalEventKinds96(d) /\ d.trigger.subject="SchemaAtom149" /\ \E p \in SetupPlayers : ConditionalActorMatches96(d,p) THEN {"WhenDeployed"} ELSE {}) \cup
(IF "ObjectivePlacementd" \in ConditionalEventKinds96(d) /\ d.trigger.subject="SchemaAtom149" /\ d.syntax.cardKind="Objective" /\ ConditionalActorMatches96(d,"SideA") THEN {"WhenScored"} ELSE {})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActorMatches96, ConditionalEventKinds96, SetupPlayers
ConditionalCreationInstruction96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalCreationInstruction96(plan,parent,ruleStep) ==
/\ plan.phase="Resolving"
/\ IF plan.origin="Ability" THEN parent.phase="Resolving" /\ InstructionPlanMatches93(plan,parent,parent.cursor)
ELSE RuleInstructionPlan93(plan,ruleStep)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPlanMatches93, RuleInstructionPlan93
ConditionalDefinitionValid96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalDefinitionValid96(d) ==
/\ d.syntax.kind="Conditional" /\ d.activity.kind="Conditional" /\ d.syntax.id \in Nat \ {0}
/\ d.syntax.source.kind \in {"Object","Rule"}
/\ IF d.syntax.source.kind="Object" THEN d.syntax.source.object \in Nat \ {0} ELSE d.syntax.source.rule # "NoValue"
/\ d.activity.id=d.syntax.id /\ d.activity.source=d.syntax.source /\ AbilityTextValid93(d.syntax)
/\ IF d.activity.provider="Lingering" THEN d.delayedEffect \in Nat \ {0} ELSE d.delayedEffect=0
/\ d.primaryKind \in {"Trigger","Static"} /\ Len(d.instructions)>0
/\ d.primaryKind="Trigger" => ConditionalEventKinds96(d) # {}
/\ \E i \in 1..Len(d.syntax.units) : d.syntax.units[i].primary /\ d.syntax.units[i].subtype=d.primaryKind
/\ d.effectChoices # {} /\ d.optionalParts \subseteq UNION d.effectChoices
/\ DOMAIN d.partsByInstruction=SubIds6(d.instructions)
/\ UNION {d.partsByInstruction[id] : id \in DOMAIN d.partsByInstruction}=UNION d.effectChoicesExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityTextValid93, ConditionalEventKinds96, SubIds6
ConditionalDefinitionsStable96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalDefinitionsStable96(beforeSnapshot,afterSnapshot) ==
\A key \in DOMAIN beforeSnapshot.definitions \cap DOMAIN afterSnapshot.definitions : beforeSnapshot.definitions[key]=afterSnapshot.definitions[key]Exact module download · Source bundle and reproduction instructions
ConditionalEpochMap96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalEpochMap96(ledger,definitions) ==
[key \in DOMAIN ledger.activationEpoch \cup DOMAIN definitions |-> IF key \in DOMAIN ledger.activationEpoch THEN ledger.activationEpoch[key] ELSE 0]Exact module download · Source bundle and reproduction instructions
ConditionalEventKinds96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalEventKinds96(d) == d.trigger.kindsExact module download · Source bundle and reproduction instructions
ConditionalExpectedEmpty96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalExpectedEmpty96(instance,instructions) ==
DOMAIN instance.expected=1..Len(instructions) /\ \A i \in DOMAIN instance.expected : instance.expected[i].effects={}Exact module download · Source bundle and reproduction instructions
ConditionalGroupValid9 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalGroupValid9(instances,windowId,group,interrupt) ==
/\ group \in Nat \ {0}
/\ \A id \in DOMAIN instances :
/\ id \in Nat \ {0} /\ instances[id].id = id /\ instances[id].ability \in Nat \ {0}
/\ instances[id].controller \in SetupPlayers /\ instances[id].mandatory \in BOOLEAN
/\ instances[id].windowId = windowId /\ instances[id].group = group /\ instances[id].interrupt = interrupt
/\ instances[id].source.kind \in {"Object","Rule"}
/\ IF instances[id].source.kind="Object" THEN instances[id].source.object \in Nat \ {0}
ELSE instances[id].source.rule # "NoValue"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SetupPlayers
ConditionalInstance9 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInstance9(id,ability,source,controller,mandatory,group,windowId,interrupt) ==
[id |-> id,ability |-> ability,source |-> source,controller |-> controller,
mandatory |-> mandatory,group |-> group,windowId |-> windowId,interrupt |-> interrupt]Exact module download · Source bundle and reproduction instructions
ConditionalInstanceCurrent96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInstanceCurrent96(instance,definitions,snapshot) ==
IF instance.definition \notin DOMAIN definitions THEN FALSE
ELSE instance.definitionCopy=definitions[instance.definition] /\ ConditionalActive96(definitions[instance.definition],snapshot) /\ instance.activationEpoch=snapshot.activationEpoch[instance.definition]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActive96
ConditionalInstructionCaller96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInstructionCaller96(p) ==
[kind |-> "AbilityInstruction",abilityKind |-> p.ability.kind,abilityInstance |-> p.id,source |-> p.ability.source,
instruction |-> p.ability.instructions[p.ability.cursor],index |-> p.ability.cursor,windowId |-> p.windowId,transactionId |-> p.transaction]Exact module download · Source bundle and reproduction instructions
ConditionalInstructionCheckpoint96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInstructionCheckpoint96(ledger,stack,before,after,actualCheckpoint) ==
/\ actualCheckpoint.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[actualCheckpoint.id].caller=ConditionalInstructionCaller96(before)
/\ ConditionalCheckpointDrained96(ledger,stack,actualCheckpoint.id)
/\ ConditionalInstructionCheckpointCore96(stack,before,after,actualCheckpoint)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, ConditionalInstructionCaller96, ConditionalInstructionCheckpointCore96
ConditionalInstructionCheckpointCore96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInstructionCheckpointCore96(stack,before,after,actualCheckpoint) ==
/\ ConditionalAtTop96(stack,before) /\ before.phase="InstructionCheckpoint"
/\ actualCheckpoint.tag="ConditionalInstructionCheckpoint" /\ actualCheckpoint.id \in Nat \ {0}
/\ actualCheckpoint.abilityInstance=before.id /\ actualCheckpoint.transactionId=before.transaction
/\ actualCheckpoint.source=before.ability.source /\ actualCheckpoint.instruction=before.ability.instructions[before.ability.cursor]
/\ actualCheckpoint.index=before.ability.cursor /\ actualCheckpoint.complete /\ actualCheckpoint.allNewerChainsComplete
/\ after=[before EXCEPT !.checkpoint=actualCheckpoint.id,!.phase=IF before.ability.lastFinished THEN "Complete" ELSE "Targets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalAtTop96
ConditionalInterrupt96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInterrupt96(d) == AbilityIsInterrupt9(FlagPresent93(d.syntax.units,"Interrupt"),d.instructionHasWould)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityIsInterrupt9, FlagPresent93
ConditionalInterruptPrimary99 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalInterruptPrimary99(d,capabilities,context,world,history) ==
IF d.primaryKind="Static" THEN TRUE
ELSE /\ "primaryGroups" \in DOMAIN capabilities
/\ \E group \in DOMAIN capabilities.primaryGroups :
\A id \in capabilities.primaryGroups[group] :
\E effect \in DOMAIN context.state.effects : CapabilityRelevant99(capabilities.clauses[id],context.state.effects[effect],context,world,history)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CapabilityRelevant99
ConditionalKey96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalKey96(d) == [ability |-> d.syntax.id,source |-> d.syntax.source]Exact module download · Source bundle and reproduction instructions
ConditionalLexemesBound99 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalLexemesBound99(definitions,lexemes,snapshot,cardFacts) ==
/\ DOMAIN lexemes=DOMAIN definitions
/\ \A key \in DOMAIN definitions : AbilityLexemesValid99(definitions[key],lexemes[key],snapshot.objects,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityLexemesValid99
ConditionalLiveInstance96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalLiveInstance96(i) == i.status \in {"Pending","Imminent","Resolving"}Exact module download · Source bundle and reproduction instructions
ConditionalMember96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalMember96(id,d,windowId,group) ==
ConditionalInstance9(id,d.syntax.id,d.syntax.source,d.syntax.controller,~ConditionalOptional96(d),group,windowId,ConditionalInterrupt96(d))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalInstance9, ConditionalInterrupt96, ConditionalOptional96
ConditionalOccurrenceBound912 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalOccurrenceBound912(ledger,r) ==
/\ OccurrenceRuntimeProfile912(r) /\ r.metadata.kind="Conditional" /\ r.id \in DOMAIN ledger.instances
/\ LET i == ledger.instances[r.id]
IN /\ i.definition=ConditionalKey96(r.technique.definition) /\ i.definitionCopy=r.technique.definition
/\ i.member.source=r.ability.source /\ i.member.windowId=r.metadata.windowId
/\ r.ability.caller=r.metadata.windowId /\ r.metadata.option.instance=r.id
/\ r.metadata.option.ability=i.member.ability /\ r.metadata.transaction \in Nat \ {0}
/\ r.metadata.option.source=i.member.source /\ r.metadata.option.controller=i.member.controllerExact module download · Source bundle and reproduction instructions
Resolved project definitions: i, ConditionalKey96, OccurrenceRuntimeProfile912
ConditionalOptionMatches9 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalOptionMatches9(w,option) ==
/\ option.instance \in w.pending
/\ LET i == w.members[option.instance]
IN option.ability = i.ability /\ option.source = i.source /\ option.controller = i.controllerExact module download · Source bundle and reproduction instructions
Resolved project definitions: i
ConditionalOptional96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalOptional96(d) == {} \in d.effectChoices \/ FlagPresent93(d.syntax.units,"OncePerTurn")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93
ConditionalPendingAfterWindows96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalPendingAfterWindows96(before,afterStack) ==
[before EXCEPT !.instances=[id \in DOMAIN @ |->
IF @[id].status="Pending" /\ \E i \in 1..Len(afterStack) : afterStack[i].id=@[id].member.windowId /\ id \notin afterStack[i].pending
THEN [@[id] EXCEPT !.status="Lost"] ELSE @[id]]]Exact module download · Source bundle and reproduction instructions
ConditionalPriorityCaller96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalPriorityCaller96(w) ==
[kind |-> "PriorityReception",windowId |-> w.id,reception |-> w.reception,player |-> w.priority]Exact module download · Source bundle and reproduction instructions
ConditionalProcedureBound96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalProcedureBound96(ledger,p) ==
/\ p.id \in DOMAIN ledger.instances
/\ LET instance == ledger.instances[p.id]
IN /\ instance.definition=ConditionalKey96(p.definition) /\ instance.definitionCopy=p.definition
/\ p.ability.id=p.id /\ p.ability.kind="Conditional" /\ p.ability.source=instance.member.source
/\ p.ability.instructions=p.definition.instructions /\ p.ability.caller=p.windowId /\ p.windowId=instance.member.windowId
/\ p.option.instance=p.id /\ p.option.ability=instance.member.ability /\ p.option.source=instance.member.source
/\ p.option.controller=instance.member.controller /\ p.transaction \in Nat \ {0}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: instance, ConditionalKey96
ConditionalRegistrySnapshotBound96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalRegistrySnapshotBound96(snapshot,ledger) ==
snapshot.holds=ledger.holds /\ snapshot.effects=ledger.effects /\ snapshot.activity.instances=ConditionalActivityRows96(ledger.instances)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityRows96
ConditionalRuntimeBound911 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalRuntimeBound911(ledger,r) ==
/\ RuntimeProfile911(r) /\ r.id \in DOMAIN ledger.instances
/\ LET i == ledger.instances[r.id]
IN /\ i.definition=ConditionalKey96(r.technique.definition) /\ i.definitionCopy=r.technique.definition
/\ r.ability.kind="Conditional" /\ r.ability.source=i.member.source /\ r.ability.caller=r.windowId
/\ r.windowId=i.member.windowId /\ r.option.instance=r.id /\ r.option.ability=i.member.ability
/\ r.option.source=i.member.source /\ r.option.controller=i.member.controller /\ r.transaction \in Nat \ {0}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: i, ConditionalKey96, RuntimeProfile911
ConditionalSibling96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalSibling96(d,instances) ==
\E id \in DOMAIN instances : instances[id].member.ability=d.syntax.id /\ instances[id].member.source=d.syntax.source /\ ConditionalLiveInstance96(instances[id])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalLiveInstance96
ConditionalSnapshotBound96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalSnapshotBound96(snapshot,ledger) ==
/\ ConditionalRegistrySnapshotBound96(snapshot,ledger)
/\ snapshot.activationEpoch=ConditionalEpochMap96(ledger,snapshot.definitions) /\ snapshot.activationSerial=ledger.activationSerialExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalEpochMap96, ConditionalRegistrySnapshotBound96
ConditionalStartWorld911 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalStartWorld911(entry,world,authority) ==
/\ entry.snapshot=SnapshotWithConditionalRegistry96(world.conditional,entry.beforeLedger)
/\ entry.snapshot.id=world.id /\ entry.turnUses=world.turnUses
/\ world.conditional.points=authority.current.points /\ world.conditional.present=authority.current.present
/\ [world.conditional.activity EXCEPT !.instances=authority.current.activity.instances]=authority.current.activityExact module download · Source bundle and reproduction instructions
Resolved project definitions: SnapshotWithConditionalRegistry96
ConditionalUseOptionalParts96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalUseOptionalParts96(d) == IF ConditionalOptional96(d) THEN UNION d.effectChoices ELSE d.optionalPartsExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalOptional96
ConditionalWindowKind96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalWindowKind96(d) == IF ConditionalInterrupt96(d) THEN "Interrupt" ELSE "Reaction"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalInterrupt96
ConditionalWindowMembers96 · operator
reference-profile · input revision 2 · CC0 1.0
ConditionalWindowMembers96(instances,windowId) ==
[id \in {i \in DOMAIN instances : instances[i].member.windowId=windowId /\ instances[i].status="Pending"} |-> instances[id].member]Exact module download · Source bundle and reproduction instructions
ContextInitialObservationBound99 · operator
reference-profile · input revision 2 · CC0 1.0
ContextInitialObservationBound99(ledger,p,context) ==
/\ ConditionalProcedureBound96(ledger,p)
/\ context.initialRef.abilityInstance=p.id /\ context.initialRef.index \in DOMAIN ledger.instances[p.id].expected
/\ ledger.instances[p.id].expected[context.initialRef.index]=[instruction |-> context.initialRef,effects |-> ExpectedObservationSet99(context.initialEffects)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalProcedureBound96, ExpectedObservationSet99
ContextInstructionClearance99 · operator
reference-profile · input revision 2 · CC0 1.0
ContextInstructionClearance99(context,windowId) ==
[tag |-> "InstructionInterruptReturn",instruction |-> context.currentRef.id,origin |-> context.currentRef.origin,
abilityInstance |-> context.currentRef.abilityInstance,index |-> context.currentRef.index,source |-> context.currentRef.source,
sourceZone |-> context.currentRef.sourceZone,revision |-> context.currentRef.revision,windowId |-> windowId,
openingRevision |-> context.openingRef.revision,complete |-> TRUE]Exact module download · Source bundle and reproduction instructions
ContextNoModifiers99 · operator
reference-profile · input revision 2 · CC0 1.0
ContextNoModifiers99(context) ==
[tag |-> "NoInstructionInterruptModifiers",instruction |-> context.currentRef,conditionalInstances |-> {},paidInterruptAbilities |-> {}]Exact module download · Source bundle and reproduction instructions
ContinueAbilityInstructions9 · operator
reference-profile · input revision 2 · CC0 1.0
ContinueAbilityInstructions9(before,after,actualCheckpointAndAllNewerChainsComplete) ==
/\ before.phase = "Between" /\ ~before.complete /\ before.cursor < Len(before.instructions)
/\ actualCheckpointAndAllNewerChainsComplete
/\ after = [before EXCEPT !.cursor = @+1,!.phase = "Imminent"]Exact module download · Source bundle and reproduction instructions
ContinuousOriginalActive99 · operator
reference-profile · input revision 2 · CC0 1.0
ContinuousOriginalActive99(original,current) ==
ContinuousOriginalPresent99(original,current) /\ original.id \in current.activeOriginalsExact module download · Source bundle and reproduction instructions
Resolved project definitions: ContinuousOriginalPresent99
ContinuousOriginalPresent99 · operator
reference-profile · input revision 2 · CC0 1.0
ContinuousOriginalPresent99(original,current) ==
original.id \in DOMAIN current.maintainedEffects /\ current.maintainedEffects[original.id]=originalExact module download · Source bundle and reproduction instructions
ContinuousStaticActive99 · operator
reference-profile · input revision 2 · CC0 1.0
ContinuousStaticActive99(definition,syntax,current) ==
StaticAbilityActive94(definition,syntax,current.objects,current.present,
current.ordinaryActivity[ContinuousStaticKey99(definition,syntax)],current.activity,current.points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ContinuousStaticKey99, StaticAbilityActive94
ContinuousStaticKey99 · operator
reference-profile · input revision 2 · CC0 1.0
ContinuousStaticKey99(d,syntax) == [ability |-> syntax.id,source |-> d.source]Exact module download · Source bundle and reproduction instructions
ControlResultBound911 · operator
reference-profile · input revision 2 · CC0 1.0
ControlResultBound911(r,context,actualReturn,result) ==
/\ r.phase="Resolve" /\ r.pc \in DOMAIN r.technique.nodes
/\ context.phase="Resolving" /\ context.currentRef.abilityInstance=r.id /\ context.currentRef.id=r.pc
/\ result.tag="ResolvedInstructionControl" /\ result.instance=r.id /\ result.node=r.pc
/\ result.instruction=context.currentRef /\ result.contextId=context.id
/\ result.actualEffects=context.actualEffects /\ result.completion=actualReturn
/\ actualReturn.tag="ExpectedEffectsProcedureReturn" /\ actualReturn.contextId=context.id
/\ actualReturn.instruction=context.currentRef /\ actualReturn.effects=context.actualEffects
/\ actualReturn.complete /\ actualReturn.childrenReturned
/\ result.mode \in {"Selected","Removed"}
/\ IF result.mode="Selected" THEN
/\ result.operation \in DOMAIN context.actualEffects
/\ context.actualEffects[result.operation].kind \in {"InstructionChoice","NestedCostChoice"}
/\ context.actualEffects[result.operation].controlNode=r.pc
/\ result.option \in DOMAIN r.technique.nodes[r.pc].options
/\ result.option \in context.actualEffects[result.operation].options
/\ result.chooser=context.actualEffects[result.operation].chooser /\ result.chooser \in SetupPlayers
ELSE ~\E op \in DOMAIN context.actualEffects :
context.actualEffects[op].kind \in {"InstructionChoice","NestedCostChoice"} /\ context.actualEffects[op].controlNode=r.pcExact module download · Source bundle and reproduction instructions
Resolved project definitions: SetupPlayers
CopiedBarrierInstructionDefinition98 · operator
reference-profile · input revision 2 · CC0 1.0
CopiedBarrierInstructionDefinition98(d,id) == [ReidentifyBarrierInstruction98(d,id) EXCEPT !.activity.provider="Granted"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReidentifyBarrierInstruction98
CopyAllBarrierInstructions98 · operator
reference-profile · input revision 2 · CC0 1.0
CopyAllBarrierInstructions98(before,after,grant,copies,spine,decision,objects,cardFacts) ==
LET gained == {copies[id] : id \in DOMAIN copies}
rows == [id \in gained |-> LET parent == CHOOSE p \in DOMAIN copies : copies[p]=id
IN [definition |-> CopiedBarrierInstructionDefinition98(before.definitions[parent],id),textKey |-> before.provenance[parent].textKey,
effect |-> grant.id,parent |-> parent,printedSlot |-> 0,template |-> 0]]
applications == [id \in {grant.id} |-> grant]
present == before.present \cup gained
IN /\ BarrierInstructionOrderValid98(before) /\ BarrierInstructionGrantValid98(grant,before.barrierCard,objects,cardFacts) /\ grant.mode="TLDR"
/\ grant.id \notin DOMAIN before.applications /\ DOMAIN copies=before.present
/\ gained \subseteq (Nat \ {0}) \ before.usedIds /\ Cardinality(gained)=Cardinality(before.present)
/\ spine=CopySubSpine98(before.spine,copies)
/\ OrderingDecisionBound98(before,decision,"TLDRCopy",gained,{},spine,present)
/\ after=OrderChangedState98(before,rows,applications,present,spine,decision,"TLDRCopy",{},"Copy")
/\ BarrierInstructionOrderValid98(after) /\ SelfCategoryIdentical98(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: applications, gained, present, rows, BarrierInstructionGrantValid98, BarrierInstructionOrderValid98, CopySubSpine98, OrderChangedState98, OrderingDecisionBound98, SelfCategoryIdentical98
CopySubSpine98 · operator
reference-profile · input revision 2 · CC0 1.0
CopySubSpine98(spine,copies) ==
IF Len(spine)=0 THEN <<>> ELSE
(IF Head(spine) \in DOMAIN copies THEN <<Head(spine),copies[Head(spine)]>> ELSE <<Head(spine)>>) \o CopySubSpine98(Tail(spine),copies)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CopySubSpine98
CounterPermissionUseSources9 · operator
reference-profile · input revision 2 · CC0 1.0
CounterPermissionUseSources9(actualPayment,permissionWitnesses) ==
IF ~actualPayment.complete THEN {}
ELSE {permissionWitnesses[id].source : id \in
{i \in DOMAIN permissionWitnesses :
permissionWitnesses[i].paymentId = actualPayment.id /\ permissionWitnesses[i].allowsPayment /\ permissionWitnesses[i].paidCounters # {} /\
permissionWitnesses[i].paidCounters \subseteq actualPayment.paidCounterIds}}Exact module download · Source bundle and reproduction instructions
CreateBarrierInstructionConditionalInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
CreateBarrierInstructionConditionalInterrupt98(before,after,id,d,p,snapshot,prepared,windowId,group,usedWindows) ==
/\ BarrierInstructionImminent98(p) /\ ConditionalSnapshotBound96(snapshot,before)
/\ ConditionalKey96(d) \in DOMAIN snapshot.definitions /\ snapshot.definitions[ConditionalKey96(d)]=d
/\ ConditionalDefinitionValid96(d) /\ ConditionalInterrupt96(d) /\ ConditionalActive96(d,snapshot)
/\ id \in (Nat \ {0}) \ DOMAIN before.instances /\ windowId \in (Nat \ {0}) \ usedWindows /\ group \in Nat \ {0}
/\ prepared.tag="ConditionalInterruptMatch" /\ prepared.instruction=BarrierInstructionWindowRef98(p)
/\ prepared.ability=d.syntax.id /\ prepared.source=d.syntax.source /\ prepared.snapshotId=snapshot.id /\ prepared.matches
/\ prepared.occurrence \in Nat \ {0}
/\ [definition |-> ConditionalKey96(d),occurrence |-> prepared.occurrence] \notin before.interruptRecognitions
/\ IF d.primaryKind="Static" THEN ~ConditionalSibling96(d,before.instances) /\ StaticRetryAllowed96(d,before) ELSE TRUE
/\ LET instance == [member |-> ConditionalMember96(id,d,windowId,group),definition |-> ConditionalKey96(d),definitionCopy |-> d,status |-> "Pending",
primaryKind |-> d.primaryKind,activationEpoch |-> snapshot.activationEpoch[ConditionalKey96(d)],checkpointId |-> before.lastCheckpoint,
occurrence |-> prepared.occurrence,hadSnapshot |-> before.lastSnapshot,expected |-> EmptyOrder98,used |-> FALSE]
IN after=[before EXCEPT !.activationEpoch=snapshot.activationEpoch,
!.interruptRecognitions=@ \cup {[definition |-> ConditionalKey96(d),occurrence |-> prepared.occurrence]},
!.instances=[i \in DOMAIN @ \cup {id} |-> IF i=id THEN instance ELSE @[i]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: instance, BarrierInstructionImminent98, BarrierInstructionWindowRef98, ConditionalActive96, ConditionalDefinitionValid96, ConditionalInterrupt96, ConditionalKey96, ConditionalSibling96, ConditionalSnapshotBound96, StaticRetryAllowed96
CreateConditionalInterrupt96 · operator
reference-profile · input revision 2 · CC0 1.0
CreateConditionalInterrupt96(before,after,id,d,plan,parent,ruleStep,snapshot,prepared,windowId,group,usedWindowIds) ==
/\ ConditionalSnapshotBound96(snapshot,before)
/\ ConditionalKey96(d) \in DOMAIN snapshot.definitions /\ snapshot.definitions[ConditionalKey96(d)]=d
/\ windowId \notin usedWindowIds
/\ ConditionalDefinitionValid96(d) /\ ConditionalInterrupt96(d) /\ ConditionalActive96(d,snapshot)
/\ InstructionImminentAtOrigin93(plan,parent,ruleStep) /\ id \in (Nat \ {0}) \ DOMAIN before.instances
/\ prepared.tag="ConditionalInterruptMatch" /\ prepared.instruction=InstructionWindowRef93(plan)
/\ prepared.ability=d.syntax.id /\ prepared.source=d.syntax.source /\ prepared.snapshotId=snapshot.id
/\ prepared.matches /\ prepared.occurrence \in Nat \ {0}
/\ [definition |-> ConditionalKey96(d),occurrence |-> prepared.occurrence] \notin before.interruptRecognitions
/\ windowId \in Nat \ {0} /\ group \in Nat \ {0}
/\ IF d.primaryKind="Static" THEN ~ConditionalSibling96(d,before.instances) /\ StaticRetryAllowed96(d,before) ELSE TRUE
/\ LET instance == [member |-> ConditionalMember96(id,d,windowId,group),definition |-> ConditionalKey96(d),definitionCopy |-> d,status |-> "Pending",
primaryKind |-> d.primaryKind,activationEpoch |-> snapshot.activationEpoch[ConditionalKey96(d)],
checkpointId |-> before.lastCheckpoint,occurrence |-> prepared.occurrence,
hadSnapshot |-> before.lastSnapshot,expected |-> [i \in {} |-> i],used |-> FALSE]
IN after=[before EXCEPT !.activationEpoch=snapshot.activationEpoch,
!.interruptRecognitions=@ \cup {[definition |-> ConditionalKey96(d),occurrence |-> prepared.occurrence]},
!.instances=[i \in DOMAIN @ \cup {id} |-> IF i=id THEN instance ELSE @[i]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: instance, ConditionalActive96, ConditionalDefinitionValid96, ConditionalInterrupt96, ConditionalKey96, ConditionalSibling96, ConditionalSnapshotBound96, InstructionImminentAtOrigin93, InstructionWindowRef93, StaticRetryAllowed96
CreateDelayedConditional96 · operator
reference-profile · input revision 2 · CC0 1.0
CreateDelayedConditional96(before,after,effectId,definitionId,template,plan,parent,ruleStep,actualCreation,traversal,usedDefinitions) ==
/\ ConditionalCreationInstruction96(plan,parent,ruleStep)
/\ actualCreation.tag="DelayedConditionalCreation" /\ actualCreation.instruction=InstructionWindowRef93(plan)
/\ actualCreation.template=template /\ template.syntax.source=plan.source
/\ ConditionalDefinitionValid96(template) /\ actualCreation.association \in {"Ordinary","IfSuccessfulInspection"}
/\ IF template.thisTraversal /\ "TraversalEnds" \in ConditionalEventKinds96(template) /\ ~TraversalTimingPresent6(traversal) THEN after=before
ELSE /\ effectId \in (Nat \ {0}) \ (DOMAIN before.effects \cup before.usedDelayedEffects)
/\ definitionId \in (Nat \ {0}) \ (usedDefinitions \cup before.usedDelayedDefinitions)
/\ definitionId \notin {before.effects[id].definition.syntax.id : id \in DOMAIN before.effects}
/\ IF actualCreation.association="IfSuccessfulInspection" THEN
"Inspection" \in ConditionalEventKinds96(template) /\ IfSuccessfulCondition6(actualCreation.ifSuccessfulOrigin,traversal,actualCreation.permittedTargetSites)
ELSE TRUE
/\ DelayedDurationValid96(actualCreation.duration)
/\ LET definition == DelayedDefinition96(template,definitionId,effectId)
duration == IF actualCreation.association="IfSuccessfulInspection" THEN TimingRef9("SchemaAtom138",traversal.id) ELSE actualCreation.duration
trigger == IF template.thisTraversal THEN TimingRef9("SchemaAtom138",traversal.id) ELSE actualCreation.triggerStructure
effect == [id |-> effectId,definition |-> definition,source |-> plan.source,
policy |-> IF duration=NoTimingRef9 THEN "UntilResolution" ELSE "UntilDurationExpires",
duration |-> duration,triggerStructure |-> trigger,association |-> actualCreation.association,
traversalId |-> IF actualCreation.association="IfSuccessfulInspection" THEN traversal.id ELSE 0]
IN after=[before EXCEPT !.effects=[id \in DOMAIN @ \cup {effectId} |-> IF id=effectId THEN effect ELSE @[id]],
!.usedDelayedEffects=@ \cup {effectId},!.usedDelayedDefinitions=@ \cup {definitionId}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effect, ConditionalCreationInstruction96, ConditionalDefinitionValid96, ConditionalEventKinds96, DelayedDurationValid96, InstructionWindowRef93, IfSuccessfulCondition6, TraversalTimingPresent6
CreateDelayedLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
CreateDelayedLingering910(beforeRegistry,afterRegistry,beforeLedger,createdLedger,effectId,definitionId,template,
context,origin,operation,actualExecution,actualCreation,world,usedDefinitions) ==
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ world.finishedDelayedEffects \subseteq beforeRegistry.usedEffects
/\ origin.kind="Instruction"
/\ CreateDelayedConditional96(beforeLedger,createdLedger,effectId,definitionId,template,origin.plan,origin.parent,
origin.ruleStep,actualCreation,world.control.traversal,usedDefinitions)
/\ actualExecution.blueprints=
IF DelayedCreationOmitted910(template,world.control.traversal) THEN [id \in {} |-> id]
ELSE [id \in {effectId} |-> DelayedLifetimeBlueprint910(createdLedger.effects[id],origin,world)]
/\ CreateLingeringEffectsCore910(beforeRegistry,afterRegistry,context,origin,operation,actualExecution,world)
/\ DelayedLifetimeBound910(afterRegistry,createdLedger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CreateDelayedConditional96, CreateLingeringEffectsCore910, DelayedCreationOmitted910, DelayedLifetimeBlueprint910, DelayedLifetimeBound910
CreateImmediateReplacementCore99 · operator
reference-profile · input revision 2 · CC0 1.0
CreateImmediateReplacementCore99(before,after,beforeOrigin,afterOrigin,modifier,world,selection,p,plan,operation,record,
afterUsedIds,states,steps,cardFacts) ==
/\ ExpectedContextOrigin99(before,beforeOrigin) /\ ExpectedContextWorld99(before,world) /\ before.phase="WindowOpen"
/\ ExpectedReplacementCreationBound99(before,modifier,plan,operation,record)
/\ record.definition=p.definition /\ record.lexemes=selection.lexemes /\ record.bindingSnapshotId=world.id
/\ record.id \in (Nat \ {0}) \ (world.usedReplacementIds \cup DOMAIN before.temporaryReplacements)
/\ afterUsedIds=world.usedReplacementIds \cup {record.id}
/\ LET created == [before EXCEPT !.temporaryReplacements=ReplacementOverlay99(@,[id \in {record.id} |-> record])]
replacements == ActiveReplacementBlueprints99(created,world)
IN /\ ReplacementSourcesBound99(created,world,cardFacts)
/\ ApplyCreatedReplacementImmediately99(before.state,states[Len(states)],replacements,record.id,
[id |-> world.id,controllers |-> world.controllers],states,steps)
/\ AppliedReplacementContext99(created,after,beforeOrigin,afterOrigin,world,states[Len(states)],Len(steps)+1)
/\ after.wouldGroups=ReplacementWouldGroups99(before.wouldGroups,states,steps,replacements)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: created, replacements, AppliedReplacementContext99, ApplyCreatedReplacementImmediately99, ExpectedContextOrigin99, ExpectedContextWorld99, ExpectedReplacementCreationBound99, ReplacementSourcesBound99, ReplacementWouldGroups99
CreateLingeringEffects910 · operator
reference-profile · input revision 2 · CC0 1.0
CreateLingeringEffects910(before,after,context,origin,operation,actualExecution,world) ==
/\ \A id \in DOMAIN actualExecution.blueprints : actualExecution.blueprints[id].kind#"Delayed"
/\ CreateLingeringEffectsCore910(before,after,context,origin,operation,actualExecution,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CreateLingeringEffectsCore910
CreateLingeringEffectsCore910 · operator
reference-profile · input revision 2 · CC0 1.0
CreateLingeringEffectsCore910(before,after,context,origin,operation,actualExecution,world) ==
/\ LingeringExecution910(context,origin,operation,actualExecution,world)
/\ LingeringCreationKey910(context,operation) \notin before.creations
/\ LET blueprints == actualExecution.blueprints
ids == DOMAIN blueprints
created == [id \in DOMAIN before.effects \cup ids |->
IF id \in ids THEN NewLingeringEffect910(id,blueprints[id],context,operation,world) ELSE before.effects[id]]
IN /\ ids \subseteq (Nat \ {0}) \ before.usedEffects
/\ \A id \in ids :
/\ blueprints[id].kind \in {"Choice","Strength","Subtype","Delayed","Replacement","Ordinary"}
/\ blueprints[id].source=context.currentRef.source
/\ blueprints[id].originKind=IF origin.plan.origin="Rule" THEN "Rule" ELSE origin.parent.kind
/\ blueprints[id].durationMode \in {"Specified","ImplicitSelfStrength"}
/\ blueprints[id].durationMode="ImplicitSelfStrength" =>
/\ blueprints[id].kind="Strength"
/\ ImplicitStrengthBinding910(blueprints[id].source,blueprints[id].target,world,
IF world.currentEncounter \in DOMAIN world.encounters THEN TimingRef9("TraversalPhase",world.currentEncounter) ELSE NoTimingRef9,
blueprints[id].baseDuration)
/\ blueprints[id].baseDuration.kind \in {"Timing","UntilResolution","DelayedResolution","Stated"}
/\ blueprints[id].baseDuration.kind="Timing" =>
blueprints[id].baseDuration.ref=NoTimingRef9 \/ blueprints[id].baseDuration.ref \in LingeringTimingRefs910(world)
/\ blueprints[id].kind="Choice" =>
/\ (ChoicePolicy910(blueprints[id])#"Follow" \/ Cardinality(blueprints[id].lingeringConsumers)=1)
/\ blueprints[id].lingeringConsumers \subseteq DOMAIN created
/\ \A consumer \in blueprints[id].lingeringConsumers :
created[consumer].kind#"Choice" /\ created[consumer].source=context.currentRef.source
/\ after=[before EXCEPT !.effects=ObserveLingeringEffects910(created,world),!.usedEffects=@ \cup ids,
!.creations=@ \cup {LingeringCreationKey910(context,operation)}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: blueprints, created, ids, ChoicePolicy910, ImplicitStrengthBinding910, LingeringCreationKey910, LingeringExecution910, LingeringTimingRefs910, NoTimingRef9, ObserveLingeringEffects910, TimingRef9
CreateObservedLingeringEffects910 · operator
reference-profile · input revision 2 · CC0 1.0
CreateObservedLingeringEffects910(before,after,context,origin,operation,execution,a) ==
/\ LifetimeReady910(before,a)
/\ CreateLingeringEffects910(before,after,context,origin,operation,execution,a.current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CreateLingeringEffects910, LifetimeReady910
CreatePersistentOnRetire912 · operator
reference-profile · input revision 2 · CC0 1.0
CreatePersistentOnRetire912(beforeRegistry,afterRegistry,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot,
inventory,trash,effectIds,usedObjects,beforeAuthority,afterAuthority,cardFacts) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority)
/\ PersistentRegistryWorldBound912(beforeRegistry,beforeAuthority.current)
/\ trash.id \notin beforeRegistry.persistentRetireIds
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=afterAuthority.current.id
/\ beforeSnapshot.objects=beforeAuthority.current.objects /\ afterSnapshot.objects=afterAuthority.current.objects
/\ PersistentRetireBound912(trash,inventory,beforeAuthority.current,afterAuthority.current.objects,usedObjects,cardFacts)
/\ usedObjects=beforeSnapshot.usedObjects
/\ afterSnapshot.usedObjects=usedObjects \cup {trash.successor}
/\ afterSnapshot.definitions=beforeSnapshot.definitions
/\ PersistentConditionalDefinitions912(beforeRegistry,beforeSnapshot.definitions)
/\ PersistentConditionalDefinitions912(afterRegistry,afterSnapshot.definitions)
/\ LET world == beforeAuthority.current
next == afterAuthority.current
cohort == PersistentBirthCohort912(inventory,world)
sourceIds == {inventory.definitions[key].syntax.id : key \in DOMAIN inventory.definitions}
records == [key \in cohort |-> PersistentRecord912(inventory.definitions[key],inventory.lexemes[key],effectIds[key],trash,world)]
effects == [id \in {effectIds[key] : key \in cohort} |->
LET key == CHOOSE key \in cohort : effectIds[key]=id
IN PersistentEffect912(id,inventory.definitions[key],inventory.lexemes[key],trash,trash.itemInspection.traversalId,world)]
created == [beforeRegistry EXCEPT !.persistent=ReplacementOverlay99(@,records),!.effects=ReplacementOverlay99(@,effects),
!.usedEffects=@ \cup DOMAIN effects,!.creations=@ \cup {effects[id].creation : id \in DOMAIN effects},!.persistentRetireIds=@ \cup {trash.id}]
base == [world EXCEPT !.id=next.id,!.objects=next.objects,!.present=@ \ sourceIds,
!.activity.instances=PersistentInstanceRows912(world.activity.instances,afterLedger)]
execution == [tag |-> "ActualObjectTransition",id |-> trash.id,snapshotId |-> next.id,source |-> RuleAbilitySource9("ProcedureCode17f2a65162fb"),trash |-> trash]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ cohort#{} /\ DOMAIN effectIds=cohort /\ cohort \cap DOMAIN beforeRegistry.persistent={}
/\ {inventory.definitions[key].syntax.id : key \in cohort} \cap PersistentKnownIds912(beforeRegistry)={}
/\ Cardinality({inventory.definitions[key].syntax.id : key \in cohort})=Cardinality(cohort)
/\ {effectIds[key] : key \in cohort} \subseteq (Nat \ {0}) \ beforeRegistry.usedEffects
/\ Cardinality({effectIds[key] : key \in cohort})=Cardinality(cohort)
/\ next=PersistentWorld912(base,created)
/\ CommitLifetimeKernelCore910(beforeAuthority,afterAuthority,next,execution)
/\ ObserveLingering910(created,local,next)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ PersistentRegistryWorldBound912(afterRegistry,afterAuthority.current)
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,world)
/\ LingeringConditionalWorld910(afterSnapshot,beforeLedger,next)
/\ \A key \in cohort : inventory.definitions[key].syntax.kind="Conditional" =>
key \in DOMAIN beforeSnapshot.definitions /\ beforeSnapshot.definitions[key]=inventory.definitions[key] /\ ~afterSnapshot.ordinaryActivity[key]
/\ ObserveConditionalActivity96(beforeLedger,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: base, cohort, created, execution, local, next, world, CommitLifetimeKernelCore910, LifetimeFrontier910, LifetimeReady910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, PersistentConditionalDefinitions912, PersistentKnownIds912, PersistentRegistryWorldBound912, PersistentRetireBound912, PersistentWorld912
CurrentBoostAlive99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentBoostAlive99(effect,current) ==
IF effect.mode="Continuous" THEN TRUE
ELSE BarrierResponseCardBoostUnexpired(effect.boost,current.liveEncounters,LAMBDA ref : ref \in current.liveDurations)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA, BarrierResponseCardBoostUnexpired
CurrentEffectReceipt99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentEffectReceipt99(context,world,history,ledger,w) ==
[tag |-> "CurrentImminentEffect",windowId |-> w.id,instruction |-> w.instruction,revision |-> context.currentRef.revision+1,
relevantConditional |-> CurrentPendingRelevant99(context,world,history,ledger),
paidInterruptAbilities |-> {key.ability : key \in CurrentPaidRelevant99(context,world,history,w)}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPaidRelevant99, CurrentPendingRelevant99
CurrentInterruptDefinitions99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentInterruptDefinitions99(world) ==
ReplacementOverlay99(world.conditional.definitions,world.paidDefinitions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
CurrentInterruptWindow99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentInterruptWindow99(context,stack) ==
/\ context.phase="WindowOpen" /\ Len(stack)>0
/\ LET w == WindowTop9(stack)
IN /\ w.id=context.windowId /\ w.kind="Interrupt" /\ w.instruction=context.openingRef
/\ w.members=context.openingMembers /\ w.group=context.groupExact module download · Source bundle and reproduction instructions
Resolved project definitions: w
CurrentInterruptWorld99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentInterruptWorld99(world,ledger,cardFacts) ==
/\ ExpectedWorldValid99(world) /\ ConditionalSnapshotBound96(world.conditional,ledger)
/\ world.conditional.id=world.id /\ world.objects=world.conditional.objects
/\ DOMAIN world.conditional.definitions \cap DOMAIN world.paidDefinitions={}
/\ DOMAIN world.lexemes=DOMAIN CurrentInterruptDefinitions99(world)
/\ DOMAIN world.capabilities=DOMAIN CurrentInterruptDefinitions99(world)
/\ DOMAIN world.paidContexts=DOMAIN world.paidDefinitions
/\ \A key \in DOMAIN CurrentInterruptDefinitions99(world) :
LET d == CurrentInterruptDefinitions99(world)[key]
IN /\ key=AbilityKey99(d) /\ (d.syntax.kind="Conditional" => ConditionalDefinitionValid96(d))
/\ AbilityLexemesValid99(d,world.lexemes[key],world.objects,cardFacts)
/\ InterruptCapabilitiesValid99(d,world.lexemes[key],world.capabilities[key])
/\ IF d.syntax.kind="Conditional" /\ AbilityInterrupt99(d,world.lexemes[key]) /\ d.primaryKind="Trigger" THEN
/\ "primaryGroups" \in DOMAIN world.capabilities[key]
/\ \A group \in DOMAIN world.capabilities[key].primaryGroups :
/\ world.capabilities[key].primaryGroups[group] # {}
/\ world.capabilities[key].primaryGroups[group] \subseteq DOMAIN world.capabilities[key].clauses
/\ \A id \in world.capabilities[key].primaryGroups[group] : world.capabilities[key].clauses[id].mode="WouldTrigger"
ELSE TRUE
/\ \A key \in DOMAIN world.paidContexts :
LET c == world.paidContexts[key]
IN /\ c.objects=world.objects /\ c.turn=world.turn /\ c.traversalControl=world.traversalControl
/\ c.traversal=world.traversalControl.traversal /\ c.present=world.conditional.present /\ c.activity=world.conditional.activity
/\ c.points=world.conditional.points /\ c.uses=world.turnUsesExact module download · Source bundle and reproduction instructions
Resolved project definitions: c, d, AbilityInterrupt99, AbilityKey99, AbilityLexemesValid99, ConditionalDefinitionValid96, ConditionalSnapshotBound96, CurrentInterruptDefinitions99, ExpectedWorldValid99, InterruptCapabilitiesValid99
CurrentLookOwner911 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentLookOwner911(grants,id,owners,authority) ==
IF id \notin DOMAIN grants THEN TRUE
ELSE LET instance == grants[id].instance
IN IF instance \notin DOMAIN owners THEN instance \notin DOMAIN authority.current.activity.instances
ELSE /\ instance \in DOMAIN authority.current.activity.instances
/\ "owner" \in DOMAIN authority.current.activity.instances[instance]
/\ owners[instance]=authority.current.activity.instances[instance].owner
/\ authority.current.activity.instances[instance].ability=owners[instance].definition.syntax.id
/\ authority.current.activity.instances[instance].sourceObject=owners[instance].ability.source.objectExact module download · Source bundle and reproduction instructions
Resolved project definitions: instance
CurrentPaidRelevanceReceipt99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentPaidRelevanceReceipt99(context,world,history,w) ==
[tag |-> "PaidInterruptRelevance",windowId |-> w.id,instruction |-> w.instruction,revision |-> context.currentRef.revision+1,
eligible |-> CurrentPaidRelevant99(context,world,history,w)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPaidRelevant99
CurrentPaidRelevant99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentPaidRelevant99(context,world,history,w) ==
{key \in DOMAIN world.paidDefinitions :
PaidBaseEligibility99(world.paidDefinitions[key],world.lexemes[key],world.paidContexts[key],w) /\
InterruptRelevant99(world.paidDefinitions[key],world.lexemes[key],world.capabilities[key],context,world,history)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InterruptRelevant99, PaidBaseEligibility99
CurrentPendingRelevant99 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentPendingRelevant99(context,world,history,ledger) ==
{id \in context.conditionalIds \cap DOMAIN ledger.instances :
LET instance == ledger.instances[id]
key == instance.definition
IN IF key \notin DOMAIN world.conditional.definitions THEN FALSE
ELSE /\ instance.status="Pending"
/\ ConditionalInstanceCurrent96(instance,world.conditional.definitions,world.conditional)
/\ InterruptRelevant99(world.conditional.definitions[key],world.lexemes[key],world.capabilities[key],context,world,history)
/\ ConditionalInterruptPrimary99(world.conditional.definitions[key],world.capabilities[key],context,world,history)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: instance, key, ConditionalInstanceCurrent96, ConditionalInterruptPrimary99, InterruptRelevant99
CurrentPlayDefinition97 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentPlayDefinition97(c) == c.sourceText.definitions[c.order[c.cursor]]Exact module download · Source bundle and reproduction instructions
CurrentUnsuppressedBarrierInstructions98 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentUnsuppressedBarrierInstructions98(e) == SubIds6(e.order) \ e.barrierInstructionSuppressedExact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
CurrentXDefinitionActive912 · operator
reference-profile · input revision 2 · CC0 1.0
CurrentXDefinitionActive912(d,world,cardFacts) ==
LET source == d.syntax.source
default == IF source.kind="Object" /\ source.object \in DOMAIN world.objects
THEN world.cardActivity[source.object] ELSE FALSE
IN FlagActivity93(d.syntax,world.present,
AbilityActive9(d.activity,world.objects,world.present,default,world.activity),
world.activity.persistentAbilities,world.points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: default, AbilityActive9, FlagActivity93
CutoffPersistentAtTraversalEnd912 · operator
reference-profile · input revision 2 · CC0 1.0
CutoffPersistentAtTraversalEnd912(before,after,ledger,cp,beforeEnd,afterEnd,events,expired,boundary) ==
/\ CompleteTraversal6(beforeEnd,afterEnd,TRUE,events,expired)
/\ PersistentRegistryWorldBound912(before,before.frontier.world)
/\ before.frontier.world.control.traversal=afterEnd.traversal /\ cp.processingSnapshot.id=before.frontier.world.id
/\ cp.id=ledger.lastCheckpoint /\ cp.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[cp.id].caller=cp.caller /\ ledger.lastSnapshot=cp.processingSnapshot
/\ cp.caller=PersistentTraversalEndCaller912(afterEnd.traversal.id)
/\ \E id \in DOMAIN cp.occurrences :
/\ cp.occurrences[id].kind="TraversalEnds" /\ cp.occurrences[id].traversal=afterEnd.traversal
/\ cp.occurrences[id].actualEvent \in events /\ cp.occurrences[id].actualEvent=[tag |-> "TraversalEnds",traversalId |-> afterEnd.traversal.id]
/\ PersistentRecognizedIds912(ledger,cp.id)=PersistentGeneratedIds912(ledger,cp.id)
/\ boundary=[tag |-> "PersistentLastCreationCheckpoint",traversal |-> afterEnd.traversal,checkpointId |-> cp.id,caller |-> cp.caller,
windowId |-> PersistentGeneratedWindow912(ledger,cp.id),completion |-> PersistentCheckpointCompletion912(ledger,cp,before.frontier.world)]
/\ LET keys == {key \in DOMAIN before.persistent : before.persistent[key].phase="Persisting" /\ before.persistent[key].traversalId=afterEnd.traversal.id}
IN /\ keys#{} /\ \A key \in keys : before.persistent[key].creationOpen
/\ after=[before EXCEPT !.persistent=[key \in DOMAIN @ |-> IF key \in keys THEN
[@[key] EXCEPT !.creationOpen=FALSE,!.endCheckpoint=cp.id,!.endWindow=boundary.windowId,!.endMembers=PersistentGeneratedIds912(ledger,cp.id)] ELSE @[key]]]
/\ PersistentRegistryWorldBound912(after,after.frontier.world) /\ PersistentCheckpointBound912(after,ledger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: keys, PersistentCheckpointBound912, PersistentCheckpointCompletion912, PersistentGeneratedIds912, PersistentGeneratedWindow912, PersistentRecognizedIds912, PersistentRegistryWorldBound912, PersistentTraversalEndCaller912, CompleteTraversal6
DeactivationConditionalCard96 · operator
reference-profile · input revision 2 · CC0 1.0
DeactivationConditionalCard96(before,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot,object,actualEffectAuthorizes,events) ==
/\ Deactivation8(beforeSnapshot.objects,afterSnapshot.objects,object,actualEffectAuthorizes,events)
/\ ObserveConditionalActivity96(before,before,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveConditionalActivity96, Deactivation8
DecideMust912 · operator
reference-profile · input revision 2 · CC0 1.0
DecideMust912(before,after,world,feasibility,decision,cardFacts) ==
/\ before.id \in Nat \ {0} /\ before.phase="Choosing"
/\ MustSourceBound912(before.declaration,before.site,world,cardFacts)
/\ MustFeasibilityBound912(before.declaration,before.site,world,feasibility)
/\ decision.tag="MustDecision" /\ decision.id \in Nat \ {0}
/\ decision.requirement=before.id /\ decision.site=before.site /\ decision.snapshot=world /\ decision.actor=before.declaration.actor
/\ decision.kind \in {"Choose","NoEffect","DeclineAdditional"}
/\ LET feasible == MustFullyResolvable912(before.declaration,world,feasibility)
IN /\ CASE decision.kind="Choose" -> decision.option \in feasible
[] decision.kind="NoEffect" -> feasible={} /\ decision.option="NoValue"
[] OTHER -> MustAdditionalDeclineBound912(before.declaration,before.site,world,feasibility,decision)
/\ after=[before EXCEPT !.phase="Committed",!.chosen=IF decision.kind="Choose" THEN decision.option ELSE "NoValue",
!.disposition=decision.kind,!.choiceSnapshot=world.id,!.feasibleAtChoice=feasible,!.decision=decision]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: feasible, MustAdditionalDeclineBound912, MustFeasibilityBound912, MustSourceBound912
DeclarationApplies93 · operator
reference-profile · input revision 2 · CC0 1.0
DeclarationApplies93(active,conditionHolds) == active /\ conditionHoldsExact module download · Source bundle and reproduction instructions
DelayedCarryStack910 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedCarryStack910(stack,beforeLedger,coreLedger) ==
[i \in 1..Len(stack) |->
LET lost == {id \in stack[i].pending \cap DOMAIN beforeLedger.instances : coreLedger.instances[id].status # "Pending"}
IN [stack[i] EXCEPT !.pending=@ \ lost,!.lostPending=@ \cup lost]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost
DelayedConditionalAbilityIds96 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedConditionalAbilityIds96(effects) == {effects[id].definition.syntax.id : id \in DOMAIN effects}Exact module download · Source bundle and reproduction instructions
DelayedConditionalDefinitions96 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedConditionalDefinitions96(effects) ==
[key \in {ConditionalKey96(effects[id].definition) : id \in DOMAIN effects} |->
effects[CHOOSE id \in DOMAIN effects : ConditionalKey96(effects[id].definition)=key].definition]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96
DelayedConditionalEventScope96 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedConditionalEventScope96(d,ledger,event) ==
IF d.delayedEffect=0 THEN TRUE
ELSE IF d.delayedEffect \notin DOMAIN ledger.effects THEN FALSE
ELSE LET effect == ledger.effects[d.delayedEffect]
IN IF effect.association="IfSuccessfulInspection" /\ event.kind="Inspection" THEN
/\ event.kind="Inspection" /\ event.step="ProcedureCoded75d879e00ff" /\ event.traversal.id=effect.traversalId
/\ TraversalInspectionModifierApplies6([traversalId |-> effect.traversalId],event.traversal,event.siteInspection)
ELSE effect.triggerStructure=NoTimingRef9 \/ event.structure=effect.triggerStructureExact module download · Source bundle and reproduction instructions
Resolved project definitions: effect, NoTimingRef9, TraversalInspectionModifierApplies6
DelayedCreationOmitted910 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedCreationOmitted910(template,traversal) ==
template.thisTraversal /\ "TraversalEnds" \in ConditionalEventKinds96(template) /\ ~TraversalTimingPresent6(traversal)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalEventKinds96, TraversalTimingPresent6
DelayedDefinition96 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedDefinition96(template,definitionId,effectId) ==
[template EXCEPT !.syntax.id=definitionId,!.activity.id=definitionId,!.activity.provider="Lingering",!.delayedEffect=effectId]Exact module download · Source bundle and reproduction instructions
DelayedDurationValid96 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedDurationValid96(duration) ==
duration=NoTimingRef9 \/ TimingRefValid9(duration) \/ (duration.kind="Stated" /\ duration.id \in Nat \ {0})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NoTimingRef9, TimingRefValid9
DelayedLifetimeBlueprint910 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedLifetimeBlueprint910(effect,origin,world) ==
[kind |-> "Delayed",source |-> effect.source,originKind |-> IF origin.plan.origin="Ability" THEN origin.parent.kind ELSE "Rule",
target |-> 0,value |-> 0,baseDuration |-> DelayedLifetimeDuration910(effect,world),durationMode |-> "Specified",
durationClass |-> "Delayed",choiceKey |-> "NoValue",lingeringConsumers |-> {},otherConsumers |-> {},
definitionId |-> effect.definition.syntax.id,whenYourTurnBegins |-> FALSE,onlyChoice |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DelayedLifetimeDuration910
DelayedLifetimeBound910 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedLifetimeBound910(registry,ledger) ==
/\ {id \in DOMAIN registry.effects : registry.effects[id].kind="Delayed"}=DOMAIN ledger.effects
/\ \A id \in DOMAIN ledger.effects : registry.effects[id].source=ledger.effects[id].source /\
registry.effects[id].definitionId=ledger.effects[id].definition.syntax.idExact module download · Source bundle and reproduction instructions
DelayedLifetimeDuration910 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedLifetimeDuration910(effect,world) ==
IF effect.policy="UntilResolution" THEN [kind |-> "DelayedResolution",effectId |-> effect.id]
ELSE IF effect.duration.kind="Stated" THEN [kind |-> "Stated",specification |-> effect.duration]
ELSE [kind |-> "Timing",ref |-> BindTimingDuration910(effect.duration,world).ref,requested |-> effect.duration]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BindTimingDuration910
DelayedRuntimePublicationAck911 · operator
reference-profile · input revision 2 · CC0 1.0
DelayedRuntimePublicationAck911(original,world) ==
ReplacementOverlay99([original EXCEPT !.snapshotId=world.id],
[publication |-> "DelayedRuntimeLifetimePublication",originatingReturn |-> original])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
DepartureAuthority96 · operator
reference-profile · input revision 2 · CC0 1.0
DepartureAuthority96(d,cp,conditions,allocation,departure,hold) ==
LET matched == DepartureMatchedEvents96(d,cp,conditions,departure)
ids == {allocation[[definition |-> ConditionalKey96(d),occurrence |-> event]] : event \in matched}
old == departure.oldObject
new == departure.newObject
IN /\ departure.tag="ConditionalDepartureRecognition" /\ departure.checkpointId=cp.id
/\ d=ReboundConditionalDefinition96(departure.originalDefinition,new)
/\ departure.originalDefinition.syntax.source=ObjectAbilitySource9(old)
/\ ConditionalDefinitionValid96(departure.originalDefinition)
/\ departure.originalDefinition.activity.provider \in {"Printed","Granted"}
/\ ConditionalKey96(departure.originalDefinition) \in DOMAIN departure.beforeSnapshot.definitions
/\ departure.beforeSnapshot.definitions[ConditionalKey96(departure.originalDefinition)]=departure.originalDefinition
/\ matched # {}
/\ \E event \in matched : cp.occurrences[event].object=old /\
cp.occurrences[event].movement.tag="SourceZoneChange" /\ cp.occurrences[event].movement.oldObject=old /\
cp.occurrences[event].movement.newObject=new /\ cp.occurrences[event].movement.beforeSnapshot=departure.beforeSnapshot
/\ departure.holdReceipt.matchingOccurrences=matched /\ departure.holdReceipt.effectId=departure.effectId
/\ old \in DOMAIN departure.beforeSnapshot.objects /\ new \in DOMAIN cp.processingSnapshot.objects
/\ old \notin DOMAIN cp.processingSnapshot.objects
/\ DOMAIN departure.beforeSnapshot.objects \subseteq departure.beforeSnapshot.usedObjects
/\ FreshSuccessors8({old},[id \in {old} |-> new],departure.beforeSnapshot.usedObjects)
/\ OpenDepartureHold9(departure.beforeSnapshot.objects,cp.processingSnapshot.objects,old,new,d.syntax.id,ids,
departure.holdReceipt,departure.beforeSnapshot.cardActivity[old],cp.processingSnapshot.cardActivity[new],hold)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ids, matched, new, old, ConditionalDefinitionValid96, ConditionalKey96, ObjectAbilitySource9, OpenDepartureHold9, ReboundConditionalDefinition96, FreshSuccessors8
DepartureCandidates96 · operator
reference-profile · input revision 2 · CC0 1.0
DepartureCandidates96(definitions,cp,conditions,departures) ==
UNION {IF key \in DOMAIN definitions /\ DepartureCurrentGate96(definitions[key],cp)
THEN {[definition |-> key,occurrence |-> id] : id \in DepartureMatchedEvents96(definitions[key],cp,conditions[key],departures[key])}
ELSE {} : key \in DOMAIN departures}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DepartureCurrentGate96, DepartureMatchedEvents96
DepartureCandidates99 · operator
reference-profile · input revision 2 · CC0 1.0
DepartureCandidates99(definitions,lexemes,cp,conditions,departures) ==
{candidate \in DepartureCandidates96(definitions,cp,conditions,departures) : ~AbilityInterrupt99(definitions[candidate.definition],lexemes[candidate.definition])}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, DepartureCandidates96
DepartureCurrentGate96 · operator
reference-profile · input revision 2 · CC0 1.0
DepartureCurrentGate96(d,cp) ==
/\ ConditionalDefinitionValid96(d) /\ ~ConditionalInterrupt96(d) /\ d.primaryKind="Trigger" /\ d.syntax.source.kind="Object"
/\ d.syntax.source.object \in DOMAIN cp.processingSnapshot.objects
/\ ~SideBFacedown8(cp.processingSnapshot.objects[d.syntax.source.object])
/\ FlagActivity93(d.syntax,cp.processingSnapshot.present,TRUE,cp.processingSnapshot.activity.persistentAbilities,cp.processingSnapshot.points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalDefinitionValid96, ConditionalInterrupt96, FlagActivity93, SideBFacedown8
DepartureHoldLive9 · operator
reference-profile · input revision 2 · CC0 1.0
DepartureHoldLive9(hold,ability,objects,instances) ==
/\ hold.ability = ability.id /\ ability.kind = "Conditional" /\ ability.source.kind = "Object"
/\ hold.object = ability.source.object /\ hold.object \in DOMAIN objects
/\ \E id \in hold.instances \cap DOMAIN instances :
instances[id].ability = ability.id /\ instances[id].sourceObject = hold.object /\
instances[id].status \in {"Pending","Triggered","Imminent","Resolving"}Exact module download · Source bundle and reproduction instructions
DepartureMatchedEvents96 · operator
reference-profile · input revision 2 · CC0 1.0
DepartureMatchedEvents96(d,cp,conditions,departure) ==
{id \in DOMAIN cp.occurrences : cp.occurrences[id].effectId=departure.effectId /\
TriggerPattern96(departure.originalDefinition,cp.occurrences[id]) /\
TriggerStipulations96(departure.originalDefinition,cp.occurrences[id],conditions[id])}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TriggerPattern96, TriggerStipulations96
DescriptionWouldGroups99 · operator
reference-profile · input revision 2 · CC0 1.0
DescriptionWouldGroups99(entryId,description) ==
IF "occurrenceGroups" \in DOMAIN description THEN [effect \in DOMAIN description.effects |-> <<entryId,description.occurrenceGroups[effect]>>]
ELSE InitialWouldGroups99(entryId,description.effects)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InitialWouldGroups99
DetachPaidAbility9 · operator
reference-profile · input revision 2 · CC0 1.0
DetachPaidAbility9(before,after,actualTriggerCostReceipt) ==
/\ before.kind = "Paid" /\ before.phase = "Ready" /\ ~before.detached
/\ actualTriggerCostReceipt.abilityInstance = before.id /\ actualTriggerCostReceipt.allPaid
/\ after = [before EXCEPT !.detached = TRUE]Exact module download · Source bundle and reproduction instructions
DetachedSourceTarget9 · operator
reference-profile · input revision 2 · CC0 1.0
DetachedSourceTarget9(frame,objects,target) ==
/\ frame.detached /\ frame.source.kind = "Object"
/\ target = frame.source.object /\ target \in DOMAIN objects
/\ objects[target].zone = frame.sourceZoneExact module download · Source bundle and reproduction instructions
EffectiveAbilityChange9 · operator
reference-profile · input revision 2 · CC0 1.0
EffectiveAbilityChange9(beforePresent,afterPresent,definitions,immutablePrintedPlayOrder,beforePlayOrder,afterPlayOrder) ==
/\ beforePlayOrder = immutablePrintedPlayOrder /\ afterPlayOrder = immutablePrintedPlayOrder
/\ SubIds6(immutablePrintedPlayOrder) =
{id \in beforePresent \cap DOMAIN definitions : definitions[id].kind="Play"}
/\ SubIds6(immutablePrintedPlayOrder) =
{id \in afterPresent \cap DOMAIN definitions : definitions[id].kind="Play"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
EffectiveAbilityOrder9 · operator
reference-profile · input revision 2 · CC0 1.0
EffectiveAbilityOrder9(presentIds,definitions,printedPlayOrder,actualBarrierInstructionOrder) ==
/\ SubIds6(printedPlayOrder) = {id \in presentIds \cap DOMAIN definitions : definitions[id].kind="Play"}
/\ Len(printedPlayOrder) = Cardinality(SubIds6(printedPlayOrder))
/\ SubIds6(actualBarrierInstructionOrder) = EffectiveBarrierInstructions9(presentIds,definitions)
/\ Len(actualBarrierInstructionOrder) = Cardinality(SubIds6(actualBarrierInstructionOrder))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EffectiveBarrierInstructions9, SubIds6
EffectiveBarrierInstructions9 · operator
reference-profile · input revision 2 · CC0 1.0
EffectiveBarrierInstructions9(presentIds,definitions) ==
{id \in presentIds \cap DOMAIN definitions : definitions[id].kind = "BarrierInstruction"}Exact module download · Source bundle and reproduction instructions
EffectiveSpecimen0100Boost99 · operator
reference-profile · input revision 2 · CC0 1.0
EffectiveSpecimen0100Boost99(original,replacement,current,comparison) ==
IF ~ContinuousOriginalActive99(original,current) THEN original.base
ELSE Specimen0100CurrentPaidDuration94(replacement.definition,replacement.syntax,current.objects,current.present,
current.ordinaryActivity[ContinuousStaticKey99(replacement.definition,replacement.syntax)],current.activity,current.points,
original.base,current.turnId,comparison.shorterThanTurn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ContinuousOriginalActive99, ContinuousStaticKey99, Specimen0100CurrentPaidDuration94
EffectsAfterConditionalResolution96 · operator
reference-profile · input revision 2 · CC0 1.0
EffectsAfterConditionalResolution96(effects,d) ==
IF d.delayedEffect=0 THEN effects
ELSE IF d.delayedEffect \in DOMAIN effects /\ effects[d.delayedEffect].definition=d /\ effects[d.delayedEffect].policy="UntilResolution"
THEN [id \in DOMAIN effects \ {d.delayedEffect} |-> effects[id]] ELSE effectsExact module download · Source bundle and reproduction instructions
EligibleReplacements99 · operator
reference-profile · input revision 2 · CC0 1.0
EligibleReplacements99(state,effectId,replacements) ==
IF effectId \notin DOMAIN state.effects THEN {}
ELSE {id \in DOMAIN replacements :
id \notin state.ancestry[effectId] /\
ReplacementPatternMatches99(replacements[id].pattern,state.effects[effectId])}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementPatternMatches99
EmptyOrder98 · operator
reference-profile · input revision 2 · CC0 1.0
EmptyOrder98 == [id \in {} |-> id]Exact module download · Source bundle and reproduction instructions
EmptyPlay97 · operator
reference-profile · input revision 2 · CC0 1.0
EmptyPlay97 == [id \in {} |-> id]Exact module download · Source bundle and reproduction instructions
EmptyWould99 · operator
reference-profile · input revision 2 · CC0 1.0
EmptyWould99 == [id \in {} |-> id]Exact module download · Source bundle and reproduction instructions
EncounterAllSetPoint912 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterAllSetPoint912(e) ==
[structure |-> TimingRef9("TraversalPhase",e.id),ordinal |-> IF e.paidReached /\ ~e.aborted /\ ~e.bypassed THEN 1 ELSE 0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
EncounterAllSubsSatisfied912 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterAllSubsSatisfied912(e) ==
AllSetSatisfied912(SubIds6(e.order),e.barrierInstructionSuppressed,EncounterAllSetPoint912(e),
[structure |-> TimingRef9("TraversalPhase",e.id),ordinal |-> IF Len(e.order)=0 THEN 1 ELSE 0])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AllSetSatisfied912, EncounterAllSetPoint912, TimingRef9, SubIds6
EncounterLive95 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterLive95(e) == e.id \in Nat \ {0} /\ ~e.aborted /\ e.stage \in {"BeginReactions","Paid","BarrierInstructions"}Exact module download · Source bundle and reproduction instructions
EncounterPaidSite95 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterPaidSite95(turn,e,actualControl) ==
PrioritySite9("SchemaAtom138","ProcedureCode8b3260c0010f","Encounter",TimingRef9("TraversalPhase",e.id),turn.owner,turn.id,e.traversalId,0,0,0,FALSE,
TurnFrameValid5(turn) /\ e.stage="Paid" /\ EncounterTimingLive95(e,actualControl),
e.stage="Paid" /\ EncounterTimingLive95(e,actualControl))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterTimingLive95, PrioritySite9, TimingRef9, TurnFrameValid5
EncounterSubStatus98 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterSubStatus98(e,sub) ==
IF sub \notin e.usedSubIds THEN "Absent" ELSE IF sub \in e.barrierInstructionSuppressed THEN "BarrierInstructionSuppressed" ELSE "UnsuppressedBarrierInstructions"Exact module download · Source bundle and reproduction instructions
EncounterSuppressInstructionRef98 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterSuppressInstructionRef98(e) == [kind |-> "Encounter",id |-> e.id,barrierCard |-> e.barrierCard,traversalId |-> e.traversalId]Exact module download · Source bundle and reproduction instructions
EncounterTimingLive95 · operator
reference-profile · input revision 2 · CC0 1.0
EncounterTimingLive95(e,actualControl) ==
/\ EncounterLive95(e) /\ TraversalFrameValid6(actualControl.traversal)
/\ e.id \notin actualControl.phaseEndedIds
/\ e.traversalId=0 \/ (e.traversalId=actualControl.traversal.id /\ TraversalTimingPresent6(actualControl.traversal))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterLive95, TraversalFrameValid6, TraversalTimingPresent6
EnterBarrierInstructionLoop98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterBarrierInstructionLoop98(before,after,e,control,step,orderState,sources,objects,present,context,points,owner,stack,declaration,cardFacts) ==
/\ e.id \notin DOMAIN before /\ BarrierInstructionStep98(e,control,step)
/\ BarrierInstructionOwnerAtTop98(owner,stack) /\ e.resolved={}
/\ BarrierInstructionOrderValid98(orderState) /\ orderState.barrierCard=e.barrierCard /\ orderState.order=e.order
/\ ExampleFamily062SourcesValid98(sources,objects,cardFacts)
/\ declaration.tag="EncounterBarrierInstructionResolutionOrder" /\ declaration.encounter=e.id /\ declaration.barrierCard=e.barrierCard
/\ declaration.step=step /\ declaration.physicalOrder=e.order /\ declaration.barrierInstructionSuppressed=e.barrierInstructionSuppressed
/\ DeckSequenceValid4(declaration.order) /\ SubIds6(declaration.order)=SubIds6(e.order) \ e.barrierInstructionSuppressed
/\ LET active == ActiveExampleFamily062Sources98(sources,objects,present,context,points)
IN /\ IF active={} THEN declaration.exampleFamily062=0 /\ declaration.order=SelectSeq(e.order,LAMBDA id : id \notin e.barrierInstructionSuppressed)
ELSE declaration.exampleFamily062 \in active /\ declaration.controller="SideB" /\ declaration.source=sources[declaration.exampleFamily062].syntax.source
/\ after=[id \in DOMAIN before \cup {e.id} |-> IF id=e.id THEN NewBarrierInstructionLoop98(e,owner,declaration.order,declaration.exampleFamily062) ELSE before[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA, active, BarrierInstructionOrderValid98, BarrierInstructionOwnerAtTop98, BarrierInstructionStep98, ExampleFamily062SourcesValid98, NewBarrierInstructionLoop98, DeckSequenceValid4, SubIds6
EnterChosenMust912 · operator
reference-profile · input revision 2 · CC0 1.0
EnterChosenMust912(before,after,ledger,stack,checkpoint,entry) ==
/\ before.phase="Committed" /\ before.disposition="Choose" /\ before.declaration.form="Choice"
/\ checkpoint.tag="MustChoiceCheckpoint" /\ checkpoint.id \in DOMAIN ledger.checkpoints
/\ checkpoint.requirement=before.id /\ checkpoint.decision=before.decision.id
/\ checkpoint.complete /\ checkpoint.allNewerChainsComplete
/\ ledger.checkpoints[checkpoint.id].caller=MustChoiceCaller912(before)
/\ ConditionalCheckpointDrained96(ledger,stack,checkpoint.id)
/\ entry.tag="ActualChosenMustEffectEntry" /\ entry.requirement=before.id /\ entry.decision=before.decision
/\ entry.option=before.declaration.options[before.chosen] /\ entry.actor=before.declaration.actor
/\ entry.source=before.declaration.source /\ entry.checkpointId=checkpoint.id
/\ entry.instruction.source=before.declaration.source /\ entry.instruction.abilityInstance=before.site.ability.id
/\ entry.instruction#InstructionWindowRef93(before.site.plan)
/\ after=[before EXCEPT !.phase="Resolving",!.result=[entry |-> entry]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, InstructionWindowRef93, MustChoiceCaller912
EnterFirstAbilityInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
EnterFirstAbilityInstruction93(beforeAbility,afterAbility,before,after,actualEntry) ==
/\ beforeAbility.cursor=1
/\ InstructionPlanReady93(before) /\ InstructionPlanMatches93(before,beforeAbility,1)
/\ InstructionEntryReceipt93(before,actualEntry)
/\ BeginAbilityInstructions9(beforeAbility,afterAbility,actualEntry.schedulerAllows,actualEntry.sourceEligible)
/\ after=[before EXCEPT !.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginAbilityInstructions9, InstructionEntryReceipt93, InstructionPlanMatches93, InstructionPlanReady93
EnterFirstBarrierInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterFirstBarrierInstructionInstruction98(before,after,e,control,orderState,objects,present,context,points,stack,plan,afterPlan,targets,entry) ==
/\ before.origin="Encounter" /\ before.caller=e.id /\ e.id=before.encounter /\ e.barrierCard=before.barrierCard
/\ BarrierInstructionEncounterCurrent98(e,control)
/\ orderState.barrierCard=e.barrierCard /\ orderState.order=e.order /\ before.barrierInstruction \in orderState.present
/\ orderState.definitions[before.barrierInstruction]=before.definition
/\ EnterFirstBarrierInstructionInstructionCore98(before,after,objects,present,context,points,stack,plan,afterPlan,targets,entry)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionEncounterCurrent98, EnterFirstBarrierInstructionInstructionCore98
EnterFirstBarrierInstructionInstructionCore98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterFirstBarrierInstructionInstructionCore98(before,after,objects,present,context,points,stack,plan,afterPlan,targets,entry) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="FirstTargets" /\ ~before.prevented
/\ BarrierInstructionCurrentActive98(before.definition,objects,present,context,points)
/\ BarrierInstructionOwnerAtTop98(before.owner,stack) /\ ~plan.announced
/\ entry.sourceEligible=BarrierInstructionCurrentActive98(before.definition,objects,present,context,points)
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [before.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,!.detached=TRUE]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,before.ability,"NoValue")
/\ EnterFirstAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.ability=imminent,!.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AnnounceInstructionTargets93, BarrierInstructionBarrierInstructionBound98, BarrierInstructionCurrentActive98, BarrierInstructionOwnerAtTop98, EnterFirstAbilityInstruction93
EnterFirstInstructionBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterFirstInstructionBarrierInstruction98(before,after,parentPlan,parent,ruleStep,orderState,objects,present,activity,points,stack,plan,afterPlan,targets,entry) ==
/\ NestedBarrierInstructionInvocation98(before,parentPlan,parent,ruleStep,before.invocation)
/\ orderState.barrierCard=before.barrierCard /\ before.barrierInstruction \in orderState.present /\ orderState.definitions[before.barrierInstruction]=before.definition
/\ EnterFirstBarrierInstructionInstructionCore98(before,after,objects,present,activity,points,stack,plan,afterPlan,targets,entry)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EnterFirstBarrierInstructionInstructionCore98, NestedBarrierInstructionInvocation98
EnterFirstSuppressInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterFirstSuppressInstructionInstruction98(beforeAbility,afterAbility,before,after,e,control,classification,intent,targets,entry,selection) ==
/\ beforeAbility.kind \in {"Conditional","BarrierInstruction","Play"}
/\ LET announced == [before EXCEPT !.announced=TRUE,!.targets=targets.targets]
IN /\ AnnounceSuppressInstructionInstructionTargets98(before,announced,beforeAbility,"NoValue",classification,intent,e,control,targets,selection)
/\ EnterFirstAbilityInstruction93(beforeAbility,afterAbility,announced,after,entry)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, AnnounceSuppressInstructionInstructionTargets98, EnterFirstAbilityInstruction93
EnterInstructionBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterInstructionBarrierInstruction98(beforeCalls,afterCalls,p,parentPlan,parent,ruleStep,actualEffect,orderState,id,usedInstances,owner,stack,objects,present,activity,points,cardFacts) ==
/\ ConditionalCreationInstruction96(parentPlan,parent,ruleStep) /\ BarrierInstructionOwnerAtTop98(owner,stack)
/\ actualEffect.id \in (Nat \ {0}) \ DOMAIN beforeCalls
/\ ~\E call \in DOMAIN beforeCalls : beforeCalls[call].instruction=InstructionWindowRef93(parentPlan) /\ beforeCalls[call].status="Active"
/\ actualEffect.step=parentPlan.cursor
/\ afterCalls=[call \in DOMAIN beforeCalls \cup {actualEffect.id} |-> IF call=actualEffect.id THEN
[instruction |-> InstructionWindowRef93(parentPlan),instance |-> id,status |-> "Active",source |-> ObjectAbilitySource9(actualEffect.barrierCard),encounter |-> actualEffect.encounter,barrierInstruction |-> actualEffect.barrierInstruction,disposition |-> "NoValue"] ELSE beforeCalls[call]]
/\ id \in (Nat \ {0}) \ usedInstances /\ BarrierInstructionOrderValid98(orderState)
/\ actualEffect.barrierCard=orderState.barrierCard /\ actualEffect.barrierInstruction \in orderState.present
/\ TimingRefValid9(actualEffect.structure) /\ actualEffect.encounter \in Nat
/\ actualEffect.sourceCard \in DOMAIN cardFacts /\ actualEffect.sourceSHA=cardFacts[actualEffect.sourceCard].sourceSHA
/\ actualEffect.origin.tag="FixedAbilitySourceObservation" /\ actualEffect.origin.source=parentPlan.source
/\ actualEffect.origin.card=actualEffect.sourceCard /\ actualEffect.origin.sourceSHA=actualEffect.sourceSHA
/\ actualEffect.selector \in {"AnotherItemActivatedBarrier","AnotherItemActivatedSubtypeClass024","NormalizedBarrierInstructionSelection"}
/\ actualEffect.barrierCard \in DOMAIN objects /\ objects[actualEffect.barrierCard].kind="Barrier"
/\ actualEffect.selector \in {"AnotherItemActivatedBarrier","AnotherItemActivatedSubtypeClass024"} =>
actualEffect.barrierCard # parentPlan.source.object /\ ActivationStatus8(objects[actualEffect.barrierCard])="ItemActivated"
/\ actualEffect.selector="AnotherItemActivatedSubtypeClass024" => "SchemaAtom024" \in actualEffect.currentSubtypes
/\ LET d == orderState.definitions[actualEffect.barrierInstruction]
base == NewBarrierInstructionBarrierInstruction98(id,actualEffect.barrierInstruction,d,
[id |-> actualEffect.encounter,barrierCard |-> actualEffect.barrierCard],owner,objects[actualEffect.barrierCard].zone)
IN /\ BarrierInstructionCurrentActive98(d,objects,present,activity,points)
/\ p=[base EXCEPT !.origin="Instruction",!.caller=parentPlan.id,!.ability.caller=parentPlan.id,
!.structure=actualEffect.structure,!.invocation=actualEffect]
/\ NestedBarrierInstructionInvocation98(p,parentPlan,parent,ruleStep,actualEffect)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: base, d, BarrierInstructionCurrentActive98, BarrierInstructionOrderValid98, BarrierInstructionOwnerAtTop98, ConditionalCreationInstruction96, InstructionWindowRef93, NestedBarrierInstructionInvocation98, ObjectAbilitySource9, TimingRefValid9, ActivationStatus8
EnterNextAbilityInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextAbilityInstruction93(beforeAbility,afterAbility,before,after,actualEntry) ==
/\ InstructionPlanReady93(before) /\ InstructionPlanMatches93(before,beforeAbility,beforeAbility.cursor+1)
/\ InstructionEntryReceipt93(before,actualEntry)
/\ ContinueAbilityInstructions9(beforeAbility,afterAbility,actualEntry.checkpointAndAllNewerChainsComplete)
/\ after=[before EXCEPT !.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ContinueAbilityInstructions9, InstructionEntryReceipt93, InstructionPlanMatches93, InstructionPlanReady93
EnterNextBarrierInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextBarrierInstructionInstruction98(before,after,stack,plan,afterPlan,targets,entry) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="Targets" /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ before.checkpoint \in Nat \ {0} /\ entry.checkpointId=before.checkpoint /\ ~plan.announced
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,before.ability,"NoValue")
/\ EnterNextAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.ability=imminent,!.checkpoint=0,!.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AnnounceInstructionTargets93, BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, EnterNextAbilityInstruction93
EnterNextConditionalInstruction96 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextConditionalInstruction96(beforeLedger,afterLedger,stack,before,after,plan,afterPlan,actualTargets,entry) ==
/\ ConditionalProcedureBound96(beforeLedger,before)
/\ beforeLedger.instances[before.id].status="Resolving"
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status="Imminent"]
/\ ConditionalAtTop96(stack,before) /\ before.phase="Targets" /\ before.checkpoint \in Nat \ {0}
/\ ~plan.announced /\ entry.checkpointId=before.checkpoint
/\ LET announced == [plan EXCEPT !.targets=actualTargets.targets,!.announced=TRUE]
imminent == [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]
IN /\ AnnounceInstructionTargets93(plan,announced,actualTargets,before.ability,"NoValue")
/\ EnterNextAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.ability=imminent,!.phase="Imminent",!.checkpoint=0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AnnounceInstructionTargets93, ConditionalAtTop96, ConditionalProcedureBound96, EnterNextAbilityInstruction93
EnterNextConditionalOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextConditionalOccurrence912(beforeLedger,afterLedger,stack,before,after,plan,afterPlan,targets,entry,lifetimes,authority) ==
/\ ConditionalOccurrenceBound912(beforeLedger,before) /\ beforeLedger.instances[before.id].status="Resolving"
/\ before.trace# <<>> /\ before.ability.detached
/\ EnterNextOccurrence912(before,after,plan,afterPlan,targets,entry,beforeLedger,stack,lifetimes,authority)
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalOccurrenceBound912, EnterNextOccurrence912
EnterNextConditionalRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextConditionalRuntime911(beforeLedger,afterLedger,stack,before,after,plan,afterPlan,targets,entry,lifetimes,authority) ==
/\ ConditionalRuntimeBound911(beforeLedger,before) /\ beforeLedger.instances[before.id].status="Resolving"
/\ RuntimeOwnerCurrent911(before,authority)
/\ ConditionalAtTop96(stack,before) /\ before.visited# <<>> /\ before.ability.detached
/\ EnterRuntimeInstructionCore911(before,after,plan,afterPlan,targets,entry,beforeLedger,stack,lifetimes,authority)
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalAtTop96, ConditionalRuntimeBound911, EnterRuntimeInstructionCore911, RuntimeOwnerCurrent911
EnterNextOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextOccurrence912(before,after,plan,afterPlan,targets,entry,ledger,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(before,authority)
/\ OccurrenceRuntimeProfile912(before) /\ before.phase="Targets" /\ before.pause.id=0 /\ before.trace# <<>>
/\ BarrierInstructionOwnerAtTop98(OccurrencePriorityOwner912(before),stack)
/\ before.checkpoint \in Nat \ {0} /\ ConditionalCheckpointDrained96(ledger,stack,before.checkpoint)
/\ entry.checkpointId=before.checkpoint /\ OccurrencePlan912(before,plan) /\ ~plan.announced
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [before.ability EXCEPT !.phase="Imminent",!.cursor=@+1]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,before.ability,"NoValue")
/\ EnterNextAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.ability=imminent,!.phase="Imminent",!.checkpoint=0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AnnounceInstructionTargets93, BarrierInstructionOwnerAtTop98, ConditionalCheckpointDrained96, EnterNextAbilityInstruction93, LifetimeReady910, OccurrenceOwnerCurrent912, OccurrencePlan912, OccurrencePriorityOwner912, OccurrenceRuntimeProfile912
EnterNextPlayInstruction97 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextPlayInstruction97(before,after,f,stack,plan,afterPlan,targets,entry) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ PlayAbilityBound97(before)
/\ before.phase="Targets" /\ before.checkpoint \in Nat \ {0} /\ entry.checkpointId=before.checkpoint
/\ ~plan.announced
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
imminent == [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,before.ability,"NoValue")
/\ EnterNextAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.ability=imminent,!.phase="Imminent",!.checkpoint=0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, imminent, AnnounceInstructionTargets93, EnterNextAbilityInstruction93, PlayAbilityBound97, PlayOwnerAtTop97
EnterNextSourceRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextSourceRuntime911(before,after,plan,afterPlan,targets,entry,ledger,stack,lifetimes,authority) ==
/\ SourceRuntimeBound911(before) /\ before.visited# <<>> /\ BarrierInstructionOwnerAtTop98(before.sourceOwner,stack)
/\ RuntimeOwnerCurrent911(before,authority)
/\ EnterRuntimeInstructionCore911(before,after,plan,afterPlan,targets,entry,ledger,stack,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOwnerAtTop98, EnterRuntimeInstructionCore911, RuntimeOwnerCurrent911, SourceRuntimeBound911
EnterNextSuppressInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterNextSuppressInstructionInstruction98(beforeAbility,afterAbility,before,after,e,control,classification,intent,targets,entry,selection) ==
/\ beforeAbility.kind \in {"Conditional","BarrierInstruction","Play"}
/\ LET announced == [before EXCEPT !.announced=TRUE,!.targets=targets.targets]
IN /\ AnnounceSuppressInstructionInstructionTargets98(before,announced,beforeAbility,"NoValue",classification,intent,e,control,targets,selection)
/\ EnterNextAbilityInstruction93(beforeAbility,afterAbility,announced,after,entry)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, AnnounceSuppressInstructionInstructionTargets98, EnterNextAbilityInstruction93
EnterPaidInstruction95 · operator
reference-profile · input revision 2 · CC0 1.0
EnterPaidInstruction95(stack,before,after,plan,afterPlan,actualTargets,actualEntry) ==
/\ PaidProcedureAtTop95(stack,before) /\ before.phase="Targets" /\ before.costPaid /\ before.checkpoint \in Nat \ {0}
/\ ~plan.announced /\ actualEntry.checkpointId=before.checkpoint
/\ LET announced == [plan EXCEPT !.targets=actualTargets.targets,!.announced=TRUE]
a == IF before.ability.phase="Ready"
THEN [before.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE]
ELSE [before.ability EXCEPT !.cursor=@+1,!.phase="Imminent"]
IN /\ AnnounceInstructionTargets93(plan,announced,actualTargets,before.ability,"NoValue")
/\ IF before.ability.phase="Ready" THEN EnterFirstAbilityInstruction93(before.ability,a,announced,afterPlan,actualEntry)
ELSE EnterNextAbilityInstruction93(before.ability,a,announced,afterPlan,actualEntry)
/\ after=[before EXCEPT !.ability=a,!.phase="Imminent",!.checkpoint=0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, announced, AnnounceInstructionTargets93, EnterFirstAbilityInstruction93, EnterNextAbilityInstruction93, PaidProcedureAtTop95
EnterPlayCohort97 · operator
reference-profile · input revision 2 · CC0 1.0
EnterPlayCohort97(beforePlay,afterPlay,c,objects,text,invocation,ledger,stack,checkpointId,cardFacts) ==
/\ checkpointId \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[checkpointId].caller=PlayActivationCaller97(beforePlay)
/\ ConditionalCheckpointDrained96(ledger,stack,checkpointId)
/\ OpenPlayAbilities8(beforePlay,afterPlay,checkpointId,TRUE)
/\ PlaySourceTextValid97(afterPlay,objects,text,cardFacts) /\ PlayInvocationValid97(afterPlay,stack,invocation)
/\ c=NewPlayCohort97(afterPlay,text,invocation)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, NewPlayCohort97, PlayActivationCaller97, PlayInvocationValid97, PlaySourceTextValid97, OpenPlayAbilities8
EnterRuleInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
EnterRuleInstruction93(before,after,actualRuleStep) ==
/\ InstructionPlanReady93(before) /\ RuleInstructionPlan93(before,actualRuleStep)
/\ after=[before EXCEPT !.phase="Imminent"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPlanReady93, RuleInstructionPlan93
EnterRuleSuppressInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterRuleSuppressInstructionInstruction98(before,after,ruleStep,e,control,classification,intent,targets,selection) ==
/\ LET announced == [before EXCEPT !.announced=TRUE,!.targets=targets.targets]
IN /\ AnnounceSuppressInstructionInstructionTargets98(before,announced,[id \in {} |-> id],ruleStep,classification,intent,e,control,targets,selection)
/\ EnterRuleInstruction93(announced,after,ruleStep)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, AnnounceSuppressInstructionInstructionTargets98, EnterRuleInstruction93
EnterRuntimeInstructionCore911 · operator
reference-profile · input revision 2 · CC0 1.0
EnterRuntimeInstructionCore911(before,after,plan,afterPlan,targets,entry,ledger,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeProfile911(before)
/\ before.phase="Targets" /\ before.pause.id=0 /\ RuntimeCurrentPlan911(before,plan) /\ ~plan.announced
/\ LET announced == [plan EXCEPT !.announced=TRUE,!.targets=targets.targets]
first == before.visited= <<>>
imminent == IF first THEN [before.ability EXCEPT !.phase="Imminent",!.firstImminent=TRUE,
!.detached=@ \/ before.ability.kind="Conditional"]
ELSE [before.ability EXCEPT !.phase="Imminent",!.cursor=@+1]
IN /\ AnnounceInstructionTargets93(plan,announced,targets,before.ability,"NoValue")
/\ IF first THEN EnterFirstAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
ELSE /\ before.checkpoint \in Nat \ {0} /\ entry.checkpointId=before.checkpoint
/\ ConditionalCheckpointDrained96(ledger,stack,before.checkpoint)
/\ EnterNextAbilityInstruction93(before.ability,imminent,announced,afterPlan,entry)
/\ after=[before EXCEPT !.ability=imminent,!.phase="Imminent",!.checkpoint=0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, first, imminent, AnnounceInstructionTargets93, ConditionalCheckpointDrained96, EnterFirstAbilityInstruction93, EnterNextAbilityInstruction93, LifetimeReady910, RuntimeCurrentPlan911, RuntimeProfile911
EnterSuppressInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
EnterSuppressInstructionInstruction98(stack,before,after,plan,afterPlan,targets,entry,intent,e,control,selection) ==
/\ SuppressInstructionIntentMatches98(intent,before) /\ plan.id=intent.classification.instruction
/\ SuppressInstructionTargetsValid98(intent,e,control,targets.targets)
/\ EnterPaidInstruction95(stack,before,after,plan,afterPlan,targets,entry)
/\ selection=NewSuppressInstructionSelection98(intent,afterPlan,targets.targets)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EnterPaidInstruction95, NewSuppressInstructionSelection98, SuppressInstructionIntentMatches98, SuppressInstructionTargetsValid98
ExampleFamily025PreventionObserved99 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily025PreventionObserved99(before,after,conditionalSource,actualResolved) ==
/\ ResolvedExpectedInterrupt99(before,after,actualResolved)
/\ conditionalSource.kind="Object" /\ conditionalSource.object \in Nat \ {0}
/\ actualResolved.source=conditionalSource
/\ \E id \in DOMAIN before : before[id].kind="Damage" /\ before[id].value>0 /\
(IF id \notin DOMAIN after THEN TRUE ELSE IF after[id].kind # "Damage" THEN TRUE ELSE after[id].value<before[id].value)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ResolvedExpectedInterrupt99
ExampleFamily033GainSourceMatches912 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily033GainSourceMatches912(definition,event) ==
event.actor=definition.syntax.controller /\ event.effectSource.kind="Object" /\ event.effectSource#definition.syntax.sourceExact module download · Source bundle and reproduction instructions
ExampleFamily040Deploy95 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily040Deploy95(p,plan,beforeObjects,afterObjects,transits,old,new,actualDeploy) ==
/\ InstructionPlanMatches93(plan,p.ability,p.ability.cursor) /\ plan.phase="Resolving" /\ old \in plan.targets
/\ p.definition.syntax.source.kind="Object" /\ p.phase="Resolve"
/\ PaidOwnerCanQuery95(p,beforeObjects,transits,old,p.id)
/\ beforeObjects[old].form="Card" /\ old \notin DOMAIN afterObjects /\ new \in DOMAIN afterObjects
/\ afterObjects[new].card=beforeObjects[old].card
/\ actualDeploy.tag="ExampleFamily040Deploy" /\ actualDeploy.abilityInstance=p.id /\ actualDeploy.old=old /\ actualDeploy.new=new
/\ actualDeploy.discount=1 /\ actualDeploy.deployProcedureComplete
/\ SideBPaidDeployPost(afterObjects[new],"SideB",afterObjects[new].kind,actualDeploy.allDeployCostsPaid,actualDeploy.allowed)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPlanMatches93, PaidOwnerCanQuery95, SideBPaidDeployPost
ExampleFamily048Move95 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily048Move95(p,plan,objects,transits,selected,target,actualProgressEligible) ==
/\ InstructionPlanMatches93(plan,p.ability,p.ability.cursor) /\ plan.phase="Resolving" /\ target \in plan.targets
/\ p.phase="Resolve" /\ selected \subseteq PaidHeldCounters95(p,objects,transits,"Progress")
/\ target \in DOMAIN objects /\ actualProgressEligible.tag="ProgressEligibleTarget"
/\ actualProgressEligible.abilityInstance=p.id /\ actualProgressEligible.target=target /\ actualProgressEligible.allowedExact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPlanMatches93, PaidHeldCounters95
ExampleFamily062SourcesValid98 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily062SourcesValid98(sources,objects,cardFacts) ==
\A key \in DOMAIN sources :
LET d == sources[key]
IN /\ d.syntax.id=key /\ d.syntax.kind="Static" /\ d.activity.kind="Static"
/\ d.activity.id=key /\ d.activity.source=d.syntax.source /\ d.syntax.source.kind="Object"
/\ d.syntax.source.object \in DOMAIN objects /\ objects[d.syntax.source.object].card="Specimen0226"
/\ d.sourceSHA=cardFacts["Specimen0226"].sourceSHA /\ AbilityTextValid93(d.syntax)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, AbilityTextValid93
ExampleFamily072DamageQuantity912 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily072DamageQuantity912(g,reference,world,cardFacts,emissions) ==
/\ g.card="Specimen0255" /\ g.source.kind="Object" /\ g.mode="Count"
/\ g.count=Cardinality(HostedQuantityCounters912(world.objects,g.source.object,"Progress"))
/\ g.partOrder= <<1>> /\ g.parts[1].operation="Damage"
/\ g.parts[1].basePresent /\ g.parts[1].base=2 /\ g.parts[1].unit=1
/\ g.parts[1].specifications.damageType="HarmClassA" /\ g.parts[1].specifications.actor="SideA"
/\ NormalizeQuantityGroup912(g,reference,world,cardFacts,emissions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: HostedQuantityCounters912, NormalizeQuantityGroup912
ExampleFamily075BatchMembers912 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily075BatchMembers912(batch,beforeObjects,targetSite) ==
{id \in batch.members \cap DOMAIN beforeObjects : beforeObjects[id].form="Card" /\ beforeObjects[id].zone="Play" /\
beforeObjects[id].targetSite=targetSite /\ beforeObjects[id].area \in {"Root","Protecting","TargetSite"}}Exact module download · Source bundle and reproduction instructions
ExampleFamily091HarmClassAToOne99 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily091HarmClassAToOne99(before,after,id) ==
/\ ExampleFamily091Relevant99(before,id) /\ SetExpectedEffectValue99(before,after,id,1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExampleFamily091Relevant99, SetExpectedEffectValue99
ExampleFamily091Relevant99 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily091Relevant99(effects,id) ==
/\ ExpectedValuePresent99(effects,id) /\ effects[id].kind="Damage" /\ effects[id].damageType="HarmClassA"
/\ effects[id].value>=2 /\ ExpectedEffectPreventable99(effects,id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectPreventable99, ExpectedValuePresent99
ExampleFamily092LookCount912 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily092LookCount912(context,effectId) == context.state.effects[effectId].value+1Exact module download · Source bundle and reproduction instructions
ExampleFamily092Occurrence96 · operator
reference-profile · input revision 2 · CC0 1.0
ExampleFamily092Occurrence96(d,requestedClass,plan,parent,ruleStep,actualEffect,snapshot,event) ==
/\ ConditionalDefinitionValid96(d)
/\ ConditionalCreationInstruction96(plan,parent,ruleStep)
/\ requestedClass \in {"WhenEncountered","WhenDeployed","WhenScored"} \cap ConditionalClasses96(d)
/\ actualEffect.tag="ConditionalExampleFamily092" /\ actualEffect.class=requestedClass
/\ actualEffect.ability=d.syntax.id /\ actualEffect.source=d.syntax.source /\ actualEffect.snapshotId=snapshot.id
/\ actualEffect.instruction=InstructionWindowRef93(plan) /\ actualEffect.authorized
/\ requestedClass="WhenScored" => d.syntax.cardKind="Objective"
/\ event.id=actualEffect.occurrenceId
/\ event.kind=CASE requestedClass="WhenScored" -> "ObjectivePlacementd" [] requestedClass="WhenDeployed" -> "Deployed" [] OTHER -> "EncounterBarrier"
/\ event.object=d.syntax.source.object
/\ event.scopeKind="Ability" /\ event.scopeDefinition=ConditionalKey96(d)
/\ event.actor=IF requestedClass="WhenScored" THEN "SideA" ELSE IF requestedClass="WhenEncountered" THEN "SideB" ELSE actualEffect.deployActor
/\ requestedClass="WhenDeployed" => actualEffect.deployActor \in SetupPlayers
/\ event.side=d.syntax.side /\ event.snapshot=snapshot /\ event.effectId=plan.idExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalClasses96, ConditionalCreationInstruction96, ConditionalDefinitionValid96, ConditionalKey96, InstructionWindowRef93, SetupPlayers
ExecutableInstructionGroups911 · operator
reference-profile · input revision 2 · CC0 1.0
ExecutableInstructionGroups911(p) == SelectSeq(p.groups,LAMBDA g : Len(g.nodes)>0)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
ExpectedAtomDescriptor99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedAtomDescriptor99(effect) == WouldDescriptor99(effect)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldDescriptor99
ExpectedAtomMapBound99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedAtomMapBound99(effects,ref) ==
/\ ReplacementEffectsValid99(effects)
/\ \A id \in DOMAIN effects : effects[id].value \in Int /\ effects[id].actor \in SetupPlayers /\ effects[id].targetSite \in STRING
/\ effects[id].baseOrigin=ref.sourceExact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementEffectsValid99, SetupPlayers
ExpectedBarrierInstructionProjection99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedBarrierInstructionProjection99(context,p,payload,prevented) ==
/\ context.currentRef=BarrierInstructionWindowRef98(p) /\ BarrierInstructionImminent98(p)
/\ IF DOMAIN context.state.effects={} THEN prevented /\ payload=p.payload /\ BarrierInstructionWasPrevented99(context,p)
ELSE /\ ~prevented /\ Cardinality(DOMAIN context.state.effects)=1
/\ LET id == CHOOSE i \in DOMAIN context.state.effects : TRUE
effect == context.state.effects[id]
IN /\ effect.kind="BarrierInstruction" /\ effect.barrierInstruction=p.barrierInstruction
/\ effect.baseOrigin=p.ability.source /\ effect.payload.kind="BarrierInstructionTemplate"
/\ Len(effect.payload.instructions)>0
/\ payload=[p.definition EXCEPT !.instructions=effect.payload.instructions]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effect, BarrierInstructionImminent98, BarrierInstructionWasPrevented99, BarrierInstructionWindowRef98
ExpectedContextOrigin99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedContextOrigin99(context,origin) ==
/\ ImminentOrigin99(origin) /\ context.currentRef=OriginReference99(origin)
/\ WouldContextKey99(context.initialRef)=WouldContextKey99(context.currentRef)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ImminentOrigin99, OriginReference99, WouldContextKey99
ExpectedContextWorld99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedContextWorld99(context,world) == ExpectedWorldValid99(world) /\ context.currentWorld=world.idExact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedWorldValid99
ExpectedControlApplies99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedControlApplies99(effects,operation) ==
/\ operation.effectId \in DOMAIN effects
/\ ReplacementPatternMatches99(operation.pattern,effects[operation.effectId])
/\ CASE operation.kind="PreventAmount" -> effects[operation.effectId].kind \in {"Damage","ExposureMarkers"} /\ ExpectedEffectPreventable99(effects,operation.effectId)
[] operation.kind="PreventWhole" -> ExpectedEffectPreventable99(effects,operation.effectId)
[] operation.kind="ExampleFamily091HarmClassAToOne" -> ExampleFamily091Relevant99(effects,operation.effectId)
[] operation.kind \in {"AddExpectedValue","SetExpectedValue"} -> ExpectedValuePresent99(effects,operation.effectId)
[] operation.kind="NoExpectedEffects" -> TRUE
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: ExampleFamily091Relevant99, ExpectedEffectPreventable99, ExpectedValuePresent99, ReplacementPatternMatches99
ExpectedControlBound99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedControlBound99(parent,modifier,plan,operation) ==
/\ modifier.phase="Resolving" /\ modifier.currentRef=InstructionWindowRef93(plan) /\ plan.phase="Resolving"
/\ operation.id \in DOMAIN modifier.actualEffects /\ modifier.actualEffects[operation.id]=operation
/\ operation.parentContextId=parent.id /\ operation.parentImminenceId=parent.imminenceId
/\ operation.parentReference=WouldContextKey99(parent.initialRef)
/\ operation.kind \in {"PreventAmount","PreventWhole","AddExpectedValue","SetExpectedValue","ExampleFamily091HarmClassAToOne","NoExpectedEffects"}
/\ operation.effectId \in Nat \ {0} /\ InterruptPatternValid99(operation.pattern)
/\ (operation.kind="PreventAmount" => operation.value \in Nat)
/\ (operation.kind \in {"AddExpectedValue","SetExpectedValue"} => operation.value \in Int)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93, InterruptPatternValid99, WouldContextKey99
ExpectedControlStep99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedControlStep99(beforeEffects,afterEffects,operation) ==
CASE operation.kind="PreventAmount" -> PreventExpectedAmount99(beforeEffects,afterEffects,operation.effectId,operation.value)
[] operation.kind="PreventWhole" -> PreventExpectedWhole99(beforeEffects,afterEffects,operation.effectId)
[] operation.kind="AddExpectedValue" -> ModifyExpectedEffectValue99(beforeEffects,afterEffects,operation.effectId,operation.value)
[] operation.kind="SetExpectedValue" -> SetExpectedEffectValue99(beforeEffects,afterEffects,operation.effectId,operation.value)
[] operation.kind="ExampleFamily091HarmClassAToOne" -> ExampleFamily091HarmClassAToOne99(beforeEffects,afterEffects,operation.effectId)
[] operation.kind="NoExpectedEffects" -> afterEffects=beforeEffects
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: ExampleFamily091HarmClassAToOne99, ModifyExpectedEffectValue99, PreventExpectedAmount99, PreventExpectedWhole99, SetExpectedEffectValue99
ExpectedEffectPreventable99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedEffectPreventable99(effects,id) ==
id \in DOMAIN effects /\ "preventable" \in DOMAIN effects[id] /\ effects[id].preventableExact module download · Source bundle and reproduction instructions
ExpectedEffectValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedEffectValid99(id,effect) ==
/\ id \in Nat \ {0} /\ effect.id=id /\ effect.kind \in STRING
/\ (effect.kind \in ExpectedValueKinds99 => effect.value \in Int)
/\ (effect.kind="Damage" => effect.damageType \in {"HarmClassA","HarmClassB","PersistentCapacityHarm"})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedValueKinds99
ExpectedEffectsValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedEffectsValid99(effects) == \A id \in DOMAIN effects : ExpectedEffectValid99(id,effects[id])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectValid99
ExpectedObservationSet99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedObservationSet99(effects) == {effects[id] : id \in DOMAIN effects}Exact module download · Source bundle and reproduction instructions
ExpectedReplacementCreationBound99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedReplacementCreationBound99(context,modifier,plan,operation,record) ==
/\ modifier.phase="Resolving" /\ modifier.currentRef=InstructionWindowRef93(plan) /\ plan.phase="Resolving"
/\ operation.id \in DOMAIN modifier.actualEffects /\ modifier.actualEffects[operation.id]=operation
/\ operation.kind="CreateReplacement" /\ operation.parentContextId=context.id /\ operation.parentImminenceId=context.imminenceId
/\ operation.parentReference=WouldContextKey99(context.initialRef)
/\ record.id=operation.replacementId /\ record.blueprint=operation.blueprint
/\ record.provider="ImminentInterrupt" /\ record.scope=[kind |-> "Instruction",context |-> WouldContextKey99(context.initialRef)]
/\ record.creation=[tag |-> "ResolvedReplacementCreation",replacement |-> record.id,instruction |-> modifier.currentRef,abilityInstance |-> plan.abilityInstance]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93, WouldContextKey99
ExpectedValueKinds99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedValueKinds99 == {"Damage","ExposureMarkers","Cost","EscalatingResourceContest"}Exact module download · Source bundle and reproduction instructions
ExpectedValueOperationReceipt99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedValueOperationReceipt99(id,operation,source,effect,before,after) ==
[tag |-> "ExpectedValueOperation",id |-> id,operation |-> operation,source |-> source,effectId |-> effect,
beforeEffects |-> before,afterEffects |-> after]Exact module download · Source bundle and reproduction instructions
ExpectedValuePresent99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedValuePresent99(effects,id) ==
id \in DOMAIN effects /\ effects[id].kind \in ExpectedValueKinds99Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedValueKinds99
ExpectedWorldValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedWorldValid99(world) ==
/\ world.tag="CurrentInterruptWorld" /\ world.id \in Nat \ {0}
/\ TurnFrameValid5(world.turn) /\ TraversalFrameValid6(world.traversalControl.traversal)
/\ DOMAIN world.controllers=DOMAIN world.objects /\ \A id \in DOMAIN world.controllers : world.controllers[id] \in SetupPlayers
/\ \A ref \in DOMAIN world.activePeriods : ref.kind \notin {"Turn","SchemaAtom138"} /\ WouldPeriodValid99(ref) /\ world.activePeriods[ref].period=refExact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldPeriodValid99, SetupPlayers, TraversalFrameValid6, TurnFrameValid5
ExpectedWouldAtomicCriterion99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedWouldAtomicCriterion99(effect,criterion) ==
/\ effect.kind=criterion.kind /\ effect.subtype=criterion.subtype
/\ (criterion.actor="SchemaAtom016" \/ effect.actor=criterion.actor)
/\ (~criterion.minimumPresent \/ effect.amount>=criterion.minimum)
/\ (~criterion.targetSitePresent \/ effect.targetSite=criterion.targetSite)Exact module download · Source bundle and reproduction instructions
ExpectedWouldCriterionMatches99 · operator
reference-profile · input revision 2 · CC0 1.0
ExpectedWouldCriterionMatches99(effect,criterion) ==
IF "alternatives" \in DOMAIN criterion THEN \E alternative \in criterion.alternatives : ExpectedWouldAtomicCriterion99(effect,alternative)
ELSE ExpectedWouldAtomicCriterion99(effect,criterion)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedWouldAtomicCriterion99
ExpireDelayedConditionalDuration96 · operator
reference-profile · input revision 2 · CC0 1.0
ExpireDelayedConditionalDuration96(before,candidate,after,beforeStack,afterStack,actualExpiry,beforeSnapshot,afterSnapshot) ==
/\ ExpireDelayedConditionalDurationCore96(before,candidate,beforeStack,
[i \in 1..Len(beforeStack) |-> LET lost == {id \in beforeStack[i].pending \cap DOMAIN before.instances : candidate.instances[id].status # "Pending"}
IN [beforeStack[i] EXCEPT !.pending=@ \ lost,!.lostPending=@ \cup lost]],actualExpiry)
/\ ObserveConditionalActivity96(before,candidate,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost, ExpireDelayedConditionalDurationCore96, ObserveConditionalActivity96
ExpireDelayedConditionalDurationCore96 · operator
reference-profile · input revision 2 · CC0 1.0
ExpireDelayedConditionalDurationCore96(before,after,beforeStack,afterStack,actualExpiry) ==
/\ actualExpiry.tag="DelayedConditionalDurationExpiry" /\ actualExpiry.observationId \in Nat \ {0}
/\ \A duration \in actualExpiry.expiredDurations : DelayedDurationValid96(duration) /\ duration # NoTimingRef9
/\ LET expired == {id \in DOMAIN before.effects : before.effects[id].policy="UntilDurationExpires" /\ before.effects[id].duration \in actualExpiry.expiredDurations}
keys == {ConditionalKey96(before.effects[id].definition) : id \in expired}
IN /\ after=[before EXCEPT !.effects=[id \in DOMAIN @ \ expired |-> @[id]],!.instances=LoseConditionalPendingKeys96(@,keys)]
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: expired, keys, DelayedDurationValid96, LoseConditionalPendingKeys96, NoTimingRef9, SyncConditionalWindows96
ExpireDelayedConditionalTiming96 · operator
reference-profile · input revision 2 · CC0 1.0
ExpireDelayedConditionalTiming96(before,candidate,after,beforeStack,afterStack,actualEnd,beforeSnapshot,afterSnapshot) ==
/\ ExpireDelayedConditionalTimingCore96(before,candidate,beforeStack,
[i \in 1..Len(beforeStack) |-> LET lost == {id \in beforeStack[i].pending \cap DOMAIN before.instances : candidate.instances[id].status # "Pending"}
IN [beforeStack[i] EXCEPT !.pending=@ \ lost,!.lostPending=@ \cup lost]],actualEnd)
/\ ObserveConditionalActivity96(before,candidate,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost, ExpireDelayedConditionalTimingCore96, ObserveConditionalActivity96
ExpireDelayedConditionalTimingCore96 · operator
reference-profile · input revision 2 · CC0 1.0
ExpireDelayedConditionalTimingCore96(before,after,beforeStack,afterStack,actualEnd) ==
/\ actualEnd.tag="TimingStructureEnded" /\ TimingRefValid9(actualEnd.structure)
/\ LET expired == {id \in DOMAIN before.effects : before.effects[id].policy="UntilDurationExpires" /\ before.effects[id].duration=actualEnd.structure}
keys == {ConditionalKey96(before.effects[id].definition) : id \in expired}
IN /\ after=[before EXCEPT !.effects=[id \in DOMAIN @ \ expired |-> @[id]],!.instances=LoseConditionalPendingKeys96(@,keys)]
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: expired, keys, LoseConditionalPendingKeys96, SyncConditionalWindows96, TimingRefValid9
ExpirePersistentNoReaction912 · operator
reference-profile · input revision 2 · CC0 1.0
ExpirePersistentNoReaction912(beforeRegistry,afterRegistry,beforeLedger,afterLedger,stack,afterStack,beforeSnapshot,afterSnapshot,
cp,clearance,beforeAuthority,afterAuthority) ==
/\ cp.id=beforeLedger.lastCheckpoint /\ cp.id \in DOMAIN beforeLedger.checkpoints
/\ beforeLedger.checkpoints[cp.id].caller=cp.caller
/\ PersistentRecognizedIds912(beforeLedger,cp.id)={}
/\ \A i \in 1..Len(stack) : stack[i].id \notin
{beforeLedger.instances[id].member.windowId : id \in {id \in DOMAIN beforeLedger.instances : beforeLedger.instances[id].checkpointId=cp.id}}
/\ clearance=[tag |-> "NormalCheckpointNoReactionWindow",checkpointId |-> cp.id,caller |-> cp.caller,
pendingInstances |-> {},point |-> "ProcedureCodeb74d673a0fc6"]
/\ LET keys == {key \in PersistentEndWindows912(beforeRegistry,0) : beforeRegistry.persistent[key].endCheckpoint=cp.id}
execution == [tag |-> "CurrentCharacteristicsEvaluation",id |-> cp.id,snapshotId |-> afterAuthority.current.id,
source |-> RuleAbilitySource9("ProcedureCode17f2a65162fb"),noWindow |-> clearance]
IN /\ keys#{}
/\ PublishPersistentExpiration912(beforeRegistry,afterRegistry,beforeLedger,beforeLedger,afterLedger,stack,afterStack,
beforeSnapshot,afterSnapshot,keys,execution,beforeAuthority,afterAuthority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, keys, PersistentRecognizedIds912, PublishPersistentExpiration912
FinishAbilityInstruction9 · operator
reference-profile · input revision 2 · CC0 1.0
FinishAbilityInstruction9(before,after,actualInstructionReceipt) ==
/\ before.phase = "Resolving" /\ ~before.complete
/\ actualInstructionReceipt.abilityInstance = before.id
/\ actualInstructionReceipt.instruction = before.instructions[before.cursor] /\ actualInstructionReceipt.complete
/\ after = IF before.cursor = Len(before.instructions)
THEN [before EXCEPT !.phase = "Complete",!.lastFinished = TRUE,!.complete = TRUE]
ELSE [before EXCEPT !.phase = "Between"]Exact module download · Source bundle and reproduction instructions
FinishActivationConditionalCard96 · operator
reference-profile · input revision 2 · CC0 1.0
FinishActivationConditionalCard96(before,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot,beforeActivation,afterActivation,actualLegal,events) ==
/\ FinishActivation8(beforeActivation,afterActivation,beforeSnapshot.objects,afterSnapshot.objects,actualLegal,events)
/\ ObserveConditionalActivity96(before,before,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveConditionalActivity96, FinishActivation8
FinishBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
FinishBarrierInstruction98(beforeLoop,afterLoop,before,after,e,afterEncounter,stack) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="AbilityComplete" /\ before.checkpoint \in Nat \ {0}
/\ BarrierInstructionLoopMatches98(beforeLoop,e) /\ before.origin="Encounter" /\ beforeLoop.current=before.id /\ beforeLoop.encounter=before.encounter /\ e.id=before.encounter /\ e.barrierCard=before.barrierCard
/\ beforeLoop.owner=before.owner /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ ReturnAbility9(before.ability,after.ability,TRUE,before.caller)
/\ after=[before EXCEPT !.ability=after.ability,!.phase="Returned"]
/\ afterEncounter=[e EXCEPT !.resolved=@ \cup {before.barrierInstruction}]
/\ afterLoop=[beforeLoop EXCEPT !.current=0,!.handled=@ \cup {before.barrierInstruction},!.resolved=@ \cup {before.barrierInstruction},
!.history=Append(@,[barrierInstruction |-> before.barrierInstruction,instance |-> before.id,disposition |-> "Resolved",source |-> before.ability.source])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionLoopMatches98, BarrierInstructionOwnerAtTop98, ReturnAbility9
FinishChainMember9 · operator
reference-profile · input revision 2 · CC0 1.0
FinishChainMember9(before,after,ability,actualChildReturnReceipt) ==
/\ Len(before)>0 /\ ability \in NextChainMembers9(before)
/\ actualChildReturnReceipt.abilityInstance = ability /\ actualChildReturnReceipt.returned
/\ LET top == before[Len(before)]
IN after = IF top.pending = {ability} THEN SubSeq(before,1,Len(before)-1)
ELSE [before EXCEPT ![Len(before)].pending = @ \ {ability}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: top, NextChainMembers9
FinishConditionalOccurrenceCore912 · operator
reference-profile · input revision 2 · CC0 1.0
FinishConditionalOccurrenceCore912(beforeLedger,afterLedger,beforeStack,afterStack,before,after,plan,afterPlan,context,
actualReturn,step,control,payment,boundary,nextId,capture) ==
/\ ConditionalOccurrenceBound912(beforeLedger,before) /\ OccurrenceAtTop912(beforeStack,before)
/\ beforeLedger.instances[before.id].status="Resolving" /\ plan.index \in DOMAIN beforeLedger.instances[before.id].expected
/\ FinishOccurrenceInstruction912(before,after,plan,afterPlan,context,actualReturn,step,control,payment,boundary,nextId,capture)
/\ LET last == after.current=0
d == before.technique.definition
expected == beforeLedger.instances[before.id].expected
throttle == last /\ d.primaryKind="Static" /\ DOMAIN expected=1..Len(after.trace) /\ \A i \in DOMAIN expected : expected[i].effects={}
IN /\ last => DOMAIN expected=1..Len(after.trace)
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status=IF last THEN "Complete" ELSE "Resolving",
!.throttle=IF throttle THEN ReplacementOverlay99(@,[key \in {ConditionalKey96(d)} |-> beforeLedger.stepSerial]) ELSE @]
/\ SyncConditionalWindows96(beforeStack,afterStack,beforeLedger,afterLedger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, expected, last, throttle, ConditionalKey96, ConditionalOccurrenceBound912, FinishOccurrenceInstruction912, OccurrenceAtTop912, ReplacementOverlay99, SyncConditionalWindows96
FinishConditionalProcedure96 · operator
reference-profile · input revision 2 · CC0 1.0
FinishConditionalProcedure96(beforeStack,afterStack,before,after,actualReturn) ==
/\ ConditionalAtTop96(beforeStack,before) /\ before.phase="Complete" /\ before.checkpoint \in Nat \ {0}
/\ actualReturn.finalCheckpointId=before.checkpoint
/\ LET returned == [before.ability EXCEPT !.returned=TRUE]
IN /\ ReturnAbility9(before.ability,returned,TRUE,before.windowId)
/\ CompletePriorityOption9(beforeStack,afterStack,actualReturn)
/\ after=[before EXCEPT !.ability=returned,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: returned, CompletePriorityOption9, ConditionalAtTop96, ReturnAbility9
FinishConditionalRuntimeCore911 · operator
reference-profile · input revision 2 · CC0 1.0
FinishConditionalRuntimeCore911(beforeLedger,afterLedger,beforeStack,afterStack,before,after,plan,afterPlan,context,
actualReturn,step,control,payment,boundary) ==
/\ ConditionalRuntimeBound911(beforeLedger,before) /\ ConditionalAtTop96(beforeStack,before)
/\ beforeLedger.instances[before.id].status="Resolving" /\ plan.index \in DOMAIN beforeLedger.instances[before.id].expected
/\ FinishRuntimeInstruction911(before,after,plan,afterPlan,context,actualReturn,step,control,payment,boundary)
/\ LET last == after.pc=0
d == before.technique.definition
expected == beforeLedger.instances[before.id].expected
throttle == last /\ d.primaryKind="Static" /\ DOMAIN expected=1..Len(after.visited) /\ \A i \in DOMAIN expected : expected[i].effects={}
IN /\ last => DOMAIN expected=1..Len(after.visited)
/\ afterLedger=[beforeLedger EXCEPT !.instances[before.id].status=IF last THEN "Complete" ELSE "Resolving",
!.throttle=IF throttle THEN ReplacementOverlay99(@,[key \in {ConditionalKey96(d)} |-> beforeLedger.stepSerial]) ELSE @]
/\ SyncConditionalWindows96(beforeStack,afterStack,beforeLedger,afterLedger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, expected, last, throttle, ConditionalAtTop96, ConditionalKey96, ConditionalRuntimeBound911, FinishRuntimeInstruction911, ReplacementOverlay99, SyncConditionalWindows96
FinishExpectedAbilityInstruction99 · operator
reference-profile · input revision 2 · CC0 1.0
FinishExpectedAbilityInstruction99(before,after,beforeOrigin,afterOrigin,world,call,actualReturn) ==
/\ before.phase="Resolving" /\ beforeOrigin.kind="Instruction" /\ beforeOrigin.plan.origin="Ability"
/\ before.currentRef=InstructionWindowRef93(beforeOrigin.plan) /\ call.beforePlan=beforeOrigin.plan
/\ call.before.ability=beforeOrigin.parent /\ call.kind=call.before.ability.kind
/\ actualReturn.tag="ExpectedEffectsProcedureReturn" /\ actualReturn.contextId=before.id
/\ actualReturn.instruction=before.currentRef /\ actualReturn.snapshotId=world.id
/\ actualReturn.effects=before.actualEffects /\ actualReturn.complete /\ actualReturn.childrenReturned
/\ call.step.expectedReturn=actualReturn
/\ CASE call.kind="Paid" -> CarryPaidInstruction95(call.stack,call.before,call.after,call.beforePlan,call.afterPlan,call.step)
[] call.kind="Conditional" -> CarryConditionalInstruction96(call.beforeLedger,call.candidateLedger,call.afterLedger,
call.beforeStack,call.afterStack,call.before,call.after,call.beforePlan,call.afterPlan,call.step,call.beforeSnapshot,call.afterSnapshot)
[] call.kind="Play" -> CarryPlayInstruction97(call.before,call.after,call.play,call.stack,call.beforePlan,call.afterPlan,call.step)
[] call.kind="BarrierInstruction" -> CarryBarrierInstructionInstruction98(call.before,call.after,call.stack,call.beforePlan,call.afterPlan,call.step)
[] OTHER -> FALSE
/\ call.afterPlan.phase="Complete"
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=call.afterPlan,!.parent=call.after.ability]
/\ after=[before EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryBarrierInstructionInstruction98, CarryConditionalInstruction96, CarryPaidInstruction95, CarryPlayInstruction97, InstructionWindowRef93
FinishExpectedDelayedInstruction910 · operator
reference-profile · input revision 2 · CC0 1.0
FinishExpectedDelayedInstruction910(beforeRegistry,afterRegistry,beforeContext,afterContext,beforeOrigin,afterOrigin,world,call,
retainedLedger,afterLedger,beforeSnapshot,afterSnapshot,beforeWorld,afterWorld,actualReturn) ==
/\ call.kind="Conditional" /\ ExpectedWorldValid99(world)
/\ world.id=beforeWorld.id /\ world.objects=beforeWorld.objects
/\ world.conditional=call.beforeSnapshot /\ beforeSnapshot=call.beforeSnapshot
/\ beforeContext.currentWorld=world.id
/\ ContextInitialObservationBound99(call.beforeLedger,call.before,beforeContext)
/\ FinishExpectedAbilityInstruction99(beforeContext,afterContext,beforeOrigin,afterOrigin,world,call,actualReturn)
/\ CarryDelayedLingeringInstruction910(beforeRegistry,afterRegistry,call.beforeLedger,call.candidateLedger,retainedLedger,afterLedger,
call.beforeStack,call.afterStack,call.before,call.after,call.beforePlan,call.afterPlan,call.step,
beforeSnapshot,afterSnapshot,beforeWorld,afterWorld)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryDelayedLingeringInstruction910, ContextInitialObservationBound99, ExpectedWorldValid99, FinishExpectedAbilityInstruction99
FinishExpectedRuleInstruction99 · operator
reference-profile · input revision 2 · CC0 1.0
FinishExpectedRuleInstruction99(before,after,beforeOrigin,afterOrigin,world,actualEffects,actualReturn,step,afterPlan) ==
/\ before.phase="Resolving" /\ beforeOrigin.kind="Instruction" /\ beforeOrigin.plan.origin="Rule"
/\ before.currentRef=InstructionWindowRef93(beforeOrigin.plan) /\ beforeOrigin.plan.phase="Resolving"
/\ actualEffects=before.actualEffects /\ actualReturn.tag="ExpectedEffectsProcedureReturn"
/\ actualReturn.contextId=before.id /\ actualReturn.instruction=before.currentRef /\ actualReturn.snapshotId=world.id
/\ actualReturn.effects=actualEffects /\ actualReturn.complete /\ actualReturn.childrenReturned
/\ step.expectedReturn=actualReturn
/\ CarryInstructionStep93(beforeOrigin.plan,afterPlan,step)
/\ afterPlan.phase="Complete"
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan]
/\ after=[before EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryInstructionStep93, InstructionWindowRef93
FinishObservedConditionalOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedConditionalOccurrence912(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
before,after,plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,nextId,capture,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ OccurrenceFinishedDelayed912(after,candidateLedger)={}
/\ FinishObservedConditionalOccurrenceCore912(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
before,after,plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,nextId,capture,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FinishObservedConditionalOccurrenceCore912, OccurrenceFinishedDelayed912
FinishObservedConditionalOccurrenceCore912 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedConditionalOccurrenceCore912(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
before,after,plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,nextId,capture,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority) /\ OccurrenceOwnerCurrent912(before,beforeAuthority)
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ ExpectedWorldValid99(world) /\ world.id=beforeAuthority.current.id /\ world.objects=beforeAuthority.current.objects
/\ world.turn=beforeAuthority.current.turn /\ world.traversalControl=beforeAuthority.current.control
/\ beforeContext.phase="Resolving" /\ beforeContext.currentWorld=world.id
/\ beforeOrigin.kind="Instruction" /\ beforeOrigin.ruleStep="NoValue" /\ beforeOrigin.plan=plan /\ beforeOrigin.parent=before.ability
/\ beforeContext.initialRef.source=before.ability.source /\ beforeContext.initialRef.abilityInstance=before.id /\ beforeContext.currentRef=InstructionWindowRef93(plan)
/\ actualReturn.snapshotId=world.id
/\ FinishConditionalOccurrenceCore912(beforeLedger,candidateLedger,beforeStack,DelayedCarryStack910(beforeStack,beforeLedger,candidateLedger),
before,after,plan,afterPlan,beforeContext,actualReturn,step,control,payment,boundary,nextId,capture)
/\ LET next == afterAuthority.current
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ OccurrenceFinishWorld912(beforeAuthority.current,next,after,candidateLedger)
/\ AppendLifetimeTransitionCore910(beforeAuthority,afterAuthority,LifetimeKernelTransition910(beforeAuthority.current,next,execution))
/\ ObserveLingering910(beforeRegistry,local,next)
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=next.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeAuthority.current)
/\ LingeringConditionalWorld910(afterSnapshot,candidateLedger,next)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,beforeAuthority.current)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,local,candidateLedger,next)
/\ ObserveConditionalActivity96(beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ DelayedLifetimeBound910(afterRegistry,afterLedger)
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan,!.parent=after.ability]
/\ afterContext=[beforeContext EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, DelayedCarryStack910, DelayedLifetimeBound910, ExpectedWorldValid99, FinishConditionalOccurrenceCore912, InstructionWindowRef93, LifetimeFrontier910, LifetimeKernelTransition910, LifetimeReady910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, OccurrenceFinishWorld912, OccurrenceOwnerCurrent912
FinishObservedConditionalRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedConditionalRuntime911(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
before,after,plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ RuntimeFinishedDelayed911(after,candidateLedger)={}
/\ FinishObservedConditionalRuntimeCore911(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
before,after,plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FinishObservedConditionalRuntimeCore911, RuntimeFinishedDelayed911
FinishObservedConditionalRuntimeCore911 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedConditionalRuntimeCore911(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,
before,after,plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority) /\ RuntimeOwnerCurrent911(before,beforeAuthority)
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ ExpectedWorldValid99(world) /\ world.id=beforeAuthority.current.id /\ world.objects=beforeAuthority.current.objects
/\ world.turn=beforeAuthority.current.turn /\ world.traversalControl=beforeAuthority.current.control
/\ beforeContext.phase="Resolving" /\ beforeContext.currentWorld=world.id
/\ beforeOrigin.kind="Instruction" /\ beforeOrigin.ruleStep="NoValue" /\ beforeOrigin.plan=plan /\ beforeOrigin.parent=before.ability
/\ beforeContext.initialRef.source=before.ability.source /\ beforeContext.initialRef.abilityInstance=before.id /\ beforeContext.currentRef=InstructionWindowRef93(plan)
/\ actualReturn.snapshotId=world.id
/\ FinishConditionalRuntimeCore911(beforeLedger,candidateLedger,beforeStack,DelayedCarryStack910(beforeStack,beforeLedger,candidateLedger),
before,after,plan,afterPlan,beforeContext,actualReturn,step,control,payment,boundary)
/\ LET next == afterAuthority.current
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ RuntimeFinishWorld911(beforeAuthority.current,next,after,candidateLedger)
/\ AppendLifetimeTransitionCore910(beforeAuthority,afterAuthority,LifetimeKernelTransition910(beforeAuthority.current,next,execution))
/\ ObserveLingering910(beforeRegistry,local,next)
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=next.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeAuthority.current)
/\ LingeringConditionalWorld910(afterSnapshot,candidateLedger,next)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,beforeAuthority.current)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,local,candidateLedger,next)
/\ ObserveConditionalActivity96(beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ DelayedLifetimeBound910(afterRegistry,afterLedger)
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan,!.parent=after.ability]
/\ afterContext=[beforeContext EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, DelayedCarryStack910, DelayedLifetimeBound910, ExpectedWorldValid99, FinishConditionalRuntimeCore911, InstructionWindowRef93, LifetimeFrontier910, LifetimeKernelTransition910, LifetimeReady910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, RuntimeFinishWorld911, RuntimeOwnerCurrent911
FinishObservedDelayedOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedDelayedOccurrence912(before,mid,after,call) ==
/\ call.before.technique.definition.delayedEffect \in Nat \ {0}
/\ OccurrenceFinishedDelayed912(call.after,call.candidateLedger)={call.before.technique.definition.delayedEffect}
/\ FinishObservedConditionalOccurrenceCore912(before.registry,mid.registry,before.ledger,call.candidateLedger,mid.ledger,before.stack,mid.stack,
call.before,call.after,call.plan,call.afterPlan,call.context,call.afterContext,call.origin,call.afterOrigin,call.world,
call.actualReturn,call.step,call.control,call.payment,call.boundary,call.nextId,call.capture,before.snapshot,mid.snapshot,before.authority,mid.authority)
/\ LET next == after.authority.current
acknowledgement == DelayedRuntimePublicationAck911(call.actualReturn,mid.authority.current)
execution == [tag |-> "ActualDelayedReturn",id |-> call.context.id,snapshotId |-> next.id,
source |-> call.before.ability.source,instruction |-> call.context.currentRef,return |-> acknowledgement]
local == [after.registry EXCEPT !.frontier=mid.registry.frontier]
IN /\ next=[mid.authority.current EXCEPT !.id=next.id,
!.finishedDelayedEffects=@ \cup OccurrenceFinishedDelayed912(call.after,call.candidateLedger)]
/\ AppendLifetimeTransitionCore910(mid.authority,after.authority,LifetimeKernelTransition910(mid.authority.current,next,execution))
/\ ObserveLingering910(mid.registry,local,next)
/\ after.snapshot.id=next.id /\ LingeringConditionalWorld910(after.snapshot,mid.ledger,next)
/\ after.snapshot=LingeringConditionalSnapshot910(after.snapshot,local,mid.ledger,next)
/\ ObserveConditionalActivity96(mid.ledger,mid.ledger,after.ledger,mid.stack,after.stack,mid.snapshot,after.snapshot)
/\ after.registry.frontier=LifetimeFrontier910(after.authority,Len(after.authority.order))
/\ DelayedLifetimeBound910(after.registry,after.ledger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, DelayedLifetimeBound910, FinishObservedConditionalOccurrenceCore912, LifetimeFrontier910, LifetimeKernelTransition910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, OccurrenceFinishedDelayed912
FinishObservedDelayedRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedDelayedRuntime911(before,mid,after,call) ==
/\ call.before.technique.definition.delayedEffect \in Nat \ {0}
/\ RuntimeFinishedDelayed911(call.after,call.candidateLedger)={call.before.technique.definition.delayedEffect}
/\ FinishObservedConditionalRuntimeCore911(before.registry,mid.registry,before.ledger,call.candidateLedger,mid.ledger,before.stack,mid.stack,
call.before,call.after,call.plan,call.afterPlan,call.context,call.afterContext,call.origin,call.afterOrigin,call.world,
call.actualReturn,call.step,call.control,call.payment,call.boundary,before.snapshot,mid.snapshot,before.authority,mid.authority)
/\ LET next == after.authority.current
acknowledgement == DelayedRuntimePublicationAck911(call.actualReturn,mid.authority.current)
execution == [tag |-> "ActualDelayedReturn",id |-> call.context.id,snapshotId |-> next.id,
source |-> call.before.ability.source,instruction |-> call.context.currentRef,return |-> acknowledgement]
local == [after.registry EXCEPT !.frontier=mid.registry.frontier]
IN /\ next=[mid.authority.current EXCEPT !.id=next.id,
!.finishedDelayedEffects=@ \cup RuntimeFinishedDelayed911(call.after,call.candidateLedger)]
/\ AppendLifetimeTransitionCore910(mid.authority,after.authority,LifetimeKernelTransition910(mid.authority.current,next,execution))
/\ ObserveLingering910(mid.registry,local,next)
/\ after.snapshot.id=next.id /\ LingeringConditionalWorld910(after.snapshot,mid.ledger,next)
/\ after.snapshot=LingeringConditionalSnapshot910(after.snapshot,local,mid.ledger,next)
/\ ObserveConditionalActivity96(mid.ledger,mid.ledger,after.ledger,mid.stack,after.stack,mid.snapshot,after.snapshot)
/\ after.registry.frontier=LifetimeFrontier910(after.authority,Len(after.authority.order))
/\ DelayedLifetimeBound910(after.registry,after.ledger)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, DelayedLifetimeBound910, FinishObservedConditionalRuntimeCore911, LifetimeFrontier910, LifetimeKernelTransition910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, RuntimeFinishedDelayed911
FinishObservedExpectedDelayedInstruction910 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedExpectedDelayedInstruction910(beforeRegistry,afterRegistry,beforeContext,afterContext,beforeOrigin,afterOrigin,world,call,
retainedLedger,afterLedger,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority,actualReturn) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority)
/\ LifetimeAuthorityValid910(afterAuthority)
/\ Len(afterAuthority.order)=Len(beforeAuthority.order)+1
/\ SubSeq(afterAuthority.order,1,Len(beforeAuthority.order))=beforeAuthority.order
/\ LET next == afterAuthority.current
execution == [tag |-> "ActualDelayedReturn",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> beforeOrigin.plan.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ AppendLifetimeTransitionCore910(beforeAuthority,afterAuthority,
LifetimeKernelTransition910(beforeAuthority.current,next,execution))
/\ FinishExpectedDelayedInstruction910(beforeRegistry,local,beforeContext,afterContext,beforeOrigin,afterOrigin,world,call,
retainedLedger,afterLedger,beforeSnapshot,afterSnapshot,beforeAuthority.current,next,actualReturn)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, FinishExpectedDelayedInstruction910, LifetimeAuthorityValid910, LifetimeFrontier910, LifetimeKernelTransition910, LifetimeReady910
FinishObservedSourceOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedSourceOccurrence912(beforeRegistry,afterRegistry,beforeLedger,afterLedger,beforeStack,afterStack,before,after,
plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,nextId,capture,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority) /\ OccurrenceOwnerCurrent912(before,beforeAuthority)
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ SourceOccurrenceBound912(before) /\ BarrierInstructionOwnerAtTop98(before.metadata.owner,beforeStack)
/\ ExpectedWorldValid99(world) /\ world.id=beforeAuthority.current.id /\ world.objects=beforeAuthority.current.objects
/\ world.turn=beforeAuthority.current.turn /\ world.traversalControl=beforeAuthority.current.control
/\ beforeContext.phase="Resolving" /\ beforeContext.currentWorld=world.id
/\ beforeContext.currentRef=InstructionWindowRef93(plan) /\ actualReturn.snapshotId=world.id
/\ beforeOrigin.kind="Instruction" /\ beforeOrigin.ruleStep="NoValue" /\ beforeOrigin.plan=plan /\ beforeOrigin.parent=before.ability
/\ beforeContext.initialRef.source=before.ability.source /\ beforeContext.initialRef.abilityInstance=before.id
/\ FinishOccurrenceInstruction912(before,after,plan,afterPlan,beforeContext,actualReturn,step,control,payment,boundary,nextId,capture)
/\ LET next == afterAuthority.current
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ OccurrenceFinishWorld912(beforeAuthority.current,next,after,beforeLedger)
/\ AppendLifetimeTransitionCore910(beforeAuthority,afterAuthority,LifetimeKernelTransition910(beforeAuthority.current,next,execution))
/\ ObserveLingering910(beforeRegistry,local,next)
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=next.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeAuthority.current)
/\ LingeringConditionalWorld910(afterSnapshot,beforeLedger,next)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,beforeAuthority.current)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,local,beforeLedger,next)
/\ ObserveConditionalActivity96(beforeLedger,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan,!.parent=after.ability]
/\ afterContext=[beforeContext EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, BarrierInstructionOwnerAtTop98, DelayedLifetimeBound910, ExpectedWorldValid99, FinishOccurrenceInstruction912, InstructionWindowRef93, LifetimeFrontier910, LifetimeKernelTransition910, LifetimeReady910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, OccurrenceFinishWorld912, OccurrenceOwnerCurrent912, SourceOccurrenceBound912
FinishObservedSourceRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
FinishObservedSourceRuntime911(beforeRegistry,afterRegistry,beforeLedger,afterLedger,beforeStack,afterStack,before,after,
plan,afterPlan,beforeContext,afterContext,beforeOrigin,afterOrigin,world,
actualReturn,step,control,payment,boundary,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority) /\ RuntimeOwnerCurrent911(before,beforeAuthority)
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ SourceRuntimeBound911(before) /\ BarrierInstructionOwnerAtTop98(before.sourceOwner,beforeStack)
/\ ExpectedWorldValid99(world) /\ world.id=beforeAuthority.current.id /\ world.objects=beforeAuthority.current.objects
/\ world.turn=beforeAuthority.current.turn /\ world.traversalControl=beforeAuthority.current.control
/\ beforeContext.phase="Resolving" /\ beforeContext.currentWorld=world.id
/\ beforeContext.currentRef=InstructionWindowRef93(plan) /\ actualReturn.snapshotId=world.id
/\ beforeOrigin.kind="Instruction" /\ beforeOrigin.ruleStep="NoValue" /\ beforeOrigin.plan=plan /\ beforeOrigin.parent=before.ability
/\ beforeContext.initialRef.source=before.ability.source /\ beforeContext.initialRef.abilityInstance=before.id
/\ FinishRuntimeInstruction911(before,after,plan,afterPlan,beforeContext,actualReturn,step,control,payment,boundary)
/\ LET next == afterAuthority.current
execution == [tag |-> "ActualObjectTransition",id |-> beforeContext.id,snapshotId |-> next.id,
source |-> before.ability.source,instruction |-> beforeContext.currentRef,return |-> actualReturn]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ RuntimeFinishWorld911(beforeAuthority.current,next,after,beforeLedger)
/\ AppendLifetimeTransitionCore910(beforeAuthority,afterAuthority,LifetimeKernelTransition910(beforeAuthority.current,next,execution))
/\ ObserveLingering910(beforeRegistry,local,next)
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=next.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeAuthority.current)
/\ LingeringConditionalWorld910(afterSnapshot,beforeLedger,next)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,beforeAuthority.current)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,local,beforeLedger,next)
/\ ObserveConditionalActivity96(beforeLedger,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ afterOrigin=[beforeOrigin EXCEPT !.plan=afterPlan,!.parent=after.ability]
/\ afterContext=[beforeContext EXCEPT !.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, local, next, AppendLifetimeTransitionCore910, BarrierInstructionOwnerAtTop98, DelayedLifetimeBound910, ExpectedWorldValid99, FinishRuntimeInstruction911, InstructionWindowRef93, LifetimeFrontier910, LifetimeKernelTransition910, LifetimeReady910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, RuntimeFinishWorld911, RuntimeOwnerCurrent911, SourceRuntimeBound911
FinishOccurrenceInstruction912 · operator
reference-profile · input revision 2 · CC0 1.0
FinishOccurrenceInstruction912(before,after,plan,afterPlan,context,actualReturn,step,control,payment,boundary,nextId,capture) ==
/\ OccurrenceRuntimeProfile912(before) /\ before.phase="Resolve" /\ before.pause.id=0
/\ OccurrencePlan912(before,plan) /\ plan.phase="Resolving" /\ plan.cursor=Len(plan.steps)
/\ context.phase="Resolving" /\ context.currentRef=InstructionWindowRef93(plan)
/\ actualReturn.tag="ExpectedEffectsProcedureReturn" /\ actualReturn.contextId=context.id
/\ actualReturn.instruction=context.currentRef /\ actualReturn.effects=context.actualEffects
/\ actualReturn.complete /\ actualReturn.childrenReturned /\ step.expectedReturn=actualReturn
/\ IF OccurrenceHasControl912(before) THEN OccurrenceControlBound912(before,context,actualReturn,control) ELSE control=NoInstructionControl911
/\ OccurrenceModalQuotaSupported912(before,control) /\ OccurrenceModalAllowed912(before,control) /\ before.current \notin DOMAIN before.choices
/\ IF OccurrencePassNext912(before,control)=0 /\ before.specification.repeat.kind="Fixed" /\ ~before.repeat.captured /\ OccurrenceRepeatRequested912(before,control)
THEN OccurrenceCountCapture912(before,context,actualReturn,capture) ELSE capture=[tag |-> "NoRepetitionCount"]
/\ LET continuation == OccurrenceContinuation912(before,control,capture)
next == continuation.sourceNode
trace == Append(before.trace,before.current)
projected == [before.ability EXCEPT !.instructions=IF next=0 THEN trace ELSE Append(trace,nextId)]
finished == IF next=0 THEN [projected EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [projected EXCEPT !.phase="Between",!.lastFinished=FALSE,!.complete=FALSE]
paid == payment.tag="CompletedInstructionCost"
IN /\ IF next=0 THEN nextId=0 ELSE nextId \in (Nat \ {0}) \ before.usedOccurrences
/\ CarryAbilityInstructionStep93(projected,finished,plan,afterPlan,step) /\ afterPlan.phase="Complete"
/\ (before.technique.nodes[before.pc].kind="NestedCost" /\ control.mode="Selected" /\ control.option="Pay") => paid
/\ IF paid THEN
/\ payment.instruction=context.currentRef /\ payment.instance=before.id /\ payment.source=before.ability.source
/\ payment.transaction \in Nat \ {0} /\ payment.operation \in DOMAIN context.actualEffects
/\ context.actualEffects[payment.operation].kind="NestedCostChoice" /\ context.actualEffects[payment.operation].controlNode=before.pc
/\ control.mode="Selected" /\ control.operation=payment.operation /\ control.option="Pay"
/\ payment.payer=context.actualEffects[payment.operation].payer /\ payment.specification=context.actualEffects[payment.operation].cost
/\ payment.receipt.tag="CompletedCostTransaction" /\ payment.receipt.id=payment.transaction
/\ payment.receipt.instance=before.id /\ payment.receipt.instruction=context.currentRef /\ payment.receipt.source=before.ability.source
/\ payment.receipt.payer=payment.payer /\ payment.receipt.specification=payment.specification /\ payment.receipt.allCostsPaid
/\ payment.paid /\ payment.lastAction /\ payment.completion=actualReturn
ELSE payment=[tag |-> "NoInstructionPayment"]
/\ boundary=OccurrenceBoundary912(before,context,IF paid THEN {"InstructionEnd","CostPaid"} ELSE {"InstructionEnd"},IF paid THEN payment.transaction ELSE 0)
/\ after=[before EXCEPT !.ability=finished,!.trace=trace,!.pc=next,!.current=nextId,
!.occurrences=IF next=0 THEN @ ELSE ReplacementOverlay99(@,[id \in {nextId} |-> [id |-> id,sourceNode |-> next,pass |-> continuation.repeat.pass]]),
!.usedOccurrences=IF next=0 THEN @ ELSE @ \cup {nextId},
!.choices=IF OccurrenceHasControl912(before) THEN ReplacementOverlay99(@,[id \in {before.current} |-> control]) ELSE @,
!.repeat=continuation.repeat,!.modal=continuation.modal,!.phase="Checkpoint",!.checkpoint=0,!.boundary=boundary]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: continuation, finished, next, paid, projected, trace, CarryAbilityInstructionStep93, InstructionWindowRef93, NoInstructionControl911, OccurrenceBoundary912, OccurrenceControlBound912, OccurrenceCountCapture912, OccurrenceHasControl912, OccurrenceModalAllowed912, OccurrenceModalQuotaSupported912, OccurrencePassNext912, OccurrencePlan912, OccurrenceRepeatRequested912, OccurrenceRuntimeProfile912, ReplacementOverlay99
FinishOnePlayAbility97 · operator
reference-profile · input revision 2 · CC0 1.0
FinishOnePlayAbility97(before,after,f,stack) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ PlayAbilityBound97(before)
/\ before.phase="AbilityComplete" /\ before.checkpoint \in Nat \ {0}
/\ ReturnAbility9(before.ability,[before.ability EXCEPT !.returned=TRUE],TRUE,before.playId)
/\ after=PlayAdvanceDisposition97(before,"Resolved",before.id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PlayAbilityBound97, PlayAdvanceDisposition97, PlayOwnerAtTop97, ReturnAbility9
FinishPaidMidItemInspection95 · operator
reference-profile · input revision 2 · CC0 1.0
FinishPaidMidItemInspection95(beforeStack,afterStack,before,after,actualReturn,a,afterItemInspection) ==
/\ before.phase="Complete" /\ before.checkpoint \in Nat \ {0} /\ PaidProcedureAtTop95(beforeStack,before)
/\ actualReturn.finalCheckpointId=before.checkpoint
/\ LET resolved == [before.ability EXCEPT !.returned=TRUE]
IN /\ ReturnAbility9(before.ability,resolved,TRUE,before.windowId)
/\ CompleteMidItemInspectionOption9(beforeStack,afterStack,actualReturn,a,afterItemInspection)
/\ after=[before EXCEPT !.ability=resolved,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolved, CompleteMidItemInspectionOption9, PaidProcedureAtTop95, ReturnAbility9
FinishPaidProcedure95 · operator
reference-profile · input revision 2 · CC0 1.0
FinishPaidProcedure95(beforeStack,afterStack,before,after,actualReturn) ==
/\ before.phase="Complete" /\ before.checkpoint \in Nat \ {0} /\ PaidProcedureAtTop95(beforeStack,before)
/\ actualReturn.finalCheckpointId=before.checkpoint
/\ LET a == [before.ability EXCEPT !.returned=TRUE]
IN /\ ReturnAbility9(before.ability,a,TRUE,before.windowId)
/\ CompletePriorityOption9(beforeStack,afterStack,actualReturn)
/\ after=[before EXCEPT !.ability=a,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, CompletePriorityOption9, PaidProcedureAtTop95, ReturnAbility9
FinishPlayCohort97 · operator
reference-profile · input revision 2 · CC0 1.0
FinishPlayCohort97(c,beforePlay,afterPlay,stack,receipt) ==
/\ PlayOwnerAtTop97(c,beforePlay,stack) /\ c.phase="Complete" /\ c.cursor=Len(c.order)+1
/\ DOMAIN c.dispositions=SubIds6(c.order)
/\ \A id \in DOMAIN c.dispositions : c.dispositions[id].disposition \in {"Resolved","SkippedInactive"}
/\ receipt.tag="PlayCohortCompletion" /\ receipt.playId=c.playId /\ receipt.object=c.source.object /\ receipt.dispositions=c.dispositions
/\ FinishPlayAbilities8(beforePlay,afterPlay,
[playId |-> c.playId,object |-> c.source.object,allPlayAbilitiesResolved |-> TRUE,
ownedTimingIds |-> receipt.ownedTimingIds,returnedTimingIds |-> receipt.returnedTimingIds,ownEndTriggersResolved |-> receipt.ownEndTriggersResolved])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PlayOwnerAtTop97, FinishPlayAbilities8, SubIds6
FinishRuntimeInstruction911 · operator
reference-profile · input revision 2 · CC0 1.0
FinishRuntimeInstruction911(before,after,plan,afterPlan,context,actualReturn,step,control,payment,boundary) ==
/\ RuntimeProfile911(before) /\ before.phase="Resolve" /\ before.pause.id=0
/\ RuntimeCurrentPlan911(before,plan) /\ plan.phase="Resolving" /\ plan.cursor=Len(plan.steps)
/\ context.phase="Resolving" /\ context.currentRef=InstructionWindowRef93(plan)
/\ context.currentRef.abilityInstance=before.id /\ actualReturn.tag="ExpectedEffectsProcedureReturn"
/\ actualReturn.contextId=context.id /\ actualReturn.instruction=context.currentRef /\ actualReturn.effects=context.actualEffects
/\ actualReturn.complete /\ actualReturn.childrenReturned /\ step.expectedReturn=actualReturn
/\ IF before.technique.nodes[before.pc].kind \in {"Choice","NestedCost"}
THEN ControlResultBound911(before,context,actualReturn,control)
ELSE control=NoInstructionControl911
/\ Len(before.visited)+1 \notin DOMAIN before.choices
/\ LET next == RuntimeNext911(before,control)
projected == RuntimeFinishFrame911(before,next)
finished == IF next=0 THEN [projected EXCEPT !.phase="Complete",!.lastFinished=TRUE,!.complete=TRUE]
ELSE [projected EXCEPT !.phase="Between"]
choices == IF before.technique.nodes[before.pc].kind \in {"Choice","NestedCost"}
THEN ReplacementOverlay99(before.choices,[i \in {Len(before.visited)+1} |-> control]) ELSE before.choices
paid == payment.tag="CompletedInstructionCost"
IN /\ CarryAbilityInstructionStep93(projected,finished,plan,afterPlan,step)
/\ afterPlan.phase="Complete"
/\ ((before.technique.nodes[before.pc].kind="NestedCost" /\ control.mode="Selected" /\ control.option="Pay") => paid)
/\ IF paid THEN
/\ payment.instruction=context.currentRef /\ payment.instance=before.id /\ payment.source=before.ability.source
/\ payment.transaction \in Nat \ {0} /\ payment.operation \in DOMAIN context.actualEffects
/\ context.actualEffects[payment.operation].kind="NestedCostChoice"
/\ context.actualEffects[payment.operation].controlNode=before.pc
/\ control.mode="Selected" /\ control.operation=payment.operation /\ control.option="Pay"
/\ payment.payer=context.actualEffects[payment.operation].payer /\ payment.payer \in SetupPlayers
/\ payment.specification=context.actualEffects[payment.operation].cost
/\ payment.receipt.tag="CompletedCostTransaction" /\ payment.receipt.id=payment.transaction
/\ payment.receipt.instance=before.id /\ payment.receipt.instruction=context.currentRef
/\ payment.receipt.source=before.ability.source /\ payment.receipt.payer=payment.payer
/\ payment.receipt.specification=payment.specification /\ payment.receipt.allCostsPaid
/\ payment.paid /\ payment.lastAction /\ payment.completion=actualReturn
ELSE payment=[tag |-> "NoInstructionPayment"]
/\ boundary=GraphInstructionBoundary911(before,context,
IF paid THEN {"InstructionEnd","CostPaid"} ELSE {"InstructionEnd"},IF paid THEN payment.transaction ELSE 0)
/\ after=[before EXCEPT !.ability=finished,!.visited=Append(@,before.pc),!.pc=next,!.choices=choices,
!.phase="Checkpoint",!.checkpoint=0,!.boundary=boundary]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: choices, finished, next, paid, projected, CarryAbilityInstructionStep93, ControlResultBound911, GraphInstructionBoundary911, InstructionWindowRef93, NoInstructionControl911, RuntimeCurrentPlan911, RuntimeProfile911, SetupPlayers
FirstWouldMatchSerial99 · operator
reference-profile · input revision 2 · CC0 1.0
FirstWouldMatchSerial99(history,key,period,criterion) ==
LET positions == {i \in 1..Len(history.evidence) : history.evidence[i].group=key /\
period \in history.evidence[i].periods /\ ExpectedWouldCriterionMatches99(history.evidence[i].descriptor,criterion)}
IN IF positions={} THEN 0 ELSE CHOOSE i \in positions : \A other \in positions : i<=otherExact module download · Source bundle and reproduction instructions
Resolved project definitions: positions
FlagActivity93 · operator
reference-profile · input revision 2 · CC0 1.0
FlagActivity93(a,effectivePresentIds,actualOrdinaryActivity,actualLivePersistentAbilities,points) ==
/\ a.id \in effectivePresentIds
/\ actualOrdinaryActivity \/ (FlagPresent93(a.units,"Persistent") /\ a.side="SideA" /\ a.id \in actualLivePersistentAbilities)
/\ ThreatFlagGate93(a.units,points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93, ThreatFlagGate93
FlagPrefixValid93 · operator
reference-profile · input revision 2 · CC0 1.0
FlagPrefixValid93(units,arrowAfterFlags) ==
/\ (TextUnitIds93(units,"AbilityFlag") # {}) => arrowAfterFlags
/\ \A i,j \in 1..Len(units) :
units[i].category="AbilityFlag" /\ units[j].category # "AbilityFlag" => i<jExact module download · Source bundle and reproduction instructions
Resolved project definitions: TextUnitIds93
FlagPresent93 · operator
reference-profile · input revision 2 · CC0 1.0
FlagPresent93(units,flag) == \E i \in 1..Len(units) : units[i].category="AbilityFlag" /\ units[i].subtype=flagExact module download · Source bundle and reproduction instructions
FreshOrderingConstraints98 · operator
reference-profile · input revision 2 · CC0 1.0
FreshOrderingConstraints98(after,gained) ==
\A a \in gained : \A b \in after.present \ {a} :
(OrdinarySub98(after,a) /\ OrdinarySub98(after,b)) =>
(OrderBefore98(after.order,a,b)=OrdinaryPrecedes98(after,a,b))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OrderBefore98, OrdinaryPrecedes98, OrdinarySub98
FreshSubRows98 · operator
reference-profile · input revision 2 · CC0 1.0
FreshSubRows98(before,rows) ==
/\ DOMAIN rows \subseteq (Nat \ {0}) \ before.usedIds
/\ \A id \in DOMAIN rows : BarrierInstructionDefinitionValid98(rows[id].definition,id,before.barrierCard)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionDefinitionValid98
GainOrderedBarrierInstructions98 · operator
reference-profile · input revision 2 · CC0 1.0
GainOrderedBarrierInstructions98(before,after,grants,rows,spine,decision,objects,cardFacts) ==
LET gained == DOMAIN rows
present == before.present \cup gained
kind == IF \E g \in DOMAIN grants : grants[g].mode="SideAChoice" THEN "SideADeclaredGain" ELSE "OrdinaryGain"
result == OrderChangedState98(before,rows,grants,present,spine,decision,kind,{},"Grant")
IN /\ BarrierInstructionOrderValid98(before) /\ FreshSubRows98(before,rows)
/\ DOMAIN grants # {} /\ DOMAIN grants \subseteq (Nat \ {0}) \ DOMAIN before.applications
/\ \A g \in DOMAIN grants : grants[g].id=g /\ BarrierInstructionGrantValid98(grants[g],before.barrierCard,objects,cardFacts) /\ grants[g].mode # "TLDR"
/\ \A g \in DOMAIN grants : grants[g].ability.syntax.kind="Static" =>
/\ ~\E old \in before.activeApplications : before.applications[old].definition.ability.syntax.id=grants[g].ability.syntax.id /\
before.applications[old].definition.ability.syntax.source=grants[g].ability.syntax.source
/\ ~\E other \in DOMAIN grants \ {g} : grants[other].ability.syntax.id=grants[g].ability.syntax.id /\ grants[other].ability.syntax.source=grants[g].ability.syntax.source
/\ \A id \in gained : rows[id].effect \in DOMAIN grants
/\ \A g \in DOMAIN grants : RowsMatchApplication98(rows,g,grants[g],decision.gainOrder,before.barrierCard)
/\ OrderingDecisionBound98(before,decision,kind,gained,{},spine,present)
/\ FreshOrderingConstraints98(result,gained)
/\ after=result /\ BarrierInstructionOrderValid98(after) /\ SelfCategoryIdentical98(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: gained, kind, present, result, BarrierInstructionGrantValid98, BarrierInstructionOrderValid98, FreshOrderingConstraints98, FreshSubRows98, OrderingDecisionBound98, RowsMatchApplication98, SelfCategoryIdentical98
GebrMaintenance910 · operator
reference-profile · input revision 2 · CC0 1.0
GebrMaintenance910(effect,world) ==
{id \in DOMAIN world.extenders :
LET r == world.extenders[id]
IN /\ effect.kind="Strength" /\ effect.originKind \in {"Paid","Conditional","Play","BarrierInstruction"} /\ effect.value>0
/\ LingeringShorterThanTurn910(effect,world)
/\ r.kind="Specimen0100Duration" /\ r.sourceSHA=world.cardFacts["Specimen0100"].sourceSHA
/\ r.definition.source=r.syntax.source /\ r.syntax.kind="Static" /\ r.definition.source.kind="Object"
/\ r.definition.source.object \in DOMAIN world.objects
/\ world.objects[r.definition.source.object].card="Specimen0100"
/\ world.objects[r.definition.source.object].host=effect.target
/\ StaticAbilityActive94(r.definition,r.syntax,world.objects,world.present,
LingeringObjectActive910(r.definition.source,world),world.activity,world.points)
/\ effect.creationTurn=world.turn.id /\ ~world.turn.formalEnded
}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: r, LingeringObjectActive910, LingeringShorterThanTurn910, StaticAbilityActive94
GrantCategory98 · operator
reference-profile · input revision 2 · CC0 1.0
GrantCategory98(grant,barrierCard) ==
IF SelfStaticGrant98(grant,barrierCard) THEN IF grant.placement="Before" THEN 2 ELSE 4
ELSE IF grant.placement="Before" THEN 1 ELSE 5Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SelfStaticGrant98
GrantCurrentInstructionLook911 · operator
reference-profile · input revision 2 · CC0 1.0
GrantCurrentInstructionLook911(before,after,id,p,plan,objects,deck,execution,cardFacts,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ objects=authority.current.objects
/\ p.id \in DOMAIN authority.current.activity.instances
/\ "owner" \in DOMAIN authority.current.activity.instances[p.id]
/\ authority.current.activity.instances[p.id].owner=p
/\ GrantInstructionLook911(before,after,id,p,plan,objects,deck,execution,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: GrantInstructionLook911, LifetimeReady910
GrantInstructionLook911 · operator
reference-profile · input revision 2 · CC0 1.0
GrantInstructionLook911(before,after,id,p,plan,objects,deck,execution,cardFacts) ==
/\ id \in (Nat \ {0}) \ DOMAIN before
/\ p.id=p.ability.id /\ p.phase="Resolve" /\ AbilityIsResolving9(p.ability)
/\ p.ability.phase="Resolving" /\ InstructionPlanMatches93(plan,p.ability,p.ability.cursor) /\ plan.phase="Resolving"
/\ execution.tag="LookInstructionExecution" /\ execution.instance=p.id /\ execution.definition=p.definition.syntax.id
/\ execution.instruction=InstructionWindowRef93(plan) /\ execution.source=p.ability.source
/\ execution.player \in SetupPlayers /\ execution.amount \in Nat /\ execution.zone \in {"SideADeck","SideBDeck"}
/\ execution.deck=deck /\ DeckSequenceValid4(deck) /\ SubIds6(deck) \subseteq DOMAIN objects
/\ \A object \in SubIds6(deck) : objects[object].zone=execution.zone
/\ execution.carriedOut /\ LookExecutionSource911(execution,objects,cardFacts)
/\ ~\E old \in DOMAIN before : before[old].instance=p.id /\ before[old].instruction=InstructionWindowRef93(plan) /\
before[old].execution.context.id=execution.context.id /\ before[old].execution.operation=execution.operation
/\ execution.context.phase="Resolving" /\ execution.context.currentRef=InstructionWindowRef93(plan)
/\ execution.operation \in DOMAIN execution.context.actualEffects
/\ execution.context.actualEffects[execution.operation].kind="Look"
/\ execution.context.actualEffects[execution.operation].amount=execution.amount
/\ execution.context.actualEffects[execution.operation].player=execution.player
/\ execution.context.actualEffects[execution.operation].zone=execution.zone
/\ after=ReplacementOverlay99(before,[key \in {id} |-> ScopedLookGrant911(id,p,plan,objects,deck,execution)])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityIsResolving9, InstructionPlanMatches93, InstructionWindowRef93, LookExecutionSource911, ReplacementOverlay99, ScopedLookGrant911, DeckSequenceValid4, SetupPlayers, SubIds6
GrantOccurrenceInstructionLook912 · operator
reference-profile · input revision 2 · CC0 1.0
GrantOccurrenceInstructionLook912(before,after,id,r,plan,objects,deck,execution,lifetimes,authority) ==
/\ OccurrenceRuntimeProfile912(r) /\ r.phase="Resolve" /\ r.pause.id=0 /\ OccurrencePlan912(r,plan)
/\ GrantCurrentInstructionLook911(before,after,id,OccurrenceLookOwner912(r),plan,objects,deck,execution,authority.current.cardFacts,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: GrantCurrentInstructionLook911, OccurrenceLookOwner912, OccurrencePlan912, OccurrenceRuntimeProfile912
GrantRuntimeInstructionLook911 · operator
reference-profile · input revision 2 · CC0 1.0
GrantRuntimeInstructionLook911(beforeGrants,afterGrants,id,r,plan,objects,deck,execution,lifetimes,authority) ==
/\ RuntimeProfile911(r) /\ r.phase="Resolve" /\ r.pause.id=0 /\ RuntimeCurrentPlan911(r,plan)
/\ GrantCurrentInstructionLook911(beforeGrants,afterGrants,id,RuntimeLookOwner911(r),plan,objects,deck,execution,authority.current.cardFacts,lifetimes,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: GrantCurrentInstructionLook911, RuntimeCurrentPlan911, RuntimeLookOwner911, RuntimeProfile911
GraphBoundaryCaller911 · operator
reference-profile · input revision 2 · CC0 1.0
GraphBoundaryCaller911(boundary) == [kind |-> "GraphInstructionBoundary",boundary |-> boundary]Exact module download · Source bundle and reproduction instructions
GraphInstructionBoundary911 · operator
reference-profile · input revision 2 · CC0 1.0
GraphInstructionBoundary911(r,context,causes,costTransaction) ==
[tag |-> "InstructionBoundary",instance |-> r.id,source |-> r.ability.source,instruction |-> context.currentRef,
node |-> r.pc,index |-> Len(r.visited)+1,causes |-> causes,costTransaction |-> costTransaction]Exact module download · Source bundle and reproduction instructions
GroupInstructionOrder911 · operator
reference-profile · input revision 2 · CC0 1.0
GroupInstructionOrder911(groups) ==
IF groups= <<>> THEN <<>> ELSE Head(groups).nodes \o GroupInstructionOrder911(Tail(groups))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: GroupInstructionOrder911
GroupNodeSegments911 · operator
reference-profile · input revision 2 · CC0 1.0
GroupNodeSegments911(p,g) ==
/\ DeckSequenceValid4(g.nodes) /\ SubIds6(g.nodes) \subseteq DOMAIN p.nodes
/\ \A id \in SubIds6(g.nodes) : p.nodes[id].segments \subseteq g.units
/\ UNION {p.nodes[id].segments : id \in SubIds6(g.nodes)}=IF Len(g.nodes)=0 THEN {} ELSE g.unitsExact module download · Source bundle and reproduction instructions
Resolved project definitions: DeckSequenceValid4, SubIds6
GroupUnitsShape911 · operator
reference-profile · input revision 2 · CC0 1.0
GroupUnitsShape911(p,g,category,shape) ==
Cardinality(g.units)=1 /\ LET u == CHOOSE id \in g.units : TRUE
IN p.units[u].category=category /\ UnitShape911(p.units[u])=shapeExact module download · Source bundle and reproduction instructions
Resolved project definitions: u, UnitShape911
HadProgressZero96 · operator
reference-profile · input revision 2 · CC0 1.0
HadProgressZero96(instance,object) ==
IF object \in DOMAIN instance.hadSnapshot.progress THEN instance.hadSnapshot.progress[object]=0 ELSE TRUEExact module download · Source bundle and reproduction instructions
HandlePreventedBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
HandlePreventedBarrierInstruction98(beforeLoop,afterLoop,p,e,afterEncounter,stack) ==
/\ BarrierInstructionBarrierInstructionBound98(p) /\ p.phase="FirstTargets" /\ p.prevented /\ ~p.ability.firstImminent
/\ BarrierInstructionLoopMatches98(beforeLoop,e) /\ beforeLoop.current=p.id /\ beforeLoop.encounter=p.encounter /\ e.id=p.encounter
/\ BarrierInstructionOwnerAtTop98(p.owner,stack) /\ p.owner=beforeLoop.owner
/\ afterEncounter=e
/\ afterLoop=[beforeLoop EXCEPT !.current=0,!.handled=@ \cup {p.barrierInstruction},!.prevented=@ \cup {p.barrierInstruction},
!.history=Append(@,[barrierInstruction |-> p.barrierInstruction,instance |-> p.id,disposition |-> "Prevented",source |-> p.ability.source])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionLoopMatches98, BarrierInstructionOwnerAtTop98
HostedPowerCount94 · operator
reference-profile · input revision 2 · CC0 1.0
HostedPowerCount94(objects,host) ==
Cardinality({id \in DOMAIN objects : objects[id].form="Counter" /\ objects[id].kind="Power" /\ objects[id].host=host})Exact module download · Source bundle and reproduction instructions
HostedQuantityCounters912 · operator
reference-profile · input revision 2 · CC0 1.0
HostedQuantityCounters912(objects,host,kind) ==
{id \in DOMAIN objects : objects[id].form="Counter" /\ objects[id].host=host /\ objects[id].zone="Play" /\ objects[id].kind=kind}Exact module download · Source bundle and reproduction instructions
IRField911 · operator
reference-profile · input revision 2 · CC0 1.0
IRField911(row,key,fallback) == IF key \in DOMAIN row THEN row[key] ELSE fallbackExact module download · Source bundle and reproduction instructions
ImminentOrigin99 · operator
reference-profile · input revision 2 · CC0 1.0
ImminentOrigin99(origin) ==
IF origin.kind="BarrierInstruction" THEN BarrierInstructionImminent98(origin.procedure)
ELSE origin.kind="Instruction" /\ InstructionImminentAtOrigin93(origin.plan,origin.parent,origin.ruleStep)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionImminent98, InstructionImminentAtOrigin93
ImplicitBarrierResponseCardStrengthDuration910 · operator
reference-profile · input revision 2 · CC0 1.0
ImplicitBarrierResponseCardStrengthDuration910(source,target,world) ==
/\ source.kind="Object" /\ source.object=target /\ target \in DOMAIN world.objects
/\ world.objects[target].kind="Technique" /\ target \in world.barrierResponseCardsExact module download · Source bundle and reproduction instructions
ImplicitStrengthBinding910 · operator
reference-profile · input revision 2 · CC0 1.0
ImplicitStrengthBinding910(source,target,world,requested,duration) ==
/\ ImplicitBarrierResponseCardStrengthDuration910(source,target,world)
/\ requested=IF world.currentEncounter \in DOMAIN world.encounters THEN TimingRef9("TraversalPhase",world.currentEncounter) ELSE NoTimingRef9
/\ duration=BindTimingDuration910(requested,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BindTimingDuration910, ImplicitBarrierResponseCardStrengthDuration910, NoTimingRef9, TimingRef9
InactivePlayer9 · operator
reference-profile · input revision 2 · CC0 1.0
InactivePlayer9(turn) == TurnOtherPlayer5(ActivePlayer9(turn))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActivePlayer9, TurnOtherPlayer5
InferredAbilityKind93 · operator
reference-profile · input revision 2 · CC0 1.0
InferredAbilityKind93(a) ==
LET instructions == TextUnitIds93(a.units,"Instruction")
primaries == PrimaryConditions93(a.units)
IN IF a.barrierInstructionPrefix THEN "BarrierInstruction"
ELSE IF a.paidPrefix.present THEN
IF a.paidPrefix.bold /\ a.paidPrefix.colon /\ Cardinality(primaries)=1 /\
\A i \in primaries : a.units[i].subtype="Cost"
THEN "Paid" ELSE "Invalid"
ELSE IF instructions={} THEN "Static"
ELSE IF primaries # {} THEN
IF Cardinality(primaries)=1 /\ instructions # {} /\
\A i \in primaries : a.units[i].subtype \in {"Trigger","Static"}
THEN "Conditional" ELSE "Invalid"
ELSE IF instructions # {} THEN IF a.cardKind \in {"Action","Plan"} THEN "Play" ELSE "Invalid"
ELSE "Static"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: instructions, primaries
InitialExpectedProjection99 · operator
reference-profile · input revision 2 · CC0 1.0
InitialExpectedProjection99(origin,world,description,projection,effects) ==
/\ ImminentOrigin99(origin) /\ ExpectedWorldValid99(world)
/\ description.tag="NormalizedInstructionEffectDescription" /\ description.context=OriginReference99(origin)
/\ description.source=OriginReference99(origin).source /\ description.snapshotId=world.id
/\ IF "occurrenceGroups" \in DOMAIN description THEN
/\ DOMAIN description.occurrenceGroups=DOMAIN description.effects
/\ \A id \in DOMAIN description.occurrenceGroups : description.occurrenceGroups[id] \in Nat \ {0}
ELSE TRUE
/\ ExpectedAtomMapBound99(description.effects,OriginReference99(origin))
/\ DeckSequenceValid4(description.order) /\ SubIds6(description.order)=DOMAIN description.effects
/\ {description.effects[id].lineage : id \in DOMAIN description.effects}=DOMAIN description.effects
/\ \A id \in DOMAIN description.effects : description.effects[id].lineage=id
/\ projection.tag="CurrentStaticExpectedProjection" /\ projection.description=description /\ projection.snapshotId=world.id
/\ projection.forbiddenIds \subseteq DOMAIN description.effects /\ DOMAIN projection.values \subseteq DOMAIN description.effects
/\ \A id \in DOMAIN projection.values : description.effects[id].kind \in ExpectedValueKinds99 /\ projection.values[id] \in Int
/\ effects=[id \in DOMAIN description.effects \ projection.forbiddenIds |->
IF id \in DOMAIN projection.values THEN [description.effects[id] EXCEPT !.value=projection.values[id]] ELSE description.effects[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedAtomMapBound99, ExpectedValueKinds99, ExpectedWorldValid99, ImminentOrigin99, OriginReference99, DeckSequenceValid4, SubIds6
InitialExpectedReceipt99 · operator
reference-profile · input revision 2 · CC0 1.0
InitialExpectedReceipt99(context) ==
[tag |-> "ConditionalExpectedEffects",point |-> "ExpectedEffectsBeforeInterrupt",instruction |-> context.initialRef,effects |-> ExpectedObservationSet99(context.initialEffects)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedObservationSet99
InitialWouldCaptured99 · operator
reference-profile · input revision 2 · CC0 1.0
InitialWouldCaptured99(context,history) ==
\E id \in DOMAIN history.observations \cap history.observationIds :
/\ history.observations[id]=InitialWouldObservation99(context,id)
/\ \A effect \in DOMAIN context.initialEffects : \E index \in 1..Len(history.evidence) :
/\ history.evidence[index].group=context.initialWouldGroups[effect]
/\ history.evidence[index].descriptor=WouldDescriptor99(context.initialEffects[effect])
/\ history.evidence[index].reference=context.initialRef /\ history.evidence[index].snapshotId=context.initialWorld
/\ history.evidence[index].periods=context.initialPeriodsExact module download · Source bundle and reproduction instructions
Resolved project definitions: InitialWouldObservation99, WouldDescriptor99
InitialWouldGroups99 · operator
reference-profile · input revision 2 · CC0 1.0
InitialWouldGroups99(imminence,effects) == [id \in DOMAIN effects |-> <<imminence,id>>]Exact module download · Source bundle and reproduction instructions
InitialWouldObservation99 · operator
reference-profile · input revision 2 · CC0 1.0
InitialWouldObservation99(context,id) ==
[tag |-> "CurrentExpectedWouldObservation",id |-> id,contextId |-> context.id,imminenceId |-> context.imminenceId,
reference |-> context.initialRef,snapshotId |-> context.initialWorld,effects |-> context.initialEffects,
groups |-> context.initialWouldGroups,periods |-> context.initialPeriods,order |-> InitialWouldOrder99(context)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InitialWouldOrder99
InitialWouldOrder99 · operator
reference-profile · input revision 2 · CC0 1.0
InitialWouldOrder99(context) == SelectSeq(context.description.order,LAMBDA effect : effect \in DOMAIN context.initialEffects)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
InitializeBarrierInstructionOrder98 · operator
reference-profile · input revision 2 · CC0 1.0
InitializeBarrierInstructionOrder98(state,barrierCard,order,definitions,keys,objects,cardFacts,printedText) ==
/\ barrierCard \in DOMAIN objects /\ objects[barrierCard].kind="Barrier" /\ DOMAIN definitions=SubIds6(order) /\ DOMAIN keys=SubIds6(order)
/\ printedText.tag="NormalizedPrintedBarrierInstructions" /\ printedText.barrierCard=barrierCard /\ printedText.card=objects[barrierCard].card
/\ printedText.sourceSHA=cardFacts[objects[barrierCard].card].sourceSHA
/\ printedText.order=order /\ printedText.definitions=definitions /\ printedText.textKeys=keys
/\ \A id \in DOMAIN definitions : definitions[id].activity.provider="Printed"
/\ state=NewBarrierInstructionOrder98(barrierCard,order,definitions,keys) /\ BarrierInstructionOrderValid98(state)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOrderValid98, NewBarrierInstructionOrder98, SubIds6
InspectionPrioritySite9 · operator
reference-profile · input revision 2 · CC0 1.0
InspectionPrioritySite9(turn,b) ==
PrioritySite9("Inspection",b.step,"Inspection",TimingRef9("Inspection",b.id),ActivePlayer9(turn),turn.id,b.traversalId,0,0,0,FALSE,
TurnFrameValid5(turn) /\ b.id \in Nat \ {0} /\ ~b.returned /\
(b.active \/ (b.complete /\ b.beginMet)),b.active /\ ~b.complete)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActivePlayer9, PrioritySite9, TimingRef9, TurnFrameValid5
InstructionCallerEntry99 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionCallerEntry99(entry,world,cardFacts) ==
/\ entry.tag="ActualInstructionEntry" /\ entry.id \in Nat \ {0} /\ entry.snapshotId=world.id
/\ entry.beforePlan.phase="Planning" /\ ~entry.beforePlan.announced
/\ entry.afterPlan.phase="Imminent"
/\ (entry.kind # "ConditionalFirst" => entry.stackAfter=entry.stackBefore)
/\ CASE entry.kind="Paid" ->
/\ EnterPaidInstruction95(entry.stackBefore,entry.before,entry.after,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt)
/\ IF WindowTop9(entry.stackBefore).kind="Interrupt" THEN
/\ entry.before.id \in DOMAIN world.interruptSelections /\ world.interruptSelections[entry.before.id]=entry.selection
/\ entry.selection.instance=entry.before.id /\ entry.selection.definition=entry.before.definition
/\ entry.selection.windowId=entry.before.windowId /\ entry.selection.option=entry.before.option
/\ entry.selection.transactionId=entry.before.transaction /\ entry.selection.source=entry.before.ability.source
ELSE TRUE
[] entry.kind="ConditionalFirst" ->
IF WindowTop9(entry.stackBefore).kind="Interrupt" THEN
/\ entry.parentWorld.id=world.id /\ entry.parentWorld.objects=world.objects
/\ entry.parentWorld.turn=world.turn /\ entry.parentWorld.traversalControl=world.traversalControl
/\ entry.parentWorld.conditional.definitions=world.conditional.definitions
/\ entry.parentWorld.conditional.activationEpoch=world.conditional.activationEpoch
/\ BeginCurrentConditionalInterrupt99(entry.beforeLedger,entry.afterLedger,entry.stackBefore,entry.stackAfter,
entry.before,entry.after,entry.definition,entry.snapshot,entry.instance,entry.option,entry.legality,
entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,entry.turnUses,entry.restrictions,
entry.parentContext,entry.parentOrigin,entry.parentWorld,entry.parentHistory,cardFacts)
ELSE BeginConditionalResolutionCore99(entry.beforeLedger,entry.afterLedger,entry.stackBefore,entry.stackAfter,
entry.before,entry.after,entry.definition,entry.lexemes,entry.snapshot,entry.instance,entry.option,entry.legality,entry.currentEffect,
entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,entry.turnUses,entry.restrictions,cardFacts)
[] entry.kind="ConditionalNext" ->
EnterNextConditionalInstruction96(entry.beforeLedger,entry.afterLedger,entry.stackBefore,entry.before,entry.after,
entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt)
[] entry.kind="PlayFirst" ->
BeginPlayAbility97(entry.before,entry.after,entry.play,entry.stackBefore,world.objects,entry.present,entry.activity,entry.points,
entry.instance,entry.usedInstances,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt,entry.restrictions)
[] entry.kind="PlayNext" ->
EnterNextPlayInstruction97(entry.before,entry.after,entry.play,entry.stackBefore,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt)
[] entry.kind="BarrierInstructionFirst" ->
EnterFirstBarrierInstructionInstruction98(entry.before,entry.after,entry.encounter,world.traversalControl,entry.orderState,world.objects,
entry.present,entry.activity,entry.points,entry.stackBefore,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt)
[] entry.kind="NestedBarrierInstructionFirst" ->
EnterFirstInstructionBarrierInstruction98(entry.before,entry.after,entry.parentPlan,entry.parentAbility,entry.parentRuleStep,entry.orderState,
world.objects,entry.present,entry.activity,entry.points,entry.stackBefore,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt)
[] entry.kind="BarrierInstructionNext" ->
EnterNextBarrierInstructionInstruction98(entry.before,entry.after,entry.stackBefore,entry.beforePlan,entry.afterPlan,entry.targets,entry.receipt)
[] entry.kind="Rule" ->
/\ entry.ruleInvocation \in DOMAIN world.ruleInvocations
/\ world.ruleInvocations[entry.ruleInvocation].tag="ActualRuleInvocation"
/\ world.ruleInvocations[entry.ruleInvocation].step=entry.ruleStep /\ ~world.ruleInvocations[entry.ruleInvocation].returned
/\ entry.sourceProcedure=world.ruleInvocations[entry.ruleInvocation].structure
/\ entry.owner=world.ruleInvocations[entry.ruleInvocation].owner
/\ LET announced == [entry.beforePlan EXCEPT !.announced=TRUE,!.targets=entry.targets.targets]
IN /\ AnnounceInstructionTargets93(entry.beforePlan,announced,entry.targets,[id \in {} |-> id],entry.ruleStep)
/\ EnterRuleInstruction93(announced,entry.afterPlan,entry.ruleStep)
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: announced, AnnounceInstructionTargets93, BeginConditionalResolutionCore99, BeginCurrentConditionalInterrupt99, BeginPlayAbility97, EnterFirstBarrierInstructionInstruction98, EnterFirstInstructionBarrierInstruction98, EnterNextBarrierInstructionInstruction98, EnterNextConditionalInstruction96, EnterNextPlayInstruction97, EnterPaidInstruction95, EnterRuleInstruction93, WindowTop9
InstructionEntryOrigin99 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionEntryOrigin99(entry,origin) ==
/\ origin.kind="Instruction" /\ origin.plan=entry.afterPlan
/\ IF entry.kind="Rule" THEN origin.ruleStep=entry.ruleStep /\ RuleInstructionPlan93(origin.plan,origin.ruleStep)
ELSE origin.ruleStep="NoValue" /\ origin.parent=entry.after.abilityExact module download · Source bundle and reproduction instructions
Resolved project definitions: RuleInstructionPlan93
InstructionEntryReceipt93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionEntryReceipt93(plan,actualEntry) ==
/\ actualEntry.tag="AbilityInstructionEntry" /\ actualEntry.abilityInstance=plan.abilityInstance
/\ actualEntry.instruction=plan.id /\ actualEntry.index=plan.index /\ actualEntry.source=plan.source /\ actualEntry.sourceZone=plan.sourceZoneExact module download · Source bundle and reproduction instructions
InstructionGroupContinuation911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionGroupContinuation911(p,g) ==
IF g.rule \in {"ProcedureCoded9954050183f","ProcedureCodef6fc0286cf28"} THEN g.join ELSE p.nodes[g.nodes[Len(g.nodes)]].nextExact module download · Source bundle and reproduction instructions
InstructionGroupValid911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionGroupValid911(p,g) ==
/\ g.units \subseteq DOMAIN p.units /\ g.units#{} /\ GroupNodeSegments911(p,g)
/\ CASE g.rule="ProcedureCode8b36a14c1569" ->
/\ Cardinality(g.units)=1 /\ Len(g.nodes)=1
/\ LET u == CHOOSE id \in g.units : TRUE
IN p.units[u].category="Trait" /\ UnitShape911(p.units[u]) \in {"Single","Effect","TimingStart"}
[] g.rule="ProcedureCodee085dc6e3123" ->
/\ g.nodes= <<>> /\ \A u \in g.units : p.units[u].category \in {"Restriction","SchemaAtom043","Clarification","Declaration"}
[] g.rule="ProcedureCode3a5790c241a3" ->
/\ GroupUnitsShape911(p,g,"Trait","MultiCard")
/\ LET u == CHOOSE id \in g.units : TRUE
unit == p.units[u]
IN /\ unit.action \in {"Play","Deploy","ItemInspection"} /\ unit.count \in Nat \ {0}
/\ Len(g.nodes)=unit.count
/\ \A i \in 1..unit.count :
/\ p.nodes[g.nodes[i]].kind="PerCard" /\ p.nodes[g.nodes[i]].cardAction=unit.action
/\ p.nodes[g.nodes[i]].cardOrdinal=i /\ p.nodes[g.nodes[i]].optional=unit.optional
/\ p.nodes[g.nodes[i]].next=IF i=unit.count THEN g.join ELSE g.nodes[i+1]
[] g.rule="ProcedureCoded3a7d2154f9f" ->
/\ Cardinality(g.units)=2 /\ Len(g.nodes)=1
/\ \E a,b \in g.units :
/\ a#b /\ p.units[a].sentence+1=p.units[b].sentence
/\ UnitShape911(p.units[a])="TargetOnly" /\ p.units[a].onlyTargets /\ ~p.units[a].otherEffects
/\ UnitShape911(p.units[b])="Effect" /\ p.units[b].actsOnChoice
/\ p.nodes[Head(g.nodes)].requiresTargets
[] g.rule="ProcedureCode1e9a46bbcc9d" ->
/\ Len(g.nodes)=2
/\ Cardinality({u \in g.units : UnitShape911(p.units[u])="SearchAndAct"})=1
/\ \A u \in g.units : UnitShape911(p.units[u]) \in {"SearchAndAct","PrintedSearchShuffle"}
/\ p.nodes[g.nodes[1]].kind="Search" /\ p.nodes[g.nodes[2]].kind="Plain"
/\ p.nodes[g.nodes[1]].searchShuffleRequired /\ p.nodes[g.nodes[2]].foundAction
/\ p.nodes[g.nodes[1]].next=g.nodes[2] /\ p.nodes[g.nodes[2]].next=g.join
/\ LET primary == CHOOSE u \in g.units : UnitShape911(p.units[u])="SearchAndAct"
IN primary \in p.nodes[g.nodes[1]].segments /\ primary \in p.nodes[g.nodes[2]].segments
/\ g.dischargedShuffleUnits={u \in g.units : UnitShape911(p.units[u])="PrintedSearchShuffle"}
[] g.rule="ProcedureCoded0cd74215226" ->
/\ GroupUnitsShape911(p,g,"Trait","LookAndAct") /\ Len(g.nodes)=2
/\ p.nodes[g.nodes[1]].kind="Look" /\ p.nodes[g.nodes[2]].requiresVisibleCohort
/\ p.nodes[g.nodes[1]].next=g.nodes[2] /\ p.nodes[g.nodes[2]].next=g.join
[] g.rule \in {"ProcedureCoded9954050183f","ProcedureCodef6fc0286cf28"} ->
/\ Cardinality(g.units)=1 /\ Len(g.nodes)>0
/\ LET u == CHOOSE id \in g.units : TRUE
unit == p.units[u]
control == p.nodes[Head(g.nodes)]
IN /\ unit.category="Trait"
/\ UnitShape911(unit)=IF g.rule="ProcedureCoded9954050183f" THEN "NestedCost" ELSE "Options"
/\ control.kind=IF g.rule="ProcedureCoded9954050183f" THEN "NestedCost" ELSE "Choice"
/\ DOMAIN control.options=DOMAIN unit.optionInstructions
/\ g.rule="ProcedureCoded9954050183f" => DOMAIN control.options={"Pay","Decline"}
/\ control.next=g.join
/\ SubIds6(g.nodes)={control.id} \cup UNION {SubIds6(unit.optionInstructions[choice]) : choice \in DOMAIN unit.optionInstructions}
/\ \A choice \in DOMAIN unit.optionInstructions :
LET body == unit.optionInstructions[choice]
IN /\ control.options[choice]=IF Len(body)=0 THEN g.join ELSE Head(body)
/\ \A i \in 1..Len(body) : p.nodes[body[i]].next=IF i=Len(body) THEN g.join ELSE body[i+1]
[] g.rule="ProcedureCodefabf14494c15" ->
/\ g.nodes= <<>> /\ \A u \in g.units : p.units[u].category="LinkedAbility"
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: u, unit, unit, body, control, primary, GroupNodeSegments911, GroupUnitsShape911, UnitShape911, SubIds6
InstructionImminentAtOrigin93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionImminentAtOrigin93(plan,ability,actualRuleStep) ==
/\ plan.phase="Imminent"
/\ IF plan.origin="Ability" THEN
/\ plan.abilityInstance \in Nat \ {0} /\ plan.index \in Nat \ {0}
/\ ability.phase="Imminent" /\ InstructionPlanMatches93(plan,ability,ability.cursor)
ELSE RuleInstructionPlan93(plan,actualRuleStep)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPlanMatches93, RuleInstructionPlan93
InstructionInterruptReturnMatches93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionInterruptReturnMatches93(plan,actualReturn) ==
/\ actualReturn.tag="InstructionInterruptReturn" /\ actualReturn.instruction=plan.id
/\ actualReturn.origin=plan.origin /\ actualReturn.abilityInstance=plan.abilityInstance /\ actualReturn.index=plan.index
/\ actualReturn.source=plan.source /\ actualReturn.sourceZone=plan.sourceZone
/\ actualReturn.revision=plan.revision /\ actualReturn.complete /\ actualReturn.windowId \in Nat
/\ actualReturn.openingRevision \in Nat /\ actualReturn.openingRevision <= plan.revisionExact module download · Source bundle and reproduction instructions
InstructionLinkGate96 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionLinkGate96(currentSnapshot,player) == currentSnapshot.link[player]>=2Exact module download · Source bundle and reproduction instructions
InstructionNode911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionNode911(id,kind,steps,requiresTargets,next,options,rank,segments) ==
[id |-> id,kind |-> kind,steps |-> steps,requiresTargets |-> requiresTargets,
next |-> next,options |-> options,rank |-> rank,segments |-> segments]Exact module download · Source bundle and reproduction instructions
InstructionPartitionValid911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionPartitionValid911(p) ==
/\ "groups" \in DOMAIN p /\ Len(p.groups)>0
/\ InstructionSourceFlow911(p)
/\ \A i \in 1..Len(p.groups) : InstructionGroupValid911(p,p.groups[i])
/\ UNION {p.groups[i].units : i \in 1..Len(p.groups)}=DOMAIN p.units
/\ \A i,j \in 1..Len(p.groups) : i#j => p.groups[i].units \cap p.groups[j].units={}
/\ UNION {SubIds6(p.groups[i].nodes) : i \in 1..Len(p.groups)}=DOMAIN p.nodes
/\ \A i,j \in 1..Len(p.groups) : i#j => SubIds6(p.groups[i].nodes) \cap SubIds6(p.groups[j].nodes)={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionGroupValid911, InstructionSourceFlow911, SubIds6
InstructionPauseCaller911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionPauseCaller911(r,plan,cause,child,point) ==
CASE cause="CostPaid" -> [kind |-> "InstructionCostCheckpoint",instance |-> r.id,instruction |-> InstructionWindowRef93(plan),transaction |-> child.id]
[] cause="Draw" -> [kind |-> "DrawCheckpoint",batchId |-> child.id,ability |-> r.id,caller |-> InstructionWindowRef93(plan),point |-> point]
[] cause="Play" -> PlayActivationCaller97(child)
[] cause="EscalatingResourceContest" -> [kind |-> "EscalatingResourceContestCheckpoint",escalatingResourceContestId |-> child.id,instance |-> r.id,caller |-> InstructionWindowRef93(plan),point |-> point]
[] cause="Timing" -> [kind |-> "TimingStructureCheckpoint",structure |-> child.structure,procedure |-> child.id,step |-> child.step,caller |-> InstructionWindowRef93(plan)]
[] OTHER -> [kind |-> "Invalid"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93, PlayActivationCaller97
InstructionPauseKey911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionPauseKey911(context,plan,cause,child,point,operation) ==
<<context.id,InstructionWindowRef93(plan),cause,child.id,point>>Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93
InstructionPausePoint911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionPausePoint911(r,plan,context,cause,child,point,operation) ==
/\ context.phase="Resolving" /\ context.currentRef=InstructionWindowRef93(plan) /\ context.currentRef.abilityInstance=r.id
/\ operation \in DOMAIN context.actualEffects /\ child.id \in Nat \ {0}
/\ CASE cause="CostPaid" ->
/\ point="CostPaid" /\ context.actualEffects[operation].kind \in {"Cost","PayNestedCost"}
/\ child.tag="CompletedInstructionCost" /\ child.instance=r.id /\ child.instruction=context.currentRef
/\ child.source=r.ability.source /\ child.paid /\ ~child.lastAction
/\ child.id=child.transaction /\ child.operation=operation /\ child.payer=context.actualEffects[operation].payer
/\ child.specification=context.actualEffects[operation].cost
/\ child.receipt.tag="CompletedCostTransaction" /\ child.receipt.id=child.transaction
/\ child.receipt.instance=r.id /\ child.receipt.instruction=context.currentRef /\ child.receipt.source=r.ability.source
/\ child.receipt.payer=child.payer /\ child.receipt.specification=child.specification /\ child.receipt.allCostsPaid
[] cause="Draw" ->
/\ point="ProcedureCode8be6d2dd1e98" /\ context.actualEffects[operation].kind="Draw"
/\ DrawBatchValid8(child) /\ child.stage="Checkpoint" /\ child.ability=r.id /\ child.caller=context.currentRef
[] cause="Play" ->
/\ point="ProcedureCodebddd9a1a600b" /\ context.actualEffects[operation].kind="Play"
/\ child.stage="ProcedureCodebddd9a1a600b" /\ child.activationReached /\ ~child.complete /\ child.caller=context.currentRef
[] cause="EscalatingResourceContest" ->
/\ point="ProcedureCoded1e36ce96789" /\ context.actualEffects[operation].kind="EscalatingResourceContest"
/\ child.tag="ActualEscalatingResourceContestProcedure" /\ child.point=point /\ child.instance=r.id /\ child.caller=context.currentRef
[] cause="Timing" ->
/\ context.actualEffects[operation].kind="OpenTimingStructure"
/\ child.tag="ActualTimingStructureCheckpoint" /\ TimingRefValid9(child.structure)
/\ child.step=point /\ child.parent=context.currentRef
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93, TimingRefValid9, DrawBatchValid8
InstructionPlanMatches93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionPlanMatches93(plan,ability,index) ==
/\ plan.origin="Ability" /\ plan.abilityInstance=ability.id /\ plan.source=ability.source /\ plan.sourceZone=ability.sourceZone
/\ index \in 1..Len(ability.instructions) /\ plan.index=index /\ plan.id=ability.instructions[index]Exact module download · Source bundle and reproduction instructions
InstructionPlanReady93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionPlanReady93(plan) ==
/\ plan.phase="Planning" /\ plan.id \in Nat \ {0} /\ Len(plan.steps)>0
/\ ~plan.requiresTargets \/ plan.announcedExact module download · Source bundle and reproduction instructions
InstructionProfileMatches93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionProfileMatches93(ref,plan) ==
/\ ref.origin=plan.origin /\ ref.id=plan.id /\ ref.abilityInstance=plan.abilityInstance /\ ref.index=plan.index
/\ ref.source=plan.source /\ ref.sourceZone=plan.sourceZone /\ ref.ruleStep=plan.ruleStepExact module download · Source bundle and reproduction instructions
InstructionSourceFlow911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionSourceFlow911(p) ==
/\ p.definition.instructions=GroupInstructionOrder911(p.groups)
/\ LET groups == ExecutableInstructionGroups911(p)
IN /\ IF Len(groups)=0 THEN p.entry=0 ELSE p.entry=Head(groups[1].nodes)
/\ \A i \in 1..Len(groups) :
InstructionGroupContinuation911(p,groups[i])=IF i=Len(groups) THEN 0 ELSE Head(groups[i+1].nodes)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: groups, GroupInstructionOrder911, InstructionGroupContinuation911
InstructionSuppressInstructionClassification98 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionSuppressInstructionClassification98(plan,classification) ==
/\ classification.tag="NormalizedInstructionSuppressInstruction" /\ classification.instruction=InstructionWindowRef93(plan)
/\ classification.mode \in {"Ordinary","All","Hook"} /\ classification.selector \in {"SchemaAtom016","Last"}
/\ classification.minimumTargets \in Nat /\ classification.maximumTargets \in Nat
/\ classification.minimumTargets<=classification.maximumTargets
/\ IF classification.mode="Ordinary" THEN classification.maximumTargets>0
ELSE IF classification.mode="Hook" THEN classification.minimumTargets=1 /\ classification.maximumTargets=1 /\ classification.selector="SchemaAtom016"
ELSE classification.minimumTargets=0 /\ classification.maximumTargets=0 /\ classification.selector="SchemaAtom016"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93
InstructionTechniqueSource911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionTechniqueSource911(p,objects,cardFacts) ==
/\ InstructionTechniqueValid911(p)
/\ AbilityLexemesValid99(p.definition,p.lexemes,objects,cardFacts)
/\ p.sourceSHA=p.lexemes.sourceSHA /\ p.card=p.lexemes.card
/\ p.originalUnits=p.definition.syntax.unitsExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityLexemesValid99, InstructionTechniqueValid911
InstructionTechniqueValid911 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionTechniqueValid911(p) ==
/\ p.tag="NormalizedInstructionTechnique" /\ p.source=p.definition.syntax.source
/\ p.ability=p.definition.syntax.id
/\ IF DOMAIN p.nodes={} THEN p.entry=0 ELSE p.entry \in DOMAIN p.nodes
/\ SubIds6(p.definition.instructions)=DOMAIN p.nodes
/\ DOMAIN p.nodes \subseteq Nat \ {0}
/\ \A id \in DOMAIN p.nodes :
LET n == p.nodes[id]
IN /\ n.id=id /\ n.kind \in {"Plain","Choice","NestedCost","Search","Look","TimingStart","PerCard"}
/\ Len(n.steps)>0 /\ n.requiresTargets \in BOOLEAN /\ n.rank \in Nat
/\ TechniqueEdges911(n) \subseteq DOMAIN p.nodes
/\ \A next \in TechniqueEdges911(n) : p.nodes[next].rank<n.rank
/\ n.segments \subseteq DOMAIN p.units /\ n.segments#{}
/\ \A unit \in n.segments : p.units[unit].category="Trait"
/\ (n.kind \in {"Choice","NestedCost"})=(DOMAIN n.options#{})
/\ n.kind="NestedCost" => DOMAIN n.options={"Pay","Decline"}
/\ ReachableTechniqueNodes911(p,IF DOMAIN p.nodes={} THEN {} ELSE {p.entry},Cardinality(DOMAIN p.nodes))=DOMAIN p.nodes
/\ p.nonoperative={unit \in DOMAIN p.units : p.units[unit].category \in {"Restriction","SchemaAtom043","Clarification","Declaration"}}
/\ p.linked={unit \in DOMAIN p.units : p.units[unit].category="LinkedAbility"}
/\ \A id \in DOMAIN p.nodes : p.nodes[id].segments \cap (p.nonoperative \cup p.linked)={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: n, ReachableTechniqueNodes911, TechniqueEdges911, SubIds6
InstructionWindowRef93 · operator
reference-profile · input revision 2 · CC0 1.0
InstructionWindowRef93(plan) ==
[origin |-> plan.origin,id |-> plan.id,abilityInstance |-> plan.abilityInstance,index |-> plan.index,
source |-> plan.source,sourceZone |-> plan.sourceZone,ruleStep |-> plan.ruleStep,revision |-> plan.revision]Exact module download · Source bundle and reproduction instructions
InterfaceFlagTiming93 · operator
reference-profile · input revision 2 · CC0 1.0
InterfaceFlagTiming93(a,actor,source,sourceSubtypes,localAbility,context,sourceStrength,barrierStrength,barrierSubtypes,targets) ==
~FlagPresent93(a.units,"Interface") \/
(/\ a.kind="Paid" /\ actor="SideB" /\ BarrierResponseCardTechnique(source,sourceSubtypes)
/\ sourceStrength.exists /\ barrierStrength.exists /\ sourceStrength.amount >= barrierStrength.amount
/\ InterfaceAbilityLocalGate(actor,source,sourceSubtypes,localAbility,context,sourceStrength,barrierStrength,barrierSubtypes,targets))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93, BarrierResponseCardTechnique, InterfaceAbilityLocalGate
InterruptCapabilitiesValid99 · operator
reference-profile · input revision 2 · CC0 1.0
InterruptCapabilitiesValid99(d,lex,capabilities) ==
/\ capabilities.tag="NormalizedInterruptCapabilities" /\ capabilities.definition=d /\ capabilities.origin=lex.origin
/\ \A id \in DOMAIN capabilities.clauses :
LET c == capabilities.clauses[id]
IN /\ c.mode \in {"PreventAmount","PreventWhole","AddValue","SetValue","CreateReplacement","WouldTrigger"}
/\ InterruptPatternValid99(c.pattern)
/\ c.mode \in {"PreventAmount","AddValue","SetValue"} => c.value \in Int
/\ c.mode="CreateReplacement" => InterruptPatternValid99(c.replacementPattern)
/\ c.mode="WouldTrigger" => c.ordinal \in Nat /\ WouldPeriodValid99(c.period)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: c, InterruptPatternValid99, WouldPeriodValid99
InterruptEffectMatches9 · operator
reference-profile · input revision 2 · CC0 1.0
InterruptEffectMatches9(w,actualCurrentEffect) ==
/\ actualCurrentEffect.tag = "CurrentImminentEffect" /\ actualCurrentEffect.windowId = w.id
/\ actualCurrentEffect.instruction = w.instruction
/\ actualCurrentEffect.revision \in Nat \ {0} /\ actualCurrentEffect.revision >= w.effectRevision
/\ actualCurrentEffect.relevantConditional \subseteq DOMAIN w.members
/\ actualCurrentEffect.paidInterruptAbilities \subseteq Nat \ {0}Exact module download · Source bundle and reproduction instructions
InterruptFlagTiming93 · operator
reference-profile · input revision 2 · CC0 1.0
InterruptFlagTiming93(a,w,actualRelevance) ==
~FlagPresent93(a.units,"Interrupt") \/
(/\ a.kind \in {"Paid","Conditional"} /\ w.kind="Interrupt"
/\ actualRelevance.tag="InterruptRelevance" /\ actualRelevance.windowId=w.id
/\ actualRelevance.instruction=w.instruction /\ actualRelevance.ability=a.id /\ actualRelevance.source=a.source
/\ actualRelevance.relevant)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93
InterruptPatternValid99 · operator
reference-profile · input revision 2 · CC0 1.0
InterruptPatternValid99(pattern) ==
/\ "kind" \in DOMAIN pattern /\ pattern.kind \in STRING
/\ ("minValue" \in DOMAIN pattern => pattern.minValue \in Int)Exact module download · Source bundle and reproduction instructions
InterruptRelevant99 · operator
reference-profile · input revision 2 · CC0 1.0
InterruptRelevant99(d,lex,capabilities,context,world,history) ==
/\ AbilityInterrupt99(d,lex) /\ InterruptCapabilitiesValid99(d,lex,capabilities)
/\ \E c \in DOMAIN capabilities.clauses : \E effect \in DOMAIN context.state.effects :
CapabilityRelevant99(capabilities.clauses[c],context.state.effects[effect],context,world,history)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, CapabilityRelevant99, InterruptCapabilitiesValid99
ItemInspectionFlagTiming93 · operator
reference-profile · input revision 2 · CC0 1.0
ItemInspectionFlagTiming93(a,w) ==
~FlagPresent93(a.units,"ItemInspection") \/
(a.kind="Paid" /\ a.side="SideB" /\ w.kind="MidItemInspection" /\ w.site.step="ProcedureCode1dd0e8f05be2")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93
ItemInspectionPrioritySite9 · operator
reference-profile · input revision 2 · CC0 1.0
ItemInspectionPrioritySite9(turn,a,objects) ==
PrioritySite9("ItemInspection",a.step,"ItemInspection",TimingRef9("ItemInspection",a.id),ActivePlayer9(turn),turn.id,a.traversalId,a.id,0,0,FALSE,
TurnFrameValid5(turn) /\ a.id \in Nat \ {0} /\ ~a.returned /\
(StillItemInspectioning7(a,objects) \/ (a.complete /\ a.beginMet)),StillItemInspectioning7(a,objects))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActivePlayer9, PrioritySite9, TimingRef9, StillItemInspectioning7, TurnFrameValid5
LegacyPriorityWindow9 · operator
reference-profile · input revision 2 · CC0 1.0
LegacyPriorityWindow9(w) ==
[id |-> w.id,kind |-> w.kind,open |-> w.open,priority |-> IF w.stage="Ready" THEN w.priority ELSE "NoValue",
step |-> w.site.step,traversalId |-> w.site.traversalId,
phaseId |-> IF w.site.structure.kind = "TraversalPhase" THEN w.site.structure.id ELSE 0,
beginPhaseId |-> IF w.beginning.kind = "TraversalPhase" THEN w.beginning.id ELSE 0,
beginItemInspectionId |-> IF w.beginning.kind = "ItemInspection" THEN w.beginning.id ELSE 0,
beginInspectionId |-> IF w.beginning.kind = "Inspection" THEN w.beginning.id ELSE 0,
pending |-> w.pending,lostPending |-> w.lostPending]Exact module download · Source bundle and reproduction instructions
LifetimeAuthorityAfter910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeAuthorityAfter910(before,transition) ==
[current |-> transition.after,order |-> Append(before.order,transition.after.id),
worlds |-> ReplacementOverlay99(before.worlds,[id \in {transition.after.id} |-> transition.after]),
transitions |-> ReplacementOverlay99(before.transitions,[id \in {transition.after.id} |-> transition])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
LifetimeAuthorityValid910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeAuthorityValid910(a) ==
/\ DeckSequenceValid4(a.order) /\ Len(a.order)>0 /\ DOMAIN a.worlds=SubIds6(a.order)
/\ a.current=a.worlds[a.order[Len(a.order)]]
/\ DOMAIN a.transitions=SubIds6(Tail(a.order))
/\ \A i \in 1..Len(a.order) : a.worlds[a.order[i]].id=a.order[i]
/\ \A i \in 2..Len(a.order) :
/\ a.transitions[a.order[i]].before=a.worlds[a.order[i-1]]
/\ a.transitions[a.order[i]].after=a.worlds[a.order[i]]
/\ LifetimeTransitionValid910(a.transitions[a.order[i]])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeTransitionValid910, DeckSequenceValid4, SubIds6
LifetimeFaceTransition910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeFaceTransition910(before,after,object,face,actualEffectAuthorizes,events) ==
[kind |-> "Face8",before |-> LifetimeWorldProjection910(before),after |-> LifetimeWorldProjection910(after),
object |-> object,face |-> face,actualEffectAuthorizes |-> actualEffectAuthorizes,events |-> events]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeWorldProjection910
LifetimeFrontier910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeFrontier910(a,position) ==
LET order == SubSeq(a.order,1,position)
IN [position |-> position,order |-> order,world |-> a.worlds[order[position]],
worlds |-> [id \in SubIds6(order) |-> a.worlds[id]],
transitions |-> [id \in SubIds6(Tail(order)) |-> a.transitions[id]]]Exact module download · Source bundle and reproduction instructions
LifetimeFrontierBound910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeFrontierBound910(registry,a) ==
/\ LifetimeAuthorityValid910(a) /\ "frontier" \in DOMAIN registry
/\ registry.frontier.position \in 1..Len(a.order)
/\ registry.frontier=LifetimeFrontier910(a,registry.frontier.position)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeAuthorityValid910, LifetimeFrontier910
LifetimeKernelTransition910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeKernelTransition910(before,after,execution) ==
[kind |-> "Kernel",before |-> LifetimeWorldProjection910(before),after |-> LifetimeWorldProjection910(after),
receipt |-> [tag |-> "AtomicLifetimeWorldCommit",previous |-> before.id,id |-> after.id,
before |-> LifetimeWorldProjection910(before),after |-> LifetimeWorldProjection910(after),execution |-> execution]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeWorldProjection910
LifetimeReady910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeReady910(registry,a) ==
LifetimeFrontierBound910(registry,a) /\ registry.frontier.position=Len(a.order)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeFrontierBound910
LifetimeTransitionValid910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeTransitionValid910(t) ==
/\ t.before.id \in Nat \ {0} /\ t.after.id \in Nat \ {0} /\ t.before.id#t.after.id
/\ t.before.cardFacts=t.after.cardFacts /\ (t.before.gameStarted => t.after.gameStarted)
/\ CASE t.kind="Face8" ->
/\ TurnSideBFace8(t.before.objects,t.after.objects,t.object,t.face,t.actualEffectAuthorizes,t.events)
/\ t.after=[t.before EXCEPT !.id=t.after.id,!.objects=t.after.objects]
[] t.kind="Kernel" ->
/\ t.receipt.tag="AtomicLifetimeWorldCommit" /\ t.receipt.previous=t.before.id /\ t.receipt.id=t.after.id
/\ t.receipt.before=t.before /\ t.receipt.after=t.after
/\ t.receipt.execution.tag \in {"CurrentCharacteristicsEvaluation","ActualTimingTransition","ActualObjectTransition","ActualDelayedReturn"}
/\ t.receipt.execution.id \in Nat \ {0} /\ t.receipt.execution.snapshotId=t.after.id
/\ t.receipt.execution.source.kind \in {"Object","Rule"}
/\ CASE t.receipt.execution.tag="CurrentCharacteristicsEvaluation" ->
/\ t.after.objects=t.before.objects /\ t.after.turn=t.before.turn /\ t.after.turnPhase=t.before.turnPhase
/\ t.after.control=t.before.control /\ t.after.encounters=t.before.encounters
/\ t.after.siteInspections=t.before.siteInspections /\ t.after.itemInspections=t.before.itemInspections
/\ t.after.finishedInstances=t.before.finishedInstances /\ t.after.finishedDelayedEffects=t.before.finishedDelayedEffects
[] t.receipt.execution.tag="ActualTimingTransition" ->
/\ t.after.objects=t.before.objects /\ t.after.finishedDelayedEffects=t.before.finishedDelayedEffects
[] t.receipt.execution.tag="ActualObjectTransition" ->
/\ t.after.turn=t.before.turn /\ t.after.turnPhase=t.before.turnPhase /\ t.after.control=t.before.control
/\ t.after.encounters=t.before.encounters /\ t.after.siteInspections=t.before.siteInspections /\ t.after.itemInspections=t.before.itemInspections
/\ t.after.finishedDelayedEffects=t.before.finishedDelayedEffects
[] t.receipt.execution.tag="ActualDelayedReturn" ->
/\ t.after=[t.before EXCEPT !.id=t.after.id,!.finishedDelayedEffects=t.after.finishedDelayedEffects]
/\ t.before.finishedDelayedEffects \subseteq t.after.finishedDelayedEffects
/\ t.receipt.execution.instruction.source=t.receipt.execution.source
/\ t.receipt.execution.return.tag="ExpectedEffectsProcedureReturn"
/\ t.receipt.execution.return.contextId=t.receipt.execution.id
/\ t.receipt.execution.return.instruction=t.receipt.execution.instruction
/\ t.receipt.execution.return.snapshotId=t.before.id
/\ t.receipt.execution.return.complete /\ t.receipt.execution.return.childrenReturned
[] OTHER -> FALSE
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: TurnSideBFace8
LifetimeWorldProjection910 · operator
reference-profile · input revision 2 · CC0 1.0
LifetimeWorldProjection910(w) ==
[id |-> w.id,objects |-> w.objects,gameStarted |-> w.gameStarted,cardFacts |-> w.cardFacts,playActivated |-> w.playActivated,
turn |-> w.turn,turnPhase |-> w.turnPhase,control |-> w.control,encounters |-> w.encounters,currentEncounter |-> w.currentEncounter,
siteInspections |-> w.siteInspections,itemInspections |-> w.itemInspections,finishedInstances |-> w.finishedInstances,finishedDelayedEffects |-> w.finishedDelayedEffects,
statedDurations |-> w.statedDurations,durationComparisons |-> w.durationComparisons,extenders |-> w.extenders,
present |-> w.present,activity |-> w.activity,points |-> w.points,barrierResponseCards |-> w.barrierResponseCards]Exact module download · Source bundle and reproduction instructions
LingeringBarrierSubtypes910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringBarrierSubtypes910(registry,world,target,base) ==
IF target \notin DOMAIN world.objects THEN base
ELSE base \cup {registry.effects[id].value : id \in {id \in ActiveLingeringIds910(registry,world) :
registry.effects[id].kind="Subtype" /\ registry.effects[id].target=target}}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveLingeringIds910
LingeringBaseAlive910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringBaseAlive910(effect,world) ==
CASE effect.baseDuration.kind="Timing" -> effect.baseDuration.ref \in LingeringTimingRefs910(world)
[] effect.baseDuration.kind="UntilResolution" -> effect.baseDuration.instance \notin world.finishedInstances
[] effect.baseDuration.kind="DelayedResolution" -> effect.baseDuration.effectId \notin world.finishedDelayedEffects
[] effect.baseDuration.kind="Stated" ->
/\ effect.id \in DOMAIN world.statedDurations
/\ world.statedDurations[effect.id].receipt=StatedDurationReceipt910(effect,world)
/\ world.statedDurations[effect.id].active
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringTimingRefs910, StatedDurationReceipt910
LingeringCheckpointFrame910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringCheckpointFrame910(ledger,cp,world) ==
[tag |-> "LingeringCheckpointCursor",checkpointId |-> cp.id,caller |-> ledger.checkpoints[cp.id].caller,
recognition |-> cp,snapshotId |-> world.id,point |-> "ProcedureCode88eda145024f",returned |-> FALSE]Exact module download · Source bundle and reproduction instructions
LingeringConditionalSnapshot910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringConditionalSnapshot910(snapshot,registry,ledger,world) ==
[SnapshotWithConditionalRegistry96(snapshot,ledger) EXCEPT
!.present=(@ \ DelayedConditionalAbilityIds96(ledger.effects)) \cup
{ledger.effects[id].definition.syntax.id : id \in DOMAIN ledger.effects \cap ActiveLingeringIds910(registry,world)}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveLingeringIds910, DelayedConditionalAbilityIds96, SnapshotWithConditionalRegistry96
LingeringConditionalWorld910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringConditionalWorld910(snapshot,ledger,world) ==
/\ snapshot.objects=world.objects /\ snapshot.points=world.points
/\ snapshot.activity=[world.activity EXCEPT !.instances=ConditionalActivityRows96(ledger.instances)]
/\ snapshot.present \ DelayedConditionalAbilityIds96(ledger.effects)=world.present \ DelayedConditionalAbilityIds96(ledger.effects)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityRows96, DelayedConditionalAbilityIds96
LingeringCreationKey910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringCreationKey910(context,operation) == <<context.imminenceId,context.currentRef,operation>>Exact module download · Source bundle and reproduction instructions
LingeringExecution910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringExecution910(context,origin,operation,actualExecution,world) ==
/\ context.phase="Resolving" /\ origin.kind="Instruction" /\ origin.plan.phase="Resolving"
/\ context.currentRef=InstructionWindowRef93(origin.plan)
/\ context.currentWorld=world.id /\ operation \in DOMAIN context.actualEffects
/\ context.actualEffects[operation].kind="CreateLingering"
/\ actualExecution.tag="LingeringEffectExecution" /\ actualExecution.contextId=context.id
/\ actualExecution.instruction=context.currentRef /\ actualExecution.operation=operation
/\ actualExecution.snapshotId=world.id /\ actualExecution.source=origin.plan.source
/\ actualExecution.blueprints=context.actualEffects[operation].blueprints /\ actualExecution.carriedOut
/\ ConditionalCreationInstruction96(origin.plan,origin.parent,origin.ruleStep)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCreationInstruction96, InstructionWindowRef93
LingeringObjectActive910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringObjectActive910(source,world) ==
IF source.kind # "Object" THEN FALSE
ELSE IF source.object \notin DOMAIN world.objects THEN FALSE
ELSE PlayCardDefaultActive4(world.objects[source.object],world.gameStarted,world.cardFacts,
source.object \in world.playActivated)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PlayCardDefaultActive4
LingeringReplacementIds910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringReplacementIds910(registry,world) ==
{id \in ActiveLingeringIds910(registry,world) : registry.effects[id].kind="Replacement"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveLingeringIds910
LingeringShorterThanTurn910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringShorterThanTurn910(effect,world) ==
IF effect.durationClass="Encounter" THEN TRUE
ELSE /\ effect.id \in DOMAIN world.durationComparisons
/\ world.durationComparisons[effect.id].tag="LingeringDurationComparison"
/\ world.durationComparisons[effect.id].effect=effect
/\ world.durationComparisons[effect.id].base=effect.baseDuration
/\ world.durationComparisons[effect.id].snapshotId=world.id
/\ world.durationComparisons[effect.id].turn=TimingRef9("Turn",world.turn.id)
/\ world.durationComparisons[effect.id].shorterThanTurnExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
LingeringStrength910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringStrength910(registry,world,target) ==
IF target \notin DOMAIN world.objects THEN 0 ELSE SumMap([id \in {id \in ActiveLingeringIds910(registry,world) : registry.effects[id].kind="Strength" /\ registry.effects[id].target=target} |-> registry.effects[id].value])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveLingeringIds910, SumMap
LingeringTimingRefs910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringTimingRefs910(world) ==
(IF TurnFrameValid5(world.turn) /\ ~world.turn.formalEnded THEN {TimingRef9("Turn",world.turn.id)} ELSE {}) \cup
(IF TraversalTimingPresent6(world.control.traversal) THEN {TimingRef9("SchemaAtom138",world.control.traversal.id)} ELSE {}) \cup
(IF world.turnPhase.id # 0 /\ ~world.turnPhase.ended /\ ~world.turn.formalEnded
THEN {TimingRef9("TurnPhase",world.turnPhase.id)} ELSE {}) \cup
(IF TraversalTimingPresent6(world.control.traversal) /\ world.control.traversal.phaseId \notin world.control.phaseEndedIds
THEN {TimingRef9("TraversalPhase",world.control.traversal.phaseId)} ELSE {}) \cup
{TimingRef9("TraversalPhase",id) : id \in {id \in DOMAIN world.encounters : EncounterTimingLive95(world.encounters[id],world.control)}} \cup
{TimingRef9("Inspection",id) : id \in {id \in DOMAIN world.siteInspections : world.siteInspections[id].active /\ ~world.siteInspections[id].complete}} \cup
{TimingRef9("ItemInspection",id) : id \in {id \in DOMAIN world.itemInspections : StillItemInspectioning7(world.itemInspections[id],world.objects)}}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterTimingLive95, TimingRef9, StillItemInspectioning7, TraversalTimingPresent6, TurnFrameValid5
LingeringWantsActive910 · operator
reference-profile · input revision 2 · CC0 1.0
LingeringWantsActive910(effect,effects,world) ==
IF effect.kind # "Choice" THEN OrdinaryLingeringAlive910(effect,world)
ELSE CASE effect.choicePolicy="Follow" ->
/\ Cardinality(effect.lingeringConsumers)=1
/\ \A id \in effect.lingeringConsumers :
/\ id \in DOMAIN effects /\ effects[id].kind#"Choice"
/\ effects[id].source=effect.source /\ effects[id].status="Active"
/\ OrdinaryLingeringAlive910(effects[id],world)
[] effect.choicePolicy="TurnOrSource" ->
LingeringObjectActive910(effect.source,world) /\ effect.creationTurn=world.turn.id /\ ~world.turn.formalEnded
[] effect.choicePolicy="SchemaAtom149" -> LingeringObjectActive910(effect.source,world)
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringObjectActive910, OrdinaryLingeringAlive910
LinkedTimingAbility911 · operator
reference-profile · input revision 2 · CC0 1.0
LinkedTimingAbility911(technique,unit,linked,context,operation,started,association) ==
/\ InstructionTechniqueValid911(technique) /\ unit \in technique.linked
/\ technique.units[unit].category="LinkedAbility" /\ technique.units[unit].definition=linked
/\ linked.syntax.id#technique.definition.syntax.id /\ linked.syntax.source=technique.source
/\ context.phase="Resolving" /\ operation \in DOMAIN context.actualEffects
/\ context.actualEffects[operation].kind="OpenTimingStructure"
/\ started.tag="ActualTimingStructureStarted" /\ TimingRefValid9(started.structure)
/\ started.parent=context.currentRef /\ started.source=technique.source /\ started.operation=operation
/\ association=[tag |-> "LinkedTimingAbility",definition |-> ConditionalKey96(linked),source |-> technique.source,
structure |-> started.structure,parentInstruction |-> context.currentRef,sourceUnit |-> unit]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96, InstructionTechniqueValid911, TimingRefValid9
LookExecutionSource911 · operator
reference-profile · input revision 2 · CC0 1.0
LookExecutionSource911(execution,objects,cardFacts) ==
IF execution.source.kind="Object" THEN
/\ execution.card \in DOMAIN cardFacts /\ execution.sourceSHA=cardFacts[execution.card].sourceSHA
/\ IF execution.source.object \in DOMAIN objects THEN objects[execution.source.object].card=execution.card ELSE TRUE
ELSE execution.card="NoValue" /\ execution.sourceSHA="0186148ecd6da8170b6555aa90d3f0115a8d5150d807078b75ac2339a2a1421e"Exact module download · Source bundle and reproduction instructions
LoseConditionalPendingKeys96 · operator
reference-profile · input revision 2 · CC0 1.0
LoseConditionalPendingKeys96(instances,keys) ==
[id \in DOMAIN instances |-> IF instances[id].status="Pending" /\ instances[id].definition \in keys
THEN [instances[id] EXCEPT !.status="Lost"] ELSE instances[id]]Exact module download · Source bundle and reproduction instructions
MaintainLingering9 · operator
reference-profile · input revision 2 · CC0 1.0
MaintainLingering9(before,after,actualExpiredEffectIds) ==
/\ actualExpiredEffectIds \subseteq DOMAIN before
/\ after = [id \in DOMAIN before \ actualExpiredEffectIds |-> before[id]]Exact module download · Source bundle and reproduction instructions
ModifyExpectedEffectValue99 · operator
reference-profile · input revision 2 · CC0 1.0
ModifyExpectedEffectValue99(before,after,id,delta) ==
/\ ExpectedValuePresent99(before,id) /\ delta \in Int
/\ SetExpectedEffectValue99(before,after,id,before[id].value+delta)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedValuePresent99, SetExpectedEffectValue99
ModifyValuePreservingSpecifications94 · operator
reference-profile · input revision 2 · CC0 1.0
ModifyValuePreservingSpecifications94(before,after,newAmount) ==
/\ before.amount \in Int /\ newAmount \in Int
/\ after=[before EXCEPT !.amount=newAmount]Exact module download · Source bundle and reproduction instructions
MustAdditionalDeclineBound912 · operator
reference-profile · input revision 2 · CC0 1.0
MustAdditionalDeclineBound912(declaration,site,world,feasibility,decision) ==
/\ declaration.form="Requirement" /\ decision.option \in DOMAIN declaration.options
/\ declaration.means="SchemaAtom016" \/ declaration.options[decision.option].means=declaration.means
/\ feasibility.options[decision.option].ordinary.failures={} /\ feasibility.options[decision.option].targetAlternatives#{}
/\ decision.decline.tag="ActualAdditionalCostDecline" /\ decision.decline.declaration=declaration
/\ decision.decline.site=site /\ decision.decline.snapshot=world /\ decision.decline.actor=declaration.actor
/\ decision.decline.option=declaration.options[decision.option]
/\ decision.decline.costs#{} /\ decision.decline.costs \subseteq declaration.options[decision.option].additionalCostsExact module download · Source bundle and reproduction instructions
MustChoiceCaller912 · operator
reference-profile · input revision 2 · CC0 1.0
MustChoiceCaller912(committed) == committed.site.checkpointCallerExact module download · Source bundle and reproduction instructions
MustFeasibilityBound912 · operator
reference-profile · input revision 2 · CC0 1.0
MustFeasibilityBound912(declaration,site,world,feasibility) ==
/\ feasibility.tag="CompleteMustFeasibility" /\ feasibility.declaration=declaration
/\ feasibility.site=site /\ feasibility.snapshot=world /\ feasibility.actor=declaration.actor
/\ DOMAIN feasibility.options=DOMAIN declaration.options
/\ \A option \in DOMAIN feasibility.options :
LET row == feasibility.options[option]
IN /\ row.tag="CurrentMustOptionProfile" /\ row.option=declaration.options[option]
/\ row.source=declaration.source /\ row.actor=declaration.actor /\ row.site=site
/\ row.snapshot=world /\ row.targetSpecification=row.option.targetSpecification
/\ row.paymentSpecification=row.option.paymentSpecification
/\ row.ordinary.tag="OrdinaryOptionLegality" /\ row.ordinary.option=row.option /\ row.ordinary.site=site
/\ row.ordinary.snapshot=world /\ row.ordinary.source=declaration.source /\ row.ordinary.actor=declaration.actor
/\ row.ordinary.failures \subseteq {"Prohibited","Inactive","WrongTiming","OnceUsed","OneShotUsed","MissingReferent","UnavailableAbility"}
/\ \A targets \in row.targetAlternatives : targets \subseteq DOMAIN world.objects
/\ \A plan \in row.paymentAlternatives : DOMAIN plan \subseteq DOMAIN world.resources /\ \A resource \in DOMAIN plan : plan[resource] \in NatExact module download · Source bundle and reproduction instructions
Resolved project definitions: row
MustFullyResolvable912 · operator
reference-profile · input revision 2 · CC0 1.0
MustFullyResolvable912(declaration,world,feasibility) ==
{option \in DOMAIN declaration.options :
(declaration.form="Choice" \/ declaration.means="SchemaAtom016" \/ declaration.options[option].means=declaration.means) /\
feasibility.options[option].ordinary.failures={} /\ feasibility.options[option].targetAlternatives#{} /\
\E plan \in feasibility.options[option].paymentAlternatives : MustResourcePlanAffordable912(plan,world)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: MustResourcePlanAffordable912
MustResourcePlanAffordable912 · operator
reference-profile · input revision 2 · CC0 1.0
MustResourcePlanAffordable912(plan,world) ==
/\ DOMAIN plan \subseteq DOMAIN world.resources
/\ \A resource \in DOMAIN plan : plan[resource] \in Nat /\ plan[resource]<=world.resources[resource]Exact module download · Source bundle and reproduction instructions
MustSourceBound912 · operator
reference-profile · input revision 2 · CC0 1.0
MustSourceBound912(declaration,site,world,cardFacts) ==
/\ world.tag="CurrentMustWorld" /\ world.id \in Nat \ {0}
/\ \A resource \in DOMAIN world.resources : world.resources[resource] \in Nat
/\ declaration.tag="NormalizedMustDeclaration" /\ declaration.card \in DOMAIN cardFacts
/\ declaration.sourceSHA=cardFacts[declaration.card].sourceSHA
/\ declaration.source=declaration.definition.syntax.source
/\ declaration.controller=declaration.definition.syntax.controller /\ declaration.actor \in SetupPlayers
/\ declaration.source.kind="Object" /\ declaration.source.object \in Nat \ {0}
/\ IF declaration.source.object \in DOMAIN world.objects
THEN world.objects[declaration.source.object].card=declaration.card ELSE declaration.origin="Instruction"
/\ AbilityTextValid93(declaration.definition.syntax)
/\ site.tag="CurrentMustDecisionSite" /\ site.id \in Nat \ {0} /\ site.snapshotId=world.id
/\ CASE declaration.origin="Instruction" ->
/\ declaration.definition.syntax.kind \in {"Paid","Conditional","Play","BarrierInstruction"}
/\ site.context.phase="Resolving" /\ site.context.currentWorld=world.id
/\ site.context.currentRef=InstructionWindowRef93(site.plan)
/\ site.context.currentRef.source=declaration.source /\ site.plan.phase="Resolving"
/\ AbilityIsResolving9(site.ability) /\ site.ability.kind=declaration.definition.syntax.kind
/\ InstructionPlanMatches93(site.plan,site.ability,site.ability.cursor)
/\ site.operation \in DOMAIN site.context.actualEffects
/\ site.context.actualEffects[site.operation].must=declaration
/\ site.context.actualEffects[site.operation].chooser=declaration.actor
/\ site.checkpointSource=[source |-> declaration.source,instruction |-> site.context.currentRef,caller |-> site.checkpointCaller]
[] declaration.origin="ActionRestriction" ->
/\ declaration.definition.syntax.kind="Static"
/\ StaticAbilityActive94(declaration.definition.activity,declaration.definition.syntax,world.objects,world.present,
world.cardActivity[declaration.source.object],world.activity,world.points)
/\ site.window.kind="NeutralValue00001" /\ site.window.open /\ site.window.stage="Ready"
/\ site.window.priority=declaration.actor /\ site.window.site.turnId=world.turn.id
/\ site.window.site.actionPoints>0 /\ site.window.site.timingLive
/\ declaration.actionScope \in {"FirstActionPoint","AnyAction"}
/\ declaration.actionScope="FirstActionPoint" => world.actionPointsSpent=0
/\ site.window.site.route="Turn" /\ site.window.site.step \in {"ProcedureCode0e20572a4bab","ProcedureCode989abc27e0c6"}
/\ declaration=site.activeRequirement
[] OTHER -> FALSE
/\ declaration.form \in {"Requirement","Choice"} /\ DOMAIN declaration.options#{}
/\ declaration.form="Choice" => Cardinality(DOMAIN declaration.options)>=2
/\ declaration.means \in STRING /\ declaration.goal \in STRING
/\ \A option \in DOMAIN declaration.options :
/\ declaration.options[option].id=option /\ declaration.options[option].means \in STRING
/\ declaration.options[option].additionalCosts \subseteq STRING
/\ declaration.form="Requirement" => declaration.options[option].goal=declaration.goalExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityIsResolving9, AbilityTextValid93, InstructionPlanMatches93, InstructionWindowRef93, StaticAbilityActive94, SetupPlayers
NestedBarrierInstructionInvocation98 · operator
reference-profile · input revision 2 · CC0 1.0
NestedBarrierInstructionInvocation98(p,parentPlan,parent,ruleStep,actualEffect) ==
/\ p.origin="Instruction" /\ ConditionalCreationInstruction96(parentPlan,parent,ruleStep)
/\ p.invocation=actualEffect /\ actualEffect.tag="ExplicitResolveBarrierInstruction"
/\ actualEffect.instruction=InstructionWindowRef93(parentPlan) /\ p.caller=parentPlan.id
/\ actualEffect.barrierCard=p.barrierCard /\ actualEffect.barrierInstruction=p.barrierInstruction /\ actualEffect.structure=p.structure
/\ actualEffect.encounter=p.encounter /\ actualEffect.authorizedExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCreationInstruction96, InstructionWindowRef93
NewBarrierInstructionBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
NewBarrierInstructionBarrierInstruction98(id,sub,d,e,owner,zone) ==
[id |-> id,barrierInstruction |-> sub,encounter |-> e.id,barrierCard |-> e.barrierCard,definition |-> d,payload |-> d,owner |-> owner,origin |-> "Encounter",caller |-> e.id,structure |-> TimingRef9("TraversalPhase",e.id),invocation |-> EmptyOrder98,
ability |-> OpenAbilityResolution9(id,"BarrierInstruction",ObjectAbilitySource9(e.barrierCard),zone,d.instructions,e.id),
phase |-> "BarrierInstructionImminent",revision |-> 0,prevented |-> FALSE,checkpoint |-> 0,replacements |-> <<>>]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EmptyOrder98, ObjectAbilitySource9, OpenAbilityResolution9, TimingRef9
NewBarrierInstructionLoop98 · operator
reference-profile · input revision 2 · CC0 1.0
NewBarrierInstructionLoop98(e,owner,declared,exampleFamily062) ==
[encounter |-> e.id,barrierCard |-> e.barrierCard,owner |-> owner,exampleFamily062 |-> exampleFamily062,
initialOrder |-> declared,initialEligible |-> SubIds6(declared),handled |-> {},resolved |-> {},prevented |-> {},
current |-> 0,usedInstances |-> {},history |-> <<>>]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
NewBarrierInstructionOrder98 · operator
reference-profile · input revision 2 · CC0 1.0
NewBarrierInstructionOrder98(barrierCard,printedOrder,definitions,textKeys) ==
[barrierCard |-> barrierCard,order |-> printedOrder,present |-> SubIds6(printedOrder),spine |-> printedOrder,usedIds |-> SubIds6(printedOrder),
definitions |-> definitions,provenance |-> [id \in SubIds6(printedOrder) |-> [kind |-> "Printed",effect |-> 0,parent |-> 0,
printedSlot |-> OrderPosition98(printedOrder,id),born |-> 0,tie |-> OrderPosition98(printedOrder,id),textKey |-> textKeys[id]]],
printedText |-> [slot \in 1..Len(printedOrder) |-> [definition |-> definitions[printedOrder[slot]],key |-> textKeys[printedOrder[slot]]]],
applications |-> EmptyOrder98,activeApplications |-> {},clock |-> 0,history |-> <<>>,decisions |-> EmptyOrder98]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EmptyOrder98, OrderPosition98, SubIds6
NewConditionalInstance96 · operator
reference-profile · input revision 2 · CC0 1.0
NewConditionalInstance96(id,d,cp,eventId,windowId,group) ==
[member |-> ConditionalMember96(id,d,windowId,group),definition |-> ConditionalKey96(d),definitionCopy |-> d,status |-> "Pending",
primaryKind |-> d.primaryKind,activationEpoch |-> cp.processingSnapshot.activationEpoch[ConditionalKey96(d)],
checkpointId |-> cp.id,occurrence |-> eventId,hadSnapshot |-> cp.previousSnapshot,
expected |-> [index \in {} |-> index],used |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96, ConditionalMember96
NewConditionalLedger96 · operator
reference-profile · input revision 2 · CC0 1.0
NewConditionalLedger96(initialSnapshot) ==
[lastCheckpoint |-> 0,checkpointIds |-> {},checkpoints |-> [id \in {} |-> id],serial |-> 0,lastSnapshot |-> initialSnapshot,processed |-> {},instances |-> [id \in {} |-> id],
throttle |-> [key \in {} |-> key],stepSerial |-> 0,activationEpoch |-> initialSnapshot.activationEpoch,activationSerial |-> initialSnapshot.activationSerial,interruptRecognitions |-> {},usedDelayedEffects |-> {},usedDelayedDefinitions |-> {},effects |-> [id \in {} |-> id],holds |-> [key \in {} |-> key]]Exact module download · Source bundle and reproduction instructions
NewEncounterBarrierInstructionOrderPublication98 · operator
reference-profile · input revision 2 · CC0 1.0
NewEncounterBarrierInstructionOrderPublication98(encounter,before,after) ==
LET step == after.history[Len(after.history)]
IN [tag |-> "AppliedEncounterBarrierInstructionOrder",encounterBefore |-> encounter,beforeOrderState |-> before,afterOrderState |-> after,
appliedStep |-> step,appliedOrderingDecision |-> after.decisions[step.decision]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: step
NewExpectedContext99 · operator
reference-profile · input revision 2 · CC0 1.0
NewExpectedContext99(id,entryId,origin,world,description,initial,owner) ==
[id |-> id,imminenceId |-> entryId,initialRef |-> OriginReference99(origin),currentRef |-> OriginReference99(origin),
openingRef |-> OriginReference99(origin),initialWorld |-> world.id,currentWorld |-> world.id,initialPeriods |-> ActualWouldPeriods99(world),
initialWouldGroups |-> [effect \in DOMAIN initial |-> DescriptionWouldGroups99(entryId,description)[effect]],
entry |-> world.entries[entryId],clearance |-> [field \in {} |-> field],site |-> [field \in {} |-> field],actualEffects |-> [effect \in {} |-> effect],
description |-> description,initialEffects |-> initial,preparedEffects |-> initial,
state |-> [NewReplacementState99(description.effects) EXCEPT !.effects=initial,!.ancestry=[effect \in DOMAIN initial |-> {}]],owner |-> owner,
ancestryArchive |-> [effect \in DOMAIN description.effects |-> {}],
templates |-> description.effects,removedEffects |-> {},retiredEffects |-> {},
phase |-> "Replacing",conditionalIds |-> {},conditionalDefinitions |-> [key \in {} |-> key],openingMembers |-> [effect \in {} |-> effect],
wouldRows |-> [root \in {} |-> root],wouldGroups |-> DescriptionWouldGroups99(entryId,description),windowId |-> 0,group |-> 0,modifications |-> <<>>,modificationIds |-> {},temporaryReplacements |-> [effect \in {} |-> effect]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActualWouldPeriods99, DescriptionWouldGroups99, NewReplacementState99, OriginReference99
NewExpectedRegistry99 · operator
reference-profile · input revision 2 · CC0 1.0
NewExpectedRegistry99 == [contexts |-> [id \in {} |-> id],entryIds |-> {},usedContextIds |-> {}]Exact module download · Source bundle and reproduction instructions
NewInstructionRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
NewInstructionRuntime911(id,p,kind,sourceZone,caller) ==
[id |-> id,technique |-> p,pc |-> p.entry,visited |-> <<>>,choices |-> [i \in {} |-> i],
ability |-> OpenAbilityResolution9(id,kind,p.source,sourceZone,<<p.entry>>,caller),
phase |-> "Targets",checkpoint |-> 0,pause |-> [id |-> 0],pauseKeys |-> {},boundary |-> [i \in {} |-> i]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpenAbilityResolution9
NewInstructionSuppressInstructionIntent98 · operator
reference-profile · input revision 2 · CC0 1.0
NewInstructionSuppressInstructionIntent98(plan,e,classification) ==
[tag |-> "InstructionSuppressInstructionTargetContext",instruction |-> InstructionWindowRef93(plan),encounter |-> EncounterSuppressInstructionRef98(e),classification |-> classification]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterSuppressInstructionRef98, InstructionWindowRef93
NewLifetimeAuthority910 · operator
reference-profile · input revision 2 · CC0 1.0
NewLifetimeAuthority910(w) ==
[current |-> LifetimeWorldProjection910(w),order |-> <<w.id>>,worlds |-> [id \in {w.id} |-> LifetimeWorldProjection910(w)],
transitions |-> [id \in {} |-> id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeWorldProjection910
NewLingeringEffect910 · operator
reference-profile · input revision 2 · CC0 1.0
NewLingeringEffect910(id,blueprint,context,operation,world) ==
[id |-> id,kind |-> blueprint.kind,source |-> context.currentRef.source,
creation |-> LingeringCreationKey910(context,operation),creationTurn |-> world.turn.id,
originKind |-> blueprint.originKind,target |-> blueprint.target,value |-> blueprint.value,
baseDuration |-> blueprint.baseDuration,durationClass |-> blueprint.durationClass,
choicePolicy |-> IF blueprint.kind="Choice" THEN ChoicePolicy910(blueprint) ELSE "NoValue",
choiceKey |-> blueprint.choiceKey,lingeringConsumers |-> blueprint.lingeringConsumers,
otherConsumers |-> blueprint.otherConsumers,definitionId |-> blueprint.definitionId,status |-> "Active"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ChoicePolicy910, LingeringCreationKey910
NewLingeringRegistry910 · operator
reference-profile · input revision 2 · CC0 1.0
NewLingeringRegistry910 ==
[effects |-> [id \in {} |-> id],usedEffects |-> {},creations |-> {},cleanupIds |-> {}]Exact module download · Source bundle and reproduction instructions
NewMustDecision912 · operator
reference-profile · input revision 2 · CC0 1.0
NewMustDecision912(id,declaration,site) ==
[id |-> id,declaration |-> declaration,site |-> site,phase |-> "Choosing",chosen |-> "NoValue",disposition |-> "NoValue",
choiceSnapshot |-> 0,feasibleAtChoice |-> {},decision |-> [key \in {} |-> key],result |-> [key \in {} |-> key]]Exact module download · Source bundle and reproduction instructions
NewOccurrenceRuntime912 · operator
reference-profile · input revision 2 · CC0 1.0
NewOccurrenceRuntime912(base,spec) ==
[id |-> base.id,technique |-> base.technique,specification |-> spec,metadata |-> OccurrenceOwnerMetadata912(base),
ability |-> base.ability,phase |-> base.phase,current |-> base.pc,pc |-> base.pc,trace |-> <<>>,
occurrences |-> [id \in {base.pc} |-> [id |-> id,sourceNode |-> base.pc,pass |-> 0]],usedOccurrences |-> {base.pc},
choices |-> [id \in {} |-> id],checkpoint |-> 0,pause |-> [id |-> 0],pauseKeys |-> {},boundary |-> [id \in {} |-> id],
repeat |-> [pass |-> 0,requested |-> FALSE,captured |-> FALSE,total |-> 0,remaining |-> 0],
modal |-> OccurrenceModalInitial912(spec,0)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrenceModalInitial912, OccurrenceOwnerMetadata912
NewOpeningInterruptInstance99 · operator
reference-profile · input revision 2 · CC0 1.0
NewOpeningInterruptInstance99(id,d,snapshot,ledger,context,windowId,group) ==
[member |-> [ConditionalMember96(id,d,windowId,group) EXCEPT !.interrupt=TRUE],definition |-> ConditionalKey96(d),definitionCopy |-> d,
status |-> "Pending",primaryKind |-> d.primaryKind,activationEpoch |-> snapshot.activationEpoch[ConditionalKey96(d)],
checkpointId |-> ledger.lastCheckpoint,occurrence |-> context.imminenceId,hadSnapshot |-> ledger.lastSnapshot,expected |-> [i \in {} |-> i],used |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96, ConditionalMember96
NewPersistentRegistry912 · operator
reference-profile · input revision 2 · CC0 1.0
NewPersistentRegistry912(base) == ReplacementOverlay99(base,
[persistent |-> [key \in {} |-> key],persistentRetireIds |-> {}])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
NewPlayCohort97 · operator
reference-profile · input revision 2 · CC0 1.0
NewPlayCohort97(f,text,invocation) ==
[playId |-> f.id,source |-> ObjectAbilitySource9(f.object),transaction |-> f.transaction,owner |-> invocation.owner,
sourceText |-> text,order |-> PrintedPlayOrder97(text),cursor |-> 1,dispositions |-> EmptyPlay97,
id |-> 0,ability |-> PlayIdleAbility97(ObjectAbilitySource9(f.object),f.id),checkpoint |-> 0,usedInstances |-> {},
phase |-> IF PrintedPlayOrder97(text)= <<>> THEN "Complete" ELSE "Ready"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EmptyPlay97, ObjectAbilitySource9, PlayIdleAbility97, PrintedPlayOrder97
NewPriorityWindow9 · operator
reference-profile · input revision 2 · CC0 1.0
NewPriorityWindow9(id,kind,site,instances,group,beginning,instruction,effectRevision) ==
[id |-> id,kind |-> kind,site |-> site,open |-> TRUE,stage |-> "NeedCheckpoint",
active |-> site.active,priority |-> IF kind = "MidItemInspection" THEN "SideB" ELSE site.active,
reception |-> 1,checkpoint |-> 0,previousPass |-> FALSE,busy |-> NoPriorityOption9,busyTransaction |-> 0,
members |-> instances,group |-> group,pending |-> DOMAIN instances,lostPending |-> {},triggered |-> {},
beginning |-> beginning,instruction |-> instruction,effectRevision |-> effectRevision]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NoPriorityOption9
NewReplacementState99 · operator
reference-profile · input revision 2 · CC0 1.0
NewReplacementState99(effects) ==
[effects |-> effects,ancestry |-> [id \in DOMAIN effects |-> {}],appliedPairs |-> {},usedEffectIds |-> DOMAIN effects,transformations |-> <<>>]Exact module download · Source bundle and reproduction instructions
NewSimultaneousEvaluation912 · operator
reference-profile · input revision 2 · CC0 1.0
NewSimultaneousEvaluation912(world,printed,effects,lifetimes) ==
[tag |-> "SimultaneousCharacteristics",world |-> world,printed |-> printed,effects |-> effects,lifetimes |-> lifetimes,
chars |-> CharacteristicInitial912(printed),outputs |-> [emptyId \in {} |-> emptyId],waiting |-> DOMAIN effects,applied |-> <<>>,skipped |-> {},trace |-> <<>>]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CharacteristicInitial912
NewSuppressInstructionIntent98 · operator
reference-profile · input revision 2 · CC0 1.0
NewSuppressInstructionIntent98(p,e,classification) ==
[tag |-> "SuppressInstructionActivation",definition |-> p.definition,abilityInstance |-> p.id,ability |-> p.definition.syntax.id,source |-> p.ability.source,
windowId |-> p.windowId,transactionId |-> p.transaction,encounter |-> EncounterSuppressInstructionRef98(e),classification |-> classification]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterSuppressInstructionRef98
NewSuppressInstructionSelection98 · operator
reference-profile · input revision 2 · CC0 1.0
NewSuppressInstructionSelection98(intent,imminentPlan,targets) ==
[tag |-> "SuppressInstructionTargets",NeutralValue00003 |-> intent,instruction |-> InstructionWindowRef93(imminentPlan),targets |-> targets]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93
NewWouldAccounting99 · operator
reference-profile · input revision 2 · CC0 1.0
NewWouldAccounting99 ==
[groups |-> [key \in {} |-> key],evidence |-> <<>>,serial |-> 0,observationIds |-> {},observations |-> [key \in {} |-> key],latest |-> [key \in {} |-> key]]Exact module download · Source bundle and reproduction instructions
NewWouldHistory99 · operator
reference-profile · input revision 2 · CC0 1.0
NewWouldHistory99 == [openings |-> EmptyWould99,occurrences |-> EmptyWould99,usedOccurrenceIds |-> {},usedOpeningIds |-> {},usedImminenceIds |-> {},serial |-> 0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EmptyWould99
NewWouldOccurrence99 · operator
reference-profile · input revision 2 · CC0 1.0
NewWouldOccurrence99(row,opening,periods,serial) ==
[id |-> row.id,root |-> row.root,imminenceId |-> opening.imminenceId,context |-> WouldContextKey99(opening.context),openingId |-> opening.id,
snapshotId |-> opening.snapshotId,effect |-> row.effect,periods |-> DOMAIN periods,serial |-> serial]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldContextKey99
NextChainMembers9 · operator
reference-profile · input revision 2 · CC0 1.0
NextChainMembers9(stack) == IF Len(stack)=0 THEN {} ELSE stack[Len(stack)].pendingExact module download · Source bundle and reproduction instructions
NextLifetimeWorld910 · operator
reference-profile · input revision 2 · CC0 1.0
NextLifetimeWorld910(registry,a) == a.worlds[a.order[registry.frontier.position+1]]Exact module download · Source bundle and reproduction instructions
NoBarrierInstructionInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
NoBarrierInstructionInterrupt98(before,after,stack,noModifiers,r) ==
/\ BarrierInstructionImminent98(before) /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ noModifiers.tag="NoBarrierInstructionInterruptModifiers" /\ noModifiers.barrierInstruction=BarrierInstructionWindowRef98(before)
/\ noModifiers.conditionalInstances={} /\ noModifiers.paidInterruptAbilities={}
/\ BarrierInstructionInterruptReturnBound98(before,r) /\ r.windowId=0 /\ r.openingRevision=before.revision
/\ after=[before EXCEPT !.phase="FirstTargets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionImminent98, BarrierInstructionInterruptReturnBound98, BarrierInstructionOwnerAtTop98, BarrierInstructionWindowRef98
NoInstructionControl911 · operator
reference-profile · input revision 2 · CC0 1.0
NoInstructionControl911 == [mode |-> "NoValue"]Exact module download · Source bundle and reproduction instructions
NoInstructionInterrupt93 · operator
reference-profile · input revision 2 · CC0 1.0
NoInstructionInterrupt93(plan,ability,actualRuleStep,actualNoModifiers,actualReturn) ==
/\ InstructionImminentAtOrigin93(plan,ability,actualRuleStep)
/\ actualNoModifiers.tag="NoInstructionInterruptModifiers" /\ actualNoModifiers.instruction=InstructionWindowRef93(plan)
/\ actualNoModifiers.conditionalInstances={} /\ actualNoModifiers.paidInterruptAbilities={}
/\ InstructionInterruptReturnMatches93(plan,actualReturn) /\ actualReturn.windowId=0
/\ actualReturn.openingRevision=plan.revisionExact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionImminentAtOrigin93, InstructionInterruptReturnMatches93, InstructionWindowRef93
NoPersistentPrepared912 · operator
reference-profile · input revision 2 · CC0 1.0
NoPersistentPrepared912(registry,before,after,origin,world,history,ledger,stack,site,cardFacts,authority) ==
/\ PersistentInterruptWorld912(registry,world,ledger,authority)
/\ before.phase="Prepared" /\ ExpectedContextOrigin99(before,origin) /\ ExpectedContextWorld99(before,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ WouldViewCurrent99(history,before,world)
/\ site.turnId=world.turn.id /\ site.active=world.turn.owner
/\ before.conditionalIds={}
/\ LET proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(stack,site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)
IN /\ PersistentOpeningPaidRelevant912(registry,before,world,history,proposed)={}
/\ after=[before EXCEPT !.phase="Cleared",!.site=site]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: proposed, BarrierInstructionOwnerAtTop98, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, PersistentInterruptWorld912, PersistentOpeningPaidRelevant912, WouldViewCurrent99
NoPreparedInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
NoPreparedInterrupt99(before,after,origin,world,history,ledger,stack,site,cardFacts) ==
/\ before.phase="Prepared" /\ ExpectedContextOrigin99(before,origin) /\ ExpectedContextWorld99(before,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ WouldViewCurrent99(history,before,world)
/\ site.turnId=world.turn.id /\ site.active=world.turn.owner
/\ before.conditionalIds={}
/\ LET proposed == NewPriorityWindow9(before.windowId,"Interrupt",PriorityOpeningSite9(stack,site),before.openingMembers,
before.group,NoTimingRef9,before.openingRef,before.openingRef.revision+1)
IN /\ OpeningPaidRelevant99(before,world,history,proposed)={}
/\ after=[before EXCEPT !.phase="Cleared",!.site=site]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: proposed, BarrierInstructionOwnerAtTop98, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, OpeningPaidRelevant99, WouldViewCurrent99
NoPriorityOption9 · operator
reference-profile · input revision 2 · CC0 1.0
NoPriorityOption9 == [id |-> 0,kind |-> "NoValue",controller |-> "NoValue",ability |-> 0,instance |-> 0,
source |-> RuleAbilitySource9("NoValue"),target |-> 0,newStructures |-> {}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: RuleAbilitySource9
NoTimingRef9 · operator
reference-profile · input revision 2 · CC0 1.0
NoTimingRef9 == TimingRef9("NoValue",0)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
NormalPlayCleanup97 · operator
reference-profile · input revision 2 · CC0 1.0
NormalPlayCleanup97(beforePlay,afterPlay,beforeObjects,afterObjects,successor,usedIds,cleanup) ==
/\ beforePlay.object \in DOMAIN beforeObjects /\ beforeObjects[beforePlay.object].form="Card"
/\ beforeObjects[beforePlay.object].zone="Play" /\ beforeObjects[beforePlay.object].host=0
/\ FinishPlayCleanup8(beforePlay,afterPlay,beforeObjects,FALSE,FALSE,cleanup,EmptyPlay97,EmptyPlay97,EmptyPlay97)
/\ CardBatchTransfer8(beforeObjects,afterObjects,{beforePlay.object},[id \in {beforePlay.object} |-> successor],usedIds,
beforePlay.actor \o "Discard","Up",[id \in {beforePlay.object} |-> "Discard"])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EmptyPlay97, CardBatchTransfer8, FinishPlayCleanup8
NormalPlayResolvedOccurrence97 · operator
reference-profile · input revision 2 · CC0 1.0
NormalPlayResolvedOccurrence97(beforeCleanup,afterCleanup,afterResolved,beforeObjects,afterObjects,successor,usedIds,cleanup,rawEvents,originalDefinition,currentDefinition,snapshot,occurrenceId,event,cohort) ==
/\ NormalPlayCleanup97(beforeCleanup,afterCleanup,beforeObjects,afterObjects,successor,usedIds,cleanup)
/\ MeetPlayResolvedConditions8(afterCleanup,afterResolved,rawEvents)
/\ cohort.playId=beforeCleanup.id /\ cohort.source=ObjectAbilitySource9(beforeCleanup.object)
/\ cohort.phase="Complete" /\ cohort.sourceText.object=beforeCleanup.object /\ cohort.sourceText.playId=beforeCleanup.id
/\ cohort.sourceText.card=beforeObjects[beforeCleanup.object].card
/\ originalDefinition.syntax.id \in DOMAIN cohort.sourceText.definitions
/\ originalDefinition=cohort.sourceText.definitions[originalDefinition.syntax.id]
/\ ConditionalDefinitionValid96(originalDefinition) /\ originalDefinition.syntax.source=ObjectAbilitySource9(beforeCleanup.object)
/\ originalDefinition.activity.provider="Printed" /\ originalDefinition.trigger.subject="SchemaAtom149"
/\ "PlayResolved" \in ConditionalEventKinds96(originalDefinition)
/\ currentDefinition=ReboundConditionalDefinition96(originalDefinition,successor)
/\ afterCleanup.actor \o "Discard" \in currentDefinition.activity.rulesOnlyZones
/\ snapshot.objects=afterObjects /\ ConditionalKey96(currentDefinition) \in DOMAIN snapshot.definitions
/\ snapshot.definitions[ConditionalKey96(currentDefinition)]=currentDefinition
/\ occurrenceId \in Nat \ {0}
/\ LET raw == [tag |-> "PlayResolved",object |-> afterCleanup.object,kind |-> afterCleanup.kind,actor |-> afterCleanup.actor,playId |-> afterCleanup.id]
IN /\ rawEvents={raw}
/\ event.id=occurrenceId /\ event.kind="PlayResolved" /\ event.object=currentDefinition.syntax.source.object
/\ event.actor=raw.actor /\ event.side=raw.actor /\ event.snapshot=snapshot /\ event.effectId=raw.playId
/\ event.scopeKind="Global" /\ event.rawOrigin=rawExact module download · Source bundle and reproduction instructions
Resolved project definitions: raw, ConditionalDefinitionValid96, ConditionalEventKinds96, ConditionalKey96, NormalPlayCleanup97, ObjectAbilitySource9, ReboundConditionalDefinition96, MeetPlayResolvedConditions8
NormalizePaidConverted95 · operator
reference-profile · input revision 2 · CC0 1.0
NormalizePaidConverted95(stack,p,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,actualNormalization) ==
LET due == PaidConvertedAsideIds95(p,beforeObjects,beforeTransits)
IN /\ p.phase="CostCheckpoint" /\ p.costPaid /\ PaidProcedureAtTop95(stack,p)
/\ actualNormalization.tag="PaidCostConversion" /\ actualNormalization.abilityInstance=p.id /\ actualNormalization.transactionId=p.transaction
/\ actualNormalization.sources=due /\ actualNormalization.beforeObjects=beforeObjects /\ actualNormalization.afterObjects=afterObjects
/\ actualNormalization.complete /\ actualNormalization.normalConversionAndRetireRules
/\ FreshSuccessors8(due,successors,usedIds) /\ DOMAIN beforeObjects \subseteq usedIds
/\ DOMAIN afterObjects=(DOMAIN beforeObjects \ due) \cup {successors[id] : id \in due}
/\ \A id \in DOMAIN beforeObjects \ due : afterObjects[id]=beforeObjects[id]
/\ \A id \in due :
LET new == successors[id]
IN afterObjects[new].form="Card" /\ afterObjects[new].card=beforeObjects[id].card
/\ afterObjects[new].zone=actualNormalization.ownerDiscard[id]
/\ actualNormalization.ownerDiscard[id] \in {"SideADiscard","SideBDiscard"}
/\ ~afterObjects[new].deployed /\ afterObjects[new].host=0
/\ afterTransits=[id \in DOMAIN beforeTransits \ due |-> beforeTransits[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: due, new, PaidProcedureAtTop95, FreshSuccessors8
NormalizeQuantityGroup912 · operator
reference-profile · input revision 2 · CC0 1.0
NormalizeQuantityGroup912(g,reference,world,cardFacts,emissions) ==
QuantitySourceBound912(g,reference,world,cardFacts) /\ emissions=QuantityEmissions912(g)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityEmissions912, QuantitySourceBound912
NormalizedSubCount98 · operator
reference-profile · input revision 2 · CC0 1.0
NormalizedSubCount98(before,application,actualCount,tag) ==
/\ actualCount.tag=tag /\ actualCount.barrierCard=before.barrierCard /\ actualCount.count \in Nat
/\ actualCount.application=application /\ actualCount.snapshotId \in Nat \ {0}
/\ IF application=0 THEN TRUE ELSE
actualCount.ability=before.applications[application].definition.ability.syntax.id /\ actualCount.source=before.applications[application].definition.ability.syntax.sourceExact module download · Source bundle and reproduction instructions
NormalizedSuppressInstructionClassification98 · operator
reference-profile · input revision 2 · CC0 1.0
NormalizedSuppressInstructionClassification98(d,objects,cardFacts,classification) ==
/\ d.syntax.kind="Paid" /\ d.canSuppressBarrierInstructions /\ d.syntax.source.kind="Object"
/\ d.syntax.source.object \in DOMAIN objects
/\ classification.tag="NormalizedSuppressInstructionInstruction" /\ classification.ability=d.syntax.id /\ classification.source=d.syntax.source
/\ classification.card=objects[d.syntax.source.object].card /\ classification.sourceSHA=cardFacts[classification.card].sourceSHA
/\ classification.instruction \in SubIds6(d.instructions)
/\ classification.mode \in {"Ordinary","All","Hook"} /\ classification.selector \in {"SchemaAtom016","Last"}
/\ classification.minimumTargets \in Nat /\ classification.maximumTargets \in Nat
/\ classification.minimumTargets<=classification.maximumTargets
/\ IF classification.mode="Ordinary" THEN classification.maximumTargets>0
ELSE IF classification.mode="Hook" THEN classification.minimumTargets=1 /\ classification.maximumTargets=1 /\ classification.selector="SchemaAtom016"
ELSE classification.minimumTargets=0 /\ classification.maximumTargets=0 /\ classification.selector="SchemaAtom016"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
NumericFinal912 · operator
reference-profile · input revision 2 · CC0 1.0
NumericFinal912(default,modifiers) ==
LET setters == {m.value : m \in {m \in modifiers : m.operation="Set"}}
supported == Cardinality(setters)<=1 /\ \A m \in modifiers : IRField911(m,"known",TRUE)
result == IF ~supported THEN 0 ELSE
(IF setters={} THEN default ELSE CHOOSE value \in setters : TRUE)
+SumSimultaneous912({[id |-> m.id,amount |-> m.value] : m \in {m \in modifiers : m.operation="Increase"}})
-SumSimultaneous912({[id |-> m.id,amount |-> m.value] : m \in {m \in modifiers : m.operation="SchemaAtom100"}})
IN [status |-> IF supported THEN "Supported" ELSE "NormalizationRequired",value |-> result]Exact module download · Source bundle and reproduction instructions
ObjectAbilitySource9 · operator
reference-profile · input revision 2 · CC0 1.0
ObjectAbilitySource9(object) == [kind |-> "Object",object |-> object,rule |-> "NoValue"]Exact module download · Source bundle and reproduction instructions
ObserveConditionalActivity96 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveConditionalActivity96(before,candidate,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot) ==
/\ ConditionalSnapshotBound96(beforeSnapshot,before) /\ ConditionalRegistrySnapshotBound96(afterSnapshot,candidate)
/\ ConditionalDefinitionsStable96(beforeSnapshot,afterSnapshot)
/\ \A effect \in DOMAIN before.effects \cap DOMAIN candidate.effects : before.effects[effect]=candidate.effects[effect]
/\ LET lost == ConditionalActivityLosses96(beforeSnapshot,afterSnapshot)
keys == DOMAIN before.activationEpoch \cup DOMAIN beforeSnapshot.definitions \cup DOMAIN afterSnapshot.definitions
epochs == [key \in keys |-> (IF key \in DOMAIN before.activationEpoch THEN before.activationEpoch[key] ELSE 0)+(IF key \in lost THEN 1 ELSE 0)]
serial == before.activationSerial+(IF lost={} THEN 0 ELSE 1)
observed == [candidate EXCEPT !.activationEpoch=epochs,!.activationSerial=serial]
IN /\ afterSnapshot.activationEpoch=epochs /\ afterSnapshot.activationSerial=serial
/\ after=ConditionalActivityLedger96(observed,afterSnapshot.definitions,afterSnapshot)
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: epochs, observed, serial, ConditionalActivityLedger96, ConditionalDefinitionsStable96, ConditionalRegistrySnapshotBound96, ConditionalSnapshotBound96, SyncConditionalWindows96
ObserveConditionalExpected96 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveConditionalExpected96(before,after,p,plan,actualExpected) ==
/\ ConditionalProcedureBound96(before,p)
/\ p.phase="Imminent" /\ InstructionImminentAtOrigin93(plan,p.ability,"NoValue")
/\ p.id \in DOMAIN before.instances /\ before.instances[p.id].status="Imminent"
/\ plan.index \notin DOMAIN before.instances[p.id].expected
/\ actualExpected.tag="ConditionalExpectedEffects" /\ actualExpected.point="ExpectedEffectsBeforeInterrupt"
/\ actualExpected.instruction=InstructionWindowRef93(plan)
/\ after=[before EXCEPT !.instances[p.id].expected=[i \in DOMAIN @ \cup {plan.index} |->
IF i=plan.index THEN [instruction |-> InstructionWindowRef93(plan),effects |-> actualExpected.effects] ELSE @[i]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalProcedureBound96, InstructionImminentAtOrigin93, InstructionWindowRef93
ObserveConditionalRuntimeExpected911 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveConditionalRuntimeExpected911(before,after,r,plan,context,history) ==
/\ ConditionalRuntimeBound911(before,r) /\ before.instances[r.id].status="Imminent"
/\ r.phase="Imminent" /\ RuntimeCurrentPlan911(r,plan)
/\ context.initialRef=InstructionWindowRef93(plan) /\ InitialWouldCaptured99(context,history)
/\ plan.index \notin DOMAIN before.instances[r.id].expected
/\ after=[before EXCEPT !.instances[r.id].expected=ReplacementOverlay99(@,[i \in {plan.index} |->
[instruction |-> context.initialRef,effects |-> ExpectedObservationSet99(context.initialEffects)]])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalRuntimeBound911, ExpectedObservationSet99, InitialWouldCaptured99, InstructionWindowRef93, ReplacementOverlay99, RuntimeCurrentPlan911
ObserveConditionalTimingStep96 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveConditionalTimingStep96(before,after,actualStep) ==
/\ actualStep.tag="TimingStructureStepCompleted" /\ TimingRefValid9(actualStep.structure)
/\ actualStep.procedureId \in Nat \ {0} /\ actualStep.step # "NoValue"
/\ actualStep.previousSerial=before.stepSerial /\ actualStep.serial=before.stepSerial+1
/\ after=[before EXCEPT !.stepSerial=actualStep.serial]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRefValid9
ObserveContinuousStaticReplacement99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveContinuousStaticReplacement99(original,replacement,current,actualReplacement,projection) ==
/\ current.id \in Nat \ {0}
/\ actualReplacement.tag="CurrentStaticReplacement" /\ actualReplacement.original=original /\ actualReplacement.replacement=replacement
/\ actualReplacement.snapshotId=current.id
/\ LET base == [id \in DOMAIN actualReplacement.base |-> actualReplacement.base[id]]
originalActive == ContinuousStaticActive99(original.definition,original.syntax,current)
replacementActive == ContinuousStaticActive99(replacement.definition,replacement.syntax,current)
IN /\ ObserveCurrentStaticDeclarations94(original.definition,original.syntax,current.objects,current.present,
current.ordinaryActivity[ContinuousStaticKey99(original.definition,original.syntax)],current.activity,current.points,
original.parts,original.conditions,original.values,base)
/\ DOMAIN actualReplacement.values \subseteq DOMAIN base
/\ projection=[id \in DOMAIN base |-> IF originalActive /\ replacementActive /\ id \in DOMAIN actualReplacement.values
THEN [base[id] EXCEPT !.value=actualReplacement.values[id]] ELSE base[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: base, originalActive, replacementActive, ContinuousStaticKey99, ObserveCurrentStaticDeclarations94
ObserveCurrentExpectedWould99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveCurrentExpectedWould99(before,after,context,origin,world,order,receipt) ==
/\ ExpectedContextOrigin99(context,origin) /\ ExpectedContextWorld99(context,world)
/\ RecordWouldDescriptors99(before,after,context.id,context.imminenceId,context.currentRef,world.id,context.state.effects,
[id \in DOMAIN context.state.effects |-> context.wouldGroups[id]],ActualWouldPeriods99(world),order,receipt)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActualWouldPeriods99, ExpectedContextOrigin99, ExpectedContextWorld99, RecordWouldDescriptors99
ObserveCurrentStaticDeclarations94 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveCurrentStaticDeclarations94(definition,syntax,objects,present,actualDefaultActive,context,points,parts,actualConditions,currentValues,after) ==
ObserveStaticDeclarations94(syntax,parts,StaticAbilityActive94(definition,syntax,objects,present,actualDefaultActive,context,points),
actualConditions,currentValues,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveStaticDeclarations94, StaticAbilityActive94
ObserveCurrentStaticRestrictions94 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveCurrentStaticRestrictions94(definition,syntax,objects,present,actualDefaultActive,context,points,parts,actualConditions,after) ==
ObserveStaticRestrictions94(syntax,parts,StaticAbilityActive94(definition,syntax,objects,present,actualDefaultActive,context,points),actualConditions,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveStaticRestrictions94, StaticAbilityActive94
ObserveInitialConditionalExpected99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveInitialConditionalExpected99(before,after,p,plan,context) ==
/\ context.initialRef=InstructionWindowRef93(plan)
/\ context.phase="Replacing" /\ context.currentRef=context.initialRef
/\ ObserveConditionalExpected96(before,after,p,plan,InitialExpectedReceipt99(context))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InitialExpectedReceipt99, InstructionWindowRef93, ObserveConditionalExpected96
ObserveLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveLingering910(before,after,world) ==
/\ world.id \in Nat \ {0}
/\ after=[before EXCEPT !.effects=ObserveLingeringEffects910(@,world)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveLingeringEffects910
ObserveLingeringEffects910 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveLingeringEffects910(before,world) ==
[id \in DOMAIN before |-> IF before[id].status="Expired" \/ ~LingeringWantsActive910(before[id],before,world)
THEN [before[id] EXCEPT !.status="Expired"] ELSE before[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringWantsActive910
ObserveOccurrenceExpected912 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveOccurrenceExpected912(before,after,r,plan,context,history) ==
/\ ConditionalOccurrenceBound912(before,r) /\ before.instances[r.id].status="Imminent"
/\ r.phase="Imminent" /\ OccurrencePlan912(r,plan) /\ context.initialRef=InstructionWindowRef93(plan)
/\ InitialWouldCaptured99(context,history) /\ plan.index \notin DOMAIN before.instances[r.id].expected
/\ after=[before EXCEPT !.instances[r.id].expected=ReplacementOverlay99(@,[i \in {plan.index} |->
[instruction |-> context.initialRef,effects |-> ExpectedObservationSet99(context.initialEffects)]])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalOccurrenceBound912, ExpectedObservationSet99, InitialWouldCaptured99, InstructionWindowRef93, OccurrencePlan912, ReplacementOverlay99
ObservePersistentKernel912 · operator
reference-profile · input revision 2 · CC0 1.0
ObservePersistentKernel912(beforeRegistry,afterRegistry,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot,
baseWorld,execution,beforeAuthority,afterAuthority) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority)
/\ PersistentRegistryWorldBound912(beforeRegistry,beforeAuthority.current)
/\ PersistentCheckpointBound912(beforeRegistry,beforeLedger)
/\ PersistentConditionalDefinitions912(beforeRegistry,beforeSnapshot.definitions)
/\ afterAuthority.current=PersistentWorld912(baseWorld,beforeRegistry)
/\ CommitLifetimeKernelCore910(beforeAuthority,afterAuthority,afterAuthority.current,execution)
/\ LET local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ ObserveLingering910(beforeRegistry,local,afterAuthority.current)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ PersistentRegistryWorldBound912(afterRegistry,afterAuthority.current)
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=afterAuthority.current.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeAuthority.current)
/\ LingeringConditionalWorld910(afterSnapshot,beforeLedger,afterAuthority.current)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,local,beforeLedger,afterAuthority.current)
/\ PersistentConditionalDefinitions912(local,afterSnapshot.definitions)
/\ ObserveConditionalActivity96(beforeLedger,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: local, CommitLifetimeKernelCore910, LifetimeFrontier910, LifetimeReady910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, PersistentCheckpointBound912, PersistentConditionalDefinitions912, PersistentRegistryWorldBound912, PersistentWorld912
ObserveQuantityRetireOccurrences912 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveQuantityRetireOccurrences912(batch,beforeSnapshot,successors,exampleFamily075Definition,targetSite,ids,used,result) ==
/\ batch.tag="CompletedSimultaneousRetireSet" /\ batch.snapshotId=beforeSnapshot.id
/\ batch.beforeObjects=beforeSnapshot.objects
/\ QuantityRetireIdsValid912(batch,beforeSnapshot.objects,ids,used)
/\ result=QuantityRetireOccurrences912(batch,beforeSnapshot,successors,exampleFamily075Definition,targetSite,ids)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityRetireIdsValid912, QuantityRetireOccurrences912
ObserveResolvingLifetimeContext910 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveResolvingLifetimeContext910(before,after,registry,a,origin) ==
/\ LifetimeReady910(registry,a) /\ before.phase="Resolving"
/\ before.currentWorld \in DOMAIN a.worlds /\ origin.kind="Instruction"
/\ ConditionalCreationInstruction96(origin.plan,origin.parent,origin.ruleStep)
/\ before.currentRef=InstructionWindowRef93(origin.plan)
/\ after=[before EXCEPT !.currentWorld=a.current.id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCreationInstruction96, InstructionWindowRef93, LifetimeReady910
ObserveSpecimen0100Duration99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveSpecimen0100Duration99(original,replacement,current,comparison,projection,cardFacts) ==
/\ original.id \in Nat \ {0} /\ current.id \in Nat \ {0} /\ current.turnId \in Nat \ {0}
/\ current.activeOriginals \subseteq DOMAIN current.maintainedEffects
/\ original.id \in DOMAIN current.maintainedEffects => current.maintainedEffects[original.id]=original
/\ Specimen0100Record99(replacement,current,cardFacts) /\ Specimen0100DurationComparison99(original,current,comparison)
/\ LET effective == EffectiveSpecimen0100Boost99(original,replacement,current,comparison)
due == ContinuousOriginalPresent99(original,current) /\ ~CurrentBoostAlive99(effective,current)
IN projection=[tag |-> "ContinuousDurationProjection",originalId |-> original.id,replacementId |-> replacement.id,
snapshotId |-> current.id,base |-> original.base,effective |-> effective,
replacementApplies |-> ContinuousOriginalActive99(original,current) /\ effective # original.base,
cleanupDue |-> due,cleanupAt |-> IF due THEN "NextCheckpoint" ELSE "NoValue"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: due, effective, ContinuousOriginalActive99, Specimen0100DurationComparison99, Specimen0100Record99
ObserveStaticDeclarations94 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveStaticDeclarations94(a,parts,active,actualConditions,currentValues,after) ==
/\ a.kind="Static" /\ DOMAIN currentValues=DOMAIN parts
/\ DOMAIN parts=TextUnitIds93(a.units,"Declaration") /\ StaticConditionSnapshot94(a,actualConditions)
/\ \A id \in DOMAIN parts : parts[id].id=id /\ parts[id].ability=a.id
/\ after=[id \in {i \in DOMAIN parts : StaticPartApplies94(a,parts[i],active,actualConditions)} |->
StaticProjection94(a,parts[id],currentValues[id])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: StaticConditionSnapshot94, StaticPartApplies94, StaticProjection94, TextUnitIds93
ObserveStaticRestrictions94 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveStaticRestrictions94(a,parts,active,actualConditions,after) ==
/\ a.kind="Static" /\ DOMAIN parts=TextUnitIds93(a.units,"Restriction") /\ StaticConditionSnapshot94(a,actualConditions)
/\ \A id \in DOMAIN parts : parts[id].id=id /\ parts[id].ability=a.id
/\ after={id \in DOMAIN parts : StaticPartApplies94(a,parts[id],active,actualConditions)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: StaticConditionSnapshot94, StaticPartApplies94, TextUnitIds93
ObserveVariableX912 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveVariableX912(d,world,cardFacts,evaluation,value) ==
/\ evaluation.tag="CurrentVariableEvaluation" /\ evaluation.ability=d.syntax.id /\ evaluation.source=d.syntax.source
/\ evaluation.snapshotId=world.id /\ evaluation.available \in BOOLEAN /\ evaluation.value \in Int
/\ value=VariableXValue912(d,world,cardFacts,evaluation)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: VariableXValue912
ObserveWouldImminence99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveWouldImminence99(before,after,opening,periods,rows) ==
/\ opening.tag="WouldEffectOpening" /\ opening.point="BecameImminent" /\ WouldContextValid99(opening.context)
/\ opening.id \in (Nat \ {0}) \ before.usedOpeningIds /\ opening.snapshotId \in Nat \ {0}
/\ opening.imminenceId \in (Nat \ {0}) \ before.usedImminenceIds
/\ opening.imminence.tag="ActualInstructionImminence" /\ opening.imminence.id=opening.imminenceId
/\ opening.imminence.context=WouldContextKey99(opening.context) /\ opening.imminence.snapshotId=opening.snapshotId
/\ DeckSequenceValid4(opening.order) /\ SubIds6(opening.order)=DOMAIN rows
/\ DOMAIN periods # {} /\ \A period \in DOMAIN periods : WouldPeriodMembership99(opening,period,periods[period])
/\ DOMAIN rows \subseteq (Nat \ {0}) \ before.usedOccurrenceIds
/\ Cardinality({rows[id].root : id \in DOMAIN rows})=Cardinality(DOMAIN rows)
/\ \A id \in DOMAIN rows : rows[id].tag="EffectWouldImminence" /\ rows[id].id=id /\ rows[id].root \in Nat \ {0}
/\ rows[id].context=WouldContextKey99(opening.context) /\ rows[id].snapshotId=opening.snapshotId
/\ rows[id].effect.amount \in Int
/\ LET key == opening.imminenceId
record == [id |-> opening.id,imminenceId |-> key,context |-> opening.context,snapshotId |-> opening.snapshotId,periods |-> periods,roots |-> {rows[id].root : id \in DOMAIN rows}]
IN after=[before EXCEPT !.openings=[k \in DOMAIN @ \cup {key} |-> IF k=key THEN record ELSE @[k]],
!.occurrences=[id \in DOMAIN @ \cup DOMAIN rows |-> IF id \in DOMAIN rows THEN
NewWouldOccurrence99(rows[id],opening,periods,before.serial+OrderPosition99(opening.order,id)) ELSE @[id]],
!.usedOccurrenceIds=@ \cup DOMAIN rows,!.usedOpeningIds=@ \cup {opening.id},!.usedImminenceIds=@ \cup {opening.imminenceId},!.serial=@+Len(opening.order)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key, record, NewWouldOccurrence99, OrderPosition99, WouldContextKey99, WouldContextValid99, WouldPeriodMembership99, DeckSequenceValid4, SubIds6
ObserveWouldOutcome99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveWouldOutcome99(before,after,outcome) ==
/\ outcome.tag="WouldEffectOutcome" /\ WouldContextValid99(outcome.context) /\ outcome.imminenceId \in DOMAIN before.openings
/\ LET original == before.openings[outcome.imminenceId]
IN /\ outcome.openingId=original.id /\ outcome.roots \subseteq original.roots
/\ WouldContextKey99(outcome.context)=WouldContextKey99(original.context)
/\ outcome.context.revision>=original.context.revision
/\ outcome.disposition \in {"Resolved","Prevented","Replaced"} /\ after=beforeExact module download · Source bundle and reproduction instructions
Resolved project definitions: original, WouldContextKey99, WouldContextValid99
ObserveWouldRevision99 · operator
reference-profile · input revision 2 · CC0 1.0
ObserveWouldRevision99(before,after,revision) ==
/\ revision.tag="WouldExpectedEffectsRevision" /\ WouldContextValid99(revision.context)
/\ revision.imminenceId \in DOMAIN before.openings
/\ LET original == before.openings[revision.imminenceId]
IN /\ revision.openingId=original.id /\ revision.openingSnapshotId=original.snapshotId
/\ WouldContextKey99(revision.context)=WouldContextKey99(original.context)
/\ revision.context.revision>=original.context.revision
/\ after=beforeExact module download · Source bundle and reproduction instructions
Resolved project definitions: original, WouldContextKey99, WouldContextValid99
OccurrenceAtTop912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceAtTop912(stack,r) == BarrierInstructionOwnerAtTop98(OccurrencePriorityOwner912(r),stack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOwnerAtTop98, OccurrencePriorityOwner912
OccurrenceBoundary912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceBoundary912(r,context,causes,costTransaction) ==
[tag |-> "OccurrenceInstructionBoundary",instance |-> r.id,source |-> r.ability.source,instruction |-> context.currentRef,
node |-> r.pc,occurrence |-> r.current,index |-> Len(r.trace)+1,pass |-> r.repeat.pass,causes |-> causes,costTransaction |-> costTransaction]Exact module download · Source bundle and reproduction instructions
OccurrenceBoundaryCaller912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceBoundaryCaller912(boundary) == [kind |-> "OccurrenceInstructionBoundary",boundary |-> boundary]Exact module download · Source bundle and reproduction instructions
OccurrenceCommittedQuota912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceCommittedQuota912(r,m) ==
LET matches == {occurrence \in SubIds6(r.trace) \cap DOMAIN r.choices :
/\ r.occurrences[occurrence].sourceNode=m.commitment.node /\ r.occurrences[occurrence].pass=r.repeat.pass
/\ r.choices[occurrence].tag="ResolvedInstructionControl" /\ r.choices[occurrence].instance=r.id
/\ r.choices[occurrence].node=m.commitment.node
/\ r.choices[occurrence].instruction.id=occurrence /\ r.choices[occurrence].instruction.source=r.ability.source
/\ r.choices[occurrence].instruction.abilityInstance=r.id
/\ r.choices[occurrence].mode="Selected" /\ r.choices[occurrence].option \in DOMAIN m.commitment.quotaByOption}
IN IF Cardinality(matches)#1 THEN [supported |-> FALSE,maximum |-> 0,upTo |-> FALSE]
ELSE LET occurrence == CHOOSE id \in matches : TRUE
quota == m.commitment.quotaByOption[r.choices[occurrence].option]
IN [supported |-> TRUE,maximum |-> quota.maximum,upTo |-> quota.upTo]Exact module download · Source bundle and reproduction instructions
OccurrenceContinuation912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceContinuation912(r,control,capture) ==
LET within == OccurrencePassNext912(r,control)
requested == OccurrenceRepeatRequested912(r,control)
firstFixed == within=0 /\ r.specification.repeat.kind="Fixed" /\ ~r.repeat.captured /\ requested
total == IF firstFixed THEN capture.count ELSE r.repeat.total
available == IF firstFixed THEN total ELSE r.repeat.remaining
again == within=0 /\ (IF r.specification.repeat.kind="Unbounded" THEN requested
ELSE r.specification.repeat.kind="Fixed" /\ (r.repeat.captured \/ firstFixed) /\ available>0)
rep == [r.repeat EXCEPT !.requested=IF again THEN FALSE ELSE requested,
!.captured=@ \/ firstFixed,!.total=total,!.remaining=IF again /\ r.specification.repeat.kind="Fixed" THEN available-1 ELSE available,
!.pass=IF again THEN @+1 ELSE @]
IN [sourceNode |-> IF again THEN OccurrenceSkipFixedTrait912([r EXCEPT !.repeat=rep],r.technique.entry) ELSE within,
repeat |-> rep,modal |-> IF again THEN OccurrenceModalInitial912(r.specification,rep.pass) ELSE OccurrenceModalUpdate912(r,control),again |-> again]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: again, rep, within, OccurrenceModalInitial912, OccurrenceModalUpdate912, OccurrenceSkipFixedTrait912
OccurrenceControlBound912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceControlBound912(r,c,ret,result) ==
/\ result.tag="ResolvedInstructionControl" /\ result.instance=r.id /\ result.node=r.pc
/\ result.instruction=c.currentRef /\ result.contextId=c.id /\ result.actualEffects=c.actualEffects /\ result.completion=ret
/\ result.mode \in {"Selected","Removed"}
/\ IF result.mode="Selected" THEN
/\ result.operation \in DOMAIN c.actualEffects
/\ c.actualEffects[result.operation].kind \in {"InstructionChoice","NestedCostChoice","ModalChoice","AbilityRepeat"}
/\ c.actualEffects[result.operation].controlNode=r.pc
/\ result.chooser=c.actualEffects[result.operation].chooser /\ result.chooser \in SetupPlayers
/\ IF r.pc=r.specification.repeat.node THEN
/\ c.actualEffects[result.operation].kind="AbilityRepeat"
/\ result.requested=c.actualEffects[result.operation].requested /\ result.requested \in BOOLEAN
ELSE IF r.pc \in DOMAIN r.specification.modal THEN
/\ c.actualEffects[result.operation].kind="ModalChoice"
/\ result.option \in c.actualEffects[result.operation].options
/\ result.option \in DOMAIN r.specification.modal[r.pc].bodies \cup {0}
/\ result.maximum=c.actualEffects[result.operation].maximum /\ result.maximum \in Nat
/\ result.upTo=c.actualEffects[result.operation].upTo /\ result.upTo \in BOOLEAN
ELSE /\ result.option \in DOMAIN r.technique.nodes[r.pc].options
/\ result.option \in c.actualEffects[result.operation].options
ELSE ~\E op \in DOMAIN c.actualEffects :
c.actualEffects[op].kind \in {"InstructionChoice","NestedCostChoice","ModalChoice","AbilityRepeat"} /\ c.actualEffects[op].controlNode=r.pcExact module download · Source bundle and reproduction instructions
Resolved project definitions: SetupPlayers
OccurrenceCountCapture912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceCountCapture912(r,context,ret,capture) ==
/\ capture.tag="ResolvedRepetitionCount" /\ capture.instance=r.id /\ capture.source=r.ability.source
/\ capture.definition=r.technique.definition /\ capture.directive=r.specification.repeat.node
/\ capture.pass=0 /\ capture.contextId=context.id /\ capture.instruction=context.currentRef
/\ capture.snapshotId=ret.snapshotId /\ capture.completion=ret /\ capture.count \in NatExact module download · Source bundle and reproduction instructions
OccurrenceFinishWorld912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceFinishWorld912(beforeWorld,afterWorld,r,ledger) ==
/\ r.id \in DOMAIN beforeWorld.activity.instances
/\ afterWorld=[beforeWorld EXCEPT !.id=afterWorld.id,
!.finishedInstances=@ \cup (IF r.current=0 THEN {r.id} ELSE {}),
!.finishedDelayedEffects=@,
!.activity.instances[r.id]=ReplacementOverlay99(@,
[ability |-> r.technique.definition.syntax.id,sourceObject |-> IF r.ability.source.kind="Object" THEN r.ability.source.object ELSE 0,
status |-> IF r.current=0 THEN "Complete" ELSE "Resolving",owner |-> OccurrenceLookOwner912(r)])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrenceLookOwner912, ReplacementOverlay99
OccurrenceFinishedDelayed912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceFinishedDelayed912(r,ledger) ==
LET effect == r.technique.definition.delayedEffect
IN IF r.current=0 /\ effect \in DOMAIN ledger.effects /\ ledger.effects[effect].policy="UntilResolution"
THEN {effect} ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effect
OccurrenceHasControl912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceHasControl912(r) == r.pc=r.specification.repeat.node \/ r.pc \in DOMAIN r.specification.modal \/ r.technique.nodes[r.pc].kind \in {"Choice","NestedCost"}Exact module download · Source bundle and reproduction instructions
OccurrenceLookOwner912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceLookOwner912(r) == ReplacementOverlay99(r,[definition |-> r.technique.definition])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
OccurrenceModalAllowed912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceModalAllowed912(r,control) ==
IF r.pc \notin DOMAIN r.specification.modal \/ control.mode="Removed" THEN TRUE
ELSE LET m == r.specification.modal[r.pc]
old == r.modal[r.pc]
maximum == IF old.latched THEN old.maximum ELSE control.maximum
upTo == IF old.latched THEN old.upTo ELSE control.upTo
IN /\ IF old.latched THEN control.maximum=old.maximum /\ control.upTo=old.upTo ELSE TRUE
/\ IF control.option=0 THEN upTo
ELSE /\ Len(old.resolved)<maximum
/\ control.option \in DOMAIN m.bodies
/\ m.allowRepeat \/ control.option \notin SubIds6(old.resolved)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: m, maximum, old, upTo, SubIds6
OccurrenceModalInitial912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceModalInitial912(spec,pass) ==
[selector \in DOMAIN spec.modal |-> [resolved |-> <<>>,currentMode |-> 0,invocation |-> pass,maximum |-> 0,upTo |-> FALSE,latched |-> FALSE]]Exact module download · Source bundle and reproduction instructions
OccurrenceModalQuotaSupported912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceModalQuotaSupported912(r,control) ==
IF r.pc \notin DOMAIN r.specification.modal \/ control.mode="Removed" THEN TRUE
ELSE LET m == r.specification.modal[r.pc]
old == r.modal[r.pc]
committed == IF m.quotaPolicy="Committed" THEN OccurrenceCommittedQuota912(r,m) ELSE [supported |-> FALSE]
IN IF old.latched THEN control.maximum=old.maximum /\ control.upTo=old.upTo
ELSE IF m.quotaPolicy="Fixed" THEN control.maximum=m.maximum /\ control.upTo=m.upTo
ELSE committed.supported /\ control.maximum=committed.maximum /\ control.upTo=committed.upToExact module download · Source bundle and reproduction instructions
OccurrenceModalUpdate912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceModalUpdate912(r,control) ==
IF r.pc \in DOMAIN r.specification.modal THEN
LET old == r.modal[r.pc]
selected == control.mode="Selected" /\ control.option#0
next == [old EXCEPT !.currentMode=IF selected THEN control.option ELSE 0,
!.resolved=IF selected THEN Append(@,control.option) ELSE @,
!.maximum=IF @=0 /\ ~old.latched /\ control.mode="Selected" THEN control.maximum ELSE @,
!.upTo=IF ~old.latched /\ control.mode="Selected" THEN control.upTo ELSE @,!.latched=TRUE]
IN [r.modal EXCEPT ![r.pc]=next]
ELSE [selector \in DOMAIN r.modal |->
IF r.modal[selector].currentMode#0 /\ r.pc=r.specification.modal[selector].bodies[r.modal[selector].currentMode][Len(r.specification.modal[selector].bodies[r.modal[selector].currentMode])]
THEN [r.modal[selector] EXCEPT !.currentMode=0] ELSE r.modal[selector]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next
OccurrenceOwnerCurrent912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceOwnerCurrent912(r,a) ==
/\ r.id \in DOMAIN a.current.activity.instances /\ "owner" \in DOMAIN a.current.activity.instances[r.id]
/\ LET owner == a.current.activity.instances[r.id].owner
IN /\ owner.ability=r.ability /\ owner.technique=r.technique /\ owner.specification=r.specification
/\ owner.metadata=r.metadata /\ owner.current=r.current /\ owner.pc=r.pc /\ owner.trace=r.trace
/\ owner.occurrences=r.occurrences /\ owner.usedOccurrences=r.usedOccurrences /\ owner.choices=r.choices
/\ owner.repeat=r.repeat /\ owner.modal=r.modalExact module download · Source bundle and reproduction instructions
Resolved project definitions: owner
OccurrenceOwnerMetadata912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceOwnerMetadata912(base) ==
IF base.ability.kind="Conditional" THEN
[kind |-> "Conditional",windowId |-> base.windowId,option |-> base.option,transaction |-> base.transaction,turnId |-> base.turnId]
ELSE [kind |-> base.ability.kind,sourceEntry |-> base.sourceEntry,owner |-> base.sourceOwner]Exact module download · Source bundle and reproduction instructions
OccurrencePassNext912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrencePassNext912(r,control) == OccurrenceSkipFixedTrait912(r,OccurrenceWithinPassNext912(r,control))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrenceSkipFixedTrait912, OccurrenceWithinPassNext912
OccurrencePlan912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrencePlan912(r,plan) ==
/\ r.current \in DOMAIN r.occurrences /\ r.pc=r.occurrences[r.current].sourceNode
/\ plan.origin="Ability" /\ plan.id=r.current /\ plan.abilityInstance=r.id /\ plan.source=r.ability.source
/\ plan.sourceZone=r.ability.sourceZone /\ plan.index=Len(r.trace)+1
/\ plan.steps=r.technique.nodes[r.pc].steps /\ plan.requiresTargets=r.technique.nodes[r.pc].requiresTargetsExact module download · Source bundle and reproduction instructions
OccurrencePriorityOwner912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrencePriorityOwner912(r) ==
IF r.metadata.kind="Conditional" THEN [windowId |-> r.metadata.windowId,option |-> r.metadata.option,transaction |-> r.metadata.transaction]
ELSE r.metadata.ownerExact module download · Source bundle and reproduction instructions
OccurrenceRepeatRequested912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceRepeatRequested912(r,control) ==
IF r.pc=r.specification.repeat.node THEN control.mode="Selected" /\ control.requested ELSE r.repeat.requestedExact module download · Source bundle and reproduction instructions
OccurrenceRuntimeProfile912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceRuntimeProfile912(r) ==
/\ InstructionTechniqueValid911(r.technique) /\ OccurrenceSpecificationShapeSupported912(r.specification,r.technique)
/\ r.id=r.ability.id /\ r.technique.source=r.ability.source /\ r.specification.definition=r.technique.definition
/\ r.ability.kind=r.technique.definition.syntax.kind /\ (r.current=0)=(r.pc=0)
/\ r.metadata.kind=r.ability.kind /\ DeckSequenceValid4(r.trace)
/\ DOMAIN r.occurrences=r.usedOccurrences /\ r.usedOccurrences \subseteq Nat \ {0} /\ SubIds6(r.trace) \subseteq r.usedOccurrences
/\ IF r.trace# <<>> THEN Head(r.trace)=r.technique.entry ELSE r.pc=r.technique.entry
/\ r.repeat.pass \in Nat /\ r.repeat.total \in Nat /\ r.repeat.remaining \in Nat
/\ r.repeat.requested \in BOOLEAN /\ r.repeat.captured \in BOOLEAN
/\ DOMAIN r.modal=DOMAIN r.specification.modal
/\ \A selector \in DOMAIN r.modal :
/\ r.modal[selector].resolved \in Seq(DOMAIN r.specification.modal[selector].bodies)
/\ r.modal[selector].currentMode \in {0} \cup DOMAIN r.specification.modal[selector].bodies
/\ r.modal[selector].invocation=r.repeat.pass
/\ r.modal[selector].maximum \in Nat /\ r.modal[selector].upTo \in BOOLEAN /\ r.modal[selector].latched \in BOOLEAN
/\ ~r.specification.modal[selector].allowRepeat => DeckSequenceValid4(r.modal[selector].resolved)
/\ \A id \in DOMAIN r.occurrences : r.occurrences[id].id=id /\ r.occurrences[id].sourceNode \in DOMAIN r.technique.nodes
/\ r.phase \in {"Targets","Imminent","Resolve","Paused","Checkpoint","Complete","Returned"}
/\ IF r.current=0 THEN r.ability.instructions=r.trace /\ r.ability.complete /\ r.ability.lastFinished
ELSE /\ r.current \in r.usedOccurrences \ SubIds6(r.trace)
/\ r.pc=r.occurrences[r.current].sourceNode /\ r.ability.instructions=Append(r.trace,r.current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionTechniqueValid911, OccurrenceSpecificationShapeSupported912, DeckSequenceValid4, SubIds6
OccurrenceSkipFixedTrait912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceSkipFixedTrait912(r,node) ==
IF r.specification.repeat.kind="Fixed" /\ r.repeat.pass>0 /\ node=r.specification.repeat.node
THEN r.technique.nodes[node].next ELSE nodeExact module download · Source bundle and reproduction instructions
OccurrenceSpecificationShapeSupported912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceSpecificationShapeSupported912(spec,p) ==
/\ IF spec.repeat.kind="NoValue" THEN TRUE
ELSE /\ spec.repeat.node \in DOMAIN p.nodes /\ p.nodes[spec.repeat.node].kind="Plain"
/\ spec.repeat.kind="Fixed" => DOMAIN p.nodes \ {spec.repeat.node}#{}
/\ \A selector \in DOMAIN spec.modal :
LET m == spec.modal[selector]
body == UNION {SubIds6(m.bodies[mode]) : mode \in DOMAIN m.bodies}
IN /\ body \cap DOMAIN spec.modal={}
/\ body \subseteq DOMAIN p.nodes
/\ \A id \in body : p.nodes[id].kind \notin {"Choice","NestedCost"}
/\ spec.repeat.kind="Fixed" => spec.repeat.node \notin body
/\ \A a,b \in DOMAIN m.bodies : a#b => SubIds6(m.bodies[a]) \cap SubIds6(m.bodies[b])={}
/\ \A other \in DOMAIN spec.modal \ {selector} :
body \cap UNION {SubIds6(spec.modal[other].bodies[mode]) : mode \in DOMAIN spec.modal[other].bodies}={}Exact module download · Source bundle and reproduction instructions
OccurrenceSpecificationValid912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceSpecificationValid912(spec,p,objects,cardFacts) ==
/\ CompiledInstructionTechnique911(p,objects,cardFacts)
/\ spec.tag="OccurrenceTechniqueSpecification" /\ spec.definition=p.definition /\ spec.source=p.source
/\ spec.sourceSHA=p.sourceSHA /\ spec.card=p.card
/\ spec.repeat.kind \in {"NoValue","Fixed","Unbounded"}
/\ IF spec.repeat.kind="NoValue" THEN spec.repeat.node=0
ELSE spec.repeat.node \in DOMAIN p.nodes
/\ DOMAIN spec.modal \subseteq DOMAIN p.nodes
/\ spec.repeat.node \notin DOMAIN spec.modal
/\ OccurrenceSpecificationShapeSupported912(spec,p)
/\ \A selector \in DOMAIN spec.modal :
LET m == spec.modal[selector]
IN /\ m.selector=selector /\ m.maximum \in Nat /\ m.upTo \in BOOLEAN /\ m.allowRepeat \in BOOLEAN
/\ m.quotaPolicy \in {"Fixed","Committed"}
/\ IF m.quotaPolicy="Committed" THEN
/\ m.commitment.tag="SourceQuotaCommitment" /\ m.commitment.source=p.source
/\ m.commitment.sourceSHA=p.sourceSHA /\ m.commitment.definition=p.definition
/\ m.commitment.node \in DOMAIN p.nodes \ {selector}
/\ p.nodes[m.commitment.node].kind \in {"Choice","NestedCost"}
/\ m.commitment.unit \in p.nodes[m.commitment.node].segments
/\ m.commitment.quotaByOption=p.units[m.commitment.unit].quotaByOption
/\ DOMAIN m.commitment.quotaByOption=DOMAIN p.nodes[m.commitment.node].options
/\ \A option \in DOMAIN m.commitment.quotaByOption :
m.commitment.quotaByOption[option].maximum \in Nat /\ m.commitment.quotaByOption[option].upTo \in BOOLEAN
ELSE TRUE
/\ m.chooser \in SetupPlayers /\ DOMAIN m.bodies \subseteq Nat \ {0} /\ DOMAIN m.bodies#{}
/\ p.nodes[selector].options=[mode \in DOMAIN m.bodies |-> Head(m.bodies[mode])]
/\ p.nodes[selector].next=m.join
/\ \A mode \in DOMAIN m.bodies :
/\ DeckSequenceValid4(m.bodies[mode]) /\ Len(m.bodies[mode])>0
/\ SubIds6(m.bodies[mode]) \subseteq DOMAIN p.nodes
/\ \A i \in 1..Len(m.bodies[mode]) :
p.nodes[m.bodies[mode][i]].next=IF i=Len(m.bodies[mode]) THEN m.join ELSE m.bodies[mode][i+1]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: m, CompiledInstructionTechnique911, OccurrenceSpecificationShapeSupported912, DeckSequenceValid4, SetupPlayers, SubIds6
OccurrenceWithinPassNext912 · operator
reference-profile · input revision 2 · CC0 1.0
OccurrenceWithinPassNext912(r,control) ==
IF r.pc \in DOMAIN r.specification.modal THEN
IF control.mode="Removed" \/ control.option=0 THEN r.specification.modal[r.pc].join
ELSE Head(r.specification.modal[r.pc].bodies[control.option])
ELSE LET completing == {selector \in DOMAIN r.modal : r.modal[selector].currentMode#0 /\
r.pc=r.specification.modal[selector].bodies[r.modal[selector].currentMode][Len(r.specification.modal[selector].bodies[r.modal[selector].currentMode])]}
IN IF completing#{} THEN
LET selector == CHOOSE s \in completing : TRUE
m == r.modal[selector]
IN IF Len(m.resolved)>=m.maximum THEN r.specification.modal[selector].join ELSE selector
ELSE IF r.pc=r.specification.repeat.node THEN r.technique.nodes[r.pc].next
ELSE IF r.technique.nodes[r.pc].kind \in {"Choice","NestedCost"} /\ control.mode="Selected"
THEN r.technique.nodes[r.pc].options[control.option] ELSE r.technique.nodes[r.pc].nextExact module download · Source bundle and reproduction instructions
Resolved project definitions: completing, m, selector
OnceChoiceController912 · operator
reference-profile · input revision 2 · CC0 1.0
OnceChoiceController912(rows,active) ==
LET players == {rows[id].chooser : id \in DOMAIN rows}
IN IF Cardinality(players)>1 THEN active ELSE CHOOSE p \in players : TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: players
OncePerTurnAllowed93 · operator
reference-profile · input revision 2 · CC0 1.0
OncePerTurnAllowed93(a,turnId,ledger) ==
~FlagPresent93(a.units,"OncePerTurn") \/
~\E id \in DOMAIN ledger : ledger[id].turnId=turnId /\ ledger[id].ability=a.id /\ ledger[id].source=a.sourceExact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93
OpenAbilityResolution9 · operator
reference-profile · input revision 2 · CC0 1.0
OpenAbilityResolution9(id,kind,source,sourceZone,instructions,caller) ==
[id |-> id,kind |-> kind,source |-> source,sourceZone |-> sourceZone,instructions |-> instructions,
caller |-> caller,cursor |-> 1,phase |-> "Ready",firstImminent |-> FALSE,lastFinished |-> FALSE,
detached |-> FALSE,complete |-> FALSE,returned |-> FALSE]Exact module download · Source bundle and reproduction instructions
OpenBarrierInstructionInstructionInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
OpenBarrierInstructionInstructionInterrupt98(p,before,after,plan,id,site,instances,opening,usedWindows) ==
/\ BarrierInstructionBarrierInstructionBound98(p) /\ p.phase="Imminent" /\ BarrierInstructionOwnerAtTop98(p.owner,before)
/\ OpenInstructionInterrupt93(before,after,id,site,instances,opening,usedWindows,plan,p.ability,"NoValue")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, OpenInstructionInterrupt93
OpenBarrierInstructionInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
OpenBarrierInstructionInterrupt98(p,before,after,id,site,instances,opening,usedWindows) ==
/\ BarrierInstructionImminent98(p) /\ BarrierInstructionOwnerAtTop98(p.owner,before)
/\ id \in (Nat \ {0}) \ usedWindows /\ id \notin {before[i].id : i \in 1..Len(before)}
/\ WindowSiteAllowed9("Interrupt",PriorityOpeningSite9(before,site))
/\ site.structure=p.structure /\ site.step="ProcedureCodef1914978bb8e"
/\ opening.tag="PriorityWindowOpening" /\ opening.windowId=id /\ opening.kind="Interrupt" /\ opening.site=site
/\ opening.members=DOMAIN instances /\ opening.instances=instances /\ ConditionalGroupValid9(instances,id,opening.group,TRUE)
/\ opening.instruction=BarrierInstructionWindowRef98(p) /\ opening.effectRevision \in Nat \ {0}
/\ opening.preparation= <<"ExpectedEffects","ReplacementEffects","ConditionalPending">>
/\ opening.modifiersExist /\ opening.beginning=NoTimingRef9
/\ after=Append(before,NewPriorityWindow9(id,"Interrupt",PriorityOpeningSite9(before,site),instances,opening.group,NoTimingRef9,opening.instruction,opening.effectRevision))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionImminent98, BarrierInstructionOwnerAtTop98, BarrierInstructionWindowRef98, ConditionalGroupValid9, NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9, WindowSiteAllowed9
OpenChapterRegistry912 · operator
reference-profile · input revision 2 · CC0 1.0
OpenChapterRegistry912(authority,registry) ==
LET base == ReplacementOverlay99(NewLingeringRegistry910,[frontier |-> LifetimeFrontier910(authority,1)])
IN /\ OpenObservedLingering910(authority,base)
/\ registry=NewPersistentRegistry912(base)
/\ PersistentRegistryWorldBound912(registry,authority.current)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: base, NewPersistentRegistry912, OpenObservedLingering910, PersistentRegistryWorldBound912
OpenConditionalInstructionInterrupt96 · operator
reference-profile · input revision 2 · CC0 1.0
OpenConditionalInstructionInterrupt96(beforeLedger,afterLedger,beforeStack,afterStack,p,plan,id,site,instances,opening,usedWindowIds,actualExpected) ==
/\ ConditionalAtTop96(beforeStack,p)
/\ ObserveConditionalExpected96(beforeLedger,afterLedger,p,plan,actualExpected)
/\ OpenInstructionInterrupt93(beforeStack,afterStack,id,site,instances,opening,usedWindowIds,plan,p.ability,"NoValue")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalAtTop96, ObserveConditionalExpected96, OpenInstructionInterrupt93
OpenConditionalProcedure96 · operator
reference-profile · input revision 2 · CC0 1.0
OpenConditionalProcedure96(id,d,w,option,transaction,sourceZone) ==
[id |-> id,definition |-> d,windowId |-> w.id,option |-> option,transaction |-> transaction,turnId |-> w.site.turnId,
ability |-> OpenAbilityResolution9(id,"Conditional",d.syntax.source,sourceZone,d.instructions,w.id),
phase |-> "Targets",checkpoint |-> 0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpenAbilityResolution9
OpenConditionalReaction96 · operator
reference-profile · input revision 2 · CC0 1.0
OpenConditionalReaction96(before,after,ledger,windowId,site,opening,usedWindows) ==
LET members == ConditionalWindowMembers96(ledger.instances,windowId)
IN /\ DOMAIN members # {} /\ OpenPriorityWindow9(before,after,windowId,"Reaction",site,members,opening,usedWindows)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: members, OpenPriorityWindow9
OpenConditionalRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
OpenConditionalRuntime911(id,technique,w,option,transaction,sourceZone) ==
ReplacementOverlay99(NewInstructionRuntime911(id,technique,"Conditional",sourceZone,w.id),
[windowId |-> w.id,option |-> option,transaction |-> transaction,turnId |-> w.site.turnId])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NewInstructionRuntime911, ReplacementOverlay99
OpenDepartureHold9 · operator
reference-profile · input revision 2 · CC0 1.0
OpenDepartureHold9(beforeObjects,afterObjects,oldObject,newObject,abilityId,matchingInstances,actualDepartureReceipt,
actualCardWasActive,actualCardIsActiveAfter,hold) ==
/\ oldObject \in DOMAIN beforeObjects /\ newObject \in DOMAIN afterObjects
/\ beforeObjects[oldObject].form = "Card" /\ afterObjects[newObject].form = "Card"
/\ beforeObjects[oldObject].card = afterObjects[newObject].card
/\ beforeObjects[oldObject].zone # afterObjects[newObject].zone /\ oldObject # newObject
/\ actualCardWasActive /\ ~actualCardIsActiveAfter /\ matchingInstances # {}
/\ actualDepartureReceipt.oldObject = oldObject /\ actualDepartureReceipt.newObject = newObject
/\ actualDepartureReceipt.ability = abilityId /\ actualDepartureReceipt.matchingInstances = matchingInstances
/\ hold = [ability |-> abilityId,object |-> newObject,instances |-> matchingInstances]Exact module download · Source bundle and reproduction instructions
OpenInstruction93 · operator
reference-profile · input revision 2 · CC0 1.0
OpenInstruction93(id,origin,abilityInstance,source,sourceZone,index,ruleStep,steps,requiresTargets) ==
[id |-> id,origin |-> origin,abilityInstance |-> abilityInstance,source |-> source,sourceZone |-> sourceZone,
index |-> index,ruleStep |-> ruleStep,
steps |-> steps,requiresTargets |-> requiresTargets,targets |-> {},announced |-> FALSE,
phase |-> "Planning",cursor |-> 1,revision |-> 0,completedSteps |-> <<>>]Exact module download · Source bundle and reproduction instructions
OpenInstructionInterrupt93 · operator
reference-profile · input revision 2 · CC0 1.0
OpenInstructionInterrupt93(before,after,id,site,instances,opening,usedWindowIds,plan,ability,actualRuleStep) ==
/\ InstructionImminentAtOrigin93(plan,ability,actualRuleStep)
/\ plan.id \in Nat \ {0} /\ plan.revision \in Nat
/\ id \in (Nat \ {0}) \ usedWindowIds /\ id \notin {before[i].id : i \in 1..Len(before)}
/\ WindowSiteAllowed9("Interrupt",PriorityOpeningSite9(before,site))
/\ plan.origin="Rule" => site.step=actualRuleStep
/\ opening.tag="PriorityWindowOpening" /\ opening.windowId=id /\ opening.kind="Interrupt" /\ opening.site=site
/\ opening.members=DOMAIN instances /\ opening.instances=instances
/\ ConditionalGroupValid9(instances,id,opening.group,TRUE)
/\ opening.instruction=InstructionWindowRef93(plan) /\ opening.effectRevision \in Nat \ {0}
/\ opening.preparation= <<"ExpectedEffects","ReplacementEffects","ConditionalPending">>
/\ opening.modifiersExist /\ opening.beginning=NoTimingRef9
/\ after=Append(before,NewPriorityWindow9(id,"Interrupt",PriorityOpeningSite9(before,site),instances,
opening.group,NoTimingRef9,opening.instruction,opening.effectRevision))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalGroupValid9, InstructionImminentAtOrigin93, InstructionWindowRef93, NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9, WindowSiteAllowed9
OpenLingeringCheckpoint910 · operator
reference-profile · input revision 2 · CC0 1.0
OpenLingeringCheckpoint910(ledger,cp,world,frame) ==
/\ cp.id \in DOMAIN ledger.checkpoints /\ cp.tag="ConditionalCheckpoint" /\ cp.point="ProcedureCodee605a78f5d5e"
/\ ledger.lastCheckpoint=cp.id /\ ledger.checkpoints[cp.id].caller=cp.caller
/\ ledger.serial=cp.serial /\ ledger.lastSnapshot=cp.processingSnapshot
/\ world.id=cp.processingSnapshot.id /\ world.objects=cp.processingSnapshot.objects
/\ frame=LingeringCheckpointFrame910(ledger,cp,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringCheckpointFrame910
OpenObservedLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
OpenObservedLingering910(a,registry) ==
/\ LifetimeAuthorityValid910(a) /\ Len(a.order)=1
/\ registry=ReplacementOverlay99(NewLingeringRegistry910,[frontier |-> LifetimeFrontier910(a,Len(a.order))])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeAuthorityValid910, LifetimeFrontier910, NewLingeringRegistry910, ReplacementOverlay99
OpenPaidInstructionInterrupt95 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPaidInstructionInterrupt95(beforeStack,afterStack,p,plan,id,site,instances,opening,usedWindowIds) ==
/\ PaidProcedureAtTop95(beforeStack,p) /\ p.phase="Imminent"
/\ OpenInstructionInterrupt93(beforeStack,afterStack,id,site,instances,opening,usedWindowIds,plan,p.ability,"NoValue")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpenInstructionInterrupt93, PaidProcedureAtTop95
OpenPaidProcedure95 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPaidProcedure95(id,d,option,window,transaction,sourceZone) ==
[id |-> id,definition |-> d,option |-> option,windowId |-> window.id,transaction |-> transaction,
ability |-> OpenAbilityResolution9(id,"Paid",d.syntax.source,sourceZone,d.instructions,window.id),
turnId |-> window.site.turnId,initialCheckpoint |-> window.checkpoint,phase |-> "PayCosts",costPaid |-> FALSE,checkpoint |-> 0,heldSourceIds |-> {},heldIds |-> {},sourceForfeited |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpenAbilityResolution9
OpenPersistentPrepared912 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPersistentPrepared912(registry,beforeContext,afterContext,beforeStack,afterStack,origin,world,history,ledger,site,opening,usedWindows,cardFacts,authority) ==
/\ PersistentInterruptWorld912(registry,world,ledger,authority)
/\ beforeContext.phase="Prepared" /\ ExpectedContextOrigin99(beforeContext,origin) /\ ExpectedContextWorld99(beforeContext,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ BarrierInstructionOwnerAtTop98(beforeContext.owner,beforeStack)
/\ WouldViewCurrent99(history,beforeContext,world)
/\ site.turnId=world.turn.id /\ site.active=world.turn.owner
/\ opening=PreparedOriginOpening99(beforeContext,site)
/\ LET proposed == NewPriorityWindow9(beforeContext.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,site),beforeContext.openingMembers,
beforeContext.group,NoTimingRef9,beforeContext.openingRef,beforeContext.openingRef.revision+1)
IN /\ beforeContext.conditionalIds # {} \/ PersistentOpeningPaidRelevant912(registry,beforeContext,world,history,proposed) # {}
/\ IF origin.kind="BarrierInstruction" THEN
OpenBarrierInstructionInterrupt98(origin.procedure,beforeStack,afterStack,beforeContext.windowId,site,beforeContext.openingMembers,opening,usedWindows)
ELSE OpenInstructionInterrupt93(beforeStack,afterStack,beforeContext.windowId,site,beforeContext.openingMembers,opening,usedWindows,
origin.plan,origin.parent,origin.ruleStep)
/\ afterContext=[beforeContext EXCEPT !.phase="WindowOpen",!.site=site]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: proposed, BarrierInstructionOwnerAtTop98, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, OpenBarrierInstructionInterrupt98, OpenInstructionInterrupt93, PersistentInterruptWorld912, PersistentOpeningPaidRelevant912, PreparedOriginOpening99, WouldViewCurrent99
OpenPlayInstructionInterrupt97 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPlayInstructionInterrupt97(c,f,beforeStack,afterStack,plan,id,site,instances,opening,usedWindows) ==
/\ PlayOwnerAtTop97(c,f,beforeStack) /\ PlayAbilityBound97(c) /\ c.phase="Imminent"
/\ OpenInstructionInterrupt93(beforeStack,afterStack,id,site,instances,opening,usedWindows,plan,c.ability,"NoValue")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpenInstructionInterrupt93, PlayAbilityBound97, PlayOwnerAtTop97
OpenPreparedBarrierInstructionInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPreparedBarrierInstructionInterrupt98(p,before,after,id,site,ledger,opening,usedWindows) ==
OpenBarrierInstructionInterrupt98(p,before,after,id,site,ConditionalWindowMembers96(ledger.instances,id),opening,usedWindows)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalWindowMembers96, OpenBarrierInstructionInterrupt98
OpenPreparedInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPreparedInterrupt99(beforeContext,afterContext,beforeStack,afterStack,origin,world,history,ledger,site,opening,usedWindows,cardFacts) ==
/\ beforeContext.phase="Prepared" /\ ExpectedContextOrigin99(beforeContext,origin) /\ ExpectedContextWorld99(beforeContext,world)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ BarrierInstructionOwnerAtTop98(beforeContext.owner,beforeStack)
/\ WouldViewCurrent99(history,beforeContext,world)
/\ site.turnId=world.turn.id /\ site.active=world.turn.owner
/\ opening=PreparedOriginOpening99(beforeContext,site)
/\ LET proposed == NewPriorityWindow9(beforeContext.windowId,"Interrupt",PriorityOpeningSite9(beforeStack,site),beforeContext.openingMembers,
beforeContext.group,NoTimingRef9,beforeContext.openingRef,beforeContext.openingRef.revision+1)
IN /\ beforeContext.conditionalIds # {} \/ OpeningPaidRelevant99(beforeContext,world,history,proposed) # {}
/\ IF origin.kind="BarrierInstruction" THEN
OpenBarrierInstructionInterrupt98(origin.procedure,beforeStack,afterStack,beforeContext.windowId,site,beforeContext.openingMembers,opening,usedWindows)
ELSE OpenInstructionInterrupt93(beforeStack,afterStack,beforeContext.windowId,site,beforeContext.openingMembers,opening,usedWindows,
origin.plan,origin.parent,origin.ruleStep)
/\ afterContext=[beforeContext EXCEPT !.phase="WindowOpen",!.site=site]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: proposed, BarrierInstructionOwnerAtTop98, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, OpenBarrierInstructionInterrupt98, OpenInstructionInterrupt93, OpeningPaidRelevant99, PreparedOriginOpening99, WouldViewCurrent99
OpenPriorityWindow9 · operator
reference-profile · input revision 2 · CC0 1.0
OpenPriorityWindow9(before,after,id,kind,site,instances,opening,usedWindowIds) ==
/\ id \in (Nat \ {0}) \ usedWindowIds
/\ id \notin {before[i].id : i \in 1..Len(before)}
/\ WindowSiteAllowed9(kind,PriorityOpeningSite9(before,site))
/\ opening.tag = "PriorityWindowOpening" /\ opening.windowId = id /\ opening.kind = kind
/\ opening.site = site /\ opening.members = DOMAIN instances
/\ opening.instances = instances
/\ IF kind = "Reaction" THEN
/\ DOMAIN instances # {} /\ ConditionalGroupValid9(instances,id,opening.group,FALSE)
/\ opening.preparation = <<"ConditionsMet","PendingGroup">>
/\ BeginningRefAtSite9(opening.beginning,site)
ELSE IF kind = "Interrupt" THEN
/\ ConditionalGroupValid9(instances,id,opening.group,TRUE)
/\ opening.instruction.id \in Nat \ {0} /\ opening.instruction.abilityInstance \in Nat \ {0}
/\ opening.instruction.index \in Nat \ {0} /\ opening.effectRevision \in Nat \ {0}
/\ opening.preparation = <<"ExpectedEffects","ReplacementEffects","ConditionalPending">>
/\ opening.modifiersExist /\ opening.beginning = NoTimingRef9
ELSE /\ instances = [x \in {} |-> x] /\ opening.group = 0 /\ opening.beginning = NoTimingRef9
/\ after = Append(before,NewPriorityWindow9(id,kind,PriorityOpeningSite9(before,site),instances,opening.group,
opening.beginning,opening.instruction,opening.effectRevision))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginningRefAtSite9, ConditionalGroupValid9, NewPriorityWindow9, NoTimingRef9, PriorityOpeningSite9, WindowSiteAllowed9
OpenSimultaneousEvaluation912 · operator
reference-profile · input revision 2 · CC0 1.0
OpenSimultaneousEvaluation912(after,world,printed,effects,lifetimes,authority,cardFacts) ==
/\ LifetimeReady910(lifetimes,authority) /\ world=authority.current
/\ PrintedCharacteristicsBound912(printed,world,cardFacts)
/\ \A id \in DOMAIN effects :
/\ effects[id].id=id /\ SimultaneousSourceBound912(effects[id],world,cardFacts)
/\ SimultaneousIRValid912(effects[id],world,printed)
/\ effects[id].provider="Lingering" =>
/\ effects[id].lifetimeId \in DOMAIN lifetimes.effects
/\ LET maintained == lifetimes.effects[effects[id].lifetimeId]
IN /\ maintained.source=effects[id].source /\ maintained.kind="Strength"
/\ effects[id].query=[kind |-> "Explicit",objects |-> {maintained.target}]
/\ effects[id].action=[kind |-> "Numeric",attribute |-> "Strength",operation |-> "Increase",
value |-> [kind |-> "Literal",value |-> maintained.value]]
/\ after=NewSimultaneousEvaluation912(world,printed,effects,lifetimes)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: maintained, LifetimeReady910, NewSimultaneousEvaluation912, PrintedCharacteristicsBound912, SimultaneousIRValid912, SimultaneousSourceBound912
OpeningConditionalKeys99 · operator
reference-profile · input revision 2 · CC0 1.0
OpeningConditionalKeys99(context,world,history,ledger) ==
{key \in DOMAIN world.conditional.definitions :
LET d == world.conditional.definitions[key]
IN /\ ConditionalActive96(d,world.conditional)
/\ InterruptRelevant99(d,world.lexemes[key],world.capabilities[key],context,world,history)
/\ ConditionalInterruptPrimary99(d,world.capabilities[key],context,world,history)
/\ IF d.primaryKind="Static" THEN ~ConditionalSibling96(d,ledger.instances) /\ StaticRetryAllowed96(d,ledger) ELSE TRUE}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, ConditionalActive96, ConditionalInterruptPrimary99, ConditionalSibling96, InterruptRelevant99, StaticRetryAllowed96
OpeningPaidRelevant99 · operator
reference-profile · input revision 2 · CC0 1.0
OpeningPaidRelevant99(context,world,history,w) ==
{key \in DOMAIN world.paidDefinitions :
LET d == world.paidDefinitions[key]
IN PaidBaseEligibility99(d,world.lexemes[key],world.paidContexts[key],[w EXCEPT !.priority=d.syntax.controller]) /\
InterruptRelevant99(d,world.lexemes[key],world.capabilities[key],context,world,history)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, InterruptRelevant99, PaidBaseEligibility99
OperativeInterruptWords99 · operator
reference-profile · input revision 2 · CC0 1.0
OperativeInterruptWords99(d,lex) ==
{lex.mentions[id].word : id \in {t \in DOMAIN lex.mentions : lex.mentions[t].owner=AbilityKey99(d) /\
(lex.mentions[t].role="EffectOperator" \/ lex.mentions[t].role="ImminentTrigger")}}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
OrderBefore98 · operator
reference-profile · input revision 2 · CC0 1.0
OrderBefore98(order,a,b) == OrderPosition98(order,a)<OrderPosition98(order,b)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OrderPosition98
OrderChangedState98 · operator
reference-profile · input revision 2 · CC0 1.0
OrderChangedState98(before,rows,newApplications,present,spine,decision,kind,lost,originKind) ==
LET gained == DOMAIN rows
IN [before EXCEPT !.present=present,!.spine=spine,!.order=VisibleSubOrder98(spine,present),!.usedIds=@ \cup gained,!.clock=@+1,
!.definitions=[id \in DOMAIN @ \cup gained |-> IF id \in gained THEN rows[id].definition ELSE @[id]],
!.applications=[id \in DOMAIN @ \cup DOMAIN newApplications |-> IF id \in DOMAIN newApplications THEN [definition |-> newApplications[id],clock |-> before.clock+1] ELSE @[id]],
!.activeApplications=@ \cup DOMAIN newApplications,
!.provenance=[id \in DOMAIN @ \cup gained |-> IF id \in gained THEN
[kind |-> originKind,effect |-> rows[id].effect,parent |-> rows[id].parent,printedSlot |-> rows[id].printedSlot,
born |-> before.clock+1,tie |-> OrderPosition98(decision.gainOrder,id),textKey |-> rows[id].textKey] ELSE @[id]],
!.history=Append(@,[kind |-> kind,clock |-> before.clock+1,gained |-> gained,lost |-> lost,decision |-> decision.id,applications |-> DOMAIN newApplications]),
!.decisions=[id \in DOMAIN @ \cup {decision.id} |-> IF id=decision.id THEN decision ELSE @[id]]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: gained, OrderPosition98, VisibleSubOrder98
OrderHasExceptions98 · operator
reference-profile · input revision 2 · CC0 1.0
OrderHasExceptions98(state) == \E id \in state.present : ~OrdinarySub98(state,id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OrdinarySub98
OrderPosition98 · operator
reference-profile · input revision 2 · CC0 1.0
OrderPosition98(order,id) == CHOOSE i \in 1..Len(order) : order[i]=idExact module download · Source bundle and reproduction instructions
OrderPosition99 · operator
reference-profile · input revision 2 · CC0 1.0
OrderPosition99(order,id) == CHOOSE i \in 1..Len(order) : order[i]=idExact module download · Source bundle and reproduction instructions
OrderPreserves98 · operator
reference-profile · input revision 2 · CC0 1.0
OrderPreserves98(after,before) == SelectSeq(after,LAMBDA id : id \in SubIds6(before))=beforeExact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
OrderingDecisionBound98 · operator
reference-profile · input revision 2 · CC0 1.0
OrderingDecisionBound98(before,decision,kind,gained,lost,spine,present) ==
/\ decision.tag="NormalizedBarrierInstructionOrderingDecision" /\ decision.id \in (Nat \ {0}) \ DOMAIN before.decisions
/\ decision.kind=kind /\ decision.barrierCard=before.barrierCard /\ decision.clock=before.clock+1
/\ decision.beforeOrder=before.order /\ decision.beforeSpine=before.spine /\ decision.beforePresent=before.present
/\ decision.beforeDefinitions=before.definitions /\ decision.beforeProvenance=before.provenance
/\ decision.beforeApplications=before.applications /\ decision.beforeHistory=before.history
/\ decision.gained=gained /\ decision.lost=lost /\ decision.afterSpine=spine /\ decision.afterOrder=VisibleSubOrder98(spine,present)
/\ DeckSequenceValid4(spine) /\ SubIds6(spine)=before.usedIds \cup gained /\ OrderPreserves98(spine,before.spine)
/\ DeckSequenceValid4(decision.gainOrder) /\ SubIds6(decision.gainOrder)=gained
/\ decision.authority=IF kind \in {"OrdinaryGain","SelfStaticResize","PrintedResize"} /\ OrderHasExceptions98(before)
THEN "MixedHistoryExtension" ELSE "DirectSourceClauses"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OrderHasExceptions98, OrderPreserves98, VisibleSubOrder98, DeckSequenceValid4, SubIds6
OrdinaryLingeringAlive910 · operator
reference-profile · input revision 2 · CC0 1.0
OrdinaryLingeringAlive910(effect,world) ==
LingeringBaseAlive910(effect,world) \/ GebrMaintenance910(effect,world)#{}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: GebrMaintenance910, LingeringBaseAlive910
OrdinaryPrecedes98 · operator
reference-profile · input revision 2 · CC0 1.0
OrdinaryPrecedes98(state,a,b) ==
LET ca == SubOriginCategory98(state,a)
cb == SubOriginCategory98(state,b)
pa == state.provenance[a]
pb == state.provenance[b]
IN IF ca # cb THEN ca<cb
ELSE CASE ca=3 -> pa.printedSlot<pb.printedSlot
[] ca \in {2,4} -> IF pa.born # pb.born THEN pa.born<pb.born ELSE pa.tie<pb.tie
[] OTHER -> LET ta == state.applications[pa.effect].clock
tb == state.applications[pb.effect].clock
IN IF ta # tb THEN IF ca=1 THEN ta>tb ELSE ta<tb ELSE pa.tie<pb.tieExact module download · Source bundle and reproduction instructions
OrdinarySub98 · operator
reference-profile · input revision 2 · CC0 1.0
OrdinarySub98(state,id) ==
state.provenance[id].kind # "Copy" /\ (state.provenance[id].kind="Printed" \/ state.applications[state.provenance[id].effect].definition.mode="Default")Exact module download · Source bundle and reproduction instructions
OriginAfterRevisions99 · operator
reference-profile · input revision 2 · CC0 1.0
OriginAfterRevisions99(before,after,count) ==
/\ ImminentOrigin99(before) /\ count \in Nat
/\ IF before.kind="BarrierInstruction" THEN after=[before EXCEPT !.procedure.revision=@+count]
ELSE after=[before EXCEPT !.plan.revision=@+count]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ImminentOrigin99
OriginReference99 · operator
reference-profile · input revision 2 · CC0 1.0
OriginReference99(origin) ==
IF origin.kind="BarrierInstruction" THEN BarrierInstructionWindowRef98(origin.procedure) ELSE InstructionWindowRef93(origin.plan)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionWindowRef98, InstructionWindowRef93
OriginRevision99 · operator
reference-profile · input revision 2 · CC0 1.0
OriginRevision99(origin) == OriginReference99(origin).revisionExact module download · Source bundle and reproduction instructions
Resolved project definitions: OriginReference99
PaidActivationContext9 · operator
reference-profile · input revision 2 · CC0 1.0
PaidActivationContext9(w) ==
[route |-> "Paid",open |-> w.open /\ w.stage = "Ready",kind |-> w.kind,priority |-> w.priority,
step |-> w.site.step,approachedBarrier |-> w.site.approachedBarrier,nonBarrierActivationAllowed |-> PaidWindowOptions9(w.site).nonBarrierActivation]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidWindowOptions9
PaidAlwaysOptional95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidAlwaysOptional95(d) == d.syntax.kind="Paid"Exact module download · Source bundle and reproduction instructions
PaidAsideExitView95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidAsideExitView95(p,transit,queryAbility,destination) ==
LET own == queryAbility=p.id /\ p.phase \in {"Targets","Imminent","Resolve"} /\ PaidProtectionAlive95(p)
base == SetAsideExitView4(transit,queryAbility,own,FALSE,destination)
IN [fromZone |-> base.fromZone,fromLocation |-> base.fromLocation,toZone |-> base.toZone,
fromFace |-> IF own THEN "Up" ELSE transit.originFace,wasDeployed |-> transit.originDeployed]Exact module download · Source bundle and reproduction instructions
PaidBaseEligibility99 · operator
reference-profile · input revision 2 · CC0 1.0
PaidBaseEligibility99(d,lex,c,w) ==
/\ PaidTraversalContextBound95(c) /\ PaidWindowContext95(c,w)
/\ d.syntax.kind="Paid" /\ d.activity.kind="Paid" /\ d.activity.id=d.syntax.id /\ d.activity.source=d.syntax.source
/\ AbilityTextValid93(d.syntax) /\ Len(d.triggerCost)>0 /\ Len(d.instructions)>0
/\ d.ruleTiming \in {"NoValue","BasicRetire"}
/\ d.ruleTiming="BasicRetire" => d.syntax.source=RuleAbilitySource9("BasicRetire")
/\ WindowSiteAllowed9(w.kind,w.site)
/\ w.kind \in PaidWindowKinds99(d,lex) /\ w.priority=d.syntax.controller /\ w.active=c.turn.owner /\ w.site.turnId=c.turn.id
/\ FlagActivity93(d.syntax,c.present,AbilityActive9(d.activity,c.objects,c.present,c.defaultActive, c.activity),c.activity.persistentAbilities,c.points)
/\ WholeAbilityRestrictionGate93(d.syntax,c.ownRestrictions) /\ PaidOtherRestrictions95(d,c)
/\ OncePerTurnAllowed93(d.syntax,c.turn.id,c.uses) /\ PaidSourceUseAllowed95(d,c)
/\ PaidEffectTiming95(d,c) /\ PaidInterfaceTiming95(d,c,w.site)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityActive9, AbilityTextValid93, FlagActivity93, OncePerTurnAllowed93, PaidEffectTiming95, PaidInterfaceTiming95, PaidOtherRestrictions95, PaidSourceUseAllowed95, PaidTraversalContextBound95, PaidWindowContext95, PaidWindowKinds99, RuleAbilitySource9, WholeAbilityRestrictionGate93, WindowSiteAllowed9
PaidCheckpoint95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidCheckpoint95(stack,before,after,objects,transits,actualCheckpoint) ==
/\ PaidProcedureAtTop95(stack,before) /\ before.phase \in {"CostCheckpoint","InstructionCheckpoint"}
/\ actualCheckpoint.tag="PaidCheckpoint" /\ actualCheckpoint.id \in Nat \ {0}
/\ actualCheckpoint.abilityInstance=before.id /\ actualCheckpoint.transactionId=before.transaction
/\ actualCheckpoint.phase=before.phase /\ actualCheckpoint.source=before.ability.source
/\ actualCheckpoint.complete /\ actualCheckpoint.allNewerChainsComplete
/\ PaidHeldProvenance95(before,objects,transits)
/\ PaidConvertedAsideIds95(before,objects,transits)={}
/\ IF before.ability.lastFinished THEN
PaidCleanupIds95(before,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(before,objects,transits,"ProcedureCode96bfa1b6a970") = {}
ELSE TRUE
/\ after=[before EXCEPT !.checkpoint=actualCheckpoint.id,
!.phase=IF before.ability.lastFinished THEN "Complete" ELSE "Targets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidCleanupIds95, PaidConvertedAsideIds95, PaidHeldProvenance95, PaidProcedureAtTop95
PaidCheckpointCaller96 · operator
reference-profile · input revision 2 · CC0 1.0
PaidCheckpointCaller96(p) ==
IF p.phase="CostCheckpoint" THEN [kind |-> "PaidTriggerCost",abilityInstance |-> p.id,source |-> p.ability.source,windowId |-> p.windowId,transactionId |-> p.transaction]
ELSE ConditionalInstructionCaller96(p)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalInstructionCaller96
PaidCheckpointWithConditionals96 · operator
reference-profile · input revision 2 · CC0 1.0
PaidCheckpointWithConditionals96(ledger,stack,before,after,objects,transits,actualCheckpoint) ==
/\ actualCheckpoint.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[actualCheckpoint.id].caller=PaidCheckpointCaller96(before)
/\ ConditionalCheckpointDrained96(ledger,stack,actualCheckpoint.id)
/\ PaidCheckpoint95(stack,before,after,objects,transits,actualCheckpoint)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, PaidCheckpoint95, PaidCheckpointCaller96
PaidCleanupIds95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidCleanupIds95(p,objects,transits,stage) ==
CostAsideCleanupIds4(transits,objects,IF p.ability.lastFinished THEN {p.id} ELSE {},stage)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CostAsideCleanupIds4
PaidConvertedAsideIds95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidConvertedAsideIds95(p,objects,transits) ==
{id \in p.heldIds \cap DOMAIN objects \cap DOMAIN transits :
objects[id].zone="SetAside" /\ transits[id].originForm="Counter" /\ objects[id].card # "none"}Exact module download · Source bundle and reproduction instructions
PaidEffectTiming95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidEffectTiming95(d,c) ==
/\ ~d.canSuppressBarrierInstructions \/ PaidEncounterLive95(c)
/\ ~d.refersApproachedBarrier \/
(/\ TraversalTimingPresent6(c.traversal) /\ ~c.traversal.ending /\ c.traversal.phase="Approach"
/\ c.approach.id=c.traversal.phaseId /\ c.approach.traversalId=c.traversal.id /\ c.approach.begun
/\ PaidReferenceStipulations95(d,"Approach",ApproachedBarrier6(c.approach,c.layout),d.approachRequirements,c))
/\ ~d.refersEncounteredBarrier \/
(PaidEncounterLive95(c) /\ PaidReferenceStipulations95(d,"Encounter",c.encounter.barrierCard,d.encounterRequirements,c))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidEncounterLive95, PaidReferenceStipulations95, ApproachedBarrier6, TraversalTimingPresent6
PaidEffectiveHeldCount95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidEffectiveHeldCount95(p,objects,transits,kind,actualCounterView,result) ==
/\ actualCounterView.tag="HeldCounterCount" /\ actualCounterView.abilityInstance=p.id /\ actualCounterView.source=p.ability.source
/\ actualCounterView.kind=kind /\ actualCounterView.physicalIds=PaidHeldCounters95(p,objects,transits,kind)
/\ actualCounterView.effectiveCount \in Nat /\ result=actualCounterView.effectiveCount
/\ actualCounterView.modifierIds={} => result=Cardinality(actualCounterView.physicalIds)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidHeldCounters95
PaidEligibility95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidEligibility95(d,c,w) ==
/\ PaidTraversalContextBound95(c) /\ PaidWindowContext95(c,w)
/\ d.syntax.kind="Paid" /\ d.activity.kind="Paid" /\ d.activity.id=d.syntax.id /\ d.activity.source=d.syntax.source
/\ AbilityTextValid93(d.syntax) /\ Len(d.triggerCost)>0 /\ Len(d.instructions)>0
/\ d.ruleTiming \in {"NoValue","BasicRetire"}
/\ d.ruleTiming="BasicRetire" => d.syntax.source=RuleAbilitySource9("BasicRetire")
/\ WindowSiteAllowed9(w.kind,w.site)
/\ w.kind \in PaidWindowKinds95(d) /\ w.priority=d.syntax.controller /\ w.active=c.turn.owner /\ w.site.turnId=c.turn.id
/\ FlagActivity93(d.syntax,c.present,AbilityActive9(d.activity,c.objects,c.present,c.defaultActive, c.activity),c.activity.persistentAbilities,c.points)
/\ WholeAbilityRestrictionGate93(d.syntax,c.ownRestrictions) /\ PaidOtherRestrictions95(d,c)
/\ OncePerTurnAllowed93(d.syntax,c.turn.id,c.uses) /\ PaidSourceUseAllowed95(d,c)
/\ PaidEffectTiming95(d,c) /\ PaidInterfaceTiming95(d,c,w.site)
/\ IF PaidIsInterrupt95(d) THEN
/\ InterruptEffectMatches9(w,c.currentEffect) /\ d.syntax.id \in c.currentEffect.paidInterruptAbilities
/\ c.paidRelevance.tag="PaidInterruptRelevance" /\ c.paidRelevance.windowId=w.id
/\ c.paidRelevance.instruction=w.instruction /\ c.paidRelevance.revision=c.currentEffect.revision
/\ [ability |-> d.syntax.id,source |-> d.syntax.source] \in c.paidRelevance.eligible
ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityActive9, AbilityTextValid93, FlagActivity93, InterruptEffectMatches9, OncePerTurnAllowed93, PaidEffectTiming95, PaidInterfaceTiming95, PaidIsInterrupt95, PaidOtherRestrictions95, PaidSourceUseAllowed95, PaidTraversalContextBound95, PaidWindowContext95, PaidWindowKinds95, RuleAbilitySource9, WholeAbilityRestrictionGate93, WindowSiteAllowed9
PaidEligibility99 · operator
reference-profile · input revision 2 · CC0 1.0
PaidEligibility99(d,lex,c,w,cardFacts) ==
/\ AbilityLexemesValid99(d,lex,c.objects,cardFacts)
/\ PaidEligibilityCore99(d,lex,c,w)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityLexemesValid99, PaidEligibilityCore99
PaidEligibilityCore99 · operator
reference-profile · input revision 2 · CC0 1.0
PaidEligibilityCore99(d,lex,c,w) ==
/\ PaidBaseEligibility99(d,lex,c,w)
/\ IF AbilityInterrupt99(d,lex) THEN
/\ InterruptEffectMatches9(w,c.currentEffect) /\ d.syntax.id \in c.currentEffect.paidInterruptAbilities
/\ c.paidRelevance.tag="PaidInterruptRelevance" /\ c.paidRelevance.windowId=w.id
/\ c.paidRelevance.instruction=w.instruction /\ c.paidRelevance.revision=c.currentEffect.revision
/\ [ability |-> d.syntax.id,source |-> d.syntax.source] \in c.paidRelevance.eligible
ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, InterruptEffectMatches9, PaidBaseEligibility99
PaidEncounterLive95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidEncounterLive95(c) == EncounterTimingLive95(c.encounter,c.traversalControl)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterTimingLive95
PaidHeldCounters95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidHeldCounters95(p,objects,transits,kind) ==
{id \in p.heldIds \cap DOMAIN objects : objects[id].form="Counter" /\ objects[id].kind=kind /\ PaidOwnerCanQuery95(p,objects,transits,id,p.id)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidOwnerCanQuery95
PaidHeldInteraction95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidHeldInteraction95(p,objects,transits,object,queryAbility) ==
IF PaidHeldObject95(p,objects,transits,object)
THEN PaidOwnerCanQuery95(p,objects,transits,object,queryAbility) ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidHeldObject95, PaidOwnerCanQuery95
PaidHeldObject95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidHeldObject95(p,objects,transits,object) ==
/\ object \in p.heldIds \cap DOMAIN objects \cap DOMAIN transits
/\ objects[object].zone="SetAside" /\ transits[object].protected /\ transits[object].ability=p.idExact module download · Source bundle and reproduction instructions
PaidHeldProvenance95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidHeldProvenance95(p,objects,transits) ==
\A id \in p.heldIds \cap DOMAIN objects : objects[id].zone="SetAside" =>
/\ id \in DOMAIN transits /\ transits[id].protected /\ transits[id].ability=p.id /\ transits[id].effect=p.transaction
/\ transits[id].cleanupStage=IF p.sourceForfeited THEN "ProcedureCode76ca53ad9dd0" ELSE "ProcedureCode96bfa1b6a970"Exact module download · Source bundle and reproduction instructions
PaidHeldTransfer95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidHeldTransfer95(p,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,actualPayment) ==
LET source == p.ability.source.object
hosted == IF p.ability.source.kind="Object" THEN PaidPhysicalHosted95(beforeObjects,source) ELSE {}
protect == (actualPayment.sourceUninstalled \/ actualPayment.sourceForfeited) /\ p.definition.refersHosted
selected == IF protect THEN hosted ELSE {}
IN /\ HostedCostSetAsideChoice4(hosted,DOMAIN successors,actualPayment.sourceUninstalled \/ actualPayment.sourceForfeited,p.definition.refersHosted)
/\ DOMAIN beforeObjects \subseteq usedIds /\ FreshSuccessors8(selected,successors,usedIds)
/\ actualPayment.sourceAfter # 0 /\ actualPayment.sourceAfter # source => actualPayment.sourceAfter \notin usedIds
/\ \A old \in selected :
LET new == successors[old]
IN /\ new \in DOMAIN afterObjects /\ old \notin DOMAIN afterObjects
/\ afterObjects[new].card=beforeObjects[old].card /\ afterObjects[new].host=0
/\ IF beforeObjects[old].card="none" THEN
afterObjects[new].form="Counter" /\ afterObjects[new].kind=beforeObjects[old].kind /\ ~afterObjects[new].virtual
ELSE TRUE
/\ SetAsideEntryPost4(afterObjects[new],FALSE,FALSE,TRUE)
/\ afterTransits=[id \in (DOMAIN beforeTransits \ selected) \cup {successors[old] : old \in selected} |->
IF id \in {successors[old] : old \in selected}
THEN ProtectedPaidTransit95(id,beforeObjects[CHOOSE old \in selected : successors[old]=id],p,actualPayment.sourceForfeited)
ELSE beforeTransits[id]]
/\ SetAsideTrackingValid4(afterObjects,afterTransits)
/\ IF actualPayment.sourceForfeited THEN
ForfeitObjectivePost8(beforeObjects,afterObjects,source,actualPayment.sourceAfter,usedIds)
ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: hosted, new, selected, source, ProtectedPaidTransit95, HostedCostSetAsideChoice4, SetAsideEntryPost4, SetAsideTrackingValid4, ForfeitObjectivePost8, FreshSuccessors8
PaidInterfaceTiming95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidInterfaceTiming95(d,c,site) ==
IF ~FlagPresent93(d.syntax.units,"Interface") THEN TRUE
ELSE LET source == d.syntax.source.object
barrierCard == c.encounter.barrierCard
IN /\ d.syntax.source.kind="Object" /\ {source,barrierCard} \subseteq DOMAIN c.objects
/\ InterfaceFlagTiming93(d.syntax,d.syntax.controller,c.objects[source],c.subtypes[source],
[isInterface |-> TRUE,presentActive |-> TRUE,restriction |-> d.interfaceSubtype],
[encounterActive |-> PaidEncounterLive95(c),step |-> site.step,
barrierForm |-> c.objects[barrierCard].form,barrierKind |-> c.objects[barrierCard].kind,barrierId |-> barrierCard,barrierInstructions |-> SubIds6(c.encounter.order)],
c.strengths[source],c.strengths[barrierCard],c.subtypes[barrierCard],{})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: barrierCard, source, FlagPresent93, InterfaceFlagTiming93, PaidEncounterLive95, SubIds6
PaidIsInterrupt95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidIsInterrupt95(d) == AbilityIsInterrupt9(FlagPresent93(d.syntax.units,"Interrupt"),d.instructionHasWould)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityIsInterrupt9, FlagPresent93
PaidOptionKind95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidOptionKind95(windowKind) ==
CASE windowKind="NeutralValue00001" -> "NeutralValue00001" [] windowKind="Paid" -> "RegularPaid"
[] windowKind="Interrupt" -> "PaidInterrupt" [] windowKind="MidItemInspection" -> "MidItemInspection" [] OTHER -> "Invalid"Exact module download · Source bundle and reproduction instructions
PaidOptionMatches95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidOptionMatches95(d,option,w) ==
option.kind=PaidOptionKind95(w.kind) /\ option.ability=d.syntax.id /\ option.source=d.syntax.source /\ option.controller=d.syntax.controllerExact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidOptionKind95
PaidOtherRestrictions95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidOtherRestrictions95(d,c) ==
/\ c.otherRestrictions.tag="OtherPaidRestrictions" /\ c.otherRestrictions.ability=d.syntax.id
/\ c.otherRestrictions.source=d.syntax.source /\ DOMAIN c.otherRestrictions.results=d.otherRestrictionIds
/\ \A id \in DOMAIN c.otherRestrictions.results : c.otherRestrictions.results[id]Exact module download · Source bundle and reproduction instructions
PaidOwnerCanQuery95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidOwnerCanQuery95(p,objects,transits,object,queryAbility) ==
/\ PaidProtectionAlive95(p) /\ PaidHeldObject95(p,objects,transits,object) /\ queryAbility=p.id
/\ p.phase \in {"Targets","Imminent","Resolve"}
/\ SetAsideAbilityCanSee4(transits[object],queryAbility,TRUE,FALSE)
/\ IF p.phase="Targets" THEN p.checkpoint \in Nat \ {0}
ELSE CostAsideStillHosted4(transits[object],queryAbility,TRUE,AbilityIsResolving9(p.ability))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityIsResolving9, PaidHeldObject95, PaidProtectionAlive95, CostAsideStillHosted4, SetAsideAbilityCanSee4
PaidPaymentProof95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidPaymentProof95(p,beforeObjects,afterObjects,actualPayment) ==
/\ p.phase="PayCosts" /\ ~p.costPaid
/\ actualPayment.tag="PaidTriggerPayment" /\ actualPayment.abilityInstance=p.id /\ actualPayment.transactionId=p.transaction
/\ actualPayment.ability=p.definition.syntax.id /\ actualPayment.source=p.ability.source
/\ actualPayment.triggerCost=p.definition.triggerCost /\ actualPayment.beforeObjects=beforeObjects /\ actualPayment.afterObjects=afterObjects
/\ actualPayment.announced /\ actualPayment.allPaid /\ actualPayment.additionalCostsPaid
/\ actualPayment.restrictionsBefore /\ actualPayment.restrictionsAfter /\ actualPayment.simultaneousProcedureComplete
/\ IF p.ability.source.kind="Rule" THEN
~actualPayment.sourceUninstalled /\ ~actualPayment.sourceForfeited /\ actualPayment.sourceAfter=0
ELSE LET source == p.ability.source.object
IN /\ source \in DOMAIN beforeObjects
/\ actualPayment.sourceAfter \in Nat
/\ actualPayment.sourceAfter # source => source \notin DOMAIN afterObjects
/\ IF actualPayment.sourceAfter=0 THEN
beforeObjects[source].form="Counter" /\ beforeObjects[source].card="none" /\ source \notin DOMAIN afterObjects
ELSE /\ actualPayment.sourceAfter \in DOMAIN afterObjects
/\ afterObjects[actualPayment.sourceAfter].card=beforeObjects[source].card
/\ beforeObjects[source].zone # afterObjects[actualPayment.sourceAfter].zone => actualPayment.sourceAfter # source
/\ actualPayment.sourceUninstalled = (beforeObjects[source].deployed /\
(IF actualPayment.sourceAfter=0 THEN TRUE ELSE ~afterObjects[actualPayment.sourceAfter].deployed))
/\ actualPayment.sourceForfeited = (\E op \in actualPayment.paidOperations : op.kind="Forfeit" /\ op.object=source)
/\ actualPayment.sourceForfeited => beforeObjects[source].zone \in SetupObjectiveZonesExact module download · Source bundle and reproduction instructions
Resolved project definitions: source, SetupObjectiveZones
PaidPhysicalHosted95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidPhysicalHosted95(objects,source) ==
{id \in DOMAIN objects : objects[id].host=source /\ (objects[id].form="Card" \/ (objects[id].form="Counter" /\ ~objects[id].virtual))}Exact module download · Source bundle and reproduction instructions
PaidProcedureAtTop95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidProcedureAtTop95(stack,p) ==
/\ Len(stack)>0
/\ LET w == WindowTop9(stack)
IN w.id=p.windowId /\ w.busy=p.option /\ w.busyTransaction=p.transaction /\ w.stage \in {"Resolving","Closed"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w
PaidProtectionAlive95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidProtectionAlive95(p) == p.costPaid /\ ~p.ability.lastFinishedExact module download · Source bundle and reproduction instructions
PaidReferenceContext95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidReferenceContext95(reference,c,witness) ==
IF reference="Approach" THEN
/\ witness.structure=TimingRef9("TraversalPhase",c.approach.id) /\ witness.traversalId=c.approach.traversalId
/\ PaidTraversalContextBound95(c) /\ c.traversal.phaseId \notin c.traversalControl.phaseEndedIds
ELSE /\ witness.structure=TimingRef9("TraversalPhase",c.encounter.id) /\ witness.traversalId=c.encounter.traversalIdExact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidTraversalContextBound95, TimingRef9
PaidReferenceStipulations95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidReferenceStipulations95(d,reference,barrierCard,requirements,c) ==
/\ barrierCard \in DOMAIN c.objects /\ c.objects[barrierCard].form="Card" /\ c.objects[barrierCard].kind="Barrier"
/\ requirements.subtypes \subseteq c.subtypes[barrierCard]
/\ ~requirements.activated \/ ActivationStatus8(c.objects[barrierCard])="ItemActivated"
/\ LET witness == c.references[reference]
IN /\ witness.tag="PaidBarrierReference" /\ witness.ability=d.syntax.id /\ witness.source=d.syntax.source
/\ witness.reference=reference /\ witness.barrierCard=barrierCard /\ PaidReferenceContext95(reference,c,witness)
/\ DOMAIN witness.results=requirements.otherIds
/\ \A id \in DOMAIN witness.results : witness.results[id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: witness, PaidReferenceContext95, ActivationStatus8
PaidRequiredWindows95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidRequiredWindows95(d) ==
(IF IsAction5(TRUE,d.triggerCost) THEN {"NeutralValue00001"} ELSE {}) \cup
(IF PaidIsInterrupt95(d) THEN {"Interrupt"} ELSE {}) \cup
(IF FlagPresent93(d.syntax.units,"ItemInspection") \/ d.ruleTiming="BasicRetire" THEN {"MidItemInspection"} ELSE {})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93, PaidIsInterrupt95, IsAction5
PaidRequiredWindows99 · operator
reference-profile · input revision 2 · CC0 1.0
PaidRequiredWindows99(d,lex) ==
(IF IsAction5(TRUE,d.triggerCost) THEN {"NeutralValue00001"} ELSE {}) \cup
(IF AbilityInterrupt99(d,lex) THEN {"Interrupt"} ELSE {}) \cup
(IF FlagPresent93(d.syntax.units,"ItemInspection") \/ d.ruleTiming="BasicRetire" THEN {"MidItemInspection"} ELSE {})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, FlagPresent93, IsAction5
PaidSourceUseAllowed95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidSourceUseAllowed95(d,c) ==
~\E p \in c.useProhibitions : p.source=d.syntax.source /\ p.traversalId=c.traversal.id /\ TraversalTimingPresent6(c.traversal)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TraversalTimingPresent6
PaidTraversalContextBound95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidTraversalContextBound95(c) ==
/\ TraversalFrameValid6(c.traversal) /\ c.traversalControl.traversal=c.traversal
/\ c.traversalControl.phaseEndedIds \subseteq Nat \ {0}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TraversalFrameValid6
PaidWindowContext95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidWindowContext95(c,w) ==
IF w.kind="Paid" /\ w.site.route="SchemaAtom138" /\ w.site.step="ProcedureCode8b3260c0010f" THEN
/\ w.site.structure=TimingRef9("TraversalPhase",c.encounter.id) /\ w.site.traversalId=c.encounter.traversalId
/\ PaidEncounterLive95(c)
ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidEncounterLive95, TimingRef9
PaidWindowKinds95 · operator
reference-profile · input revision 2 · CC0 1.0
PaidWindowKinds95(d) ==
LET required == PaidRequiredWindows95(d)
IN IF required={} THEN {"Paid"} ELSE IF Cardinality(required)=1 THEN required ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: required
PaidWindowKinds99 · operator
reference-profile · input revision 2 · CC0 1.0
PaidWindowKinds99(d,lex) ==
LET required == PaidRequiredWindows99(d,lex)
IN IF required={} THEN {"Paid"} ELSE IF Cardinality(required)=1 THEN required ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: required
PaidWindowOptions9 · operator
reference-profile · input revision 2 · CC0 1.0
PaidWindowOptions9(site) ==
CASE site.route = "Turn" ->
LET info == IF site.active = "SideA" THEN SideAStepInfo5(site.step) ELSE SideBStepInfo5(site.step)
IN [paid |-> info.kind = "PaidWindow",nonBarrierActivation |-> "Activation" \in info.options,
approachedBarrierActivation |-> FALSE,score |-> "ObjectiveCompletion" \in info.options]
[] site.route = "SchemaAtom138" -> TraversalWindowOptions6(site.step)
[] OTHER -> [paid |-> FALSE,nonBarrierActivation |-> FALSE,approachedBarrierActivation |-> FALSE,score |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: info, TraversalWindowOptions6
PassConditionalPriority96 · operator
reference-profile · input revision 2 · CC0 1.0
PassConditionalPriority96(before,candidate,after,beforeStack,afterStack,player,currentEffect,beforeSnapshot,afterSnapshot) ==
/\ PassConditionalPriorityCore96(before,candidate,beforeStack,
ReplaceWindowTop9(beforeStack,PassPriorityFrame9(WindowTop9(beforeStack))),player,currentEffect)
/\ ObserveConditionalActivity96(before,candidate,after,ReplaceWindowTop9(beforeStack,PassPriorityFrame9(WindowTop9(beforeStack))),afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObserveConditionalActivity96, PassConditionalPriorityCore96, PassPriorityFrame9, ReplaceWindowTop9, WindowTop9
PassConditionalPriorityCore96 · operator
reference-profile · input revision 2 · CC0 1.0
PassConditionalPriorityCore96(beforeLedger,afterLedger,beforeStack,afterStack,player,currentEffect) ==
/\ PassPriority9(beforeStack,afterStack,player,currentEffect)
/\ afterLedger=ConditionalPendingAfterWindows96(beforeLedger,afterStack)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalPendingAfterWindows96, PassPriority9
PassCurrentInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
PassCurrentInterrupt99(beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,player,context,origin,world,history,
beforeSnapshot,afterSnapshot,cardFacts) ==
/\ CurrentInterruptWorld99(world,beforeLedger,cardFacts) /\ ExpectedContextOrigin99(context,origin)
/\ ExpectedContextWorld99(context,world) /\ WouldViewCurrent99(history,context,world) /\ CurrentInterruptWindow99(context,beforeStack)
/\ beforeSnapshot=world.conditional
/\ PassConditionalPriority96(beforeLedger,candidateLedger,afterLedger,beforeStack,afterStack,player,
CurrentEffectReceipt99(context,world,history,beforeLedger,WindowTop9(beforeStack)),beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentEffectReceipt99, CurrentInterruptWindow99, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, PassConditionalPriority96, WindowTop9, WouldViewCurrent99
PassMidItemInspection9 · operator
reference-profile · input revision 2 · CC0 1.0
PassMidItemInspection9(before,after,a,afterItemInspection,objects,options,mustRetire,exampleFamily034) ==
/\ Len(before)>0
/\ LET w == WindowTop9(before)
IN /\ w.kind = "MidItemInspection" /\ w.open /\ w.stage = "Ready" /\ w.priority = "SideB"
/\ w.checkpoint # 0 /\ w.busy.id = 0 /\ w.site.structure = TimingRef9("ItemInspection",a.id)
/\ DeclineMidItemInspection7(a,afterItemInspection,objects,options,mustRetire,exampleFamily034,TRUE)
/\ after = ReplaceWindowTop9(before,ClosePriorityWindow9(w))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, ClosePriorityWindow9, ReplaceWindowTop9, TimingRef9, DeclineMidItemInspection7
PassPersistentPriority912 · operator
reference-profile · input revision 2 · CC0 1.0
PassPersistentPriority912(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,beforeStack,candidateStack,afterStack,
player,currentEffect,beforeSnapshot,afterSnapshot,beforeAuthority,afterAuthority) ==
/\ PassConditionalPriorityCore96(beforeLedger,candidateLedger,beforeStack,candidateStack,player,currentEffect)
/\ LET w == WindowTop9(beforeStack)
closed == WindowTop9(candidateStack)
keys == IF w.kind="Reaction" /\ w.open /\ ~closed.open THEN PersistentEndWindows912(beforeRegistry,w.id) ELSE {}
execution == [tag |-> "CurrentCharacteristicsEvaluation",id |-> w.id,snapshotId |-> afterAuthority.current.id,
source |-> RuleAbilitySource9("ProcedureCode17f2a65162fb"),closedWindow |-> IF closed.open THEN 0 ELSE closed.id]
IN /\ \A key \in keys :
/\ w.site.traversalId=beforeRegistry.persistent[key].traversalId
/\ DOMAIN w.members=beforeRegistry.persistent[key].endMembers
/\ \A id \in DOMAIN w.members : w.members[id]=beforeLedger.instances[id].member
/\ PublishPersistentExpiration912(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,candidateStack,afterStack,
beforeSnapshot,afterSnapshot,keys,execution,beforeAuthority,afterAuthority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, keys, w, PassConditionalPriorityCore96, PublishPersistentExpiration912
PassPriority9 · operator
reference-profile · input revision 2 · CC0 1.0
PassPriority9(before,after,player,actualCurrentEffect) ==
/\ Len(before)>0
/\ LET w == WindowTop9(before)
IN /\ w.open /\ w.stage = "Ready" /\ w.checkpoint # 0 /\ w.busy.id = 0 /\ w.priority = player
/\ CanPassPriority9(w,actualCurrentEffect)
/\ after = ReplaceWindowTop9(before,PassPriorityFrame9(w))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, CanPassPriority9, PassPriorityFrame9, ReplaceWindowTop9
PassPriorityFrame9 · operator
reference-profile · input revision 2 · CC0 1.0
PassPriorityFrame9(w) ==
IF w.kind = "Reaction" THEN
LET optional == PendingOwned9(w,w.priority,FALSE)
lost == [w EXCEPT !.pending = @ \ optional,!.lostPending = @ \cup optional]
IN IF w.priority = w.active THEN ReceivePriority9(lost,TurnOtherPlayer5(w.active)) ELSE ClosePriorityWindow9(lost)
ELSE IF w.previousPass THEN ClosePriorityWindow9(w)
ELSE ReceivePriority9([w EXCEPT !.previousPass = TRUE],TurnOtherPlayer5(w.priority))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost, ClosePriorityWindow9, ReceivePriority9, TurnOtherPlayer5
PauseOccurrenceInstruction912 · operator
reference-profile · input revision 2 · CC0 1.0
PauseOccurrenceInstruction912(before,after,plan,context,id,cause,child,point,operation,request,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceRuntimeProfile912(before)
/\ before.phase="Resolve" /\ before.ability.phase="Resolving" /\ before.pause.id=0
/\ OccurrencePlan912(before,plan) /\ plan.phase="Resolving"
/\ id \in Nat \ {0} /\ InstructionPausePoint911(before,plan,context,cause,child,point,operation)
/\ InstructionPauseKey911(context,plan,cause,child,point,operation) \notin before.pauseKeys
/\ request.tag="OwnedInstructionCheckpointRequest" /\ request.id \in Nat \ {0}
/\ request.caller=InstructionPauseCaller911(before,plan,cause,child,point)
/\ after=[before EXCEPT !.phase="Paused",!.pauseKeys=@ \cup {InstructionPauseKey911(context,plan,cause,child,point,operation)},!.pause=[id |-> id,cause |-> cause,childId |-> child.id,point |-> point,
instruction |-> InstructionWindowRef93(plan),cursor |-> plan.cursor,operation |-> operation,request |-> request]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPauseCaller911, InstructionPauseKey911, InstructionPausePoint911, InstructionWindowRef93, LifetimeReady910, OccurrencePlan912, OccurrenceRuntimeProfile912
PauseRuntimeInstruction911 · operator
reference-profile · input revision 2 · CC0 1.0
PauseRuntimeInstruction911(before,after,plan,context,id,cause,child,point,operation,request,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeProfile911(before)
/\ before.phase="Resolve" /\ before.ability.phase="Resolving" /\ before.pause.id=0
/\ RuntimeCurrentPlan911(before,plan) /\ plan.phase="Resolving"
/\ id \in Nat \ {0} /\ InstructionPausePoint911(before,plan,context,cause,child,point,operation)
/\ InstructionPauseKey911(context,plan,cause,child,point,operation) \notin before.pauseKeys
/\ request.tag="OwnedInstructionCheckpointRequest" /\ request.id \in Nat \ {0}
/\ request.caller=InstructionPauseCaller911(before,plan,cause,child,point)
/\ after=[before EXCEPT !.phase="Paused",!.pauseKeys=@ \cup {InstructionPauseKey911(context,plan,cause,child,point,operation)},!.pause=[id |-> id,cause |-> cause,childId |-> child.id,point |-> point,
instruction |-> InstructionWindowRef93(plan),cursor |-> plan.cursor,operation |-> operation,request |-> request]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionPauseCaller911, InstructionPauseKey911, InstructionPausePoint911, InstructionWindowRef93, LifetimeReady910, RuntimeCurrentPlan911, RuntimeProfile911
PayMidItemInspectionOption9 · operator
reference-profile · input revision 2 · CC0 1.0
PayMidItemInspectionOption9(stack,a,afterItemInspection,objects,midOption,options,mustRetire,exampleFamily034,actualPayment) ==
/\ Len(stack)>0
/\ LET w == WindowTop9(stack)
IN /\ w.kind="MidItemInspection" /\ w.busy.id # 0 /\ w.stage \in {"Resolving","Closed"}
/\ w.site.structure=TimingRef9("ItemInspection",a.id) /\ w.busy.target=a.object /\ w.busy.ability=midOption.id
/\ PriorityPaymentMatches9(w,actualPayment)
/\ UseMidItemInspection7(a,afterItemInspection,objects,midOption,options,mustRetire,exampleFamily034,
actualPayment.allTriggerCostsPaid,actualPayment.costCheckpointAndReactionsDrained)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, PriorityPaymentMatches9, TimingRef9, UseMidItemInspection7
PayPaidMidItemInspection95 · operator
reference-profile · input revision 2 · CC0 1.0
PayPaidMidItemInspection95(stack,before,after,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,
actualPayment,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events,a,afterItemInspection,midOption,options,mustRetire,exampleFamily034,beginDrain,itemInspectionEvents) ==
/\ PaidProcedureAtTop95(stack,before) /\ WindowTop9(stack).kind="MidItemInspection"
/\ WindowTop9(stack).site.structure=TimingRef9("ItemInspection",a.id)
/\ before.option.target=a.object /\ before.option.ability=midOption.id
/\ beginDrain.tag="MidItemInspectionBeginDrained" /\ beginDrain.itemInspectionId=a.id /\ beginDrain.windowId=before.windowId
/\ beginDrain.checkpointId=before.initialCheckpoint /\ beginDrain.checkpointId \in Nat \ {0} /\ beginDrain.complete
/\ CommitPaidTrigger95(stack,before,after,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,
actualPayment,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events)
/\ LET used == [a EXCEPT !.midUsed=TRUE,!.midResolving=TRUE]
IN /\ UseMidItemInspection7(a,used,beforeObjects,midOption,options,mustRetire,exampleFamily034,actualPayment.allPaid,beginDrain.complete)
/\ ItemInspectionMovementOutcome7(used,afterItemInspection,afterObjects,TRUE,itemInspectionEvents)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: used, CommitPaidTrigger95, PaidProcedureAtTop95, TimingRef9, WindowTop9, ItemInspectionMovementOutcome7, UseMidItemInspection7
PayPaidTrigger95 · operator
reference-profile · input revision 2 · CC0 1.0
PayPaidTrigger95(stack,before,after,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,actualPayment,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events) ==
/\ PaidProcedureAtTop95(stack,before) /\ WindowTop9(stack).kind # "MidItemInspection"
/\ CommitPaidTrigger95(stack,before,after,beforeObjects,afterObjects,beforeTransits,afterTransits,successors,usedIds,actualPayment,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CommitPaidTrigger95, PaidProcedureAtTop95, WindowTop9
PendingOwned9 · operator
reference-profile · input revision 2 · CC0 1.0
PendingOwned9(w,player,mandatoryOnly) ==
{id \in w.pending : w.members[id].controller = player /\ (~mandatoryOnly \/ w.members[id].mandatory)}Exact module download · Source bundle and reproduction instructions
PersistentApplicationAllowed912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentApplicationAllowed912(registry,d,traversalId) ==
/\ PersistentDefinitionProfile912(registry,d)
/\ LET key == AbilityKey99(d)
IN IF key \notin DOMAIN registry.persistent THEN TRUE
ELSE LET row == registry.persistent[key]
IN row.definition=d /\ key \in PersistentLiveKeys912(registry) /\ row.traversalId#0 /\ traversalId=row.traversalIdExact module download · Source bundle and reproduction instructions
Resolved project definitions: key, row, PersistentDefinitionProfile912, PersistentLiveKeys912
PersistentBirthCohort912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentBirthCohort912(inventory,world) ==
{key \in DOMAIN inventory.definitions : FlagPresent93(inventory.definitions[key].syntax.units,"Persistent") /\
inventory.definitions[key].syntax.side="SideA" /\ inventory.definitions[key].syntax.id \in world.present}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FlagPresent93
PersistentCandidateAllowed912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCandidateAllowed912(registry,d,cp,eventId,scope) ==
IF eventId=0 THEN PersistentGenerationAllowed912(registry,d,scope.traversalId)
ELSE PersistentGenerationAllowed912(registry,d,cp.occurrences[eventId].traversal.id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentGenerationAllowed912
PersistentCapturedLexemes912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCapturedLexemes912(registry,definitions,lexemes) ==
\A key \in PersistentLiveKeys912(registry) \cap DOMAIN definitions :
registry.persistent[key].definition.syntax.kind \in {"Conditional","Paid"} =>
/\ key \in DOMAIN lexemes /\ lexemes[key]=registry.persistent[key].lexemesExact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentLiveKeys912
PersistentCheckpointBound912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCheckpointBound912(registry,ledger) ==
\A key \in PersistentLiveKeys912(registry) :
LET row == registry.persistent[key]
seen == {id \in DOMAIN ledger.checkpoints : ledger.checkpoints[id].caller=PersistentTraversalEndCaller912(row.traversalId)}
IN IF seen={} THEN row.creationOpen /\ row.endCheckpoint=0 /\ row.endWindow=0 /\ row.endMembers={}
ELSE /\ ~row.creationOpen /\ row.endCheckpoint \in seen
/\ row.endMembers \subseteq {id \in DOMAIN ledger.instances : ledger.instances[id].checkpointId=row.endCheckpoint}
/\ {id \in DOMAIN ledger.instances : ledger.instances[id].checkpointId=row.endCheckpoint /\ ledger.instances[id].status="Pending"} \subseteq row.endMembers
/\ IF row.endMembers={} THEN row.endWindow=0
ELSE row.endWindow \in Nat \ {0} /\ \A id \in row.endMembers : ledger.instances[id].member.windowId=row.endWindowExact module download · Source bundle and reproduction instructions
Resolved project definitions: row, seen, PersistentLiveKeys912
PersistentCheckpointCandidates912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCheckpointCandidates912(registry,definitions,lexemes,ledger,cp,conditions,scope) ==
{candidate \in CheckpointCandidates99(definitions,lexemes,ledger,cp,conditions) :
PersistentCandidateAllowed912(registry,definitions[candidate.definition],cp,candidate.occurrence,scope)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CheckpointCandidates99, PersistentCandidateAllowed912
PersistentCheckpointCompletion912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCheckpointCompletion912(ledger,cp,world) ==
[tag |-> "NormalCheckpointCompletion",checkpointId |-> cp.id,caller |-> cp.caller,snapshotId |-> world.id,point |-> "ProcedureCodeb74d673a0fc6",
recognizedInstances |-> PersistentRecognizedIds912(ledger,cp.id),
members |-> [id \in PersistentRecognizedIds912(ledger,cp.id) |-> ledger.instances[id].member]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentRecognizedIds912
PersistentConditionalDefinitions912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentConditionalDefinitions912(registry,definitions) ==
/\ PersistentDefinitionsProfile912(registry,definitions)
/\ \A key \in PersistentLiveKeys912(registry) :
registry.persistent[key].definition.syntax.kind="Conditional" =>
/\ key \in DOMAIN definitions /\ definitions[key]=registry.persistent[key].definitionExact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentDefinitionsProfile912, PersistentLiveKeys912
PersistentCurrentEffect912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCurrentEffect912(registry,context,world,history,ledger,w) ==
[tag |-> "CurrentImminentEffect",windowId |-> w.id,instruction |-> w.instruction,revision |-> context.currentRef.revision+1,
relevantConditional |-> CurrentPendingRelevant99(context,world,history,ledger),
paidInterruptAbilities |-> {key.ability : key \in PersistentCurrentPaidRelevant912(registry,context,world,history,w)}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPendingRelevant99, PersistentCurrentPaidRelevant912
PersistentCurrentPaidRelevance912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCurrentPaidRelevance912(registry,context,world,history,w) ==
[tag |-> "PaidInterruptRelevance",windowId |-> w.id,instruction |-> w.instruction,revision |-> context.currentRef.revision+1,
eligible |-> PersistentCurrentPaidRelevant912(registry,context,world,history,w)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentCurrentPaidRelevant912
PersistentCurrentPaidRelevant912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentCurrentPaidRelevant912(registry,context,world,history,w) ==
{key \in CurrentPaidRelevant99(context,world,history,w) : PersistentGenerationAllowed912(registry,world.paidDefinitions[key],world.traversalControl.traversal.id)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPaidRelevant99, PersistentGenerationAllowed912
PersistentDefinitionProfile912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentDefinitionProfile912(registry,d) ==
LET owners == {key \in DOMAIN registry.persistent : registry.persistent[key].definition.syntax.id=d.syntax.id}
IN owners={} \/ (owners={AbilityKey99(d)} /\ registry.persistent[AbilityKey99(d)].definition=d)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: owners, AbilityKey99
PersistentDefinitionsProfile912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentDefinitionsProfile912(registry,definitions) ==
\A key \in DOMAIN definitions : PersistentDefinitionProfile912(registry,definitions[key])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentDefinitionProfile912
PersistentEffect912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentEffect912(id,d,lex,trash,traversalId,world) ==
[id |-> id,kind |-> "Ordinary",source |-> d.syntax.source,creation |-> <<"PersistentItemInspectionRetire",trash.id,AbilityKey99(d)>>,
creationTurn |-> world.turn.id,originKind |-> "Rule",target |-> trash.source,value |-> "MaintainOriginalAbility",
baseDuration |-> [kind |-> "Stated",specification |-> [kind |-> "PersistentOriginalTraversalEndReaction",ability |-> AbilityKey99(d),
traversalId |-> traversalId,trash |-> trash.id,itemInspection |-> trash.itemInspection.id]],durationClass |-> "Stated",choicePolicy |-> "NoValue",choiceKey |-> "NoValue",
lingeringConsumers |-> {},otherConsumers |-> {},definitionId |-> d.syntax.id,persistence |-> PersistentOrigin912(id,d,lex,trash,world),
status |-> IF traversalId=0 THEN "Expired" ELSE "Active"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, PersistentOrigin912
PersistentEndWindows912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentEndWindows912(registry,windowId) ==
{key \in DOMAIN registry.persistent : registry.persistent[key].phase="Persisting" /\
~registry.persistent[key].creationOpen /\ registry.persistent[key].endCheckpoint#0 /\ registry.persistent[key].endWindow=windowId}Exact module download · Source bundle and reproduction instructions
PersistentExpirationRegistry912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentExpirationRegistry912(registry,keys) ==
[registry EXCEPT !.persistent=[key \in DOMAIN @ |-> IF key \in keys THEN
[@[key] EXCEPT !.phase="Expired",!.creationOpen=FALSE] ELSE @[key]]]Exact module download · Source bundle and reproduction instructions
PersistentGeneratedIds912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentGeneratedIds912(ledger,cpId) == {id \in DOMAIN ledger.instances : ledger.instances[id].checkpointId=cpId /\ ledger.instances[id].status="Pending"}Exact module download · Source bundle and reproduction instructions
PersistentGeneratedWindow912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentGeneratedWindow912(ledger,cpId) ==
LET ids == PersistentGeneratedIds912(ledger,cpId)
IN IF ids={} THEN 0 ELSE ledger.instances[CHOOSE id \in ids : TRUE].member.windowIdExact module download · Source bundle and reproduction instructions
Resolved project definitions: ids
PersistentGenerationAllowed912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentGenerationAllowed912(registry,d,traversalId) ==
/\ PersistentApplicationAllowed912(registry,d,traversalId)
/\ AbilityKey99(d) \notin DOMAIN registry.persistent \/ registry.persistent[AbilityKey99(d)].creationOpenExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, PersistentApplicationAllowed912
PersistentHasExposureMarkersIds912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentHasExposureMarkersIds912(rows) == {id \in DOMAIN rows : "persistence" \in DOMAIN rows[id]}Exact module download · Source bundle and reproduction instructions
PersistentInstanceRows912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentInstanceRows912(rows,ledger) ==
[id \in DOMAIN rows \cup DOMAIN ledger.instances |->
IF id \in DOMAIN ledger.instances THEN
ReplacementOverlay99(IF id \in DOMAIN rows THEN rows[id] ELSE [field \in {} |-> field],
[ability |-> ledger.instances[id].member.ability,sourceObject |-> ledger.instances[id].member.source.object,status |-> ledger.instances[id].status])
ELSE rows[id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
PersistentInterruptWorld912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentInterruptWorld912(registry,world,ledger,authority) ==
/\ LifetimeReady910(registry,authority) /\ PersistentRegistryWorldBound912(registry,authority.current) /\ PersistentCheckpointBound912(registry,ledger)
/\ world.id=authority.current.id /\ world.objects=authority.current.objects
/\ world.turn=authority.current.turn /\ world.traversalControl=authority.current.control
/\ world.conditional.id=world.id /\ ConditionalSnapshotBound96(world.conditional,ledger)
/\ LingeringConditionalWorld910(world.conditional,ledger,authority.current)
/\ PersistentConditionalDefinitions912(registry,world.conditional.definitions)
/\ PersistentPaidDefinitions912(registry,world.paidDefinitions)
/\ PersistentCapturedLexemes912(registry,CurrentInterruptDefinitions99(world),world.lexemes)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalSnapshotBound96, CurrentInterruptDefinitions99, LifetimeReady910, LingeringConditionalWorld910, PersistentCapturedLexemes912, PersistentCheckpointBound912, PersistentConditionalDefinitions912, PersistentPaidDefinitions912, PersistentRegistryWorldBound912
PersistentInventory912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentInventory912(inventory,trash,world,cardFacts) ==
/\ inventory.tag="AuthoritativeSourceAbilityInventory" /\ inventory.worldId=world.id /\ inventory.source=ObjectAbilitySource9(trash.source)
/\ inventory.card=world.objects[trash.source].card /\ inventory.sourceSHA=cardFacts[inventory.card].sourceSHA
/\ DOMAIN inventory.lexemes=DOMAIN inventory.definitions
/\ \A key \in DOMAIN inventory.definitions :
LET d == inventory.definitions[key]
IN /\ key=AbilityKey99(d) /\ d.syntax.source=inventory.source /\ d.activity.source=inventory.source
/\ d.activity.provider \in {"Printed","Granted"}
/\ AbilityTextValid93(d.syntax) /\ AbilityLexemesValid99(d,inventory.lexemes[key],world.objects,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, AbilityKey99, AbilityLexemesValid99, AbilityTextValid93, ObjectAbilitySource9
PersistentKnownIds912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentKnownIds912(registry) == {registry.persistent[key].definition.syntax.id : key \in DOMAIN registry.persistent}Exact module download · Source bundle and reproduction instructions
PersistentLiveIds912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentLiveIds912(registry) == {registry.persistent[key].definition.syntax.id : key \in PersistentLiveKeys912(registry)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentLiveKeys912
PersistentLiveKeys912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentLiveKeys912(registry) == {key \in DOMAIN registry.persistent : registry.persistent[key].phase="Persisting" /\ registry.persistent[key].effectId \in DOMAIN registry.effects /\ registry.effects[registry.persistent[key].effectId].status="Active"}Exact module download · Source bundle and reproduction instructions
PersistentOpeningPaidRelevant912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentOpeningPaidRelevant912(registry,context,world,history,w) ==
{key \in OpeningPaidRelevant99(context,world,history,w) : PersistentGenerationAllowed912(registry,world.paidDefinitions[key],world.traversalControl.traversal.id)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpeningPaidRelevant99, PersistentGenerationAllowed912
PersistentOrigin912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentOrigin912(id,d,lex,trash,world) ==
[tag |-> "PersistentAbilityMaintenance",effectId |-> id,key |-> AbilityKey99(d),definition |-> d,lexemes |-> lex,
sourceCard |-> world.objects[trash.source].card,sourceCardSHA |-> world.cardFacts[world.objects[trash.source].card].sourceSHA,
sourceZone |-> world.objects[trash.source].zone,sourceTargetSite |-> world.objects[trash.source].targetSite,
successor |-> trash.successor,trashId |-> trash.id,itemInspectionId |-> trash.itemInspection.id,traversalId |-> trash.itemInspection.traversalId]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
PersistentPaidContext912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentPaidContext912(c,ledger,world) ==
/\ c.points=world.points
/\ c.present \ DelayedConditionalAbilityIds96(ledger.effects)=world.present \ DelayedConditionalAbilityIds96(ledger.effects)
/\ c.activity=world.activity \/ c.activity=[world.activity EXCEPT !.instances=ConditionalActivityRows96(ledger.instances)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityRows96, DelayedConditionalAbilityIds96
PersistentPaidDefinitions912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentPaidDefinitions912(registry,definitions) ==
/\ PersistentDefinitionsProfile912(registry,definitions)
/\ \A key \in PersistentLiveKeys912(registry) :
registry.persistent[key].definition.syntax.kind="Paid" =>
/\ key \in DOMAIN definitions /\ definitions[key]=registry.persistent[key].definitionExact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentDefinitionsProfile912, PersistentLiveKeys912
PersistentRecognizedIds912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentRecognizedIds912(ledger,cpId) == {id \in DOMAIN ledger.instances : ledger.instances[id].checkpointId=cpId}Exact module download · Source bundle and reproduction instructions
PersistentRecord912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentRecord912(d,lex,id,trash,world) ==
[definition |-> d,lexemes |-> lex,effectId |-> id,sourceCard |-> world.objects[trash.source].card,
sourceCardSHA |-> world.cardFacts[world.objects[trash.source].card].sourceSHA,sourceZone |-> world.objects[trash.source].zone,
sourceTargetSite |-> world.objects[trash.source].targetSite,successor |-> trash.successor,trashId |-> trash.id,itemInspectionId |-> trash.itemInspection.id,
traversalId |-> trash.itemInspection.traversalId,phase |-> IF trash.itemInspection.traversalId=0 THEN "Expired" ELSE "Persisting",
creationOpen |-> trash.itemInspection.traversalId#0,endCheckpoint |-> 0,endWindow |-> 0,endMembers |-> {}]Exact module download · Source bundle and reproduction instructions
PersistentRegistryBound912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentRegistryBound912(registry) ==
/\ Cardinality({registry.persistent[key].effectId : key \in DOMAIN registry.persistent})=Cardinality(DOMAIN registry.persistent)
/\ PersistentHasExposureMarkersIds912(registry.effects)={registry.persistent[key].effectId : key \in
{key \in DOMAIN registry.persistent : registry.persistent[key].effectId \in DOMAIN registry.effects}}
/\ \A key \in DOMAIN registry.persistent :
LET row == registry.persistent[key]
IN /\ key=AbilityKey99(row.definition) /\ FlagPresent93(row.definition.syntax.units,"Persistent")
/\ row.effectId \in registry.usedEffects /\ row.trashId \in registry.persistentRetireIds
/\ row.phase \in {"Persisting","Expired"} /\ (row.phase="Expired" => ~row.creationOpen)
/\ IF row.effectId \notin DOMAIN registry.effects THEN row.phase="Expired"
ELSE LET effect == registry.effects[row.effectId]
IN /\ effect.persistence=PersistentRowOrigin912(key,row)
/\ effect.id=row.effectId /\ effect.source=row.definition.syntax.source /\ effect.definitionId=row.definition.syntax.id
/\ effect.kind="Ordinary" /\ effect.originKind="Rule" /\ effect.value="MaintainOriginalAbility"
/\ effect.creation= <<"PersistentItemInspectionRetire",row.trashId,key>>
/\ effect.baseDuration=[kind |-> "Stated",specification |-> [kind |-> "PersistentOriginalTraversalEndReaction",ability |-> key,
traversalId |-> row.traversalId,trash |-> row.trashId,itemInspection |-> row.itemInspectionId]]
/\ effect.status=IF row.phase="Persisting" THEN "Active" ELSE "Expired"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effect, row, AbilityKey99, FlagPresent93, PersistentHasExposureMarkersIds912, PersistentRowOrigin912
PersistentRegistryWorldBound912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentRegistryWorldBound912(registry,world) ==
/\ PersistentRegistryBound912(registry)
/\ world.activity.persistentAbilities=PersistentLiveIds912(registry)
/\ world.present \cap PersistentKnownIds912(registry)=PersistentLiveIds912(registry)
/\ PersistentHasExposureMarkersIds912(world.statedDurations)={registry.persistent[key].effectId : key \in DOMAIN registry.persistent}
/\ \A key \in DOMAIN registry.persistent :
LET row == registry.persistent[key]
observation == world.statedDurations[row.effectId]
IN /\ observation.persistence=PersistentRowOrigin912(key,row)
/\ observation.active=(row.phase="Persisting")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: observation, row, PersistentHasExposureMarkersIds912, PersistentKnownIds912, PersistentLiveIds912, PersistentRegistryBound912, PersistentRowOrigin912
PersistentRetireBound912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentRetireBound912(trash,inventory,beforeWorld,afterObjects,usedObjects,cardFacts) ==
/\ trash.tag="ActualSideBItemInspectionRetire" /\ trash.id \in Nat \ {0} /\ trash.actor="SideB"
/\ trash.source \in DOMAIN beforeWorld.objects /\ beforeWorld.objects[trash.source].side="SideA"
/\ ActivationStatus8(beforeWorld.objects[trash.source])="ItemActivated"
/\ trash.itemInspection.id \in DOMAIN beforeWorld.itemInspections /\ beforeWorld.itemInspections[trash.itemInspection.id]=trash.itemInspection
/\ trash.itemInspection.object=trash.source /\ StillItemInspectioning7(trash.itemInspection,beforeWorld.objects)
/\ trash.itemInspection.traversalId=0 \/ (trash.itemInspection.traversalId=beforeWorld.control.traversal.id /\ TraversalTimingPresent6(beforeWorld.control.traversal))
/\ PersistentInventory912(inventory,trash,beforeWorld,cardFacts)
/\ CardBatchTransfer8(beforeWorld.objects,afterObjects,{trash.source},[id \in {trash.source} |-> trash.successor],usedObjects,
"SideADiscard","Up",[id \in {trash.source} |-> "SideADiscard"])
/\ trash.movement.tag="CardMovement" /\ trash.movement.kind="Retire" /\ trash.movement.sources={trash.source}
/\ trash.movement.successors=[id \in {trash.source} |-> trash.successor]
/\ trash.movement.id=trash.id /\ trash.movement.disposition="Complete"
/\ RecordMovement8(trash.historyBefore,trash.historyAfter,trash.id,"Retire",{trash.source},"Complete",TRUE,trash.events)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentInventory912, StillItemInspectioning7, ActivationStatus8, CardBatchTransfer8, RecordMovement8, TraversalTimingPresent6
PersistentRowOrigin912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentRowOrigin912(key,row) ==
[tag |-> "PersistentAbilityMaintenance",effectId |-> row.effectId,key |-> key,definition |-> row.definition,lexemes |-> row.lexemes,
sourceCard |-> row.sourceCard,sourceCardSHA |-> row.sourceCardSHA,sourceZone |-> row.sourceZone,sourceTargetSite |-> row.sourceTargetSite,
successor |-> row.successor,trashId |-> row.trashId,itemInspectionId |-> row.itemInspectionId,traversalId |-> row.traversalId]Exact module download · Source bundle and reproduction instructions
PersistentSourceActive912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentSourceActive912(d,world) ==
FlagActivity93(d.syntax,world.present,AbilityActive9(d.activity,world.objects,world.present,
LingeringObjectActive910(d.syntax.source,world),world.activity),world.activity.persistentAbilities,world.points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityActive9, FlagActivity93, LingeringObjectActive910
PersistentStaticDefinitions912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentStaticDefinitions912(registry) ==
[key \in {k \in PersistentLiveKeys912(registry) : registry.persistent[k].definition.syntax.kind="Static"} |-> registry.persistent[key].definition]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentLiveKeys912
PersistentStaticPart912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentStaticPart912(registry,d,part,conditions,world,application,ledger,authority) ==
/\ LifetimeReady910(registry,authority) /\ PersistentRegistryWorldBound912(registry,authority.current) /\ world=authority.current
/\ application.tag="CurrentStaticApplication" /\ application.worldId=world.id /\ application.traversalId=world.control.traversal.id
/\ PersistentApplicationAllowed912(registry,d,application.traversalId)
/\ StaticPartApplies94(d.syntax,part,PersistentSourceActive912(d,world),conditions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, PersistentApplicationAllowed912, PersistentRegistryWorldBound912, PersistentSourceActive912, StaticPartApplies94
PersistentTraversalEndCaller912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentTraversalEndCaller912(traversalId) == [kind |-> "TraversalStep",structure |-> TimingRef9("SchemaAtom138",traversalId),step |-> "ProcedureCode9606a4cd52b4"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
PersistentWorld912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentWorld912(base,registry) ==
LET ids == {registry.persistent[key].effectId : key \in DOMAIN registry.persistent}
IN [base EXCEPT !.present=(@ \ PersistentKnownIds912(registry)) \cup PersistentLiveIds912(registry),
!.activity.persistentAbilities=(@ \ PersistentKnownIds912(registry)) \cup PersistentLiveIds912(registry),
!.statedDurations=ReplacementOverlay99(@,[id \in ids |->
LET key == CHOOSE key \in DOMAIN registry.persistent : registry.persistent[key].effectId=id
IN IF id \in DOMAIN registry.effects THEN
[receipt |-> StatedDurationReceipt910(registry.effects[id],base),active |-> registry.persistent[key].phase="Persisting",
persistence |-> PersistentRowOrigin912(key,registry.persistent[key])]
ELSE [active |-> FALSE,persistence |-> PersistentRowOrigin912(key,registry.persistent[key])]] )]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ids, key, PersistentKnownIds912, PersistentLiveIds912, PersistentRowOrigin912, ReplacementOverlay99, StatedDurationReceipt910
PersistentWorldBound912 · operator
reference-profile · input revision 2 · CC0 1.0
PersistentWorldBound912(registry,world,ledger,authority) ==
PersistentInterruptWorld912(registry,world,ledger,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PersistentInterruptWorld912
PlayAbilityBound97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayAbilityBound97(c) ==
/\ c.cursor<=Len(c.order) /\ c.id \in Nat \ {0} /\ c.id \in c.usedInstances
/\ c.ability.id=c.id /\ c.ability.kind="Play" /\ c.ability.source=c.source /\ c.ability.sourceZone="Play"
/\ c.ability.caller=c.playId /\ c.ability.instructions=CurrentPlayDefinition97(c).instructions /\ ~c.ability.detachedExact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPlayDefinition97
PlayActivationCaller97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayActivationCaller97(f) == [kind |-> "PlayActivation",playId |-> f.id,caller |-> f.caller,source |-> ObjectAbilitySource9(f.object),transactionId |-> f.transaction]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObjectAbilitySource9
PlayAdvanceDisposition97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayAdvanceDisposition97(c,disposition,instance) ==
[c EXCEPT !.dispositions=[id \in DOMAIN @ \cup {c.order[c.cursor]} |->
IF id=c.order[c.cursor] THEN [disposition |-> disposition,instance |-> instance] ELSE @[id]],
!.cursor=@+1,!.phase=IF c.cursor=Len(c.order) THEN "Complete" ELSE "Ready",
!.id=0,!.ability=PlayIdleAbility97(c.source,c.playId),!.checkpoint=0]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PlayIdleAbility97
PlayCurrentActive97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayCurrentActive97(c,f,objects,present,activity,points) ==
LET d == CurrentPlayDefinition97(c)
IN IF c.source.object \notin DOMAIN objects THEN FALSE
ELSE FlagActivity93(d.syntax,present,
AbilityActive9(d.activity,objects,present,PlayEffectiveCardActivity8(f,c.source.object,objects[c.source.object],FALSE),activity),
activity.persistentAbilities,points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, AbilityActive9, FlagActivity93, PlayEffectiveCardActivity8
PlayDefinitionValid97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayDefinitionValid97(d) ==
/\ d.syntax.kind="Play" /\ d.activity.kind="Play" /\ d.activity.provider="Printed"
/\ d.syntax.cardKind \in {"Action","Plan"} /\ AbilityTextValid93(d.syntax)
/\ d.activity.id=d.syntax.id /\ d.activity.source=d.syntax.source /\ Len(d.instructions)>0
/\ DOMAIN d.partsByInstruction=SubIds6(d.instructions)
/\ d.optionalParts \subseteq UNION {d.partsByInstruction[i] : i \in DOMAIN d.partsByInstruction}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityTextValid93, SubIds6
PlayIdleAbility97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayIdleAbility97(source,caller) == OpenAbilityResolution9(0,"Play",source,"Play",<<>>,caller)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OpenAbilityResolution9
PlayInstructionCaller97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayInstructionCaller97(c) ==
[kind |-> "PlayInstruction",playId |-> c.playId,abilityInstance |-> c.id,source |-> c.source,transactionId |-> c.transaction,
instruction |-> c.ability.instructions[c.ability.cursor],index |-> c.ability.cursor,windowId |-> c.owner.windowId]Exact module download · Source bundle and reproduction instructions
PlayInstructionCheckpoint97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayInstructionCheckpoint97(before,after,f,stack,ledger,receipt) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ PlayAbilityBound97(before) /\ before.phase="InstructionCheckpoint"
/\ receipt.tag="PlayInstructionCheckpoint" /\ receipt.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[receipt.id].caller=PlayInstructionCaller97(before)
/\ ConditionalCheckpointDrained96(ledger,stack,receipt.id)
/\ receipt.playId=before.playId /\ receipt.abilityInstance=before.id /\ receipt.source=before.source
/\ receipt.instruction=before.ability.instructions[before.ability.cursor] /\ receipt.index=before.ability.cursor
/\ receipt.transactionId=before.transaction /\ receipt.complete /\ receipt.allNewerChainsComplete
/\ after=[before EXCEPT !.checkpoint=receipt.id,!.phase=IF before.ability.lastFinished THEN "AbilityComplete" ELSE "Targets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, PlayAbilityBound97, PlayInstructionCaller97, PlayOwnerAtTop97
PlayInvocationValid97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayInvocationValid97(f,stack,invocation) ==
/\ invocation.tag="PlayInvocation" /\ invocation.playId=f.id /\ invocation.object=f.object
/\ invocation.caller=f.caller /\ invocation.transactionId=f.transaction
/\ invocation.owner.windowId \in Nat /\ invocation.origin \in {"NeutralValue00001","Instruction"}
/\ IF invocation.origin="NeutralValue00001" THEN
/\ invocation.owner.windowId # 0 /\ f.caller=invocation.owner.windowId
/\ Len(stack)>0 /\ WindowTop9(stack).kind="NeutralValue00001"
ELSE /\ f.caller=invocation.parentPlan.id
/\ ConditionalCreationInstruction96(invocation.parentPlan,invocation.parentAbility,invocation.ruleStep)
/\ invocation.instruction=InstructionWindowRef93(invocation.parentPlan)
/\ IF invocation.owner.windowId=0 THEN
Len(stack)=0 /\ invocation.owner.option=NoPriorityOption9 /\ invocation.owner.transaction=0
ELSE /\ Len(stack)>0 /\ WindowTop9(stack).id=invocation.owner.windowId
/\ WindowTop9(stack).busy=invocation.owner.option /\ WindowTop9(stack).busy.id # 0
/\ WindowTop9(stack).busyTransaction=invocation.owner.transactionExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCreationInstruction96, InstructionWindowRef93, NoPriorityOption9, WindowTop9
PlayOwnerAtTop97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayOwnerAtTop97(c,f,stack) ==
/\ f.stage="ProcedureCode3d7f756d78f7" /\ ~f.complete /\ ~f.returned
/\ c.playId=f.id /\ c.source=ObjectAbilitySource9(f.object) /\ c.transaction=f.transaction
/\ IF c.owner.windowId=0 THEN Len(stack)=0
ELSE /\ Len(stack)>0 /\ WindowTop9(stack).id=c.owner.windowId
/\ WindowTop9(stack).busy=c.owner.option /\ WindowTop9(stack).busy.id # 0
/\ WindowTop9(stack).busyTransaction=c.owner.transactionExact module download · Source bundle and reproduction instructions
Resolved project definitions: ObjectAbilitySource9, WindowTop9
PlayPresenceValid97 · operator
reference-profile · input revision 2 · CC0 1.0
PlayPresenceValid97(c,objects,present) ==
c.source.object \notin DOMAIN objects \/ SubIds6(c.order) \subseteq presentExact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
PlaySourceTextValid97 · operator
reference-profile · input revision 2 · CC0 1.0
PlaySourceTextValid97(f,objects,text,cardFacts) ==
/\ f.object \in DOMAIN objects /\ PlayTypeAllowed8(objects[f.object],f.actor)
/\ objects[f.object].zone="Play" /\ f.kind=objects[f.object].kind /\ f.activationReached
/\ text.tag="NormalizedPrintedAbilities" /\ text.playId=f.id /\ text.object=f.object
/\ text.card=objects[f.object].card /\ text.sourceSHA=cardFacts[text.card].sourceSHA
/\ DeckSequenceValid4(text.order) /\ DOMAIN text.definitions=SubIds6(text.order)
/\ \A id \in DOMAIN text.definitions :
LET d == text.definitions[id]
IN /\ d.syntax.id=id /\ d.syntax.source=ObjectAbilitySource9(f.object)
/\ d.syntax.controller=f.actor /\ d.syntax.cardKind=f.kind /\ d.syntax.side=f.actor
/\ d.activity.id=id /\ d.activity.source=d.syntax.source /\ d.activity.kind=d.syntax.kind /\ d.activity.provider="Printed"
/\ AbilityTextValid93(d.syntax)
/\ (d.syntax.kind="Play" => PlayDefinitionValid97(d))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, AbilityTextValid93, ObjectAbilitySource9, PlayDefinitionValid97, DeckSequenceValid4, PlayTypeAllowed8, SubIds6
PlayedSourceIsResolving9 · operator
reference-profile · input revision 2 · CC0 1.0
PlayedSourceIsResolving9(playFrame) == playFrame.stage = "ProcedureCode3d7f756d78f7" /\ ~playFrame.completeExact module download · Source bundle and reproduction instructions
PopClosedPriorityWindow9 · operator
reference-profile · input revision 2 · CC0 1.0
PopClosedPriorityWindow9(before,after) ==
/\ Len(before)>0 /\ ~WindowTop9(before).open /\ WindowTop9(before).busy.id = 0
/\ LET rest == SubSeq(before,1,Len(before)-1)
IN after = IF Len(rest)>0 /\ WindowTop9(rest).open /\ WindowTop9(rest).stage = "Ready"
THEN ReplaceWindowTop9(rest,ReceivePriority9(WindowTop9(rest),WindowTop9(rest).priority)) ELSE restExact module download · Source bundle and reproduction instructions
Resolved project definitions: rest, ReceivePriority9, ReplaceWindowTop9, WindowTop9
PositiveBeforeEffect99 · operator
reference-profile · input revision 2 · CC0 1.0
PositiveBeforeEffect99(before,id) ==
id \in DOMAIN before /\ before[id].kind \in {"Damage","ExposureMarkers"} /\ before[id].value>0Exact module download · Source bundle and reproduction instructions
PositivePreventionObservations99 · operator
reference-profile · input revision 2 · CC0 1.0
PositivePreventionObservations99(before,after,actualResolved) ==
{[tag |-> "ExpectedPreventionObservation",kind |-> IF before[id].kind="ExposureMarkers" THEN "AvoidExposureMarker" ELSE "PreventDamage",
effectId |-> id,amount |-> PreventedPositiveAmount99(before,after,id),source |-> actualResolved.source,
interruptInstance |-> actualResolved.abilityInstance,operationId |-> actualResolved.id,instruction |-> actualResolved.instruction] :
id \in {effect \in DOMAIN before : PositivePreventionObserved99(before,after,effect,actualResolved)}}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PositivePreventionObserved99, PreventedPositiveAmount99
PositivePreventionObserved99 · operator
reference-profile · input revision 2 · CC0 1.0
PositivePreventionObserved99(before,after,id,actualResolved) ==
/\ ResolvedExpectedInterrupt99(before,after,actualResolved)
/\ actualResolved.operation \in {"PreventAmount","PreventWhole","ExampleFamily091HarmClassAToOne"}
/\ PreventedPositiveAmount99(before,after,id)>0Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PreventedPositiveAmount99, ResolvedExpectedInterrupt99
PreImminentAbilityPlan93 · operator
reference-profile · input revision 2 · CC0 1.0
PreImminentAbilityPlan93(plan,ability) ==
/\ CASE ability.phase="Ready" -> ability.cursor=1 /\ ~ability.firstImminent /\ InstructionPlanMatches93(plan,ability,1)
[] ability.phase="Between" -> AbilityIsResolving9(ability) /\ InstructionPlanMatches93(plan,ability,ability.cursor+1)
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityIsResolving9, InstructionPlanMatches93
PrepareOpeningInterrupts99 · operator
reference-profile · input revision 2 · CC0 1.0
PrepareOpeningInterrupts99(beforeContext,afterContext,beforeLedger,afterLedger,origin,world,history,windowId,group,allocation,usedWindows,cardFacts) ==
/\ InitialWouldCaptured99(beforeContext,history)
/\ beforeContext.phase="Replacing" /\ ExpectedContextOrigin99(beforeContext,origin) /\ ExpectedContextWorld99(beforeContext,world)
/\ WouldViewCurrent99(history,beforeContext,world)
/\ CurrentInterruptWorld99(world,beforeLedger,cardFacts)
/\ ReplacementSourcesBound99(beforeContext,world,cardFacts)
/\ ReplacementPreparationComplete99(beforeContext.state,ActiveReplacementBlueprints99(beforeContext,world))
/\ windowId \in (Nat \ {0}) \ usedWindows /\ group \in Nat \ {0}
/\ LET candidates == OpeningConditionalKeys99(beforeContext,world,history,beforeLedger)
ids == {allocation[key] : key \in candidates}
recognitions == {[definition |-> key,occurrence |-> beforeContext.imminenceId] : key \in candidates}
additions == [id \in ids |-> LET key == CHOOSE k \in candidates : allocation[k]=id
IN NewOpeningInterruptInstance99(id,world.conditional.definitions[key],world.conditional,beforeLedger,beforeContext,windowId,group)]
IN /\ DOMAIN allocation=candidates /\ Cardinality(ids)=Cardinality(candidates)
/\ ids \subseteq (Nat \ {0}) \ DOMAIN beforeLedger.instances
/\ recognitions \cap beforeLedger.interruptRecognitions={}
/\ afterLedger=[beforeLedger EXCEPT !.instances=ReplacementOverlay99(@,additions),!.interruptRecognitions=@ \cup recognitions]
/\ afterContext=[beforeContext EXCEPT !.phase="Prepared",!.preparedEffects=beforeContext.state.effects,!.openingRef=beforeContext.currentRef,
!.conditionalIds=ids,!.conditionalDefinitions=[key \in candidates |-> world.conditional.definitions[key]],
!.windowId=windowId,!.group=group,!.openingMembers=[id \in ids |-> additions[id].member]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: additions, candidates, ids, recognitions, ActiveReplacementBlueprints99, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, InitialWouldCaptured99, ReplacementOverlay99, ReplacementPreparationComplete99, ReplacementSourcesBound99, WouldViewCurrent99
PreparePersistentOpening912 · operator
reference-profile · input revision 2 · CC0 1.0
PreparePersistentOpening912(registry,beforeContext,afterContext,beforeLedger,afterLedger,origin,world,history,windowId,group,allocation,usedWindows,cardFacts,authority) ==
/\ PersistentInterruptWorld912(registry,world,beforeLedger,authority)
/\ InitialWouldCaptured99(beforeContext,history)
/\ beforeContext.phase="Replacing" /\ ExpectedContextOrigin99(beforeContext,origin) /\ ExpectedContextWorld99(beforeContext,world)
/\ WouldViewCurrent99(history,beforeContext,world)
/\ CurrentInterruptWorld99(world,beforeLedger,cardFacts)
/\ ReplacementSourcesBound99(beforeContext,world,cardFacts)
/\ ReplacementPreparationComplete99(beforeContext.state,ActiveReplacementBlueprints99(beforeContext,world))
/\ windowId \in (Nat \ {0}) \ usedWindows /\ group \in Nat \ {0}
/\ LET candidates == {key \in OpeningConditionalKeys99(beforeContext,world,history,beforeLedger) :
PersistentGenerationAllowed912(registry,world.conditional.definitions[key],world.traversalControl.traversal.id)}
ids == {allocation[key] : key \in candidates}
recognitions == {[definition |-> key,occurrence |-> beforeContext.imminenceId] : key \in candidates}
additions == [id \in ids |-> LET key == CHOOSE k \in candidates : allocation[k]=id
IN NewOpeningInterruptInstance99(id,world.conditional.definitions[key],world.conditional,beforeLedger,beforeContext,windowId,group)]
IN /\ DOMAIN allocation=candidates /\ Cardinality(ids)=Cardinality(candidates)
/\ ids \subseteq (Nat \ {0}) \ DOMAIN beforeLedger.instances
/\ recognitions \cap beforeLedger.interruptRecognitions={}
/\ afterLedger=[beforeLedger EXCEPT !.instances=ReplacementOverlay99(@,additions),!.interruptRecognitions=@ \cup recognitions]
/\ afterContext=[beforeContext EXCEPT !.phase="Prepared",!.preparedEffects=beforeContext.state.effects,!.openingRef=beforeContext.currentRef,
!.conditionalIds=ids,!.conditionalDefinitions=[key \in candidates |-> world.conditional.definitions[key]],
!.windowId=windowId,!.group=group,!.openingMembers=[id \in ids |-> additions[id].member]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: additions, candidates, ids, recognitions, ActiveReplacementBlueprints99, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, InitialWouldCaptured99, PersistentInterruptWorld912, ReplacementOverlay99, ReplacementPreparationComplete99, ReplacementSourcesBound99, WouldViewCurrent99
PrepareReplacementEffects99 · operator
reference-profile · input revision 2 · CC0 1.0
PrepareReplacementEffects99(before,after,replacements,world,states,steps) ==
/\ Len(states)=Len(steps)+1 /\ states[1]=before /\ states[Len(states)]=after
/\ ReplacementStateValid99(before) /\ ReplacementBlueprintsValid99(replacements)
/\ \A index \in 1..Len(steps) :
ApplyReplacementStep99(states[index],states[index+1],steps[index].effectId,replacements,world,steps[index].decision)
/\ ReplacementPreparationComplete99(after,replacements)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ApplyReplacementStep99, ReplacementBlueprintsValid99, ReplacementPreparationComplete99, ReplacementStateValid99
PreparedOriginOpening99 · operator
reference-profile · input revision 2 · CC0 1.0
PreparedOriginOpening99(context,site) ==
[tag |-> "PriorityWindowOpening",windowId |-> context.windowId,kind |-> "Interrupt",site |-> site,
members |-> context.conditionalIds,instances |-> context.openingMembers,group |-> context.group,beginning |-> NoTimingRef9,
instruction |-> context.openingRef,effectRevision |-> context.openingRef.revision+1,
modifiersExist |-> TRUE,preparation |-> <<"ExpectedEffects","ReplacementEffects","ConditionalPending">>]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NoTimingRef9
PreventExpectedAllDamageOrExposureMarkers99 · operator
reference-profile · input revision 2 · CC0 1.0
PreventExpectedAllDamageOrExposureMarkers99(before,after,id) ==
/\ id \in DOMAIN before /\ before[id].kind \in {"Damage","ExposureMarkers"}
/\ PreventExpectedWhole99(before,after,id)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PreventExpectedWhole99
PreventExpectedAmount99 · operator
reference-profile · input revision 2 · CC0 1.0
PreventExpectedAmount99(before,after,id,amount) ==
/\ ExpectedEffectsValid99(before) /\ id \in DOMAIN before /\ before[id].kind \in {"Damage","ExposureMarkers"}
/\ amount \in Nat /\ ExpectedEffectPreventable99(before,id)
/\ SetExpectedEffectValue99(before,after,id,before[id].value-amount)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectPreventable99, ExpectedEffectsValid99, SetExpectedEffectValue99
PreventExpectedWhole99 · operator
reference-profile · input revision 2 · CC0 1.0
PreventExpectedWhole99(before,after,id) ==
/\ ExpectedEffectsValid99(before) /\ ExpectedEffectPreventable99(before,id)
/\ after=[effect \in DOMAIN before \ {id} |-> before[effect]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectPreventable99, ExpectedEffectsValid99
PreventImminentBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
PreventImminentBarrierInstruction98(before,after,stack,plan,parent,actualPrevention) ==
/\ BarrierInstructionImminent98(before) /\ ~before.prevented
/\ BarrierInstructionModifierAtTop98(before,stack,plan,parent)
/\ actualPrevention.instruction=InstructionWindowRef93(plan)
/\ actualPrevention.tag="BarrierInstructionPrevention" /\ actualPrevention.barrierInstruction=BarrierInstructionWindowRef98(before) /\ actualPrevention.authorized
/\ after=[before EXCEPT !.prevented=TRUE,!.revision=@+1]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionImminent98, BarrierInstructionModifierAtTop98, BarrierInstructionWindowRef98, InstructionWindowRef93
PreventedPositiveAmount99 · operator
reference-profile · input revision 2 · CC0 1.0
PreventedPositiveAmount99(before,after,id) ==
IF ~PositiveBeforeEffect99(before,id) THEN 0
ELSE LET remaining == IF id \notin DOMAIN after THEN 0
ELSE IF after[id].kind # before[id].kind THEN 0 ELSE MaxOf(0,after[id].value)
IN MaxOf(0,before[id].value-remaining)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: remaining, PositiveBeforeEffect99, MaxOf
PrimaryConditions93 · operator
reference-profile · input revision 2 · CC0 1.0
PrimaryConditions93(units) ==
{i \in 1..Len(units) : units[i].category="SchemaAtom043" /\ units[i].primary}Exact module download · Source bundle and reproduction instructions
PrintedCharacteristicsBound912 · operator
reference-profile · input revision 2 · CC0 1.0
PrintedCharacteristicsBound912(printed,world,cardFacts) ==
/\ DOMAIN printed=DOMAIN world.objects
/\ \A id \in DOMAIN printed :
/\ printed[id].card=world.objects[id].card /\ printed[id].sourceSHA=cardFacts[printed[id].card].sourceSHA
/\ printed[id].printedBarrierInstructions \subseteq printed[id].abilities
/\ \A key \in DOMAIN printed[id].values : printed[id].values[key] \in IntExact module download · Source bundle and reproduction instructions
PrintedPlayOrder97 · operator
reference-profile · input revision 2 · CC0 1.0
PrintedPlayOrder97(text) == SelectSeq(text.order,LAMBDA id : text.definitions[id].syntax.kind="Play")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
PriorityChoiceValid9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityChoiceValid9(before,option,objects,actualLegality,actualCurrentEffect) ==
/\ Len(before) > 0
/\ LET w == WindowTop9(before)
IN /\ w.open /\ w.stage = "Ready" /\ w.checkpoint # 0 /\ w.busy.id = 0
/\ PriorityOptionAllowed9(w,option,objects,actualCurrentEffect)
/\ PriorityOptionLegality9(w,option,actualLegality)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, PriorityOptionAllowed9, PriorityOptionLegality9
PriorityOpeningSite9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityOpeningSite9(stack,site) ==
[site EXCEPT !.traversalEnding = @ \/ (IF Len(stack)=0 THEN FALSE ELSE WindowTop9(stack).site.traversalEnding)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WindowTop9
PriorityOption9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityOption9(id,kind,controller,ability,instance,source,target,newStructures) ==
[id |-> id,kind |-> kind,controller |-> controller,ability |-> ability,instance |-> instance,
source |-> source,target |-> target,newStructures |-> newStructures]Exact module download · Source bundle and reproduction instructions
PriorityOptionAllowed9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityOptionAllowed9(w,option,objects,actualCurrentEffect) ==
CASE w.kind = "NeutralValue00001" -> option.kind = "NeutralValue00001" /\ option.controller = w.active
[] w.kind = "Paid" ->
/\ ~w.site.traversalEnding
/\ CASE option.kind = "RegularPaid" -> TRUE
[] option.kind = "Activation" ->
/\ option.controller = "SideA" /\ option.target \in DOMAIN objects
/\ objects[option.target].kind \in {"Facility","Attachment","Barrier"}
/\ ActivationPermission8(option.target,objects[option.target],PaidActivationContext9(w))
[] option.kind = "ObjectiveCompletion" -> option.controller = "SideA" /\ PaidWindowOptions9(w.site).score
[] OTHER -> FALSE
[] w.kind = "Reaction" -> option.kind = "Conditional" /\ ConditionalOptionMatches9(w,option)
[] w.kind = "Interrupt" ->
/\ InterruptEffectMatches9(w,actualCurrentEffect)
/\ CASE option.kind = "ConditionalInterrupt" ->
ConditionalOptionMatches9(w,option) /\ option.instance \in actualCurrentEffect.relevantConditional
[] option.kind = "PaidInterrupt" -> option.ability \in actualCurrentEffect.paidInterruptAbilities
[] OTHER -> FALSE
[] w.kind = "MidItemInspection" -> option.kind = "MidItemInspection" /\ option.controller = "SideB"
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalOptionMatches9, InterruptEffectMatches9, PaidActivationContext9, PaidWindowOptions9, ActivationPermission8
PriorityOptionLegality9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityOptionLegality9(w,option,actualLegality) ==
/\ option.id \in Nat \ {0} /\ option.controller = w.priority
/\ actualLegality.tag = "PriorityOptionLegality" /\ actualLegality.windowId = w.id
/\ actualLegality.reception = w.reception /\ actualLegality.option = option
/\ actualLegality.legal /\ actualLegality.active
/\ actualLegality.transactionId \in Nat \ {0} /\ actualLegality.costsPayable
/\ \A ref \in option.newStructures : TimingRefValid9(ref)
/\ ~w.site.traversalEnding \/ option.newStructures = {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRefValid9
PriorityOptionReturnValid9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityOptionReturnValid9(before,actualReturn) ==
/\ Len(before) > 0
/\ LET w == WindowTop9(before)
IN /\ w.busy.id # 0 /\ w.stage \in {"Resolving","Closed"}
/\ actualReturn.tag = "PriorityOptionReturn" /\ actualReturn.windowId = w.id
/\ actualReturn.option = w.busy /\ actualReturn.transactionId \in Nat \ {0}
/\ actualReturn.transactionId = w.busyTransaction
/\ PriorityPaymentMatches9(w,actualReturn.triggerPayment)
/\ actualReturn.allCostsPaid /\ actualReturn.optionComplete
/\ actualReturn.childrenReturned /\ actualReturn.reactionsDrainedExact module download · Source bundle and reproduction instructions
Resolved project definitions: w, PriorityPaymentMatches9
PriorityPaymentMatches9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityPaymentMatches9(w,actualPayment) ==
/\ actualPayment.tag="PriorityOptionPayment" /\ actualPayment.windowId=w.id
/\ actualPayment.option=w.busy /\ actualPayment.transactionId=w.busyTransaction
/\ actualPayment.allTriggerCostsPaid /\ actualPayment.costCheckpointAndReactionsDrainedExact module download · Source bundle and reproduction instructions
PrioritySite9 · operator
reference-profile · input revision 2 · CC0 1.0
PrioritySite9(route,step,phase,ref,active,turnId,traversalId,itemInspectionId,actionPoints,approachedBarrier,traversalEnding,live,timingLive) ==
[route |-> route,step |-> step,phase |-> phase,structure |-> ref,active |-> active,
turnId |-> turnId,traversalId |-> traversalId,itemInspectionId |-> itemInspectionId,actionPoints |-> actionPoints,
approachedBarrier |-> approachedBarrier,traversalEnding |-> traversalEnding,live |-> live,timingLive |-> timingLive]Exact module download · Source bundle and reproduction instructions
PriorityStackValid9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityStackValid9(stack) ==
/\ \A i \in 1..Len(stack) : PriorityWindowValid9(stack[i])
/\ Cardinality({stack[i].id : i \in 1..Len(stack)}) = Len(stack)
/\ Cardinality(ActionablePriority9(stack)) <= 1Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActionablePriority9, PriorityWindowValid9
PriorityWindowKinds9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityWindowKinds9 == {"NeutralValue00001","Paid","Reaction","Interrupt","MidItemInspection"}Exact module download · Source bundle and reproduction instructions
PriorityWindowValid9 · operator
reference-profile · input revision 2 · CC0 1.0
PriorityWindowValid9(w) ==
/\ w.id \in Nat \ {0} /\ w.kind \in PriorityWindowKinds9 /\ w.active=w.site.active
/\ w.stage \in {"NeedCheckpoint","Ready","Resolving","Closed"} /\ w.open = (w.stage # "Closed")
/\ w.reception \in Nat \ {0} /\ w.previousPass \in BOOLEAN
/\ w.pending \cup w.lostPending \cup w.triggered = DOMAIN w.members
/\ w.pending \cap w.lostPending = {} /\ w.pending \cap w.triggered = {} /\ w.lostPending \cap w.triggered = {}
/\ IF w.kind \in {"Reaction","Interrupt"} THEN ConditionalGroupValid9(w.members,w.id,w.group,w.kind="Interrupt")
ELSE w.members = [x \in {} |-> x] /\ w.group=0
/\ IF w.stage \in {"Ready","NeedCheckpoint"} THEN
/\ w.priority \in SetupPlayers /\ w.busy.id=0 /\ w.busyTransaction=0
/\ w.checkpoint \in Nat /\ (w.checkpoint=0) = (w.stage="NeedCheckpoint")
/\ (w.kind="NeutralValue00001" => w.priority=w.active) /\ (w.kind="MidItemInspection" => w.priority="SideB")
ELSE w.priority="NoValue"
/\ IF w.busy.id=0 THEN w.busyTransaction=0 /\ w.stage # "Resolving"
ELSE w.busyTransaction \in Nat \ {0} /\ w.stage \in {"Resolving","Closed"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalGroupValid9, PriorityWindowKinds9, SetupPlayers
ProcedureStepIsInstruction911 · operator
reference-profile · input revision 2 · CC0 1.0
ProcedureStepIsInstruction911(kind) == kind \in TimingStructureKinds9Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingStructureKinds9
ProcessConditionalCheckpoint96 · operator
reference-profile · input revision 2 · CC0 1.0
ProcessConditionalCheckpoint96(before,after,beforeStack,afterStack,definitions,cp,conditions,allocation,bindings,departures,holds,usedWindowIds) ==
/\ ProcessConditionalCheckpointCore96(before,after,definitions,cp,conditions,allocation,bindings,departures,holds)
/\ \A key \in DOMAIN bindings : bindings[key].windowId \notin usedWindowIds \cup {beforeStack[i].id : i \in 1..Len(beforeStack)}
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ProcessConditionalCheckpointCore96, SyncConditionalWindows96
ProcessConditionalCheckpoint99 · operator
reference-profile · input revision 2 · CC0 1.0
ProcessConditionalCheckpoint99(before,after,beforeStack,afterStack,definitions,lexemes,cp,conditions,allocation,bindings,departures,holds,usedWindowIds,cardFacts) ==
/\ ProcessConditionalCheckpointCore99(before,after,definitions,lexemes,cp,conditions,allocation,bindings,departures,holds,cardFacts)
/\ \A key \in DOMAIN bindings : bindings[key].windowId \notin usedWindowIds \cup {beforeStack[i].id : i \in 1..Len(beforeStack)}
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ProcessConditionalCheckpointCore99, SyncConditionalWindows96
ProcessConditionalCheckpointCore96 · operator
reference-profile · input revision 2 · CC0 1.0
ProcessConditionalCheckpointCore96(before,after,definitions,cp,conditions,allocation,bindings,departures,holds) ==
LET stable == ConditionalActivityLedger96(before,definitions,cp.processingSnapshot)
candidates == CheckpointCandidates96(definitions,stable,cp,conditions) \cup DepartureCandidates96(definitions,cp,conditions,departures)
departureKeys == {key.definition : key \in DepartureCandidates96(definitions,cp,conditions,departures)}
ids == {allocation[key] : key \in candidates}
IN /\ definitions=cp.processingSnapshot.definitions
/\ ConditionalDefinitionsStable96(before.lastSnapshot,cp.processingSnapshot)
/\ \A key \in DOMAIN definitions : key=ConditionalKey96(definitions[key]) /\ ConditionalDefinitionValid96(definitions[key])
/\ ConditionalSnapshotBound96(cp.processingSnapshot,before)
/\ CheckpointBatchValid96(before,cp,candidates,allocation,bindings)
/\ DOMAIN holds=departureKeys
/\ \A key \in departureKeys : DepartureAuthority96(definitions[key],cp,conditions[key],allocation,departures[key],holds[key])
/\ after=[stable EXCEPT !.activationEpoch=cp.processingSnapshot.activationEpoch,!.holds=[key \in DOMAIN @ \cup departureKeys |-> IF key \in departureKeys THEN holds[key] ELSE @[key]],!.lastCheckpoint=cp.id,!.checkpointIds=@ \cup {cp.id},
!.checkpoints=[id \in DOMAIN @ \cup {cp.id} |-> IF id=cp.id THEN [caller |-> cp.caller] ELSE @[id]],!.serial=cp.serial,!.lastSnapshot=cp.processingSnapshot,
!.processed=@ \cup DOMAIN cp.occurrences,
!.instances=[id \in DOMAIN @ \cup ids |->
IF id \in ids THEN LET key == CHOOSE k \in candidates : allocation[k]=id
d == definitions[key.definition]
IN NewConditionalInstance96(id,d,cp,key.occurrence,bindings[key].windowId,bindings[key].group)
ELSE @[id]]]
/\ \A key \in departureKeys :
ConditionalActive96(definitions[key],SnapshotWithConditionalRegistry96(cp.processingSnapshot,after))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates, d, departureKeys, ids, key, stable, CheckpointBatchValid96, ConditionalActive96, ConditionalDefinitionValid96, ConditionalDefinitionsStable96, ConditionalKey96, ConditionalSnapshotBound96, DepartureAuthority96, NewConditionalInstance96, SnapshotWithConditionalRegistry96
ProcessConditionalCheckpointCore99 · operator
reference-profile · input revision 2 · CC0 1.0
ProcessConditionalCheckpointCore99(before,after,definitions,lexemes,cp,conditions,allocation,bindings,departures,holds,cardFacts) ==
LET stable == ConditionalActivityLedger96(before,definitions,cp.processingSnapshot)
candidates == CheckpointCandidates99(definitions,lexemes,stable,cp,conditions) \cup DepartureCandidates99(definitions,lexemes,cp,conditions,departures)
departureKeys == {key.definition : key \in DepartureCandidates99(definitions,lexemes,cp,conditions,departures)}
ids == {allocation[key] : key \in candidates}
IN /\ ConditionalLexemesBound99(definitions,lexemes,cp.processingSnapshot,cardFacts)
/\ definitions=cp.processingSnapshot.definitions
/\ ConditionalDefinitionsStable96(before.lastSnapshot,cp.processingSnapshot)
/\ \A key \in DOMAIN definitions : key=ConditionalKey96(definitions[key]) /\ ConditionalDefinitionValid96(definitions[key])
/\ ConditionalSnapshotBound96(cp.processingSnapshot,before)
/\ CheckpointBatchValid96(before,cp,candidates,allocation,bindings)
/\ DOMAIN holds=departureKeys
/\ \A key \in departureKeys : DepartureAuthority96(definitions[key],cp,conditions[key],allocation,departures[key],holds[key])
/\ after=[stable EXCEPT !.activationEpoch=cp.processingSnapshot.activationEpoch,!.holds=[key \in DOMAIN @ \cup departureKeys |-> IF key \in departureKeys THEN holds[key] ELSE @[key]],!.lastCheckpoint=cp.id,!.checkpointIds=@ \cup {cp.id},
!.checkpoints=[id \in DOMAIN @ \cup {cp.id} |-> IF id=cp.id THEN [caller |-> cp.caller] ELSE @[id]],!.serial=cp.serial,!.lastSnapshot=cp.processingSnapshot,
!.processed=@ \cup DOMAIN cp.occurrences,
!.instances=[id \in DOMAIN @ \cup ids |->
IF id \in ids THEN LET key == CHOOSE k \in candidates : allocation[k]=id
d == definitions[key.definition]
IN NewConditionalInstance96(id,d,cp,key.occurrence,bindings[key].windowId,bindings[key].group)
ELSE @[id]]]
/\ \A key \in departureKeys :
ConditionalActive96(definitions[key],SnapshotWithConditionalRegistry96(cp.processingSnapshot,after))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates, d, departureKeys, ids, key, stable, CheckpointBatchValid96, ConditionalActive96, ConditionalDefinitionValid96, ConditionalDefinitionsStable96, ConditionalKey96, ConditionalLexemesBound99, ConditionalSnapshotBound96, DepartureAuthority96, NewConditionalInstance96, SnapshotWithConditionalRegistry96
ProcessPersistentCheckpoint912 · operator
reference-profile · input revision 2 · CC0 1.0
ProcessPersistentCheckpoint912(registry,before,after,beforeStack,afterStack,definitions,lexemes,cp,conditions,allocation,bindings,departures,holds,scope,usedWindows,cardFacts,world,authority) ==
/\ LifetimeReady910(registry,authority) /\ PersistentRegistryWorldBound912(registry,authority.current) /\ world=authority.current
/\ PersistentCheckpointBound912(registry,before)
/\ cp.processingSnapshot.id=world.id /\ LingeringConditionalWorld910(cp.processingSnapshot,before,world)
/\ scope.traversalId=world.control.traversal.id
/\ ProcessPersistentCheckpointCore912(registry,before,after,definitions,lexemes,cp,conditions,allocation,bindings,departures,holds,scope,cardFacts)
/\ \A key \in DOMAIN bindings : bindings[key].windowId \notin usedWindows \cup {beforeStack[i].id : i \in 1..Len(beforeStack)}
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, LingeringConditionalWorld910, PersistentCheckpointBound912, PersistentRegistryWorldBound912, ProcessPersistentCheckpointCore912, SyncConditionalWindows96
ProcessPersistentCheckpointCore912 · operator
reference-profile · input revision 2 · CC0 1.0
ProcessPersistentCheckpointCore912(registry,before,after,definitions,lexemes,cp,conditions,allocation,bindings,departures,holds,scope,cardFacts) ==
LET stable == ConditionalActivityLedger96(before,definitions,cp.processingSnapshot)
ordinary == PersistentCheckpointCandidates912(registry,definitions,lexemes,stable,cp,conditions,scope)
departing == {candidate \in DepartureCandidates99(definitions,lexemes,cp,conditions,departures) :
PersistentCandidateAllowed912(registry,definitions[candidate.definition],cp,candidate.occurrence,scope)}
candidates == ordinary \cup departing
departureKeys == {key.definition : key \in departing}
ids == {allocation[key] : key \in candidates}
IN /\ PersistentConditionalDefinitions912(registry,definitions)
/\ PersistentCapturedLexemes912(registry,definitions,lexemes)
/\ scope.tag="PersistentCheckpointTraversalScope" /\ scope.checkpointId=cp.id /\ scope.caller=cp.caller
/\ ConditionalLexemesBound99(definitions,lexemes,cp.processingSnapshot,cardFacts)
/\ definitions=cp.processingSnapshot.definitions /\ ConditionalDefinitionsStable96(before.lastSnapshot,cp.processingSnapshot)
/\ \A key \in DOMAIN definitions : key=ConditionalKey96(definitions[key]) /\ ConditionalDefinitionValid96(definitions[key])
/\ ConditionalSnapshotBound96(cp.processingSnapshot,before)
/\ CheckpointBatchValid96(before,cp,candidates,allocation,bindings)
/\ DOMAIN holds=departureKeys
/\ \A key \in departureKeys : DepartureAuthority96(definitions[key],cp,conditions[key],allocation,departures[key],holds[key])
/\ after=[stable EXCEPT !.activationEpoch=cp.processingSnapshot.activationEpoch,
!.holds=[key \in DOMAIN @ \cup departureKeys |-> IF key \in departureKeys THEN holds[key] ELSE @[key]],
!.lastCheckpoint=cp.id,!.checkpointIds=@ \cup {cp.id},!.checkpoints=ReplacementOverlay99(@,[id \in {cp.id} |-> [caller |-> cp.caller]]),
!.serial=cp.serial,!.lastSnapshot=cp.processingSnapshot,!.processed=@ \cup DOMAIN cp.occurrences,
!.instances=ReplacementOverlay99(@,[id \in ids |-> LET key == CHOOSE k \in candidates : allocation[k]=id
IN NewConditionalInstance96(id,definitions[key.definition],cp,key.occurrence,bindings[key].windowId,bindings[key].group)])]
/\ \A key \in departureKeys : ConditionalActive96(definitions[key],SnapshotWithConditionalRegistry96(cp.processingSnapshot,after))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: candidates, departureKeys, ids, key, stable, CheckpointBatchValid96, ConditionalActive96, ConditionalDefinitionValid96, ConditionalDefinitionsStable96, ConditionalKey96, ConditionalLexemesBound99, ConditionalSnapshotBound96, DepartureAuthority96, NewConditionalInstance96, PersistentCapturedLexemes912, PersistentConditionalDefinitions912, ReplacementOverlay99, SnapshotWithConditionalRegistry96
ProjectLingeringReplacements910 · operator
reference-profile · input revision 2 · CC0 1.0
ProjectLingeringReplacements910(registry,world,beforeExpected,afterExpected) ==
LET ids == {id \in DOMAIN registry.effects : registry.effects[id].kind="Replacement"}
IN /\ world.id=beforeExpected.id /\ world.objects=beforeExpected.objects
/\ ids={id \in DOMAIN beforeExpected.replacementDefinitions : beforeExpected.replacementDefinitions[id].provider="Maintained"}
/\ \A id \in ids :
/\ beforeExpected.replacementDefinitions[id].blueprint.source=registry.effects[id].source
/\ beforeExpected.replacementDefinitions[id].creation.instruction=registry.effects[id].creation[2]
/\ beforeExpected.replacementDefinitions[id].creation.replacement=id
/\ afterExpected=[beforeExpected EXCEPT !.liveReplacementIds=LingeringReplacementIds910(registry,world)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ids, LingeringReplacementIds910
ProjectObservedLingeringReplacements910 · operator
reference-profile · input revision 2 · CC0 1.0
ProjectObservedLingeringReplacements910(registry,a,beforeExpected,afterExpected) ==
/\ LifetimeReady910(registry,a)
/\ ProjectLingeringReplacements910(registry,a.current,beforeExpected,afterExpected)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, ProjectLingeringReplacements910
ProtectedPaidTransit95 · operator
reference-profile · input revision 2 · CC0 1.0
ProtectedPaidTransit95(current,oldObject,p,forfeited) ==
LET base == SetAsideTransit4(current,oldObject.zone,oldObject.loc,p.transaction,p.id,TRUE,forfeited)
IN [object |-> base.object,originZone |-> base.originZone,originLocation |-> base.originLocation,
effect |-> base.effect,ability |-> base.ability,protected |-> base.protected,cleanupStage |-> base.cleanupStage,
originFace |-> oldObject.face,originDeployed |-> oldObject.deployed,originForm |-> oldObject.form]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: base
PublishChapterOccurrenceAdoption912 · operator
reference-profile · input revision 2 · CC0 1.0
PublishChapterOccurrenceAdoption912(beforeRegistry,afterRegistry,beforeAuthority,afterAuthority,beforeRuntime,afterRuntime,spec,
beforeContext,afterContext,origin,ledger,world,cardFacts) ==
/\ ChapterExpectedWorld912(beforeRegistry,world,ledger,beforeAuthority,cardFacts)
/\ PublishOccurrenceAdoption912(beforeRegistry,afterRegistry,beforeAuthority,afterAuthority,beforeRuntime,afterRuntime,spec,
beforeContext,afterContext,origin,ledger,world,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ChapterExpectedWorld912, PublishOccurrenceAdoption912
PublishCreatedDelayedLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
PublishCreatedDelayedLingering910(beforeRegistry,afterRegistry,beforeLedger,createdLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,effectId,definitionId,template,context,origin,operation,
actualExecution,actualCreation,world,usedDefinitions) ==
/\ CreateDelayedLingering910(beforeRegistry,afterRegistry,beforeLedger,createdLedger,effectId,definitionId,template,
context,origin,operation,actualExecution,actualCreation,world,usedDefinitions)
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,world)
/\ LingeringConditionalWorld910(afterSnapshot,createdLedger,world)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,world)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,afterRegistry,createdLedger,world)
/\ ObserveConditionalActivity96(beforeLedger,createdLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CreateDelayedLingering910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96
PublishCreatedObservedDelayedLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
PublishCreatedObservedDelayedLingering910(beforeRegistry,afterRegistry,beforeLedger,createdLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,effectId,definitionId,template,context,origin,operation,
execution,creation,a,usedDefinitions) ==
/\ LifetimeReady910(beforeRegistry,a)
/\ PublishCreatedDelayedLingering910(beforeRegistry,afterRegistry,beforeLedger,createdLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,effectId,definitionId,template,context,origin,operation,execution,creation,a.current,usedDefinitions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, PublishCreatedDelayedLingering910
PublishEncounterBarrierInstructionOrder98 · operator
reference-profile · input revision 2 · CC0 1.0
PublishEncounterBarrierInstructionOrder98(beforeE,afterE,beforeOrder,afterOrder,boundPublication,events) ==
/\ BarrierInstructionOrderPublicationStep98(beforeOrder,afterOrder)
/\ beforeE.barrierCard=beforeOrder.barrierCard /\ beforeE.order=beforeOrder.order
/\ beforeE.usedSubIds \subseteq beforeOrder.usedIds /\ beforeOrder.present \subseteq beforeE.usedSubIds
/\ DOMAIN beforeE.barrierInstructionSuppressedBy=beforeE.usedSubIds /\ beforeE.barrierInstructionSuppressed \cup beforeE.resolved \subseteq beforeE.usedSubIds
/\ boundPublication=NewEncounterBarrierInstructionOrderPublication98(beforeE,beforeOrder,afterOrder)
/\ UpdateEncounterSubs6(beforeE,afterE,afterOrder.order,TRUE,events)
/\ LET gained == afterOrder.present \ beforeOrder.present
IN /\ afterE.usedSubIds=beforeE.usedSubIds \cup gained
/\ afterE.usedSubIds \subseteq afterOrder.usedIds
/\ gained \cap afterE.barrierInstructionSuppressed={} /\ gained \cap afterE.resolved={}
/\ \A id \in gained : afterE.barrierInstructionSuppressedBy[id]=0
/\ afterE.barrierInstructionSuppressed=beforeE.barrierInstructionSuppressed /\ afterE.resolved=beforeE.resolved
/\ \A id \in beforeE.usedSubIds : afterE.barrierInstructionSuppressedBy[id]=beforeE.barrierInstructionSuppressedBy[id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: gained, BarrierInstructionOrderPublicationStep98, NewEncounterBarrierInstructionOrderPublication98, UpdateEncounterSubs6
PublishLingeringActivity910 · operator
reference-profile · input revision 2 · CC0 1.0
PublishLingeringActivity910(beforeRegistry,afterRegistry,beforeLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,beforeWorld,afterWorld) ==
/\ DelayedLifetimeBound910(beforeRegistry,beforeLedger)
/\ beforeWorld.finishedDelayedEffects=afterWorld.finishedDelayedEffects
/\ beforeSnapshot.id=beforeWorld.id /\ afterSnapshot.id=afterWorld.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeWorld)
/\ LingeringConditionalWorld910(afterSnapshot,beforeLedger,afterWorld)
/\ ObserveLingering910(beforeRegistry,afterRegistry,afterWorld)
/\ beforeSnapshot=LingeringConditionalSnapshot910(beforeSnapshot,beforeRegistry,beforeLedger,beforeWorld)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,afterRegistry,beforeLedger,afterWorld)
/\ ObserveConditionalActivity96(beforeLedger,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DelayedLifetimeBound910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910
PublishNextLifetime910 · operator
reference-profile · input revision 2 · CC0 1.0
PublishNextLifetime910(before,after,a) ==
/\ LifetimeFrontierBound910(before,a) /\ before.frontier.position<Len(a.order)
/\ ~\E id \in DOMAIN before.effects : before.effects[id].kind="Delayed"
/\ LET next == NextLifetimeWorld910(before,a)
local == [after EXCEPT !.frontier=before.frontier]
IN /\ a.transitions[next.id].before=before.frontier.world
/\ ObserveLingering910(before,local,next)
/\ after.frontier=LifetimeFrontier910(a,before.frontier.position+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: local, next, LifetimeFrontier910, LifetimeFrontierBound910, ObserveLingering910
PublishNextLingeringActivity910 · operator
reference-profile · input revision 2 · CC0 1.0
PublishNextLingeringActivity910(beforeRegistry,afterRegistry,beforeLedger,afterLedger,beforeStack,afterStack,beforeSnapshot,afterSnapshot,a) ==
/\ LifetimeFrontierBound910(beforeRegistry,a) /\ beforeRegistry.frontier.position<Len(a.order)
/\ LET next == NextLifetimeWorld910(beforeRegistry,a)
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ a.transitions[next.id].before=beforeRegistry.frontier.world
/\ PublishLingeringActivity910(beforeRegistry,local,beforeLedger,afterLedger,beforeStack,afterStack,
beforeSnapshot,afterSnapshot,beforeRegistry.frontier.world,next)
/\ afterRegistry.frontier=LifetimeFrontier910(a,beforeRegistry.frontier.position+1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: local, next, LifetimeFrontier910, LifetimeFrontierBound910, PublishLingeringActivity910
PublishNormalPlayCleanup97 · operator
reference-profile · input revision 2 · CC0 1.0
PublishNormalPlayCleanup97(before,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot,beforePlay,afterPlay,successor,usedIds,cleanup) ==
/\ NormalPlayCleanup97(beforePlay,afterPlay,beforeSnapshot.objects,afterSnapshot.objects,successor,usedIds,cleanup)
/\ ObserveConditionalActivity96(before,before,after,beforeStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NormalPlayCleanup97, ObserveConditionalActivity96
PublishOccurrenceAdoption912 · operator
reference-profile · input revision 2 · CC0 1.0
PublishOccurrenceAdoption912(beforeRegistry,afterRegistry,beforeAuthority,afterAuthority,beforeRuntime,afterRuntime,spec,
beforeContext,afterContext,origin,ledger,world,cardFacts) ==
/\ AdoptOccurrenceRuntime912(beforeRuntime,afterRuntime,spec,beforeContext,origin,ledger,world,beforeRegistry,beforeAuthority,cardFacts)
/\ LET next == afterAuthority.current
execution == [tag |-> "CurrentCharacteristicsEvaluation",id |-> beforeContext.id,snapshotId |-> next.id,source |-> RuleAbilitySource9("ProcedureCode29f759d7ea55")]
IN /\ next=[beforeAuthority.current EXCEPT !.id=next.id,
!.activity.instances[beforeRuntime.id].owner=OccurrenceLookOwner912(afterRuntime)]
/\ CommitLifetimeKernelCore910(beforeAuthority,afterAuthority,next,execution)
/\ PublishNextLifetime910(beforeRegistry,afterRegistry,afterAuthority)
/\ ObserveResolvingLifetimeContext910(beforeContext,afterContext,afterRegistry,afterAuthority,origin)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: execution, next, AdoptOccurrenceRuntime912, CommitLifetimeKernelCore910, ObserveResolvingLifetimeContext910, OccurrenceLookOwner912, PublishNextLifetime910
PublishPersistentExpiration912 · operator
reference-profile · input revision 2 · CC0 1.0
PublishPersistentExpiration912(beforeRegistry,afterRegistry,beforeLedger,candidateLedger,afterLedger,candidateStack,afterStack,beforeSnapshot,afterSnapshot,
keys,execution,beforeAuthority,afterAuthority) ==
/\ LifetimeReady910(beforeRegistry,beforeAuthority)
/\ PersistentRegistryWorldBound912(beforeRegistry,beforeAuthority.current)
/\ keys \subseteq PersistentLiveKeys912(beforeRegistry)
/\ PersistentConditionalDefinitions912(beforeRegistry,beforeSnapshot.definitions)
/\ LET changed == PersistentExpirationRegistry912(beforeRegistry,keys)
next == afterAuthority.current
base == [beforeAuthority.current EXCEPT !.id=next.id,!.activity.instances=PersistentInstanceRows912(@,afterLedger)]
local == [afterRegistry EXCEPT !.frontier=beforeRegistry.frontier]
IN /\ next=PersistentWorld912(base,changed)
/\ CommitLifetimeKernelCore910(beforeAuthority,afterAuthority,next,execution)
/\ ObserveLingering910(changed,local,next)
/\ afterRegistry.frontier=LifetimeFrontier910(afterAuthority,Len(afterAuthority.order))
/\ PersistentRegistryWorldBound912(afterRegistry,afterAuthority.current)
/\ beforeSnapshot.id=beforeAuthority.current.id /\ afterSnapshot.id=next.id
/\ LingeringConditionalWorld910(beforeSnapshot,beforeLedger,beforeAuthority.current)
/\ LingeringConditionalWorld910(afterSnapshot,candidateLedger,next)
/\ afterSnapshot=LingeringConditionalSnapshot910(afterSnapshot,local,candidateLedger,next)
/\ PersistentConditionalDefinitions912(local,afterSnapshot.definitions)
/\ ObserveConditionalActivity96(beforeLedger,candidateLedger,afterLedger,candidateStack,afterStack,beforeSnapshot,afterSnapshot)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: base, changed, local, next, CommitLifetimeKernelCore910, LifetimeFrontier910, LifetimeReady910, LingeringConditionalSnapshot910, LingeringConditionalWorld910, ObserveConditionalActivity96, ObserveLingering910, PersistentConditionalDefinitions912, PersistentLiveKeys912, PersistentRegistryWorldBound912, PersistentWorld912
PublishSelectedPaidInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
PublishSelectedPaidInterrupt99(beforeWorld,afterWorld,beforeStack,afterStack,p,selection,id,d,c,context,origin,history,ledger,
option,legality,usedInstances,cardFacts) ==
/\ ReserveCurrentPaidWithSelection99(beforeStack,afterStack,p,selection,id,d,c,context,origin,beforeWorld,history,ledger,
option,legality,usedInstances,cardFacts)
/\ LET selections == IF "interruptSelections" \in DOMAIN beforeWorld THEN beforeWorld.interruptSelections ELSE [key \in {} |-> key]
IN /\ id \notin DOMAIN selections
/\ afterWorld=ReplacementOverlay99(beforeWorld,[interruptSelections |-> ReplacementOverlay99(selections,[key \in {id} |-> selection])])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: selections, ReplacementOverlay99, ReserveCurrentPaidWithSelection99
PushChainGroup9 · operator
reference-profile · input revision 2 · CC0 1.0
PushChainGroup9(before,after,id,conditionSerial,abilities,usedGroupIds) ==
/\ id \in (Nat \ {0}) \ usedGroupIds /\ abilities # {}
/\ IF Len(before) = 0 THEN conditionSerial \in Nat \ {0} ELSE conditionSerial > before[Len(before)].serial
/\ after = Append(before,[id |-> id,serial |-> conditionSerial,pending |-> abilities])Exact module download · Source bundle and reproduction instructions
QuantityAggregates912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityAggregates912(g) == \A part \in DOMAIN g.parts : QuantityPartAggregates912(g.parts[part])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityPartAggregates912
QuantityEmission912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityEmission912(g,part,index,aggregated) ==
[tag |-> "NormalizedQuantityEmission",group |-> g.id,instruction |-> g.instruction,source |-> g.source,
part |-> part,operation |-> g.parts[part].operation,specifications |-> g.parts[part].specifications,
value |-> IF aggregated THEN QuantityTotal912(g,part)
ELSE IF index=0 THEN g.parts[part].base ELSE QuantityUnitValue912(g,part,index),
occurrence |-> index,aggregated |-> aggregated,
arguments |-> IF aggregated THEN
(IF g.parts[part].basePresent THEN <<g.parts[part].baseArguments>> ELSE <<>>) \o
[i \in 1..QuantityRepeatCount912(g) |-> QuantityUnitArguments912(g,part,i)]
ELSE IF index=0 THEN g.parts[part].baseArguments ELSE QuantityUnitArguments912(g,part,index)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityRepeatCount912, QuantityTotal912, QuantityUnitArguments912, QuantityUnitValue912
QuantityEmissions912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityEmissions912(g) ==
IF QuantityAggregates912(g) THEN QuantityEmitParts912(g,g.partOrder,0,TRUE)
ELSE QuantityEmitParts912(g,g.partOrder,0,FALSE) \o QuantityEmitRounds912(g,1,QuantityRepeatCount912(g))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityAggregates912, QuantityEmitParts912, QuantityEmitRounds912, QuantityRepeatCount912
QuantityEmitParts912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityEmitParts912(g,parts,index,aggregated) ==
IF parts= <<>> THEN <<>>
ELSE LET part == Head(parts)
include == IF aggregated THEN QuantityTotal912(g,part)>0 ELSE index#0 \/ g.parts[part].basePresent
IN (IF include THEN <<QuantityEmission912(g,part,index,aggregated)>> ELSE <<>>) \o
QuantityEmitParts912(g,Tail(parts),index,aggregated)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: include, part, QuantityEmission912, QuantityEmitParts912
QuantityEmitRounds912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityEmitRounds912(g,index,remaining) ==
IF remaining=0 THEN <<>>
ELSE QuantityEmitParts912(g,g.partOrder,index,FALSE) \o QuantityEmitRounds912(g,index+1,remaining-1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityEmitParts912, QuantityEmitRounds912
QuantityGroupShape912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityGroupShape912(g) ==
/\ g.tag="NormalizedQuantityGroup" /\ g.id \in Nat \ {0} /\ g.mode \in {"Count","Items"}
/\ DeckSequenceValid4(g.partOrder) /\ SubIds6(g.partOrder)=DOMAIN g.parts /\ Len(g.partOrder)>0
/\ IF g.mode="Count" THEN g.count \in Int ELSE DeckSequenceValid4(g.items)
/\ \A part \in DOMAIN g.parts :
LET p == g.parts[part]
IN /\ p.id=part /\ p.basePresent \in BOOLEAN /\ p.base \in Int
/\ IF g.mode="Count" THEN p.unit \in Int
ELSE /\ DOMAIN p.units=SubIds6(g.items) /\ DOMAIN p.arguments=SubIds6(g.items)
/\ \A item \in SubIds6(g.items) : p.units[item] \in IntExact module download · Source bundle and reproduction instructions
Resolved project definitions: p, DeckSequenceValid4, SubIds6
QuantityPartAggregates912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityPartAggregates912(part) ==
/\ part.operation \in AggregatedOperations912
/\ IF part.operation \in {"LookAtCards","RevealCards","RetireCards"}
THEN ("location" \in DOMAIN part.specifications /\ part.specifications.location#"NoValue") \/
("locations" \in DOMAIN part.specifications /\ part.specifications.locations#{})
ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: AggregatedOperations912
QuantityPartOrder912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityPartOrder912(g) == g.partOrderExact module download · Source bundle and reproduction instructions
QuantityRepeatCount912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityRepeatCount912(g) == IF g.mode="Items" THEN Len(g.items) ELSE IF g.count>0 THEN g.count ELSE 0Exact module download · Source bundle and reproduction instructions
QuantityRetireIdsValid912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityRetireIdsValid912(batch,beforeObjects,ids,used) ==
LET sideA == {id \in batch.members : beforeObjects[id].side="SideA"}
values == {ids.perCard[id] : id \in DOMAIN ids.perCard}
IN /\ DOMAIN ids.perCard=sideA /\ values \subseteq (Nat \ {0}) \ used
/\ Cardinality(values)=Cardinality(sideA) /\ ids.batch \in (Nat \ {0}) \ (used \cup values)Exact module download · Source bundle and reproduction instructions
QuantityRetireOccurrences912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityRetireOccurrences912(batch,beforeSnapshot,successors,exampleFamily075Definition,targetSite,ids) ==
LET sideA == {id \in batch.members : beforeSnapshot.objects[id].side="SideA"}
perCard == [id \in sideA |-> [tag |-> "ConditionalOccurrence",id |-> ids.perCard[id],kind |-> "Retireed",object |-> id,
actor |-> batch.actor,side |-> "SideA",snapshot |-> beforeSnapshot,effectId |-> batch.id,
scopeKind |-> "Global",scopeDefinition |-> [ability |-> 0,source |-> RuleAbilitySource9("NoValue")],
structure |-> NoTimingRef9,step |-> "NoValue",traversal |-> NoTraversal6,siteInspection |-> [traversalId |-> 0,origin |-> "NoValue"],movement |-> [tag |-> "SourceZoneChange",oldObject |-> id,newObject |-> successors[id],beforeSnapshot |-> beforeSnapshot]]]
relevant == ExampleFamily075BatchMembers912(batch,beforeSnapshot.objects,targetSite)
anchor == exampleFamily075Definition.syntax.source.object
batchEvent == [tag |-> "ConditionalOccurrence",id |-> ids.batch,kind |-> "AtLeastOneRetireed",object |-> anchor,
actor |-> batch.actor,side |-> "SchemaAtom016",snapshot |-> beforeSnapshot,effectId |-> batch.id,
scopeKind |-> "Ability",scopeDefinition |-> ConditionalKey96(exampleFamily075Definition),members |-> relevant,
structure |-> NoTimingRef9,step |-> "NoValue",traversal |-> NoTraversal6,siteInspection |-> [traversalId |-> 0,origin |-> "NoValue"],
movement |-> IF anchor \in DOMAIN successors THEN [tag |-> "SourceZoneChange",oldObject |-> anchor,newObject |-> successors[anchor],beforeSnapshot |-> beforeSnapshot]
ELSE [tag |-> "NoValue",oldObject |-> 0,newObject |-> 0,beforeSnapshot |-> beforeSnapshot]]
IN [perCard |-> perCard,batchEvent |-> batchEvent,batchEvents |-> IF relevant#{} THEN [id \in {batchEvent.id} |-> batchEvent] ELSE [id \in {} |-> id]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: batchEvent, perCard, relevant
QuantitySourceBound912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantitySourceBound912(g,reference,world,cardFacts) ==
/\ QuantityGroupShape912(g) /\ g.instruction=reference /\ g.source=reference.source /\ g.snapshotId=world.id
/\ g.origin.tag="FixedAbilitySourceObservation" /\ g.origin.source=g.source
/\ g.origin.card=g.card /\ g.origin.sourceSHA=g.sourceSHA
/\ IF g.source.kind="Rule" THEN g.card="Rule" /\ g.sourceSHA="0186148ecd6da8170b6555aa90d3f0115a8d5150d807078b75ac2339a2a1421e"
ELSE /\ g.card \in DOMAIN cardFacts /\ g.sourceSHA=cardFacts[g.card].sourceSHA
/\ IF g.source.object \in DOMAIN world.objects THEN world.objects[g.source.object].card=g.card ELSE TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantityGroupShape912
QuantitySum912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantitySum912(values) == IF values= <<>> THEN 0 ELSE Head(values)+QuantitySum912(Tail(values))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantitySum912
QuantityTotal912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityTotal912(g,part) ==
(IF g.parts[part].basePresent THEN g.parts[part].base ELSE 0) +
(IF g.mode="Count" THEN g.parts[part].unit*g.count
ELSE QuantitySum912([i \in 1..Len(g.items) |-> g.parts[part].units[g.items[i]]]))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: QuantitySum912
QuantityUnitArguments912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityUnitArguments912(g,part,index) ==
IF g.mode="Count" THEN g.parts[part].arguments ELSE g.parts[part].arguments[g.items[index]]Exact module download · Source bundle and reproduction instructions
QuantityUnitValue912 · operator
reference-profile · input revision 2 · CC0 1.0
QuantityUnitValue912(g,part,index) ==
IF g.mode="Count" THEN g.parts[part].unit ELSE g.parts[part].units[g.items[index]]Exact module download · Source bundle and reproduction instructions
ReachableTechniqueNodes911 · operator
reference-profile · input revision 2 · CC0 1.0
ReachableTechniqueNodes911(p,seen,remaining) ==
IF remaining=0 THEN seen
ELSE ReachableTechniqueNodes911(p,seen \cup UNION {TechniqueEdges911(p.nodes[id]) : id \in seen},remaining-1)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReachableTechniqueNodes911, TechniqueEdges911
ReadActiveLingering910 · operator
reference-profile · input revision 2 · CC0 1.0
ReadActiveLingering910(registry,a,receipt) ==
/\ LifetimeReady910(registry,a)
/\ receipt=[tag |-> "CurrentActiveLingeringEffects",worldId |-> a.current.id,ids |-> ActiveLingeringIds910(registry,a.current)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveLingeringIds910, LifetimeReady910
ReadLingeringStrength910 · operator
reference-profile · input revision 2 · CC0 1.0
ReadLingeringStrength910(registry,a,target,receipt) ==
/\ LifetimeReady910(registry,a)
/\ receipt=[tag |-> "CurrentLingeringStrength",worldId |-> a.current.id,target |-> target,
value |-> LingeringStrength910(registry,a.current,target)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, LingeringStrength910
ReadLingeringSubtypes910 · operator
reference-profile · input revision 2 · CC0 1.0
ReadLingeringSubtypes910(registry,a,target,base,receipt) ==
/\ LifetimeReady910(registry,a)
/\ receipt=[tag |-> "CurrentLingeringSubtypes",worldId |-> a.current.id,target |-> target,
values |-> LingeringBarrierSubtypes910(registry,a.current,target,base)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, LingeringBarrierSubtypes910
ReadOccurrenceQuotaSupport912 · operator
reference-profile · input revision 2 · CC0 1.0
ReadOccurrenceQuotaSupport912(r,context,actualReturn,control,registry,authority,receipt) ==
/\ LifetimeReady910(registry,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ OccurrenceRuntimeProfile912(r) /\ r.phase="Resolve" /\ context.phase="Resolving"
/\ context.currentRef.id=r.current /\ context.currentRef.abilityInstance=r.id /\ context.currentRef.source=r.ability.source
/\ context.currentRef.index=Len(r.trace)+1 /\ context.currentRef.sourceZone=r.ability.sourceZone
/\ context.currentRef.origin="Ability" /\ context.currentRef.ruleStep="NoValue"
/\ context.currentWorld=authority.current.id /\ actualReturn.snapshotId=authority.current.id
/\ actualReturn.tag="ExpectedEffectsProcedureReturn" /\ actualReturn.contextId=context.id
/\ actualReturn.instruction=context.currentRef /\ actualReturn.effects=context.actualEffects
/\ actualReturn.complete /\ actualReturn.childrenReturned
/\ OccurrenceControlBound912(r,context,actualReturn,control)
/\ receipt=[tag |-> "CurrentModalQuotaSupport",instance |-> r.id,contextId |-> context.id,instruction |-> context.currentRef,
snapshotId |-> authority.current.id,status |-> IF OccurrenceModalQuotaSupported912(r,control) THEN "Supported" ELSE "Unsupported",
policy |-> "FixedOrAlreadyCommittedQuota"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, OccurrenceControlBound912, OccurrenceModalQuotaSupported912, OccurrenceOwnerCurrent912, OccurrenceRuntimeProfile912
ReadRememberedChoices910 · operator
reference-profile · input revision 2 · CC0 1.0
ReadRememberedChoices910(registry,a,source,key,receipt) ==
/\ LifetimeReady910(registry,a)
/\ receipt=[tag |-> "CurrentRememberedChoices",worldId |-> a.current.id,source |-> source,key |-> key,
values |-> RememberedChoices910(registry,a.current,source,key)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LifetimeReady910, RememberedChoices910
ReadScopedLookPermission911 · operator
reference-profile · input revision 2 · CC0 1.0
ReadScopedLookPermission911(grants,id,viewer,object,owners,objects,lifetimes,authority,receipt) ==
/\ LifetimeReady910(lifetimes,authority) /\ objects=authority.current.objects
/\ CurrentLookOwner911(grants,id,owners,authority)
/\ receipt=[tag |-> "CurrentScopedLookPermission",worldId |-> authority.current.id,grantId |-> id,viewer |-> viewer,object |-> object,
allowed |-> ScopedLookPermission911(grants,id,viewer,object,owners,objects)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentLookOwner911, LifetimeReady910, ScopedLookPermission911
ReboundConditionalDefinition96 · operator
reference-profile · input revision 2 · CC0 1.0
ReboundConditionalDefinition96(original,newObject) ==
[original EXCEPT !.syntax.source=ObjectAbilitySource9(newObject),!.activity.source=ObjectAbilitySource9(newObject)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObjectAbilitySource9
ReceivePriority9 · operator
reference-profile · input revision 2 · CC0 1.0
ReceivePriority9(w,player) ==
[w EXCEPT !.priority = player,!.reception = @+1,!.checkpoint = 0,!.stage = "NeedCheckpoint"]Exact module download · Source bundle and reproduction instructions
RecognizeNormalPlayResolved97 · operator
reference-profile · input revision 2 · CC0 1.0
RecognizeNormalPlayResolved97(before,after,beforeStack,afterStack,origin,definitions,cp,conditions,allocation,bindings,departures,holds,usedWindows) ==
/\ NormalPlayResolvedOccurrence97(origin.beforeCleanup,origin.afterCleanup,origin.afterResolved,origin.beforeObjects,origin.afterObjects,
origin.successor,origin.usedIds,origin.cleanup,origin.rawEvents,origin.originalDefinition,origin.currentDefinition,
origin.snapshot,origin.occurrenceId,origin.event,origin.cohort)
/\ origin.occurrenceId \in DOMAIN cp.occurrences /\ cp.occurrences[origin.occurrenceId]=origin.event
/\ ProcessConditionalCheckpoint96(before,after,beforeStack,afterStack,definitions,cp,conditions,allocation,bindings,departures,holds,usedWindows)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NormalPlayResolvedOccurrence97, ProcessConditionalCheckpoint96
RecordAbilityUse9 · operator
reference-profile · input revision 2 · CC0 1.0
RecordAbilityUse9(before,after,useId,abilityInstance,source,player,actualUseDue,events) ==
/\ useId \in (Nat \ {0}) \ DOMAIN before /\ player \in SetupPlayers /\ actualUseDue
/\ LET entry == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> abilityInstance,source |-> source,player |-> player]
IN /\ after = [id \in DOMAIN before \cup {useId} |-> IF id = useId THEN entry ELSE before[id]]
/\ events = {entry}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: entry, SetupPlayers
RecordConditionalExecutionUse96 · operator
reference-profile · input revision 2 · CC0 1.0
RecordConditionalExecutionUse96(before,after,p,plan,actualExecution,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events) ==
/\ ConditionalProcedureBound96(before,p)
/\ p.phase="Resolve" /\ p.id \in DOMAIN before.instances /\ before.instances[p.id].status="Resolving"
/\ InstructionPlanMatches93(plan,p.ability,p.ability.cursor) /\ plan.phase="Resolving"
/\ actualExecution.tag="ConditionalEffectExecution" /\ actualExecution.instruction=InstructionWindowRef93(plan)
/\ actualExecution.abilityInstance=p.id /\ actualExecution.source=p.ability.source
/\ actualExecution.partIds \subseteq p.definition.partsByInstruction[plan.id]
/\ LET optional == actualExecution.partIds \cap ConditionalUseOptionalParts96(p.definition)
first == optional # {} /\ ~before.instances[p.id].used
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> p.id,source |-> p.ability.source,player |-> p.definition.syntax.controller]
IN IF first THEN
/\ OncePerTurnAllowed93(p.definition.syntax,p.turnId,beforeTurnUses)
/\ AbilityUseDue9("Conditional",ConditionalUseOptionalParts96(p.definition)={},FALSE,TRUE,FALSE)
/\ RecordAbilityUse9(beforeUses,afterUses,useId,p.id,p.ability.source,p.definition.syntax.controller,TRUE,{used})
/\ RecordTurnAbilityUse93(beforeTurnUses,afterTurnUses,p.definition.syntax,p.turnId,
[id |-> p.id,ability |-> p.definition.syntax.id,source |-> p.ability.source],used)
/\ after=[before EXCEPT !.instances[p.id].used=TRUE] /\ events={used}
ELSE after=before /\ afterUses=beforeUses /\ afterTurnUses=beforeTurnUses /\ events={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: first, used, AbilityUseDue9, ConditionalProcedureBound96, ConditionalUseOptionalParts96, InstructionPlanMatches93, InstructionWindowRef93, OncePerTurnAllowed93, RecordAbilityUse9, RecordTurnAbilityUse93
RecordConditionalOccurrenceUse912 · operator
reference-profile · input revision 2 · CC0 1.0
RecordConditionalOccurrenceUse912(before,after,r,plan,execution,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events,world,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ world.id=authority.current.id /\ world.objects=authority.current.objects /\ world.turn=authority.current.turn
/\ ConditionalSnapshotBound96(world.conditional,before) /\ beforeTurnUses=world.turnUses
/\ ConditionalOccurrenceBound912(before,r) /\ before.instances[r.id].status="Resolving" /\ r.phase="Resolve"
/\ OccurrencePlan912(r,plan) /\ plan.phase="Resolving"
/\ execution.tag="ConditionalEffectExecution" /\ execution.instruction=InstructionWindowRef93(plan)
/\ execution.abilityInstance=r.id /\ execution.source=r.ability.source
/\ execution.partIds \subseteq r.technique.definition.partsByInstruction[r.pc]
/\ LET d == r.technique.definition
optional == execution.partIds \cap ConditionalUseOptionalParts96(d)
first == optional#{} /\ ~before.instances[r.id].used
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> r.id,source |-> r.ability.source,player |-> d.syntax.controller]
IN IF first THEN
/\ OncePerTurnAllowed93(d.syntax,r.metadata.turnId,beforeTurnUses)
/\ RecordAbilityUse9(beforeUses,afterUses,useId,r.id,r.ability.source,d.syntax.controller,TRUE,{used})
/\ RecordTurnAbilityUse93(beforeTurnUses,afterTurnUses,d.syntax,r.metadata.turnId,
[id |-> r.id,ability |-> d.syntax.id,source |-> r.ability.source],used)
/\ after=[before EXCEPT !.instances[r.id].used=TRUE] /\ events={used}
ELSE after=before /\ afterUses=beforeUses /\ afterTurnUses=beforeTurnUses /\ events={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, first, used, ConditionalOccurrenceBound912, ConditionalSnapshotBound96, InstructionWindowRef93, LifetimeReady910, OccurrenceOwnerCurrent912, OccurrencePlan912, OncePerTurnAllowed93, RecordAbilityUse9, RecordTurnAbilityUse93
RecordConditionalRuntimeUse911 · operator
reference-profile · input revision 2 · CC0 1.0
RecordConditionalRuntimeUse911(before,after,r,plan,execution,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events) ==
/\ ConditionalRuntimeBound911(before,r) /\ before.instances[r.id].status="Resolving" /\ r.phase="Resolve"
/\ RuntimeCurrentPlan911(r,plan) /\ plan.phase="Resolving"
/\ execution.tag="ConditionalEffectExecution" /\ execution.instruction=InstructionWindowRef93(plan)
/\ execution.abilityInstance=r.id /\ execution.source=r.ability.source
/\ execution.partIds \subseteq r.technique.definition.partsByInstruction[plan.id]
/\ LET d == r.technique.definition
optional == execution.partIds \cap ConditionalUseOptionalParts96(d)
first == optional#{} /\ ~before.instances[r.id].used
used == [tag |-> "AbilityUsed",useId |-> useId,abilityInstance |-> r.id,source |-> r.ability.source,player |-> d.syntax.controller]
IN IF first THEN
/\ OncePerTurnAllowed93(d.syntax,r.turnId,beforeTurnUses)
/\ RecordAbilityUse9(beforeUses,afterUses,useId,r.id,r.ability.source,d.syntax.controller,TRUE,{used})
/\ RecordTurnAbilityUse93(beforeTurnUses,afterTurnUses,d.syntax,r.turnId,
[id |-> r.id,ability |-> d.syntax.id,source |-> r.ability.source],used)
/\ after=[before EXCEPT !.instances[r.id].used=TRUE] /\ events={used}
ELSE after=before /\ afterUses=beforeUses /\ afterTurnUses=beforeTurnUses /\ events={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, first, used, ConditionalRuntimeBound911, InstructionWindowRef93, OncePerTurnAllowed93, RecordAbilityUse9, RecordTurnAbilityUse93, RuntimeCurrentPlan911
RecordObservedConditionalRuntimeUse911 · operator
reference-profile · input revision 2 · CC0 1.0
RecordObservedConditionalRuntimeUse911(before,after,r,plan,execution,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events,
world,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(r,authority)
/\ world.id=authority.current.id /\ world.objects=authority.current.objects /\ world.turn=authority.current.turn
/\ ConditionalSnapshotBound96(world.conditional,before) /\ beforeTurnUses=world.turnUses
/\ RecordConditionalRuntimeUse911(before,after,r,plan,execution,beforeUses,afterUses,beforeTurnUses,afterTurnUses,useId,events)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalSnapshotBound96, LifetimeReady910, RecordConditionalRuntimeUse911, RuntimeOwnerCurrent911
RecordPlayOptionalChoice97 · operator
reference-profile · input revision 2 · CC0 1.0
RecordPlayOptionalChoice97(beforeUses,afterUses,beforeChoices,afterChoices,c,plan,choice,useId,events) ==
/\ PlayAbilityBound97(c) /\ c.phase="Resolve" /\ plan.phase="Resolving"
/\ InstructionPlanMatches93(plan,c.ability,c.ability.cursor)
/\ choice.tag="PlayOptionalChoice" /\ choice.instruction=InstructionWindowRef93(plan)
/\ choice.abilityInstance=c.id /\ choice.source=c.source /\ choice.component \in CurrentPlayDefinition97(c).optionalParts
/\ choice.component \in CurrentPlayDefinition97(c).partsByInstruction[plan.id]
/\ choice.id \in Nat \ {0} /\ [instance |-> c.id,choice |-> choice.id] \notin beforeChoices
/\ choice.complete /\ afterChoices=beforeChoices \cup {[instance |-> c.id,choice |-> choice.id]}
/\ IF choice.carriedOut THEN
/\ AbilityUseDue9("Play",FALSE,FALSE,FALSE,TRUE)
/\ RecordAbilityUse9(beforeUses,afterUses,useId,c.id,c.source,CurrentPlayDefinition97(c).syntax.controller,TRUE,events)
ELSE afterUses=beforeUses /\ events={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityUseDue9, CurrentPlayDefinition97, InstructionPlanMatches93, InstructionWindowRef93, PlayAbilityBound97, RecordAbilityUse9
RecordTurnAbilityUse93 · operator
reference-profile · input revision 2 · CC0 1.0
RecordTurnAbilityUse93(before,after,a,turnId,instance,actualUse) ==
/\ turnId \in Nat \ {0} /\ instance.ability=a.id /\ instance.source=a.source
/\ actualUse.tag="AbilityUsed" /\ actualUse.useId \in (Nat \ {0}) \ DOMAIN before
/\ actualUse.abilityInstance=instance.id /\ actualUse.source=a.source /\ actualUse.player=a.controller
/\ after = [id \in DOMAIN before \cup {actualUse.useId} |->
IF id=actualUse.useId THEN [turnId |-> turnId,ability |-> a.id,source |-> a.source,useId |-> actualUse.useId]
ELSE before[id]]Exact module download · Source bundle and reproduction instructions
RecordWouldDescriptors99 · operator
reference-profile · input revision 2 · CC0 1.0
RecordWouldDescriptors99(before,after,contextId,imminence,ref,worldId,effects,groups,periods,order,receipt) ==
/\ receipt.tag="CurrentExpectedWouldObservation" /\ receipt.id \in (Nat \ {0}) \ before.observationIds
/\ receipt.contextId=contextId /\ receipt.imminenceId=imminence /\ receipt.reference=ref /\ receipt.snapshotId=worldId
/\ receipt.effects=effects /\ receipt.groups=groups /\ receipt.periods=periods /\ receipt.order=order
/\ DOMAIN groups=DOMAIN effects /\ DeckSequenceValid4(order) /\ SubIds6(order)=DOMAIN effects
/\ \A id \in DOMAIN groups : Len(groups[id])>=2 /\ groups[id][1]=imminence
/\ LET keys == {groups[id] : id \in DOMAIN groups}
owner == [imminenceId |-> imminence,context |-> WouldContextKey99(ref)]
observed == [i \in 1..Len(order) |-> [group |-> groups[order[i]],descriptor |-> WouldDescriptor99(effects[order[i]]),
periods |-> periods,serial |-> before.serial+i,reference |-> ref,snapshotId |-> worldId]]
IN /\ \A key \in keys \cap DOMAIN before.groups : before.groups[key]=owner
/\ after=[before EXCEPT !.groups=ReplacementOverlay99(@,[key \in keys |-> owner]),
!.evidence=@ \o observed,!.serial=@+Len(order),!.observationIds=@ \cup {receipt.id},
!.latest=ReplacementOverlay99(@,[key \in {contextId} |-> receipt]),
!.observations=ReplacementOverlay99(@,[key \in {receipt.id} |-> receipt])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: keys, observed, owner, ReplacementOverlay99, DeckSequenceValid4, SubIds6
RefreshExpectedWorld99 · operator
reference-profile · input revision 2 · CC0 1.0
RefreshExpectedWorld99(before,after,beforeOrigin,afterOrigin,world,projection,history) ==
/\ InitialWouldCaptured99(before,history)
/\ ExpectedContextOrigin99(before,beforeOrigin) /\ before.phase \in {"Replacing","Prepared","WindowOpen"}
/\ ExpectedWorldValid99(world)
/\ projection.tag="ContinuousExpectedEffectsUpdate" /\ projection.context=before.currentRef
/\ projection.snapshotId=world.id /\ projection.description=before.description
/\ projection.beforeEffects=before.state.effects /\ projection.instructionReplacements=before.state.transformations
/\ projection.resolvedModifications=before.modifications
/\ DOMAIN projection.effects \subseteq before.state.usedEffectIds \ (before.removedEffects \cup before.retiredEffects)
/\ ReplacementEffectsValid99(projection.effects)
/\ \A id \in DOMAIN projection.effects :
/\ id \in DOMAIN before.templates
/\ DOMAIN projection.effects[id]=DOMAIN before.templates[id]
/\ \A field \in DOMAIN before.templates[id] \ {"value","preventable","specifications","restrictions"} : projection.effects[id][field]=before.templates[id][field]
/\ AdvanceImminentOrigin99(beforeOrigin,afterOrigin)
/\ after=[before EXCEPT !.currentRef=OriginReference99(afterOrigin),!.currentWorld=world.id,!.state.effects=projection.effects,
!.state.ancestry=[id \in DOMAIN projection.effects |-> IF id \in DOMAIN before.state.ancestry THEN before.state.ancestry[id] ELSE before.ancestryArchive[id]],
!.ancestryArchive=ReplacementOverlay99(@,before.state.ancestry),
!.modifications=Append(@,[kind |-> "ContinuousProjection",snapshotId |-> world.id,from |-> before.currentRef,to |-> OriginReference99(afterOrigin),effects |-> projection.effects])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AdvanceImminentOrigin99, ExpectedContextOrigin99, ExpectedWorldValid99, InitialWouldCaptured99, OriginReference99, ReplacementEffectsValid99, ReplacementOverlay99
ReidentifyBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
ReidentifyBarrierInstruction98(d,id) == [d EXCEPT !.syntax.id=id,!.activity.id=id]Exact module download · Source bundle and reproduction instructions
RemainingBarrierInstructions98 · operator
reference-profile · input revision 2 · CC0 1.0
RemainingBarrierInstructions98(loop,e) == SubIds6(e.order) \ (e.barrierInstructionSuppressed \cup loop.handled)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
RememberedChoices910 · operator
reference-profile · input revision 2 · CC0 1.0
RememberedChoices910(registry,world,source,key) ==
{registry.effects[id].value : id \in {id \in ActiveLingeringIds910(registry,world) : registry.effects[id].kind="Choice" /\
registry.effects[id].source=source /\ registry.effects[id].choiceKey=key}}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActiveLingeringIds910
RemoveOrderedBarrierInstructions98 · operator
reference-profile · input revision 2 · CC0 1.0
RemoveOrderedBarrierInstructions98(before,after,loss) ==
/\ BarrierInstructionOrderValid98(before) /\ loss.tag="NormalizedBarrierInstructionPresenceLoss" /\ loss.barrierCard=before.barrierCard
/\ loss.beforeOrder=before.order /\ loss.beforeHistory=before.history /\ loss.id \in (Nat \ {0}) \ DOMAIN before.decisions
/\ loss.ids \subseteq before.present /\ loss.endedApplications \subseteq before.activeApplications
/\ {id \in before.present : before.provenance[id].effect \in loss.endedApplications} \subseteq loss.ids
/\ after=[before EXCEPT !.present=@ \ loss.ids,!.order=VisibleSubOrder98(before.spine,before.present \ loss.ids),!.clock=@+1,
!.activeApplications=@ \ loss.endedApplications,
!.history=Append(@,[kind |-> "Loss",clock |-> before.clock+1,gained |-> {},lost |-> loss.ids,decision |-> loss.id,applications |-> loss.endedApplications]),
!.decisions=[id \in DOMAIN @ \cup {loss.id} |-> IF id=loss.id THEN loss ELSE @[id]]]
/\ BarrierInstructionOrderValid98(after) /\ SelfCategoryIdentical98(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOrderValid98, SelfCategoryIdentical98, VisibleSubOrder98
ReplaceBarrierInstructionPayload98 · operator
reference-profile · input revision 2 · CC0 1.0
ReplaceBarrierInstructionPayload98(before,after,exampleFamily006,actualReplacement,cardFacts) ==
/\ BarrierInstructionImminent98(before) /\ ~before.prevented
/\ actualReplacement.tag="ExampleFamily006BarrierInstructionReplacement" /\ actualReplacement.barrierInstruction=BarrierInstructionWindowRef98(before)
/\ actualReplacement.source=ObjectAbilitySource9(exampleFamily006) /\ actualReplacement.card="Specimen0252"
/\ actualReplacement.sourceSHA=cardFacts["Specimen0252"].sourceSHA /\ actualReplacement.applies
/\ actualReplacement.payload.kind="BarrierInstructionTemplate" /\ Len(actualReplacement.payload.instructions)>0
/\ LET payload == [before.definition EXCEPT !.instructions=actualReplacement.payload.instructions]
IN after=[before EXCEPT !.payload=payload,!.ability.instructions=payload.instructions,!.revision=@+1,
!.replacements=Append(@,[source |-> ObjectAbilitySource9(exampleFamily006),original |-> before.barrierInstruction,encounter |-> before.encounter,revision |-> before.revision])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: payload, BarrierInstructionImminent98, BarrierInstructionWindowRef98, ObjectAbilitySource9
ReplaceWindowTop9 · operator
reference-profile · input revision 2 · CC0 1.0
ReplaceWindowTop9(stack,frame) == [stack EXCEPT ![Len(stack)] = frame]Exact module download · Source bundle and reproduction instructions
ReplacementBlueprintValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementBlueprintValid99(id,replacement) ==
/\ id \in Nat \ {0} /\ replacement.id=id
/\ replacement.source.kind \in {"Object","Rule"} /\ replacement.sourceSHA \in STRING
/\ IF replacement.source.kind="Object" THEN replacement.source.object \in Nat \ {0}
ELSE replacement.source.rule # "NoValue"
/\ ReplacementPatternValid99(replacement.pattern)
/\ replacement.behavior.mode \in {"Patch","Replace"}
/\ IF replacement.behavior.mode="Patch"
THEN DOMAIN replacement.behavior.fields \cap ReplacementReserved99={}
ELSE \A index \in 1..Len(replacement.behavior.results) : ReplacementBodyValid99(replacement.behavior.results[index])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementBodyValid99, ReplacementPatternValid99, ReplacementReserved99
ReplacementBlueprintsValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementBlueprintsValid99(replacements) ==
\A id \in DOMAIN replacements : ReplacementBlueprintValid99(id,replacements[id])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementBlueprintValid99
ReplacementBodyValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementBodyValid99(body) ==
/\ DOMAIN body \cap ReplacementReserved99={}
/\ body.kind \in STRING /\ body.targeted \in BOOLEAN /\ body.targetCard \in Nat
/\ (body.targeted => body.targetCard>0)
/\ (body.kind="CompositeTechnique" => ReplacementTechniqueValid99(body.technique))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementReserved99, ReplacementTechniqueValid99
ReplacementController99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementController99(effect,world) ==
IF effect.targeted THEN world.controllers[effect.targetCard] ELSE effect.baseControllerExact module download · Source bundle and reproduction instructions
ReplacementDecision99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementDecision99(state,effectId,replacements,world,chosen,resultIds) ==
[tag |-> "ReplacementOrderDecision",inputEffect |-> state.effects[effectId],eligible |-> EligibleReplacements99(state,effectId,replacements),
replacements |-> replacements,worldSnapshotId |-> world.id,controller |-> ReplacementController99(state.effects[effectId],world),
chosen |-> chosen,resultIds |-> resultIds]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EligibleReplacements99, ReplacementController99
ReplacementEffectValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementEffectValid99(id,effect) ==
/\ ExpectedEffectValid99(id,effect) /\ effect.lineage \in Nat \ {0}
/\ effect.baseController \in SetupPlayers /\ effect.targeted \in BOOLEAN
/\ effect.targetCard \in Nat /\ (effect.targeted => effect.targetCard>0)
/\ effect.baseOrigin.kind \in {"Object","Rule"}
/\ (effect.kind="CompositeTechnique" => ReplacementTechniqueValid99(effect.technique))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectValid99, ReplacementTechniqueValid99, SetupPlayers
ReplacementEffectsValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementEffectsValid99(effects) ==
\A id \in DOMAIN effects : ReplacementEffectValid99(id,effects[id])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementEffectValid99
ReplacementNextState99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementNextState99(state,effectId,replacements,chosen,resultIds,decision) ==
LET effect == state.effects[effectId]
outputs == ReplacementOutputs99(effect,replacements[chosen],resultIds)
effects == ReplacementOverlay99([id \in DOMAIN state.effects \ {effectId} |-> state.effects[id]],outputs)
ancestry == ReplacementOverlay99([id \in DOMAIN state.ancestry \ {effectId} |-> state.ancestry[id]],
[id \in DOMAIN outputs |-> state.ancestry[effectId] \cup {chosen}])
IN [effects |-> effects,ancestry |-> ancestry,appliedPairs |-> state.appliedPairs \cup {ReplacementPair99(chosen,effect)},
usedEffectIds |-> state.usedEffectIds \cup DOMAIN outputs,transformations |-> Append(state.transformations,decision)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ancestry, effect, effects, outputs, ReplacementPair99
ReplacementOutputIdsValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementOutputIdsValid99(state,effect,replacement,resultIds) ==
IF replacement.behavior.mode="Patch" THEN resultIds= <<effect.id>>
ELSE /\ Len(resultIds)=Len(replacement.behavior.results)
/\ DeckSequenceValid4(resultIds) /\ SubIds6(resultIds) \subseteq Nat \ {0}
/\ SubIds6(resultIds) \cap state.usedEffectIds={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: DeckSequenceValid4, SubIds6
ReplacementOutputs99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementOutputs99(effect,replacement,resultIds) ==
IF replacement.behavior.mode="Patch"
THEN [id \in {effect.id} |-> ReplacementOverlay99(effect,replacement.behavior.fields)]
ELSE [id \in SubIds6(resultIds) |->
ReplacementResult99(effect,replacement.behavior.results[CHOOSE index \in 1..Len(resultIds) : resultIds[index]=id],id)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99, ReplacementResult99, SubIds6
ReplacementOverlay99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementOverlay99(base,patch) ==
[field \in DOMAIN base \cup DOMAIN patch |-> IF field \in DOMAIN patch THEN patch[field] ELSE base[field]]Exact module download · Source bundle and reproduction instructions
ReplacementPair99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementPair99(replacement,effect) == <<replacement,effect.id>>Exact module download · Source bundle and reproduction instructions
ReplacementPatternMatches99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementPatternMatches99(pattern,effect) ==
/\ effect.kind=pattern.kind
/\ \A field \in DOMAIN pattern \ {"kind","minValue"} :
IF field \in DOMAIN effect THEN effect[field]=pattern[field] ELSE FALSE
/\ IF "minValue" \in DOMAIN pattern
THEN IF "value" \in DOMAIN effect THEN effect.value>=pattern.minValue ELSE FALSE
ELSE TRUEExact module download · Source bundle and reproduction instructions
ReplacementPatternValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementPatternValid99(pattern) ==
/\ "kind" \in DOMAIN pattern /\ pattern.kind \in STRING
/\ DOMAIN pattern \subseteq {"kind","damageType","targetCard","affectedCard","targetSite","actor","minValue"}
/\ ("minValue" \in DOMAIN pattern => pattern.minValue \in Int)Exact module download · Source bundle and reproduction instructions
ReplacementPreparationComplete99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementPreparationComplete99(state,replacements) ==
\A id \in DOMAIN state.effects : EligibleReplacements99(state,id,replacements)={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EligibleReplacements99
ReplacementRecordActive99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementRecordActive99(record,context,world) ==
/\ ReplacementScopeCurrent99(record,context,world)
/\ CASE record.provider="Static" ->
/\ record.definition.syntax.kind="Static" /\ record.definition.activity.source.kind="Object"
/\ record.definition.activity.source.object \in DOMAIN world.objects
/\ StaticPartApplies94(record.definition.syntax,record.part,
StaticAbilityActive94(record.definition.activity,record.definition.syntax,world.objects,world.conditional.present,
world.conditional.cardActivity[record.definition.activity.source.object],world.conditional.activity,world.conditional.points),record.conditions)
[] record.provider="Maintained" -> record.id \in world.liveReplacementIds
[] record.provider="ImminentInterrupt" -> record.id \in DOMAIN context.temporaryReplacements /\ context.temporaryReplacements[record.id]=record
[] OTHER -> FALSEExact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementScopeCurrent99, StaticAbilityActive94, StaticPartApplies94
ReplacementRecords99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementRecords99(context,world) == ReplacementOverlay99(world.replacementDefinitions,context.temporaryReplacements)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
ReplacementReserved99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementReserved99 == {"id","lineage","baseController","baseOrigin"}Exact module download · Source bundle and reproduction instructions
ReplacementResult99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementResult99(effect,body,id) ==
ReplacementOverlay99(body,[id |-> id,lineage |-> effect.lineage,baseController |-> effect.baseController,baseOrigin |-> effect.baseOrigin])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
ReplacementScopeCurrent99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementScopeCurrent99(record,context,world) ==
CASE record.scope.kind="Instruction" -> record.scope.context=WouldContextKey99(context.initialRef)
[] record.scope.kind="SchemaAtom138" -> TraversalTimingPresent6(world.traversalControl.traversal) /\ record.scope.id=world.traversalControl.traversal.id
[] record.scope.kind="Turn" -> record.scope.id=world.turn.id /\ ~world.turn.formalEnded
[] record.scope.kind="WhileStaticActive" -> record.provider="Static"
[] OTHER -> record.scope.period \in DOMAIN world.activePeriodsExact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldContextKey99, TraversalTimingPresent6
ReplacementSourcesBound99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementSourcesBound99(context,world,cardFacts) ==
/\ DOMAIN world.replacementDefinitions \cap DOMAIN context.temporaryReplacements={}
/\ world.liveReplacementIds \subseteq DOMAIN world.replacementDefinitions
/\ \A id \in DOMAIN ReplacementRecords99(context,world) :
LET r == ReplacementRecords99(context,world)[id]
IN /\ r.id=id /\ ReplacementBlueprintValid99(id,r.blueprint)
/\ AbilityLexemesValid99(r.definition,r.lexemes,world.objects,cardFacts) /\ ReplacementText99(r.definition,r.lexemes)
/\ r.blueprint.source=r.definition.syntax.source /\ r.blueprint.sourceSHA=r.lexemes.sourceSHA
/\ r.blueprint.wouldGrouping \in {"Preserve","SeparateResults"}
/\ r.bindingSnapshotId=world.id
/\ r.provider \in {"Static","Maintained","ImminentInterrupt"}
/\ IF r.provider="Static" THEN r.definition.syntax.kind="Static"
ELSE /\ r.creation.tag="ResolvedReplacementCreation" /\ r.creation.replacement=id
/\ r.creation.instruction.source=r.blueprint.source /\ r.creation.abilityInstance \in Nat
/\ WouldContextValid99(r.creation.instruction)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: r, AbilityLexemesValid99, ReplacementBlueprintValid99, ReplacementRecords99, ReplacementText99, WouldContextValid99
ReplacementStateValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementStateValid99(state) ==
/\ ReplacementEffectsValid99(state.effects)
/\ DOMAIN state.effects \subseteq state.usedEffectIds
/\ DOMAIN state.ancestry=DOMAIN state.effects
/\ \A id \in DOMAIN state.ancestry : state.ancestry[id] \subseteq Nat \ {0}
/\ state.usedEffectIds \subseteq Nat \ {0}
/\ \A pair \in state.appliedPairs : /\ Len(pair)=2 /\ pair[1] \in Nat \ {0} /\ pair[2] \in Nat \ {0}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementEffectsValid99
ReplacementTechniqueValid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementTechniqueValid99(technique) ==
/\ technique.tag="CompositeEffectTechnique" /\ Len(technique.steps)>0
/\ \A index \in 1..Len(technique.steps) :
/\ technique.steps[index].tag="EffectTechniqueStep"
/\ technique.steps[index].operation \in STRING
/\ \A prior \in technique.steps[index].reads : prior \in 1..(index-1)Exact module download · Source bundle and reproduction instructions
ReplacementText99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementText99(d,lex) ==
\E id \in DOMAIN lex.mentions : lex.mentions[id].owner=AbilityKey99(d) /\ lex.mentions[id].word="instead" /\
lex.mentions[id].role \in {"EffectOperator","StaticDeclaration"}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99
ReplacementWouldGroups99 · operator
reference-profile · input revision 2 · CC0 1.0
ReplacementWouldGroups99(groups,states,steps,replacements) ==
IF Len(steps)=0 THEN groups
ELSE LET step == Head(steps).decision
input == Head(steps).effectId
ids == SubIds6(step.resultIds)
policy == replacements[step.chosen].wouldGrouping
additions == [id \in ids |-> IF policy="Preserve" THEN groups[input] ELSE Append(groups[input],id)]
next == ReplacementOverlay99([id \in DOMAIN groups \ {input} |-> groups[id]],additions)
IN ReplacementWouldGroups99(next,Tail(states),Tail(steps),replacements)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: next, ReplacementWouldGroups99
ReserveCurrentMidItemInspection99 · operator
reference-profile · input revision 2 · CC0 1.0
ReserveCurrentMidItemInspection99(before,after,p,id,d,lex,c,option,legality,usedInstances,a,afterItemInspection,midOption,options,mustRetire,exampleFamily034,cardFacts) ==
/\ Len(before)>0 /\ id \in (Nat \ {0}) \ usedInstances /\ ~AbilityInterrupt99(d,lex)
/\ PaidEligibility99(d,lex,c,WindowTop9(before),cardFacts) /\ PaidOptionMatches95(d,option,WindowTop9(before))
/\ BeginMidItemInspectionOption9(before,after,option,c.objects,legality,a,afterItemInspection,midOption,options,mustRetire,exampleFamily034)
/\ p=OpenPaidProcedure95(id,d,option,WindowTop9(before),legality.transactionId,
IF d.syntax.source.kind="Object" THEN c.objects[d.syntax.source.object].zone ELSE "Rule")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, BeginMidItemInspectionOption9, OpenPaidProcedure95, PaidEligibility99, PaidOptionMatches95, WindowTop9
ReserveCurrentPaidInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
ReserveCurrentPaidInterrupt99(beforeStack,afterStack,p,id,d,c,context,origin,world,history,ledger,option,legality,usedInstances,cardFacts) ==
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ ExpectedContextWorld99(context,world)
/\ ExpectedContextOrigin99(context,origin) /\ WouldViewCurrent99(history,context,world) /\ CurrentInterruptWindow99(context,beforeStack)
/\ LET key == AbilityKey99(d)
w == WindowTop9(beforeStack)
IN /\ key \in DOMAIN world.paidDefinitions /\ world.paidDefinitions[key]=d
/\ c=world.paidContexts[key] /\ c.currentEffect=CurrentEffectReceipt99(context,world,history,ledger,w)
/\ c.paidRelevance=CurrentPaidRelevanceReceipt99(context,world,history,w)
/\ key \in CurrentPaidRelevant99(context,world,history,w)
/\ ReservePaidAbility99(beforeStack,afterStack,p,id,d,world.lexemes[key],c,option,legality,usedInstances,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key, w, CurrentEffectReceipt99, CurrentInterruptWindow99, CurrentInterruptWorld99, CurrentPaidRelevanceReceipt99, CurrentPaidRelevant99, ExpectedContextOrigin99, ExpectedContextWorld99, ReservePaidAbility99, WouldViewCurrent99
ReserveCurrentPaidWithSelection99 · operator
reference-profile · input revision 2 · CC0 1.0
ReserveCurrentPaidWithSelection99(beforeStack,afterStack,p,selection,id,d,c,context,origin,world,history,ledger,option,legality,usedInstances,cardFacts) ==
/\ ReserveCurrentPaidInterrupt99(beforeStack,afterStack,p,id,d,c,context,origin,world,history,ledger,option,legality,usedInstances,cardFacts)
/\ selection=SelectedInterrupt99(p,d,world.lexemes[AbilityKey99(d)],world.capabilities[AbilityKey99(d)],context,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, ReserveCurrentPaidInterrupt99, SelectedInterrupt99
ReserveCurrentPersistentPaid912 · operator
reference-profile · input revision 2 · CC0 1.0
ReserveCurrentPersistentPaid912(registry,beforeStack,afterStack,p,id,d,c,context,origin,world,history,ledger,option,legality,usedInstances,cardFacts,authority) ==
/\ PersistentInterruptWorld912(registry,world,ledger,authority)
/\ CurrentInterruptWorld99(world,ledger,cardFacts) /\ ExpectedContextWorld99(context,world)
/\ ExpectedContextOrigin99(context,origin) /\ WouldViewCurrent99(history,context,world) /\ CurrentInterruptWindow99(context,beforeStack)
/\ LET key == AbilityKey99(d)
w == WindowTop9(beforeStack)
IN /\ key \in DOMAIN world.paidDefinitions /\ world.paidDefinitions[key]=d
/\ c=world.paidContexts[key] /\ c.currentEffect=PersistentCurrentEffect912(registry,context,world,history,ledger,w)
/\ c.paidRelevance=PersistentCurrentPaidRelevance912(registry,context,world,history,w)
/\ key \in PersistentCurrentPaidRelevant912(registry,context,world,history,w)
/\ ReservePersistentPaid912(registry,beforeStack,afterStack,p,id,d,world.lexemes[key],c,option,legality,usedInstances,cardFacts,ledger,authority)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: key, w, CurrentInterruptWindow99, CurrentInterruptWorld99, ExpectedContextOrigin99, ExpectedContextWorld99, PersistentCurrentEffect912, PersistentCurrentPaidRelevance912, PersistentCurrentPaidRelevant912, PersistentInterruptWorld912, ReservePersistentPaid912, WouldViewCurrent99
ReserveNormalPaid99 · operator
reference-profile · input revision 2 · CC0 1.0
ReserveNormalPaid99(before,after,p,id,d,lex,c,option,legality,usedInstances,cardFacts) ==
/\ ~AbilityInterrupt99(d,lex)
/\ ReservePaidAbility99(before,after,p,id,d,lex,c,option,legality,usedInstances,cardFacts)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityInterrupt99, ReservePaidAbility99
ReservePaidAbility95 · operator
reference-profile · input revision 2 · CC0 1.0
ReservePaidAbility95(before,after,p,id,d,c,option,legality,usedAbilityInstances) ==
/\ Len(before)>0 /\ id \in (Nat \ {0}) \ usedAbilityInstances
/\ PaidEligibility95(d,c,WindowTop9(before)) /\ PaidOptionMatches95(d,option,WindowTop9(before))
/\ BeginPriorityOption9(before,after,option,c.objects,legality,c.currentEffect)
/\ p=OpenPaidProcedure95(id,d,option,WindowTop9(before),legality.transactionId,
IF d.syntax.source.kind="Object" THEN c.objects[d.syntax.source.object].zone ELSE "Rule")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginPriorityOption9, OpenPaidProcedure95, PaidEligibility95, PaidOptionMatches95, WindowTop9
ReservePaidAbility99 · operator
reference-profile · input revision 2 · CC0 1.0
ReservePaidAbility99(before,after,p,id,d,lex,c,option,legality,usedInstances,cardFacts) ==
/\ Len(before)>0 /\ id \in (Nat \ {0}) \ usedInstances
/\ PaidEligibility99(d,lex,c,WindowTop9(before),cardFacts) /\ PaidOptionMatches95(d,option,WindowTop9(before))
/\ BeginPriorityOption9(before,after,option,c.objects,legality,c.currentEffect)
/\ p=OpenPaidProcedure95(id,d,option,WindowTop9(before),legality.transactionId,
IF d.syntax.source.kind="Object" THEN c.objects[d.syntax.source.object].zone ELSE "Rule")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginPriorityOption9, OpenPaidProcedure95, PaidEligibility99, PaidOptionMatches95, WindowTop9
ReservePaidMidItemInspection95 · operator
reference-profile · input revision 2 · CC0 1.0
ReservePaidMidItemInspection95(before,after,p,id,d,c,option,legality,usedAbilityInstances,a,afterItemInspection,midOption,options,mustRetire,exampleFamily034) ==
/\ Len(before)>0 /\ id \in (Nat \ {0}) \ usedAbilityInstances
/\ PaidEligibility95(d,c,WindowTop9(before)) /\ PaidOptionMatches95(d,option,WindowTop9(before))
/\ BeginMidItemInspectionOption9(before,after,option,c.objects,legality,a,afterItemInspection,midOption,options,mustRetire,exampleFamily034)
/\ p=OpenPaidProcedure95(id,d,option,WindowTop9(before),legality.transactionId,
IF d.syntax.source.kind="Object" THEN c.objects[d.syntax.source.object].zone ELSE "Rule")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BeginMidItemInspectionOption9, OpenPaidProcedure95, PaidEligibility95, PaidOptionMatches95, WindowTop9
ReservePersistentPaid912 · operator
reference-profile · input revision 2 · CC0 1.0
ReservePersistentPaid912(registry,before,after,p,id,d,lex,c,option,legality,usedInstances,cardFacts,ledger,authority) ==
/\ LifetimeReady910(registry,authority) /\ PersistentRegistryWorldBound912(registry,authority.current) /\ PersistentCheckpointBound912(registry,ledger)
/\ c.objects=authority.current.objects /\ c.turn=authority.current.turn /\ c.traversalControl=authority.current.control
/\ PersistentPaidContext912(c,ledger,authority.current)
/\ PersistentCapturedLexemes912(registry,[key \in {AbilityKey99(d)} |-> d],[key \in {AbilityKey99(d)} |-> lex])
/\ Len(before)>0 /\ PersistentGenerationAllowed912(registry,d,WindowTop9(before).site.traversalId)
/\ id \in (Nat \ {0}) \ usedInstances /\ PaidEligibility99(d,lex,c,WindowTop9(before),cardFacts)
/\ PaidOptionMatches95(d,option,WindowTop9(before))
/\ BeginPriorityOption9(before,after,option,c.objects,legality,c.currentEffect)
/\ p=OpenPaidProcedure95(id,d,option,WindowTop9(before),legality.transactionId,
IF AbilityKey99(d) \in DOMAIN registry.persistent THEN registry.persistent[AbilityKey99(d)].sourceZone
ELSE IF d.syntax.source.kind="Object" THEN c.objects[d.syntax.source.object].zone ELSE "Rule")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, BeginPriorityOption9, LifetimeReady910, OpenPaidProcedure95, PaidEligibility99, PaidOptionMatches95, PersistentCapturedLexemes912, PersistentCheckpointBound912, PersistentGenerationAllowed912, PersistentPaidContext912, PersistentRegistryWorldBound912, WindowTop9
ReserveSuppressInstructionAbility98 · operator
reference-profile · input revision 2 · CC0 1.0
ReserveSuppressInstructionAbility98(beforeStack,afterStack,p,id,d,c,option,legality,usedInstances,classification,intent,cardFacts) ==
/\ NormalizedSuppressInstructionClassification98(d,c.objects,cardFacts,classification)
/\ SuppressInstructionEncounterCurrent98(c.encounter,c.traversalControl)
/\ classification.mode="All" => CurrentUnsuppressedBarrierInstructions98(c.encounter) # {}
/\ classification.mode="Hook" => SubIds6(c.encounter.order) # {}
/\ ReservePaidAbility95(beforeStack,afterStack,p,id,d,c,option,legality,usedInstances)
/\ intent=NewSuppressInstructionIntent98(p,c.encounter,classification)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentUnsuppressedBarrierInstructions98, NewSuppressInstructionIntent98, NormalizedSuppressInstructionClassification98, ReservePaidAbility95, SuppressInstructionEncounterCurrent98, SubIds6
ResizeSelfStaticSubs98 · operator
reference-profile · input revision 2 · CC0 1.0
ResizeSelfStaticSubs98(before,after,application,actualCount,rows,spine,decision) ==
LET grant == before.applications[application].definition
old == SubRowsFromEffect98(before,application)
count == actualCount.count
keep == SubSeq(old,1,IF count<Len(old) THEN count ELSE Len(old))
lost == SubIds6(old) \ SubIds6(keep)
gained == DOMAIN rows
present == (before.present \ lost) \cup gained
result == OrderChangedState98(before,rows,EmptyOrder98,present,spine,decision,"SelfStaticResize",lost,"Grant")
IN /\ BarrierInstructionOrderValid98(before) /\ application \in before.activeApplications /\ SelfStaticGrant98(grant,before.barrierCard)
/\ NormalizedSubCount98(before,application,actualCount,"NormalizedSelfStaticSubCount")
/\ FreshSubRows98(before,rows) /\ Cardinality(gained)=IF count>Len(old) THEN count-Len(old) ELSE 0
/\ \A id \in gained : rows[id].effect=application
/\ RowsMatchApplication98(rows,application,grant,decision.gainOrder,before.barrierCard)
/\ OrderingDecisionBound98(before,decision,"SelfStaticResize",gained,lost,spine,present)
/\ FreshOrderingConstraints98(result,gained)
/\ after=result /\ BarrierInstructionOrderValid98(after) /\ SelfCategoryIdentical98(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: count, gained, grant, lost, old, present, result, BarrierInstructionOrderValid98, FreshOrderingConstraints98, FreshSubRows98, NormalizedSubCount98, OrderingDecisionBound98, RowsMatchApplication98, SelfCategoryIdentical98, SelfStaticGrant98
ResolutionOrderBound98 · operator
reference-profile · input revision 2 · CC0 1.0
ResolutionOrderBound98(loop,e,actualOrder) ==
/\ actualOrder.tag="CurrentBarrierInstructionResolutionOrder" /\ actualOrder.encounter=e.id /\ actualOrder.barrierCard=e.barrierCard
/\ actualOrder.physicalOrder=e.order /\ actualOrder.barrierInstructionSuppressed=e.barrierInstructionSuppressed /\ actualOrder.handled=loop.handled
/\ actualOrder.initialOrder=loop.initialOrder /\ actualOrder.exampleFamily062=loop.exampleFamily062
/\ DeckSequenceValid4(actualOrder.order) /\ SubIds6(actualOrder.order)=RemainingBarrierInstructions98(loop,e)
/\ IF loop.exampleFamily062=0 THEN actualOrder.order=SelectSeq(e.order,LAMBDA id : id \in RemainingBarrierInstructions98(loop,e))
ELSE /\ SelectSeq(actualOrder.order,LAMBDA id : id \in loop.initialEligible)=SelectSeq(loop.initialOrder,LAMBDA id : id \in RemainingBarrierInstructions98(loop,e))
/\ SelectSeq(actualOrder.order,LAMBDA id : id \notin loop.initialEligible)=SelectSeq(e.order,LAMBDA id : id \in RemainingBarrierInstructions98(loop,e) \ loop.initialEligible)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA, LAMBDA, LAMBDA, LAMBDA, LAMBDA, RemainingBarrierInstructions98, DeckSequenceValid4, SubIds6
ResolveBarrierInstructionAfterInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveBarrierInstructionAfterInterrupt98(before,after,beforeStack,afterStack,plan,afterPlan,clearance) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="Imminent"
/\ ReturnInstructionInterrupt93(beforeStack,afterStack,plan,before.ability,"NoValue",clearance)
/\ BarrierInstructionOwnerAtTop98(before.owner,afterStack)
/\ LET resolving == [before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(before.ability,resolving,plan,afterPlan,clearance)
/\ after=[before EXCEPT !.ability=resolving,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, BeginAbilityInstructionAtomic93, ReturnInstructionInterrupt93
ResolveBarrierInstructionWithoutInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveBarrierInstructionWithoutInterrupt98(before,after,stack,plan,afterPlan,noModifiers,clearance) ==
/\ BarrierInstructionBarrierInstructionBound98(before) /\ before.phase="Imminent" /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ LET resolving == [before.ability EXCEPT !.phase="Resolving"]
IN /\ NoInstructionInterrupt93(plan,before.ability,"NoValue",noModifiers,clearance)
/\ BeginAbilityInstructionAtomic93(before.ability,resolving,plan,afterPlan,clearance)
/\ after=[before EXCEPT !.ability=resolving,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, BeginAbilityInstructionAtomic93, NoInstructionInterrupt93
ResolveConditionalAfterInterrupt96 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveConditionalAfterInterrupt96(beforeLedger,afterLedger,beforeStack,afterStack,beforeP,afterP,plan,afterPlan,clearance) ==
/\ ConditionalProcedureBound96(beforeLedger,beforeP) /\ beforeLedger.instances[beforeP.id].status="Imminent"
/\ beforeP.phase="Imminent" /\ plan.index \in DOMAIN beforeLedger.instances[beforeP.id].expected
/\ clearance.openingRevision=beforeLedger.instances[beforeP.id].expected[plan.index].instruction.revision
/\ ReturnInstructionInterrupt93(beforeStack,afterStack,plan,beforeP.ability,"NoValue",clearance)
/\ ConditionalAtTop96(afterStack,beforeP)
/\ LET resolving == [beforeP.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(beforeP.ability,resolving,plan,afterPlan,clearance)
/\ afterP=[beforeP EXCEPT !.ability=resolving,!.phase="Resolve"]
/\ afterLedger=[beforeLedger EXCEPT !.instances[beforeP.id].status="Resolving"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BeginAbilityInstructionAtomic93, ConditionalAtTop96, ConditionalProcedureBound96, ReturnInstructionInterrupt93
ResolveConditionalInterruptAndReturn99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveConditionalInterruptAndReturn99(before,after,beforeOrigin,afterOrigin,beforeModifier,afterModifier,world,selection,call,operation,
afterEffects,resolved,actualReturn,cardFacts) ==
/\ ResolveConditionalInterruptControl99(before,after,beforeOrigin,afterOrigin,beforeModifier,world,selection,call,operation,afterEffects,resolved,cardFacts)
/\ CompleteModifierExpectedContext99(beforeModifier,afterModifier,call,world,actualReturn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CompleteModifierExpectedContext99, ResolveConditionalInterruptControl99
ResolveConditionalInterruptControl99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveConditionalInterruptControl99(before,after,beforeOrigin,afterOrigin,modifier,world,selection,call,operation,afterEffects,resolved,cardFacts) ==
/\ SelectedInterruptAtTop99(selection,call.before,before,call.beforeStack,call.beforePlan,world,cardFacts)
/\ call.before.ability.kind="Conditional"
/\ ApplyExpectedControlCore99(before,after,beforeOrigin,afterOrigin,modifier,call.beforePlan,operation,world,afterEffects)
/\ CarryConditionalInstruction96(call.beforeLedger,call.candidateLedger,call.afterLedger,call.beforeStack,call.afterStack,
call.before,call.after,call.beforePlan,call.afterPlan,call.step,call.beforeSnapshot,call.afterSnapshot)
/\ call.step.expectedControl=operation
/\ resolved=ResolvedControlReceipt99(before,after,modifier,call.before,operation)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ApplyExpectedControlCore99, CarryConditionalInstruction96, ResolvedControlReceipt99, SelectedInterruptAtTop99
ResolveConditionalReplacementAndReturn99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveConditionalReplacementAndReturn99(before,after,beforeOrigin,afterOrigin,beforeModifier,afterModifier,world,selection,call,
operation,record,afterUsedIds,states,steps,actualReturn,cardFacts) ==
/\ SelectedInterruptAtTop99(selection,call.before,before,call.beforeStack,call.beforePlan,world,cardFacts)
/\ call.before.ability.kind="Conditional"
/\ CreateImmediateReplacementCore99(before,after,beforeOrigin,afterOrigin,beforeModifier,world,selection,call.before,call.beforePlan,operation,record,
afterUsedIds,states,steps,cardFacts)
/\ CarryConditionalInstruction96(call.beforeLedger,call.candidateLedger,call.afterLedger,call.beforeStack,call.afterStack,
call.before,call.after,call.beforePlan,call.afterPlan,call.step,call.beforeSnapshot,call.afterSnapshot)
/\ call.step.expectedReplacement=operation
/\ CompleteModifierExpectedContext99(beforeModifier,afterModifier,call,world,actualReturn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryConditionalInstruction96, CompleteModifierExpectedContext99, CreateImmediateReplacementCore99, SelectedInterruptAtTop99
ResolveConditionalWithoutInterrupt96 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveConditionalWithoutInterrupt96(beforeLedger,afterLedger,stack,beforeP,afterP,plan,afterPlan,noModifiers,clearance,actualExpected) ==
/\ ConditionalAtTop96(stack,beforeP)
/\ LET observed == [beforeLedger EXCEPT !.instances[beforeP.id].expected=[i \in DOMAIN @ \cup {plan.index} |->
IF i=plan.index THEN [instruction |-> InstructionWindowRef93(plan),effects |-> actualExpected.effects] ELSE @[i]]]
resolving == [beforeP.ability EXCEPT !.phase="Resolving"]
IN /\ ObserveConditionalExpected96(beforeLedger,observed,beforeP,plan,actualExpected)
/\ NoInstructionInterrupt93(plan,beforeP.ability,"NoValue",noModifiers,clearance)
/\ BeginAbilityInstructionAtomic93(beforeP.ability,resolving,plan,afterPlan,clearance)
/\ afterP=[beforeP EXCEPT !.ability=resolving,!.phase="Resolve"]
/\ afterLedger=[observed EXCEPT !.instances[beforeP.id].status="Resolving"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: observed, resolving, BeginAbilityInstructionAtomic93, ConditionalAtTop96, NoInstructionInterrupt93, ObserveConditionalExpected96
ResolveCurrentInstruction9 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveCurrentInstruction9(before,after,actualInterruptWindowComplete) ==
/\ before.phase = "Imminent" /\ ~before.complete /\ actualInterruptWindowComplete
/\ after = [before EXCEPT !.phase = "Resolving"]Exact module download · Source bundle and reproduction instructions
ResolveCurrentOnceChoice912 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveCurrentOnceChoice912(before,after,key,rows,world,lifetimes,authority,package,choice,receipt,cardFacts) ==
/\ LifetimeReady910(lifetimes,authority) /\ world=authority.current
/\ package.tag="AuthoritativeResolvedChoiceGrants" /\ package.worldId=world.id
/\ package.turnId=world.turn.id /\ package.decision=key /\ package.effects=rows
/\ \A id \in DOMAIN rows :
LET row == rows[id]
IN /\ row.tag="SourceBoundOnceChoiceEffect" /\ row.occurrence=id
/\ row.card \in DOMAIN cardFacts /\ row.sourceSHA=cardFacts[row.card].sourceSHA
/\ row.source.kind="Object"
/\ IF row.source.object \in DOMAIN world.objects THEN world.objects[row.source.object].card=row.card ELSE TRUE
/\ row.grant.tag="ResolvedOnceChoiceGrant" /\ row.grant.occurrence=id /\ row.grant.decision=key
/\ row.grant.source=row.source /\ row.grant.card=row.card /\ row.grant.sourceSHA=row.sourceSHA
/\ row.grant.chooser=row.chooser /\ row.grant.options=row.options /\ row.grant.remainder=row.remainder
/\ ResolveOnceChoice912(before,after,key,rows,world.turn,choice,receipt)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: row, LifetimeReady910, ResolveOnceChoice912
ResolveOnceChoice912 · operator
reference-profile · input revision 2 · CC0 1.0
ResolveOnceChoice912(before,after,key,rows,turn,choice,receipt) ==
/\ rows#[emptyId \in {} |-> emptyId] /\ key \notin DOMAIN before /\ turn.owner \in SetupPlayers
/\ \A id \in DOMAIN rows : rows[id].key=key /\ rows[id].chooser \in SetupPlayers
/\ choice.player=OnceChoiceController912(rows,turn.owner)
/\ choice.selection \in UNION {rows[id].options : id \in {id \in DOMAIN rows : rows[id].chooser=choice.player}}
/\ receipt=[tag |-> "OnceOnlySimultaneousChoice",key |-> key,turnId |-> turn.id,active |-> turn.owner,
chooser |-> choice.player,choice |-> choice.selection,remainder |-> [id \in DOMAIN rows |-> rows[id].remainder],sources |-> rows]
/\ after=ReplacementOverlay99(before,[id \in {key} |-> receipt])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: OnceChoiceController912, ReplacementOverlay99, SetupPlayers
ResolvePaidAfterInterrupt95 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePaidAfterInterrupt95(beforeStack,afterStack,before,after,plan,afterPlan,actualReturn) ==
/\ before.phase="Imminent"
/\ ReturnInstructionInterrupt93(beforeStack,afterStack,plan,before.ability,"NoValue",actualReturn)
/\ PaidProcedureAtTop95(afterStack,before)
/\ LET a == [before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(before.ability,a,plan,afterPlan,actualReturn)
/\ after=[before EXCEPT !.ability=a,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, BeginAbilityInstructionAtomic93, PaidProcedureAtTop95, ReturnInstructionInterrupt93
ResolvePaidInterruptAndReturn99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePaidInterruptAndReturn99(before,after,beforeOrigin,afterOrigin,beforeModifier,afterModifier,world,selection,call,operation,
afterEffects,resolved,actualReturn,cardFacts) ==
/\ ResolvePaidInterruptControl99(before,after,beforeOrigin,afterOrigin,beforeModifier,world,selection,call,operation,afterEffects,resolved,cardFacts)
/\ CompleteModifierExpectedContext99(beforeModifier,afterModifier,call,world,actualReturn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CompleteModifierExpectedContext99, ResolvePaidInterruptControl99
ResolvePaidInterruptControl99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePaidInterruptControl99(before,after,beforeOrigin,afterOrigin,modifier,world,selection,call,operation,afterEffects,resolved,cardFacts) ==
/\ SelectedInterruptAtTop99(selection,call.before,before,call.stack,call.beforePlan,world,cardFacts)
/\ call.before.ability.kind="Paid"
/\ ApplyExpectedControlCore99(before,after,beforeOrigin,afterOrigin,modifier,call.beforePlan,operation,world,afterEffects)
/\ CarryPaidInstruction95(call.stack,call.before,call.after,call.beforePlan,call.afterPlan,call.step)
/\ call.step.expectedControl=operation
/\ resolved=ResolvedControlReceipt99(before,after,modifier,call.before,operation)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ApplyExpectedControlCore99, CarryPaidInstruction95, ResolvedControlReceipt99, SelectedInterruptAtTop99
ResolvePaidReplacementAndReturn99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePaidReplacementAndReturn99(before,after,beforeOrigin,afterOrigin,beforeModifier,afterModifier,world,selection,call,
operation,record,afterUsedIds,states,steps,actualReturn,cardFacts) ==
/\ SelectedInterruptAtTop99(selection,call.before,before,call.stack,call.beforePlan,world,cardFacts)
/\ call.before.ability.kind="Paid"
/\ CreateImmediateReplacementCore99(before,after,beforeOrigin,afterOrigin,beforeModifier,world,selection,call.before,call.beforePlan,operation,record,
afterUsedIds,states,steps,cardFacts)
/\ CarryPaidInstruction95(call.stack,call.before,call.after,call.beforePlan,call.afterPlan,call.step)
/\ call.step.expectedReplacement=operation
/\ CompleteModifierExpectedContext99(beforeModifier,afterModifier,call,world,actualReturn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CarryPaidInstruction95, CompleteModifierExpectedContext99, CreateImmediateReplacementCore99, SelectedInterruptAtTop99
ResolvePaidSuppressInstructionInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePaidSuppressInstructionInstruction98(before,after,control,stack,p,plan,intent,selection,actualEffect,events) ==
/\ SuppressInstructionIntentMatches98(intent,p) /\ EncounterSuppressInstructionRef98(before)=intent.encounter
/\ PaidProcedureAtTop95(stack,p) /\ p.phase="Resolve" /\ p.costPaid /\ p.ability.phase="Resolving"
/\ plan.phase="Resolving" /\ InstructionPlanMatches93(plan,p.ability,p.ability.cursor)
/\ plan.id=intent.classification.instruction /\ SuppressInstructionSelectionMatches98(intent,selection,plan)
/\ actualEffect.tag="NormalizedSuppressInstructionResolution" /\ actualEffect.instruction=InstructionWindowRef93(plan)
/\ actualEffect.abilityInstance=p.id /\ actualEffect.source=intent.source /\ actualEffect.encounter=intent.encounter
/\ actualEffect.classification=intent.classification /\ actualEffect.operation \in {"SuppressInstruction","NoEffects"}
/\ IF SuppressInstructionEncounterEnded98(before,control) THEN after=before /\ events={}
ELSE /\ SuppressInstructionEncounterCurrent98(before,control)
/\ LET subs == IF actualEffect.operation="NoEffects" THEN {}
ELSE CASE intent.classification.mode="All" -> CurrentUnsuppressedBarrierInstructions98(before)
[] intent.classification.mode="Hook" -> CurrentUnsuppressedBarrierInstructions98(before) \ selection.targets
[] OTHER -> SuppressInstructionOrdinaryCandidates98(before,intent.classification) \cap selection.targets
IN IF subs={} THEN after=before /\ events={}
ELSE SuppressInstructionEncounterSubs6(before,after,subs,intent.source.object,TRUE,p.costPaid,events)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: subs, EncounterSuppressInstructionRef98, InstructionPlanMatches93, InstructionWindowRef93, PaidProcedureAtTop95, SuppressInstructionEncounterCurrent98, SuppressInstructionEncounterEnded98, SuppressInstructionIntentMatches98, SuppressInstructionSelectionMatches98, SuppressInstructionEncounterSubs6
ResolvePaidWithoutInterrupt95 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePaidWithoutInterrupt95(stack,before,after,plan,afterPlan,actualNoModifiers,actualReturn) ==
/\ before.phase="Imminent" /\ PaidProcedureAtTop95(stack,before)
/\ NoInstructionInterrupt93(plan,before.ability,"NoValue",actualNoModifiers,actualReturn)
/\ LET a == [before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(before.ability,a,plan,afterPlan,actualReturn)
/\ after=[before EXCEPT !.ability=a,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: a, BeginAbilityInstructionAtomic93, NoInstructionInterrupt93, PaidProcedureAtTop95
ResolvePlayAfterInterrupt97 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePlayAfterInterrupt97(before,after,f,beforeStack,afterStack,plan,afterPlan,clearance) ==
/\ PlayAbilityBound97(before) /\ before.phase="Imminent"
/\ ReturnInstructionInterrupt93(beforeStack,afterStack,plan,before.ability,"NoValue",clearance)
/\ PlayOwnerAtTop97(before,f,afterStack)
/\ LET resolving == [before.ability EXCEPT !.phase="Resolving"]
IN /\ BeginAbilityInstructionAtomic93(before.ability,resolving,plan,afterPlan,clearance)
/\ after=[before EXCEPT !.ability=resolving,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BeginAbilityInstructionAtomic93, PlayAbilityBound97, PlayOwnerAtTop97, ReturnInstructionInterrupt93
ResolvePlayWithoutInterrupt97 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvePlayWithoutInterrupt97(before,after,f,stack,plan,afterPlan,noModifiers,clearance) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ PlayAbilityBound97(before) /\ before.phase="Imminent"
/\ LET resolving == [before.ability EXCEPT !.phase="Resolving"]
IN /\ NoInstructionInterrupt93(plan,before.ability,"NoValue",noModifiers,clearance)
/\ BeginAbilityInstructionAtomic93(before.ability,resolving,plan,afterPlan,clearance)
/\ after=[before EXCEPT !.ability=resolving,!.phase="Resolve"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: resolving, BeginAbilityInstructionAtomic93, NoInstructionInterrupt93, PlayAbilityBound97, PlayOwnerAtTop97
ResolvedBarrierInstructionCount98 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvedBarrierInstructionCount98(loop,calls,barrierCard,encounter) ==
(IF loop.encounter=encounter THEN Cardinality({h \in 1..Len(loop.history) : loop.history[h].source=ObjectAbilitySource9(barrierCard) /\ loop.history[h].disposition="Resolved"}) ELSE 0) +
Cardinality({call \in DOMAIN calls : calls[call].encounter=encounter /\ calls[call].source=ObjectAbilitySource9(barrierCard) /\ calls[call].status="Returned" /\ calls[call].disposition="Resolved"})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObjectAbilitySource9
ResolvedControlReceipt99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvedControlReceipt99(before,after,modifier,p,operation) ==
[tag |-> "ResolvedInterruptEffectModification",status |-> "Resolved",classification |-> "Interrupt",abilityKind |-> p.ability.kind,
id |-> operation.operationId,abilityInstance |-> p.id,source |-> p.ability.source,
beforeEffects |-> before.state.effects,afterEffects |-> after.state.effects,
revisionBefore |-> before.currentRef.revision,revisionAfter |-> after.currentRef.revision,
instruction |-> modifier.currentRef,operation |-> operation.kind]Exact module download · Source bundle and reproduction instructions
ResolvedExpectedInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
ResolvedExpectedInterrupt99(before,after,actualResolved) ==
/\ ExpectedEffectsValid99(before) /\ ExpectedEffectsValid99(after)
/\ actualResolved.tag="ResolvedInterruptEffectModification" /\ actualResolved.status="Resolved"
/\ actualResolved.classification="Interrupt" /\ actualResolved.abilityKind \in {"Paid","Conditional"}
/\ actualResolved.id \in Nat \ {0} /\ actualResolved.abilityInstance \in Nat \ {0}
/\ actualResolved.source.kind \in {"Object","Rule"}
/\ IF actualResolved.source.kind="Object" THEN actualResolved.source.object \in Nat \ {0} ELSE actualResolved.source.rule # "NoValue"
/\ actualResolved.beforeEffects=before /\ actualResolved.afterEffects=after
/\ actualResolved.revisionBefore \in Nat /\ actualResolved.revisionAfter=actualResolved.revisionBefore+1Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectsValid99
RestrictionKinds93 · operator
reference-profile · input revision 2 · CC0 1.0
RestrictionKinds93 == {"OwnCost","CardTimingLocation","AbilityUse","Payment","Hosting","Variable","Unpreventable"}Exact module download · Source bundle and reproduction instructions
ResumeOccurrenceInstruction912 · operator
reference-profile · input revision 2 · CC0 1.0
ResumeOccurrenceInstruction912(before,after,plan,ledger,stack,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceRuntimeProfile912(before)
/\ before.phase="Paused" /\ before.ability.phase="Resolving" /\ before.pause.id \in Nat \ {0}
/\ before.pause.instruction=InstructionWindowRef93(plan) /\ before.pause.cursor=plan.cursor /\ plan.phase="Resolving"
/\ receipt.tag="OwnedInstructionCheckpointReturn" /\ receipt.pauseId=before.pause.id /\ receipt.childId=before.pause.childId
/\ receipt.instruction=before.pause.instruction /\ receipt.point=before.pause.point
/\ receipt.id=before.pause.request.id /\ receipt.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[receipt.id].caller=before.pause.request.caller
/\ receipt.complete /\ receipt.allNewerChainsComplete /\ ConditionalCheckpointDrained96(ledger,stack,receipt.id)
/\ after=[before EXCEPT !.phase="Resolve",!.pause=[id |-> 0]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, InstructionWindowRef93, LifetimeReady910, OccurrenceRuntimeProfile912
ResumeRuntimeInstruction911 · operator
reference-profile · input revision 2 · CC0 1.0
ResumeRuntimeInstruction911(before,after,plan,ledger,stack,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeProfile911(before)
/\ before.phase="Paused" /\ before.ability.phase="Resolving" /\ before.pause.id \in Nat \ {0}
/\ before.pause.instruction=InstructionWindowRef93(plan) /\ before.pause.cursor=plan.cursor /\ plan.phase="Resolving"
/\ receipt.tag="OwnedInstructionCheckpointReturn" /\ receipt.pauseId=before.pause.id /\ receipt.childId=before.pause.childId
/\ receipt.instruction=before.pause.instruction /\ receipt.point=before.pause.point
/\ receipt.id=before.pause.request.id /\ receipt.id \in DOMAIN ledger.checkpoints
/\ ledger.checkpoints[receipt.id].caller=before.pause.request.caller
/\ receipt.complete /\ receipt.allNewerChainsComplete /\ ConditionalCheckpointDrained96(ledger,stack,receipt.id)
/\ after=[before EXCEPT !.phase="Resolve",!.pause=[id |-> 0]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalCheckpointDrained96, InstructionWindowRef93, LifetimeReady910, RuntimeProfile911
ReturnAbility9 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnAbility9(before,after,actualFinalCheckpointAndChainsComplete,caller) ==
/\ before.complete /\ ~before.returned /\ actualFinalCheckpointAndChainsComplete /\ caller = before.caller
/\ after = [before EXCEPT !.returned = TRUE]Exact module download · Source bundle and reproduction instructions
ReturnBarrierInstructionInterrupt98 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnBarrierInstructionInterrupt98(beforeP,afterP,before,after,r) ==
/\ BarrierInstructionImminent98(beforeP) /\ BarrierInstructionInterruptReturnBound98(beforeP,r) /\ Len(before)>0
/\ LET w == WindowTop9(before)
IN /\ w.kind="Interrupt" /\ w.pending={} /\ r.windowId=w.id
/\ w.instruction.origin="BarrierInstruction" /\ w.instruction.id=beforeP.id /\ w.instruction.barrierInstruction=beforeP.barrierInstruction
/\ w.instruction.encounter=beforeP.encounter /\ w.instruction.source=beforeP.ability.source /\ w.instruction.sourceZone=beforeP.ability.sourceZone
/\ w.instruction.abilityInstance=beforeP.id /\ w.instruction.index=0 /\ r.openingRevision=w.instruction.revision
/\ PopClosedPriorityWindow9(before,after) /\ BarrierInstructionOwnerAtTop98(beforeP.owner,after)
/\ afterP=[beforeP EXCEPT !.phase="FirstTargets"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, BarrierInstructionImminent98, BarrierInstructionInterruptReturnBound98, BarrierInstructionOwnerAtTop98, PopClosedPriorityWindow9
ReturnConditionalOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnConditionalOccurrence912(beforeStack,afterStack,before,after,ledger,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(before,authority)
/\ before.id \in authority.current.finishedInstances /\ ConditionalOccurrenceBound912(ledger,before)
/\ before.phase="Complete" /\ before.current=0 /\ ledger.instances[before.id].status="Complete"
/\ OccurrenceAtTop912(beforeStack,before) /\ before.checkpoint \in Nat \ {0}
/\ receipt.finalCheckpointId=before.checkpoint
/\ LET returned == [before.ability EXCEPT !.returned=TRUE]
IN /\ ReturnAbility9(before.ability,returned,TRUE,before.metadata.windowId)
/\ CompletePriorityOption9(beforeStack,afterStack,receipt)
/\ after=[before EXCEPT !.ability=returned,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: returned, CompletePriorityOption9, ConditionalOccurrenceBound912, LifetimeReady910, OccurrenceAtTop912, OccurrenceOwnerCurrent912, ReturnAbility9
ReturnConditionalRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnConditionalRuntime911(beforeStack,afterStack,before,after,ledger,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(before,authority)
/\ before.id \in authority.current.finishedInstances /\ ConditionalRuntimeBound911(ledger,before)
/\ before.phase="Complete" /\ before.pc=0 /\ ledger.instances[before.id].status="Complete"
/\ ConditionalAtTop96(beforeStack,before) /\ before.checkpoint \in Nat \ {0}
/\ receipt.finalCheckpointId=before.checkpoint
/\ LET returned == [before.ability EXCEPT !.returned=TRUE]
IN /\ ReturnAbility9(before.ability,returned,TRUE,before.windowId)
/\ CompletePriorityOption9(beforeStack,afterStack,receipt)
/\ after=[before EXCEPT !.ability=returned,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: returned, CompletePriorityOption9, ConditionalAtTop96, ConditionalRuntimeBound911, LifetimeReady910, ReturnAbility9, RuntimeOwnerCurrent911
ReturnEncounterBarrierInstructionOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnEncounterBarrierInstructionOccurrence912(r,afterRuntime,beforeLoop,afterLoop,e,afterEncounter,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceOccurrenceBound912(r) /\ r.metadata.sourceEntry.kind="BarrierInstructionFirst"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0}
/\ LET p == r.metadata.sourceEntry.after
IN /\ BarrierInstructionLoopMatches98(beforeLoop,e) /\ p.origin="Encounter" /\ beforeLoop.current=r.id
/\ e.id=p.encounter /\ e.barrierCard=p.barrierCard /\ beforeLoop.owner=r.metadata.owner /\ BarrierInstructionOwnerAtTop98(r.metadata.owner,stack)
/\ ReturnAbility9(r.ability,[r.ability EXCEPT !.returned=TRUE],TRUE,p.caller)
/\ afterEncounter=[e EXCEPT !.resolved=@ \cup {p.barrierInstruction}]
/\ afterLoop=[beforeLoop EXCEPT !.current=0,!.handled=@ \cup {p.barrierInstruction},!.resolved=@ \cup {p.barrierInstruction},
!.history=Append(@,[barrierInstruction |-> p.barrierInstruction,instance |-> r.id,disposition |-> "Resolved",source |-> r.ability.source])]
/\ afterRuntime=[r EXCEPT !.ability.returned=TRUE,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, BarrierInstructionLoopMatches98, BarrierInstructionOwnerAtTop98, LifetimeReady910, OccurrenceOwnerCurrent912, ReturnAbility9, SourceOccurrenceBound912
ReturnEncounterBarrierInstructionRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnEncounterBarrierInstructionRuntime911(r,afterRuntime,beforeLoop,afterLoop,e,afterEncounter,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceRuntimeBound911(r) /\ r.sourceEntry.kind="BarrierInstructionFirst"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0}
/\ LET p == r.sourceEntry.after
IN /\ BarrierInstructionLoopMatches98(beforeLoop,e) /\ p.origin="Encounter" /\ beforeLoop.current=r.id
/\ e.id=p.encounter /\ e.barrierCard=p.barrierCard /\ beforeLoop.owner=r.sourceOwner /\ BarrierInstructionOwnerAtTop98(r.sourceOwner,stack)
/\ ReturnAbility9(r.ability,[r.ability EXCEPT !.returned=TRUE],TRUE,p.caller)
/\ afterEncounter=[e EXCEPT !.resolved=@ \cup {p.barrierInstruction}]
/\ afterLoop=[beforeLoop EXCEPT !.current=0,!.handled=@ \cup {p.barrierInstruction},!.resolved=@ \cup {p.barrierInstruction},
!.history=Append(@,[barrierInstruction |-> p.barrierInstruction,instance |-> r.id,disposition |-> "Resolved",source |-> r.ability.source])]
/\ afterRuntime=[r EXCEPT !.ability.returned=TRUE,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, BarrierInstructionLoopMatches98, BarrierInstructionOwnerAtTop98, LifetimeReady910, ReturnAbility9, RuntimeOwnerCurrent911, SourceRuntimeBound911
ReturnInstructionBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnInstructionBarrierInstruction98(beforeCalls,afterCalls,before,after,parentPlan,parent,ruleStep,stack,actualReturn) ==
/\ BarrierInstructionBarrierInstructionBound98(before)
/\ NestedBarrierInstructionInvocation98(before,parentPlan,parent,ruleStep,before.invocation)
/\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ before.invocation.id \in DOMAIN beforeCalls
/\ beforeCalls[before.invocation.id]=[instruction |-> InstructionWindowRef93(parentPlan),instance |-> before.id,status |-> "Active",source |-> before.ability.source,encounter |-> before.encounter,barrierInstruction |-> before.barrierInstruction,disposition |-> "NoValue"]
/\ actualReturn.tag="NestedBarrierInstructionReturn" /\ actualReturn.instruction=InstructionWindowRef93(parentPlan)
/\ actualReturn.invocation=before.invocation.id /\ actualReturn.instance=before.id /\ actualReturn.source=before.ability.source
/\ actualReturn.barrierInstruction=before.barrierInstruction /\ actualReturn.complete
/\ IF before.prevented THEN
/\ before.phase="FirstTargets" /\ ~before.ability.firstImminent
/\ actualReturn.disposition="Prevented" /\ actualReturn.finalCheckpoint=0
/\ after=[before EXCEPT !.phase="PreventedReturn"]
ELSE /\ before.phase="AbilityComplete" /\ before.checkpoint \in Nat \ {0}
/\ actualReturn.disposition="Resolved" /\ actualReturn.finalCheckpoint=before.checkpoint
/\ ReturnAbility9(before.ability,after.ability,TRUE,before.caller)
/\ after=[before EXCEPT !.ability=after.ability,!.phase="Returned"]
/\ afterCalls=[beforeCalls EXCEPT ![before.invocation.id].status="Returned",![before.invocation.id].disposition=actualReturn.disposition]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionBarrierInstructionBound98, BarrierInstructionOwnerAtTop98, InstructionWindowRef93, NestedBarrierInstructionInvocation98, ReturnAbility9
ReturnInstructionInterrupt93 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnInstructionInterrupt93(before,after,plan,ability,actualRuleStep,actualReturn) ==
/\ Len(before)>0 /\ InstructionImminentAtOrigin93(plan,ability,actualRuleStep)
/\ InstructionInterruptReturnMatches93(plan,actualReturn)
/\ LET w == WindowTop9(before)
IN /\ w.kind="Interrupt" /\ InstructionProfileMatches93(w.instruction,plan)
/\ w.pending={}
/\ actualReturn.windowId=w.id /\ actualReturn.openingRevision=w.instruction.revision
/\ PopClosedPriorityWindow9(before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, InstructionImminentAtOrigin93, InstructionInterruptReturnMatches93, InstructionProfileMatches93, PopClosedPriorityWindow9
ReturnMidItemInspectionOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnMidItemInspectionOccurrence912(beforeStack,afterStack,r,afterRuntime,afterProcedure,receipt,objects,transits,a,afterItemInspection,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceOccurrenceBound912(r) /\ r.metadata.sourceEntry.kind="Paid"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0}
/\ objects=authority.current.objects /\ SetAsideTrackingValid4(objects,transits)
/\ LET p == [r.metadata.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]
IN /\ PaidConvertedAsideIds95(p,objects,transits)={}
/\ PaidCleanupIds95(p,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(p,objects,transits,"ProcedureCode96bfa1b6a970")={}
/\ FinishPaidMidItemInspection95(beforeStack,afterStack,p,afterProcedure,receipt,a,afterItemInspection)
/\ afterRuntime=[r EXCEPT !.ability=afterProcedure.ability,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, FinishPaidMidItemInspection95, LifetimeReady910, OccurrenceOwnerCurrent912, PaidCleanupIds95, PaidConvertedAsideIds95, SourceOccurrenceBound912, SetAsideTrackingValid4
ReturnMidItemInspectionRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnMidItemInspectionRuntime911(beforeStack,afterStack,r,afterRuntime,afterProcedure,receipt,objects,transits,a,afterItemInspection,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceRuntimeBound911(r) /\ r.sourceEntry.kind="Paid"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0}
/\ objects=authority.current.objects /\ SetAsideTrackingValid4(objects,transits)
/\ LET p == [r.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]
IN /\ PaidConvertedAsideIds95(p,objects,transits)={}
/\ PaidCleanupIds95(p,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(p,objects,transits,"ProcedureCode96bfa1b6a970")={}
/\ FinishPaidMidItemInspection95(beforeStack,afterStack,p,afterProcedure,receipt,a,afterItemInspection)
/\ afterRuntime=[r EXCEPT !.ability=afterProcedure.ability,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, FinishPaidMidItemInspection95, LifetimeReady910, PaidCleanupIds95, PaidConvertedAsideIds95, RuntimeOwnerCurrent911, SourceRuntimeBound911, SetAsideTrackingValid4
ReturnNestedBarrierInstructionOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnNestedBarrierInstructionOccurrence912(r,afterRuntime,beforeCalls,afterCalls,parentPlan,parent,ruleStep,stack,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceOccurrenceBound912(r) /\ r.metadata.sourceEntry.kind="NestedBarrierInstructionFirst"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0} /\ BarrierInstructionOwnerAtTop98(r.metadata.owner,stack)
/\ LET p == r.metadata.sourceEntry.after
IN /\ NestedBarrierInstructionInvocation98(p,parentPlan,parent,ruleStep,p.invocation)
/\ p.invocation.id \in DOMAIN beforeCalls
/\ beforeCalls[p.invocation.id]=[instruction |-> InstructionWindowRef93(parentPlan),instance |-> r.id,status |-> "Active",
source |-> r.ability.source,encounter |-> p.encounter,barrierInstruction |-> p.barrierInstruction,disposition |-> "NoValue"]
/\ receipt=[tag |-> "NestedBarrierInstructionReturn",instruction |-> InstructionWindowRef93(parentPlan),invocation |-> p.invocation.id,
instance |-> r.id,source |-> r.ability.source,barrierInstruction |-> p.barrierInstruction,complete |-> TRUE,
disposition |-> "Resolved",finalCheckpoint |-> r.checkpoint]
/\ ReturnAbility9(r.ability,[r.ability EXCEPT !.returned=TRUE],TRUE,p.caller)
/\ afterCalls=[beforeCalls EXCEPT ![p.invocation.id].status="Returned",![p.invocation.id].disposition="Resolved"]
/\ afterRuntime=[r EXCEPT !.ability.returned=TRUE,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, BarrierInstructionOwnerAtTop98, InstructionWindowRef93, LifetimeReady910, NestedBarrierInstructionInvocation98, OccurrenceOwnerCurrent912, ReturnAbility9, SourceOccurrenceBound912
ReturnNestedBarrierInstructionRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnNestedBarrierInstructionRuntime911(r,afterRuntime,beforeCalls,afterCalls,parentPlan,parent,ruleStep,stack,receipt,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceRuntimeBound911(r) /\ r.sourceEntry.kind="NestedBarrierInstructionFirst"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0} /\ BarrierInstructionOwnerAtTop98(r.sourceOwner,stack)
/\ LET p == r.sourceEntry.after
IN /\ NestedBarrierInstructionInvocation98(p,parentPlan,parent,ruleStep,p.invocation)
/\ p.invocation.id \in DOMAIN beforeCalls
/\ beforeCalls[p.invocation.id]=[instruction |-> InstructionWindowRef93(parentPlan),instance |-> r.id,status |-> "Active",
source |-> r.ability.source,encounter |-> p.encounter,barrierInstruction |-> p.barrierInstruction,disposition |-> "NoValue"]
/\ receipt=[tag |-> "NestedBarrierInstructionReturn",instruction |-> InstructionWindowRef93(parentPlan),invocation |-> p.invocation.id,
instance |-> r.id,source |-> r.ability.source,barrierInstruction |-> p.barrierInstruction,complete |-> TRUE,
disposition |-> "Resolved",finalCheckpoint |-> r.checkpoint]
/\ ReturnAbility9(r.ability,[r.ability EXCEPT !.returned=TRUE],TRUE,p.caller)
/\ afterCalls=[beforeCalls EXCEPT ![p.invocation.id].status="Returned",![p.invocation.id].disposition="Resolved"]
/\ afterRuntime=[r EXCEPT !.ability.returned=TRUE,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, BarrierInstructionOwnerAtTop98, InstructionWindowRef93, LifetimeReady910, NestedBarrierInstructionInvocation98, ReturnAbility9, RuntimeOwnerCurrent911, SourceRuntimeBound911
ReturnPaidOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnPaidOccurrence912(beforeStack,afterStack,r,afterRuntime,afterProcedure,receipt,objects,transits,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceOccurrenceBound912(r) /\ r.metadata.sourceEntry.kind="Paid"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0}
/\ objects=authority.current.objects /\ SetAsideTrackingValid4(objects,transits)
/\ LET p == [r.metadata.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]
IN /\ PaidConvertedAsideIds95(p,objects,transits)={}
/\ PaidCleanupIds95(p,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(p,objects,transits,"ProcedureCode96bfa1b6a970")={}
/\ FinishPaidProcedure95(beforeStack,afterStack,p,afterProcedure,receipt)
/\ afterRuntime=[r EXCEPT !.ability=afterProcedure.ability,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, FinishPaidProcedure95, LifetimeReady910, OccurrenceOwnerCurrent912, PaidCleanupIds95, PaidConvertedAsideIds95, SourceOccurrenceBound912, SetAsideTrackingValid4
ReturnPaidRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnPaidRuntime911(beforeStack,afterStack,r,afterRuntime,afterProcedure,receipt,objects,transits,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceRuntimeBound911(r) /\ r.sourceEntry.kind="Paid"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0}
/\ objects=authority.current.objects /\ SetAsideTrackingValid4(objects,transits)
/\ LET p == [r.sourceEntry.after EXCEPT !.ability=r.ability,!.phase="Complete",!.checkpoint=r.checkpoint]
IN /\ PaidConvertedAsideIds95(p,objects,transits)={}
/\ PaidCleanupIds95(p,objects,transits,"ProcedureCode76ca53ad9dd0") \cup PaidCleanupIds95(p,objects,transits,"ProcedureCode96bfa1b6a970")={}
/\ FinishPaidProcedure95(beforeStack,afterStack,p,afterProcedure,receipt)
/\ afterRuntime=[r EXCEPT !.ability=afterProcedure.ability,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: p, FinishPaidProcedure95, LifetimeReady910, PaidCleanupIds95, PaidConvertedAsideIds95, RuntimeOwnerCurrent911, SourceRuntimeBound911, SetAsideTrackingValid4
ReturnPlayOccurrence912 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnPlayOccurrence912(r,afterRuntime,beforeCohort,afterCohort,f,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ OccurrenceOwnerCurrent912(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceOccurrenceBound912(r) /\ r.metadata.sourceEntry.kind="PlayFirst"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0} /\ ~r.ability.detached
/\ beforeCohort=r.metadata.sourceEntry.after /\ CurrentPlayDefinition97(beforeCohort)=r.technique.definition
/\ PlayOwnerAtTop97(beforeCohort,f,stack) /\ BarrierInstructionOwnerAtTop98(r.metadata.owner,stack)
/\ ReturnAbility9(r.ability,[r.ability EXCEPT !.returned=TRUE],TRUE,beforeCohort.playId)
/\ afterCohort=PlayAdvanceDisposition97([beforeCohort EXCEPT !.ability=r.ability],"Resolved",r.id)
/\ afterRuntime=[r EXCEPT !.ability.returned=TRUE,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOwnerAtTop98, CurrentPlayDefinition97, LifetimeReady910, OccurrenceOwnerCurrent912, PlayAdvanceDisposition97, PlayOwnerAtTop97, ReturnAbility9, SourceOccurrenceBound912
ReturnPlayRuntime911 · operator
reference-profile · input revision 2 · CC0 1.0
ReturnPlayRuntime911(r,afterRuntime,beforeCohort,afterCohort,f,stack,lifetimes,authority) ==
/\ LifetimeReady910(lifetimes,authority) /\ RuntimeOwnerCurrent911(r,authority)
/\ r.id \in authority.current.finishedInstances /\ SourceRuntimeBound911(r) /\ r.sourceEntry.kind="PlayFirst"
/\ r.phase="Complete" /\ r.pc=0 /\ r.checkpoint \in Nat \ {0} /\ ~r.ability.detached
/\ beforeCohort=r.sourceEntry.after /\ CurrentPlayDefinition97(beforeCohort)=r.technique.definition
/\ PlayOwnerAtTop97(beforeCohort,f,stack) /\ BarrierInstructionOwnerAtTop98(r.sourceOwner,stack)
/\ ReturnAbility9(r.ability,[r.ability EXCEPT !.returned=TRUE],TRUE,beforeCohort.playId)
/\ afterCohort=PlayAdvanceDisposition97([beforeCohort EXCEPT !.ability=r.ability],"Resolved",r.id)
/\ afterRuntime=[r EXCEPT !.ability.returned=TRUE,!.phase="Returned"]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: BarrierInstructionOwnerAtTop98, CurrentPlayDefinition97, LifetimeReady910, PlayAdvanceDisposition97, PlayOwnerAtTop97, ReturnAbility9, RuntimeOwnerCurrent911, SourceRuntimeBound911
RowsMatchApplication98 · operator
reference-profile · input revision 2 · CC0 1.0
RowsMatchApplication98(rows,application,grant,gainOrder,barrierCard) ==
LET ids == {id \in DOMAIN rows : rows[id].effect=application}
ordered == SelectSeq(gainOrder,LAMBDA id : id \in ids)
IN /\ \A id \in ids : rows[id].template \in 1..Len(grant.templates) /\ rows[id].parent=0 /\ rows[id].printedSlot=0 /\
rows[id].textKey=grant.templates[rows[id].template].key /\ rows[id].definition=ReidentifyBarrierInstruction98(grant.templates[rows[id].template].definition,id)
/\ IF SelfStaticGrant98(grant,barrierCard) THEN \A id \in ids : rows[id].template=1
ELSE /\ {rows[id].template : id \in ids}=1..Len(grant.templates) /\ Cardinality(ids)=Len(grant.templates)
/\ (grant.specified => [i \in 1..Len(ordered) |-> rows[ordered[i]].template]=[i \in 1..Len(grant.templates) |-> i])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ids, ordered, ReidentifyBarrierInstruction98, SelfStaticGrant98
RuleAbilitySource9 · operator
reference-profile · input revision 2 · CC0 1.0
RuleAbilitySource9(rule) == [kind |-> "Rule",object |-> 0,rule |-> rule]Exact module download · Source bundle and reproduction instructions
RuleInstructionPlan93 · operator
reference-profile · input revision 2 · CC0 1.0
RuleInstructionPlan93(plan,actualRuleStep) ==
/\ plan.origin="Rule" /\ plan.abilityInstance=0 /\ plan.index=0 /\ plan.source=RuleAbilitySource9(plan.ruleStep)
/\ plan.sourceZone="NoValue"
/\ plan.ruleStep # "NoValue" /\ plan.ruleStep=actualRuleStepExact module download · Source bundle and reproduction instructions
Resolved project definitions: RuleAbilitySource9
RuntimeCurrentPlan911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeCurrentPlan911(r,plan) ==
/\ r.pc \in DOMAIN r.technique.nodes
/\ plan.id=r.pc /\ plan.source=r.ability.source /\ plan.abilityInstance=r.id
/\ plan.index=Len(r.visited)+1 /\ plan.steps=r.technique.nodes[r.pc].steps
/\ plan.requiresTargets=r.technique.nodes[r.pc].requiresTargetsExact module download · Source bundle and reproduction instructions
RuntimeEntryIds911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeEntryIds911(entry) == IF entry.kind="SourceFirst" THEN {entry.id,entry.sourceEntry.id} ELSE {entry.id}Exact module download · Source bundle and reproduction instructions
RuntimeFinishFrame911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeFinishFrame911(r,next) ==
[r.ability EXCEPT !.instructions=IF next=0 THEN Append(r.visited,r.pc) ELSE Append(Append(r.visited,r.pc),next)]Exact module download · Source bundle and reproduction instructions
RuntimeFinishWorld911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeFinishWorld911(beforeWorld,afterWorld,r,ledger) ==
/\ r.id \in DOMAIN beforeWorld.activity.instances
/\ afterWorld=[beforeWorld EXCEPT !.id=afterWorld.id,
!.finishedInstances=@ \cup (IF r.pc=0 THEN {r.id} ELSE {}),
!.finishedDelayedEffects=@,
!.activity.instances[r.id]=ReplacementOverlay99(@,
[ability |-> r.technique.definition.syntax.id,sourceObject |-> IF r.ability.source.kind="Object" THEN r.ability.source.object ELSE 0,
status |-> IF r.pc=0 THEN "Complete" ELSE "Resolving",owner |-> RuntimeLookOwner911(r)])]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99, RuntimeLookOwner911
RuntimeFinishedDelayed911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeFinishedDelayed911(r,ledger) ==
LET effect == r.technique.definition.delayedEffect
IN IF r.pc=0 /\ effect \in DOMAIN ledger.effects /\ ledger.effects[effect].policy="UntilResolution"
THEN {effect} ELSE {}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: effect
RuntimeLookOwner911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeLookOwner911(r) == ReplacementOverlay99(r,[definition |-> r.technique.definition])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReplacementOverlay99
RuntimeNext911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeNext911(r,result) ==
IF r.technique.nodes[r.pc].kind \notin {"Choice","NestedCost"} THEN r.technique.nodes[r.pc].next
ELSE IF result.mode="Removed" THEN r.technique.nodes[r.pc].next ELSE r.technique.nodes[r.pc].options[result.option]Exact module download · Source bundle and reproduction instructions
RuntimeOwnerCurrent911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeOwnerCurrent911(r,authority) ==
/\ r.id \in DOMAIN authority.current.activity.instances
/\ "owner" \in DOMAIN authority.current.activity.instances[r.id]
/\ authority.current.activity.instances[r.id].owner.ability=r.ability
/\ authority.current.activity.instances[r.id].owner.technique=r.technique
/\ authority.current.activity.instances[r.id].owner.pc=r.pc
/\ authority.current.activity.instances[r.id].owner.visited=r.visited
/\ authority.current.activity.instances[r.id].owner.choices=r.choices
/\ IF "sourceEntry" \in DOMAIN r THEN
/\ authority.current.activity.instances[r.id].owner.sourceEntry=r.sourceEntry
/\ authority.current.activity.instances[r.id].owner.sourceOwner=r.sourceOwner
ELSE IF "windowId" \in DOMAIN r THEN
/\ authority.current.activity.instances[r.id].owner.windowId=r.windowId
/\ authority.current.activity.instances[r.id].owner.option=r.option
/\ authority.current.activity.instances[r.id].owner.transaction=r.transaction
/\ authority.current.activity.instances[r.id].owner.turnId=r.turnId
ELSE TRUEExact module download · Source bundle and reproduction instructions
RuntimeProfile911 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeProfile911(r) ==
/\ InstructionTechniqueValid911(r.technique) /\ r.id=r.ability.id /\ r.ability.source=r.technique.source
/\ r.ability.kind=r.technique.definition.syntax.kind
/\ DeckSequenceValid4(r.visited) /\ SubIds6(r.visited) \subseteq DOMAIN r.technique.nodes
/\ IF r.visited# <<>> THEN Head(r.visited)=r.technique.entry ELSE r.pc=r.technique.entry
/\ r.pc=0 \/ r.pc \in DOMAIN r.technique.nodes
/\ IF r.pc=0 THEN r.ability.instructions=r.visited
ELSE r.pc \notin SubIds6(r.visited) /\ r.ability.instructions=Append(r.visited,r.pc)
/\ r.phase \in {"Targets","Imminent","Resolve","Paused","Checkpoint","Complete","Returned"}
/\ IF r.pc=0 THEN r.ability.lastFinished /\ r.ability.complete
ELSE r.technique.nodes[r.pc].id=r.pcExact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionTechniqueValid911, DeckSequenceValid4, SubIds6
RuntimeSubIds98 · operator
reference-profile · input revision 2 · CC0 1.0
RuntimeSubIds98(state) == SubIds6(state.order)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SubIds6
ScopedLookGrant911 · operator
reference-profile · input revision 2 · CC0 1.0
ScopedLookGrant911(id,p,plan,objects,deck,execution) ==
[id |-> id,instance |-> p.id,definition |-> p.definition.syntax.id,source |-> p.ability.source,
instruction |-> InstructionWindowRef93(plan),player |-> execution.player,zone |-> execution.zone,
objects |-> SubIds6(SubSeq(deck,1,MinOf(execution.amount,Len(deck)))),
execution |-> execution]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionWindowRef93, MinOf, SubIds6
ScopedLookPermission911 · operator
reference-profile · input revision 2 · CC0 1.0
ScopedLookPermission911(grants,id,viewer,object,owners,objects) ==
IF id \notin DOMAIN grants THEN FALSE
ELSE LET grant == grants[id]
IN IF grant.instance \notin DOMAIN owners \/ object \notin DOMAIN objects THEN FALSE
ELSE LET owner == owners[grant.instance]
IN /\ owner.ability.id=grant.instance /\ owner.definition.syntax.id=grant.definition
/\ owner.ability.source=grant.source /\ AbilityIsResolving9(owner.ability)
/\ ~owner.ability.lastFinished /\ ~owner.ability.complete
/\ viewer=grant.player /\ object \in grant.objects /\ objects[object].zone=grant.zone
/\ DeckMayLook4(viewer,TRUE)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: grant, owner, AbilityIsResolving9, DeckMayLook4
SelectCurrentConditionalInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
SelectCurrentConditionalInterrupt99(beforeLedger,afterLedger,beforeStack,afterStack,p,afterP,selection,d,snapshot,id,option,legality,
plan,afterPlan,targets,entry,turnUses,restrictions,context,origin,world,history,cardFacts) ==
/\ BeginCurrentConditionalInterrupt99(beforeLedger,afterLedger,beforeStack,afterStack,p,afterP,d,snapshot,id,option,legality,
plan,afterPlan,targets,entry,turnUses,restrictions,context,origin,world,history,cardFacts)
/\ selection=SelectedInterrupt99(afterP,d,world.lexemes[AbilityKey99(d)],world.capabilities[AbilityKey99(d)],context,world)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityKey99, BeginCurrentConditionalInterrupt99, SelectedInterrupt99
SelectNextBarrierInstruction98 · operator
reference-profile · input revision 2 · CC0 1.0
SelectNextBarrierInstruction98(before,after,p,e,control,step,orderState,actualOrder,id,usedInstances,objects,present,context,points,stack) ==
/\ BarrierInstructionLoopMatches98(before,e) /\ before.current=0
/\ BarrierInstructionStep98(e,control,step) /\ BarrierInstructionOwnerAtTop98(before.owner,stack)
/\ BarrierInstructionOrderValid98(orderState) /\ orderState.barrierCard=e.barrierCard /\ orderState.order=e.order
/\ ResolutionOrderBound98(before,e,actualOrder) /\ Len(actualOrder.order)>0
/\ id \in (Nat \ {0}) \ (usedInstances \cup before.usedInstances)
/\ e.barrierCard \in DOMAIN objects
/\ LET sub == actualOrder.order[1]
d == orderState.definitions[sub]
IN /\ BarrierInstructionCurrentActive98(d,objects,present,context,points)
/\ p=NewBarrierInstructionBarrierInstruction98(id,sub,d,e,before.owner,objects[e.barrierCard].zone)
/\ after=[before EXCEPT !.current=id,!.usedInstances=@ \cup {id}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: d, sub, BarrierInstructionCurrentActive98, BarrierInstructionLoopMatches98, BarrierInstructionOrderValid98, BarrierInstructionOwnerAtTop98, BarrierInstructionStep98, NewBarrierInstructionBarrierInstruction98, ResolutionOrderBound98
SelectedInterrupt99 · operator
reference-profile · input revision 2 · CC0 1.0
SelectedInterrupt99(p,d,lex,capabilities,context,world) ==
[tag |-> "SelectedInterrupt",instance |-> p.id,definition |-> d,lexemes |-> lex,capabilities |-> capabilities,
source |-> p.ability.source,windowId |-> p.windowId,option |-> p.option,transactionId |-> p.transaction,
contextId |-> context.id,imminenceId |-> context.imminenceId,selectedReference |-> context.currentRef,snapshotId |-> world.id]Exact module download · Source bundle and reproduction instructions
SelectedInterruptAtTop99 · operator
reference-profile · input revision 2 · CC0 1.0
SelectedInterruptAtTop99(selection,p,context,stack,plan,world,cardFacts) ==
/\ selection.tag="SelectedInterrupt" /\ selection.contextId=context.id /\ selection.imminenceId=context.imminenceId
/\ WouldContextKey99(selection.selectedReference)=WouldContextKey99(context.initialRef)
/\ selection.instance=p.id /\ selection.definition=p.definition /\ selection.source=p.ability.source
/\ selection.windowId=p.windowId /\ selection.option=p.option /\ selection.transactionId=p.transaction
/\ AbilityLexemesValid99(p.definition,selection.lexemes,world.objects,cardFacts) /\ AbilityInterrupt99(p.definition,selection.lexemes)
/\ p.ability.kind \in {"Paid","Conditional"} /\ p.ability.kind=p.definition.syntax.kind
/\ p.phase="Resolve" /\ p.ability.phase="Resolving" /\ plan.phase="Resolving"
/\ InstructionPlanMatches93(plan,p.ability,p.ability.cursor)
/\ CurrentInterruptWindow99(context,stack)
/\ LET w == WindowTop9(stack)
IN /\ w.id=p.windowId /\ w.busy=p.option /\ w.busyTransaction=p.transaction /\ w.busy.id # 0
/\ w.stage \in {"Resolving","Closed"}
/\ (p.ability.kind="Conditional" => w.busy.instance=p.id)
/\ (p.ability.kind="Paid" => p.costPaid)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: w, AbilityInterrupt99, AbilityLexemesValid99, CurrentInterruptWindow99, InstructionPlanMatches93, WouldContextKey99
SelfCategoryIdentical98 · operator
reference-profile · input revision 2 · CC0 1.0
SelfCategoryIdentical98(state) ==
\A a,b \in state.present :
(SubOriginCategory98(state,a) \in {2,4} /\ SubOriginCategory98(state,a)=SubOriginCategory98(state,b)) =>
state.provenance[a].textKey=state.provenance[b].textKey /\ ReidentifyBarrierInstruction98(state.definitions[a],b)=state.definitions[b]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ReidentifyBarrierInstruction98, SubOriginCategory98
SelfStaticGrant98 · operator
reference-profile · input revision 2 · CC0 1.0
SelfStaticGrant98(grant,barrierCard) == grant.ability.syntax.kind="Static" /\ grant.ability.syntax.source=ObjectAbilitySource9(barrierCard)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ObjectAbilitySource9
SetExpectedEffectValue99 · operator
reference-profile · input revision 2 · CC0 1.0
SetExpectedEffectValue99(before,after,id,value) ==
/\ ExpectedEffectsValid99(before) /\ ExpectedValuePresent99(before,id) /\ value \in Int
/\ after=[before EXCEPT ![id].value=value]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedEffectsValid99, ExpectedValuePresent99
SetPrintedSubCount98 · operator
reference-profile · input revision 2 · CC0 1.0
SetPrintedSubCount98(before,after,actualCount,rows,spine,decision) ==
LET old == SelectSeq(before.order,LAMBDA id : before.provenance[id].kind="Printed")
count == actualCount.count
keep == SubSeq(old,1,IF count<Len(old) THEN count ELSE Len(old))
lost == SubIds6(old) \ SubIds6(keep)
gained == DOMAIN rows
present == (before.present \ lost) \cup gained
result == OrderChangedState98(before,rows,EmptyOrder98,present,spine,decision,"PrintedResize",lost,"Printed")
IN /\ BarrierInstructionOrderValid98(before) /\ NormalizedSubCount98(before,0,actualCount,"NormalizedPrintedSubCount")
/\ count<=Len(before.printedText)
/\ {before.provenance[id].printedSlot : id \in SubIds6(old)}=1..Len(old)
/\ FreshSubRows98(before,rows) /\ Cardinality(gained)=IF count>Len(old) THEN count-Len(old) ELSE 0
/\ {rows[id].printedSlot : id \in gained}=(IF count>Len(old) THEN (Len(old)+1)..count ELSE {})
/\ \A id \in gained : rows[id].effect=0 /\ rows[id].parent=0 /\
rows[id].definition=ReidentifyBarrierInstruction98(before.printedText[rows[id].printedSlot].definition,id) /\ rows[id].textKey=before.printedText[rows[id].printedSlot].key
/\ OrderingDecisionBound98(before,decision,"PrintedResize",gained,lost,spine,present)
/\ FreshOrderingConstraints98(result,gained)
/\ after=result /\ BarrierInstructionOrderValid98(after) /\ SelfCategoryIdentical98(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: count, gained, lost, old, present, result, BarrierInstructionOrderValid98, FreshOrderingConstraints98, FreshSubRows98, NormalizedSubCount98, OrderingDecisionBound98, ReidentifyBarrierInstruction98, SelfCategoryIdentical98, SubIds6
SimultaneousActionValue912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousActionValue912(s,value) ==
IF value.kind="Literal" THEN [known |-> TRUE,value |-> value.value]
ELSE [known |-> value.attribute \notin s.chars[value.object].unresolved,value |-> s.chars[value.object].values[value.attribute]]Exact module download · Source bundle and reproduction instructions
SimultaneousActions912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousActions912(s,e,targets) ==
CASE e.action.kind="CopyItemActivatedBarrierSubtypes" ->
{[id |-> e.id,target |-> target,kind |-> "Subtype",subtype |-> subtype,amount |-> 1] :
target \in targets,subtype \in UNION {s.chars[id].subtypes : id \in
{id \in DOMAIN s.chars : id#e.source.object /\ s.world.objects[id].kind="Barrier" /\ s.world.objects[id].activated}}}
[] e.action.kind="Subtype" ->
{[id |-> e.id,target |-> target,kind |-> "Subtype",subtype |-> e.action.subtype,amount |-> e.action.amount] : target \in targets}
[] e.action.kind="Numeric" ->
{[id |-> e.id,target |-> target,kind |-> "Numeric",attribute |-> e.action.attribute,operation |-> e.action.operation,
value |-> SimultaneousActionValue912(s,e.action.value).value,known |-> SimultaneousActionValue912(s,e.action.value).known] : target \in targets}
[] e.action.kind="GrantAbility" ->
{[id |-> e.id,target |-> target,kind |-> "GrantAbility",ability |-> e.action.ability,placement |-> e.action.placement] : target \in {target \in targets : ~s.chars[target].cannotGain}}
[] OTHER -> {[id |-> e.id,target |-> target,kind |-> e.action.kind] : target \in targets}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousActionValue912
SimultaneousAllActions912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousAllActions912(outputs) == UNION {outputs[id] : id \in DOMAIN outputs}Exact module download · Source bundle and reproduction instructions
SimultaneousBoundary912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousBoundary912(s) ==
IF s.waiting#{} /\ SimultaneousEligible912(s)={} THEN "ResidualCycleNormalizationRequired"
ELSE IF \E id \in DOMAIN s.chars : s.chars[id].unresolved#{}
THEN "SetterNormalizationRequired" ELSE "Supported"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousEligible912
SimultaneousDependencies912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousDependencies912(s) ==
LET raw == SimultaneousRawDependencies912(s)
IN IF SimultaneousIndependent912(s,raw)#{} THEN raw
ELSE {edge \in raw : ~SimultaneousHostedEdge912(s,edge)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: raw, SimultaneousHostedEdge912, SimultaneousIndependent912
SimultaneousEligible912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousEligible912(s) == SimultaneousIndependent912(s,SimultaneousDependencies912(s))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousDependencies912, SimultaneousIndependent912
SimultaneousEnabled912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousEnabled912(s,e) ==
CASE e.provider="Static" ->
StaticAbilityActive94(e.definition.activity,e.definition.syntax,s.world.objects,SimultaneousPresent912(s),
LingeringObjectActive910(e.source,s.world),s.world.activity,s.world.points)
[] e.provider="Lingering" ->
e.lifetimeId \in DOMAIN s.lifetimes.effects /\ s.lifetimes.effects[e.lifetimeId].status="Active"
[] OTHER -> TRUEExact module download · Source bundle and reproduction instructions
Resolved project definitions: LingeringObjectActive910, SimultaneousPresent912, StaticAbilityActive94
SimultaneousHostedEdge912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousHostedEdge912(s,edge) ==
LET child == s.effects[edge.dependent].source
host == s.effects[edge.prerequisite].source
IN /\ child.kind="Object" /\ host.kind="Object" /\ child.object \in DOMAIN s.world.objects
/\ s.world.objects[child.object].host=host.objectExact module download · Source bundle and reproduction instructions
SimultaneousIRValid912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousIRValid912(e,world,printed) ==
/\ e.query.kind \in {"Self","Host","ItemActivatedSubtype","HostedTechniques","Explicit"}
/\ e.action.kind \in {"CopyItemActivatedBarrierSubtypes","Subtype","Numeric","GrantAbility","LoseAllAbilities","LoseExceptPrintedBarrierInstructions"}
/\ e.query.kind="Explicit" => e.query.objects \subseteq DOMAIN printed
/\ e.action.kind="Numeric" =>
/\ e.action.operation \in {"Set","Increase","SchemaAtom100"}
/\ \A id \in SimultaneousPotentialTargets912(e,world) : e.action.attribute \in DOMAIN printed[id].values
/\ e.action.value.kind \in {"Literal","Attribute"}
/\ IF e.action.value.kind="Literal" THEN e.action.value.value \in Int
ELSE e.action.value.object \in DOMAIN printed /\ e.action.value.attribute \in DOMAIN printed[e.action.value.object].values
/\ e.action.kind="Subtype" => e.action.amount \in IntExact module download · Source bundle and reproduction instructions
Resolved project definitions: SimultaneousPotentialTargets912
SimultaneousIndependent912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousIndependent912(s,dependencies) ==
{id \in s.waiting : ~\E edge \in dependencies : edge.dependent=id}Exact module download · Source bundle and reproduction instructions
SimultaneousPotentialTargets912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousPotentialTargets912(e,world) ==
CASE e.query.kind="Explicit" -> e.query.objects
[] e.query.kind="Self" -> {e.source.object} \cap DOMAIN world.objects
[] e.query.kind="Host" -> IF e.source.object \in DOMAIN world.objects THEN {world.objects[e.source.object].host} \cap DOMAIN world.objects ELSE {}
[] e.query.kind="ItemActivatedSubtype" -> {id \in DOMAIN world.objects : world.objects[id].kind="Barrier" /\ world.objects[id].activated}
[] OTHER -> {id \in DOMAIN world.objects : world.objects[id].host=e.source.object /\ world.objects[id].kind="Technique"}Exact module download · Source bundle and reproduction instructions
SimultaneousPresent912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousPresent912(s) == UNION {s.chars[id].abilities : id \in DOMAIN s.chars}Exact module download · Source bundle and reproduction instructions
SimultaneousPreview912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousPreview912(s,id) ==
LET view == SimultaneousView912(s,id)
outputs == ReplacementOverlay99(s.outputs,[key \in {id} |-> view.actions])
IN [s EXCEPT !.outputs=outputs,!.chars=SimultaneousProject912(s,outputs,view.actions)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: outputs, view, SimultaneousProject912
SimultaneousProject912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousProject912(s,outputs,actions) ==
LET all == SimultaneousAllActions912(outputs)
IN [target \in DOMAIN s.chars |->
LET row == s.chars[target]
local == {a \in actions : a.target=target}
numeric == {a \in all : a.target=target /\ a.kind="Numeric"}
subtype == {a \in all : a.target=target /\ a.kind="Subtype"}
lossAll == \E a \in local : a.kind="LoseAllAbilities"
lossExcept == \E a \in local : a.kind="LoseExceptPrintedBarrierInstructions"
blocked == row.cannotGain \/ lossAll \/ lossExcept
abilities == IF lossAll THEN {} ELSE IF lossExcept THEN row.abilities \cap s.printed[target].printedBarrierInstructions ELSE row.abilities
IN [subtypes |-> {subtypeName \in s.printed[target].subtypes \cup {a.subtype : a \in subtype} : SubtypePresent912(s.printed[target].subtypes,subtype,subtypeName)},
values |-> [key \in DOMAIN s.printed[target].values |-> NumericFinal912(s.printed[target].values[key],{m \in numeric : m.attribute=key}).value],
unresolved |-> {key \in DOMAIN s.printed[target].values : NumericFinal912(s.printed[target].values[key],{m \in numeric : m.attribute=key}).status#"Supported"},
cannotGain |-> blocked,abilities |-> abilities \cup
(IF blocked THEN {} ELSE {a.ability : a \in {a \in local : a.kind="GrantAbility"}})]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: abilities, blocked, local, numeric, subtype, NumericFinal912, SubtypePresent912
SimultaneousRawDependencies912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousRawDependencies912(s) ==
LET pairs == {[dependent |-> b,prerequisite |-> a] : b \in s.waiting,a \in s.waiting}
IN {edge \in pairs : edge.dependent#edge.prerequisite /\
SimultaneousView912(s,edge.dependent)#SimultaneousView912(SimultaneousPreview912(s,edge.prerequisite),edge.dependent)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: pairs, SimultaneousPreview912, SimultaneousView912
SimultaneousSourceBound912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousSourceBound912(e,world,cardFacts) ==
/\ e.id \in Nat \ {0} /\ e.provider \in {"Static","Lingering","Rule"}
/\ e.source=e.definition.syntax.source /\ e.definition.activity.source=e.source
/\ e.definition.activity.id=e.definition.syntax.id
/\ AbilityLexemesValid99(e.definition,e.lexemes,world.objects,cardFacts)
/\ e.card=e.lexemes.card /\ e.sourceSHA=e.lexemes.sourceSHA
/\ IF e.source.kind="Rule" THEN
/\ e.provider \in {"Rule","Lingering"} /\ e.card="NoValue"
/\ e.sourceSHA="0186148ecd6da8170b6555aa90d3f0115a8d5150d807078b75ac2339a2a1421e"
ELSE /\ e.card \in DOMAIN cardFacts /\ e.sourceSHA=cardFacts[e.card].sourceSHA
/\ IF e.source.object \in DOMAIN world.objects THEN (e.definition.activity.provider="Printed" => world.objects[e.source.object].card=e.card) ELSE e.provider="Lingering"
/\ e.provider="Static" => e.definition.syntax.kind="Static" /\ e.definition.activity.kind="Static"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityLexemesValid99
SimultaneousTargets912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousTargets912(s,e) ==
CASE e.query.kind="Self" -> IF e.source.object \in DOMAIN s.chars THEN {e.source.object} ELSE {}
[] e.query.kind="Host" ->
IF e.source.object \in DOMAIN s.world.objects /\ s.world.objects[e.source.object].host \in DOMAIN s.chars
THEN {s.world.objects[e.source.object].host} ELSE {}
[] e.query.kind="ItemActivatedSubtype" ->
{id \in DOMAIN s.chars : s.world.objects[id].kind="Barrier" /\ s.world.objects[id].activated /\ e.query.subtype \in s.chars[id].subtypes}
[] e.query.kind="HostedTechniques" ->
{id \in DOMAIN s.chars : s.world.objects[id].host=e.source.object /\ s.world.objects[id].kind="Technique"}
[] OTHER -> e.query.objects \cap DOMAIN s.charsExact module download · Source bundle and reproduction instructions
SimultaneousView912 · operator
reference-profile · input revision 2 · CC0 1.0
SimultaneousView912(s,id) ==
LET e == s.effects[id]
enabled == SimultaneousEnabled912(s,e)
targets == IF enabled THEN SimultaneousTargets912(s,e) ELSE {}
IN [enabled |-> enabled,targets |-> targets,actions |-> IF enabled THEN SimultaneousActions912(s,e,targets) ELSE {}]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: e, enabled, targets, SimultaneousActions912
SkipInactivePlay97 · operator
reference-profile · input revision 2 · CC0 1.0
SkipInactivePlay97(before,after,f,stack,objects,present,activity,points) ==
/\ PlayOwnerAtTop97(before,f,stack) /\ before.phase="Ready" /\ before.cursor<=Len(before.order)
/\ PlayPresenceValid97(before,objects,present)
/\ ~PlayCurrentActive97(before,f,objects,present,activity,points)
/\ after=PlayAdvanceDisposition97(before,"SkippedInactive",0)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: PlayAdvanceDisposition97, PlayCurrentActive97, PlayOwnerAtTop97, PlayPresenceValid97
SnapshotWithConditionalRegistry96 · operator
reference-profile · input revision 2 · CC0 1.0
SnapshotWithConditionalRegistry96(snapshot,ledger) ==
[snapshot EXCEPT !.holds=ledger.holds,!.effects=ledger.effects,!.activity.instances=ConditionalActivityRows96(ledger.instances)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityRows96
SourceEntryDefinition911 · operator
reference-profile · input revision 2 · CC0 1.0
SourceEntryDefinition911(entry) ==
CASE entry.kind="Paid" -> entry.after.definition
[] entry.kind="PlayFirst" -> CurrentPlayDefinition97(entry.after)
[] OTHER -> entry.after.payloadExact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentPlayDefinition97
SourceEntryOwner911 · operator
reference-profile · input revision 2 · CC0 1.0
SourceEntryOwner911(entry) ==
IF entry.kind="Paid" THEN [windowId |-> entry.after.windowId,option |-> entry.after.option,transaction |-> entry.after.transaction]
ELSE entry.after.ownerExact module download · Source bundle and reproduction instructions
SourceOccurrenceBound912 · operator
reference-profile · input revision 2 · CC0 1.0
SourceOccurrenceBound912(r) ==
/\ OccurrenceRuntimeProfile912(r) /\ r.metadata.kind#"Conditional"
/\ r.metadata.sourceEntry.kind \in {"Paid","PlayFirst","BarrierInstructionFirst","NestedBarrierInstructionFirst"}
/\ r.technique.definition=SourceEntryDefinition911(r.metadata.sourceEntry)
/\ r.id=r.metadata.sourceEntry.after.id /\ r.ability.source=r.metadata.sourceEntry.after.ability.source
/\ r.ability.kind=r.metadata.sourceEntry.after.ability.kind /\ r.ability.caller=r.metadata.sourceEntry.after.ability.caller
/\ r.ability.sourceZone=r.metadata.sourceEntry.after.ability.sourceZone
/\ r.metadata.owner=SourceEntryOwner911(r.metadata.sourceEntry)
/\ r.ability.detached=r.metadata.sourceEntry.after.ability.detachedExact module download · Source bundle and reproduction instructions
Resolved project definitions: OccurrenceRuntimeProfile912, SourceEntryDefinition911, SourceEntryOwner911
SourceRuntimeBound911 · operator
reference-profile · input revision 2 · CC0 1.0
SourceRuntimeBound911(r) ==
/\ RuntimeProfile911(r) /\ r.sourceEntry.kind \in {"Paid","PlayFirst","BarrierInstructionFirst","NestedBarrierInstructionFirst"}
/\ r.technique.definition=SourceEntryDefinition911(r.sourceEntry)
/\ r.id=r.sourceEntry.after.id /\ r.ability.source=r.sourceEntry.after.ability.source
/\ r.ability.kind=r.sourceEntry.after.ability.kind /\ r.ability.caller=r.sourceEntry.after.ability.caller
/\ r.ability.sourceZone=r.sourceEntry.after.ability.sourceZone /\ r.sourceOwner=SourceEntryOwner911(r.sourceEntry)
/\ r.ability.detached=r.sourceEntry.after.ability.detachedExact module download · Source bundle and reproduction instructions
Resolved project definitions: RuntimeProfile911, SourceEntryDefinition911, SourceEntryOwner911
Specimen0090ResourceUnits95 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0090ResourceUnits95(effectiveClusterCount) == 2*effectiveClusterCountExact module download · Source bundle and reproduction instructions
Specimen0094FullySuppressInstructionMatch912 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0094FullySuppressInstructionMatch912(effect,before,after,event,occurrenceSubtypes,earlierMatchingEvents,cardFacts) ==
/\ effect.card="Specimen0094" /\ effect.sourceSHA=cardFacts["Specimen0094"].sourceSHA
/\ effect.traversalId=after.traversalId /\ earlierMatchingEvents={}
/\ event \in NewFullySuppressInstructionEvents6(before,after) /\ event.traversalId=effect.traversalId /\ event.barrierCard=after.barrierCard
/\ "Sentry" \in occurrenceSubtypes /\ EncounterAllSubsSatisfied912(after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterAllSubsSatisfied912, NewFullySuppressInstructionEvents6
Specimen0100CurrentPaidDuration94 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0100CurrentPaidDuration94(definition,syntax,objects,present,actualDefaultActive,context,points,effect,turnId,actualShorterThanTurn) ==
IF ~StaticAbilityActive94(definition,syntax,objects,present,actualDefaultActive,context,points) THEN effect
ELSE IF definition.source.kind # "Object" THEN effect
ELSE LET source == definition.source.object
IN IF source \notin DOMAIN objects THEN effect
ELSE IF objects[source].host=0 THEN effect
ELSE Specimen0100PaidStrengthDuration94(effect,objects[source].host,turnId,actualShorterThanTurn)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: source, Specimen0100PaidStrengthDuration94, StaticAbilityActive94
Specimen0100DurationComparison99 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0100DurationComparison99(original,current,comparison) ==
/\ comparison.tag="CurrentBoostDurationComparison" /\ comparison.original=original
/\ comparison.snapshotId=current.id /\ comparison.turn=TimingRef9("Turn",current.turnId)
/\ comparison.shorterThanTurn \in BOOLEANExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
Specimen0100PaidStrengthDuration94 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0100PaidStrengthDuration94(effect,host,turnId,actualShorterThanTurn) ==
IF effect.mode="Continuous" THEN effect
ELSE IF effect.originKind="Paid" /\ effect.property="Strength" /\ effect.boost.target=host /\
effect.boost.amount>0 /\ turnId \in Nat \ {0} /\ actualShorterThanTurn
THEN [effect EXCEPT !.boost.hasExplicit=TRUE,!.boost.explicit=TimingRef9("Turn",turnId)]
ELSE effectExact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRef9
Specimen0100Record99 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0100Record99(replacement,current,cardFacts) ==
/\ replacement.kind="Specimen0100Duration" /\ replacement.definition.source.kind="Object"
/\ replacement.definition.source=replacement.syntax.source /\ replacement.syntax.kind="Static"
/\ replacement.sourceSHA=cardFacts["Specimen0100"].sourceSHA
/\ IF replacement.definition.source.object \in DOMAIN current.objects
THEN current.objects[replacement.definition.source.object].card="Specimen0100" ELSE TRUEExact module download · Source bundle and reproduction instructions
Specimen0189Values94 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0189Values94(objects,source) ==
[id \in {10,11} |-> IF id=10 THEN 2+HostedPowerCount94(objects,source) ELSE 1+HostedPowerCount94(objects,source)]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: HostedPowerCount94
Specimen0202DrawQuantity912 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0202DrawQuantity912(g,reference,world,cardFacts,emissions) ==
/\ g.card="Specimen0202" /\ g.mode="Count" /\ g.count=world.actionPoints["SideB"]
/\ g.partOrder= <<1>> /\ g.parts[1].operation="Draw" /\ ~g.parts[1].basePresent /\ g.parts[1].unit=1
/\ NormalizeQuantityGroup912(g,reference,world,cardFacts,emissions)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NormalizeQuantityGroup912
Specimen0203AdditionalMoveConstraint94 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0203AdditionalMoveConstraint94(objects,Specimen0203,target,actualBarrierPositions) ==
IF ~Specimen0203HostedOnBarrier94(objects,Specimen0203) THEN TRUE
ELSE LET host == objects[Specimen0203].host
IN /\ {host,target} \subseteq DOMAIN actualBarrierPositions
/\ actualBarrierPositions[host].targetSite=actualBarrierPositions[target].targetSite \/
actualBarrierPositions[host].position=actualBarrierPositions[target].positionExact module download · Source bundle and reproduction instructions
Resolved project definitions: host, Specimen0203HostedOnBarrier94
Specimen0203HostedOnBarrier94 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0203HostedOnBarrier94(objects,Specimen0203) ==
IF Specimen0203 \notin DOMAIN objects THEN FALSE
ELSE LET host == objects[Specimen0203].host
IN IF host \notin DOMAIN objects THEN FALSE ELSE objects[host].form="Card" /\ objects[host].kind="Barrier"Exact module download · Source bundle and reproduction instructions
Resolved project definitions: host
Specimen0219RetireSet912 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0219RetireSet912(world,afterObjects,effect,directive,context,successors,usedObjects,receipt,cardFacts) ==
/\ effect.tag="ResolvedSpecimen0219Replacement" /\ effect.card="NeutralValue00015" /\ TraversalTimingPresent6(world.traversal)
/\ effect.sourceSHA=cardFacts["NeutralValue00015"].sourceSHA /\ effect.source.kind="Object"
/\ effect.origin.source=effect.source /\ effect.origin.card=effect.card /\ effect.origin.sourceSHA=effect.sourceSHA
/\ effect.origin.tag="FixedAbilitySourceObservation" /\ effect.traversalId=world.traversal.id
/\ world.targetSiteKinds[world.traversal.attacked]="SchemaAtom132" /\ world.traversal.successful
/\ world.traversal.phase="Success" /\ world.traversal.step="ProcedureCoded75d879e00ff" /\ ~world.traversal.ending
/\ TraversalInspectionModifierApplies6(effect,world.traversal,directive)
/\ directive.kind="Replacement" /\ directive.choice="Specimen0219" /\ directive.targetSite=world.traversal.attacked
/\ context.phase="Resolving" /\ context.currentWorld=world.id
/\ context.currentRef.origin="Rule" /\ context.currentRef.source=RuleAbilitySource9("ProcedureCoded75d879e00ff")
/\ context.currentRef.abilityInstance=0 /\ context.currentRef.index=0
/\ LET selected == Specimen0219RootCards912(world)
IN /\ \A id \in DOMAIN world.objects : world.objects[id].host \notin selected
/\ receipt=[tag |-> "CompletedSimultaneousRetireSet",id |-> effect.id,contextId |-> context.id,
instruction |-> context.currentRef,snapshotId |-> world.id,source |-> effect.source,
actor |-> "SideB",members |-> selected,purpose |-> "Specimen0219Root",targetSite |-> world.traversal.attacked,
beforeObjects |-> world.objects,afterObjects |-> afterObjects]
/\ CardBatchTransfer8(world.objects,afterObjects,selected,successors,usedObjects,"SideADiscard","Up",[id \in selected |-> "Discard"])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: selected, RuleAbilitySource9, CardBatchTransfer8, TraversalInspectionModifierApplies6, TraversalTimingPresent6
Specimen0219RootCards912 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0219RootCards912(world) ==
{id \in DOMAIN world.objects : world.objects[id].form="Card" /\ world.objects[id].side="SideA" /\
world.objects[id].zone="Play" /\ world.objects[id].deployed /\ world.objects[id].area="Root" /\
world.objects[id].targetSite=world.traversal.attacked /\ world.objects[id].host=0}Exact module download · Source bundle and reproduction instructions
Specimen0232ProtectingBarrier912 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0232ProtectingBarrier912(source,objects) ==
IF source.kind#"Object" \/ source.object \notin DOMAIN objects THEN {}
ELSE {id \in DOMAIN objects : objects[id].form="Card" /\ objects[id].kind="Barrier" /\ objects[id].zone="Play" /\ objects[id].deployed /\
objects[id].area="Protecting" /\ objects[id].targetSite=objects[source.object].targetSite}Exact module download · Source bundle and reproduction instructions
Specimen0232XEvaluation912 · operator
reference-profile · input revision 2 · CC0 1.0
Specimen0232XEvaluation912(d,world) ==
[tag |-> "CurrentVariableEvaluation",ability |-> d.syntax.id,source |-> d.syntax.source,snapshotId |-> world.id,
available |-> TRUE,value |-> 2*Cardinality(Specimen0232ProtectingBarrier912(d.syntax.source,world.objects))]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: Specimen0232ProtectingBarrier912
StartPriorityOptionFrame9 · operator
reference-profile · input revision 2 · CC0 1.0
StartPriorityOptionFrame9(w,option,transactionId) ==
[w EXCEPT !.stage = "Resolving",!.priority = "NoValue",!.busy = option,!.busyTransaction = transactionId,
!.pending = IF option.kind \in {"Conditional","ConditionalInterrupt"} THEN @ \ {option.instance} ELSE @,
!.triggered = IF option.kind \in {"Conditional","ConditionalInterrupt"} THEN @ \cup {option.instance} ELSE @]Exact module download · Source bundle and reproduction instructions
StatedDurationReceipt910 · operator
reference-profile · input revision 2 · CC0 1.0
StatedDurationReceipt910(effect,world) ==
[tag |-> "LingeringStatedDuration",effectId |-> effect.id,source |-> effect.source,
creation |-> effect.creation,specification |-> effect.baseDuration.specification,snapshotId |-> world.id]Exact module download · Source bundle and reproduction instructions
StaticAbilityActive94 · operator
reference-profile · input revision 2 · CC0 1.0
StaticAbilityActive94(definition,syntax,objects,present,actualDefaultActive,context,points) ==
/\ definition.kind="Static" /\ syntax.kind="Static" /\ definition.id=syntax.id /\ definition.source=syntax.source
/\ AbilityTextValid93(syntax)
/\ FlagActivity93(syntax,present,AbilityActive9(definition,objects,present,actualDefaultActive,context),context.persistentAbilities,points)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityActive9, AbilityTextValid93, FlagActivity93
StaticConditionIds94 · operator
reference-profile · input revision 2 · CC0 1.0
StaticConditionIds94(a) ==
{a.units[i].id : i \in {j \in 1..Len(a.units) : a.units[j].category="SchemaAtom043" /\ a.units[j].subtype="Static"}}Exact module download · Source bundle and reproduction instructions
StaticConditionSnapshot94 · operator
reference-profile · input revision 2 · CC0 1.0
StaticConditionSnapshot94(a,actualConditions) ==
/\ actualConditions.tag="StaticConditionSnapshot" /\ actualConditions.ability=a.id /\ actualConditions.source=a.source
/\ DOMAIN actualConditions.receipts=StaticConditionIds94(a)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: StaticConditionIds94
StaticPartApplies94 · operator
reference-profile · input revision 2 · CC0 1.0
StaticPartApplies94(a,part,active,actualConditions) ==
/\ a.kind="Static" /\ part.id \in TextUnitIds93(a.units,"Declaration") \cup TextUnitIds93(a.units,"Restriction")
/\ part.ability=a.id /\ active
/\ StaticConditionSnapshot94(a,actualConditions) /\ part.conditions \subseteq StaticConditionIds94(a)
/\ \A id \in part.conditions :
LET unit == a.units[CHOOSE i \in 1..Len(a.units) : a.units[i].id=id]
IN ConditionReceiptMatches93(unit,a.id,actualConditions.receipts[id])Exact module download · Source bundle and reproduction instructions
Resolved project definitions: unit, ConditionReceiptMatches93, StaticConditionIds94, StaticConditionSnapshot94, TextUnitIds93
StaticPrimaryTruth96 · operator
reference-profile · input revision 2 · CC0 1.0
StaticPrimaryTruth96(d,cp,actualCondition) ==
/\ actualCondition.tag="ConditionalStaticTruth" /\ actualCondition.ability=d.syntax.id /\ actualCondition.source=d.syntax.source
/\ actualCondition.checkpointId=cp.id /\ actualCondition.snapshotId=cp.beginSnapshot.id
/\ actualCondition.condition=d.primaryCondition /\ actualCondition.holdsExact module download · Source bundle and reproduction instructions
StaticProjection94 · operator
reference-profile · input revision 2 · CC0 1.0
StaticProjection94(a,part,currentValue) ==
[ability |-> a.id,source |-> a.source,part |-> part.id,target |-> part.target,property |-> part.property,
mode |-> "Continuous",value |-> currentValue,duration |-> NoTimingRef9,window |-> NoTimingRef9,resolving |-> FALSE,lingering |-> FALSE]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: NoTimingRef9
StaticRetryAllowed96 · operator
reference-profile · input revision 2 · CC0 1.0
StaticRetryAllowed96(d,ledger) ==
ConditionalKey96(d) \notin DOMAIN ledger.throttle \/ ledger.throttle[ConditionalKey96(d)] < ledger.stepSerialExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalKey96
SubOriginCategory98 · operator
reference-profile · input revision 2 · CC0 1.0
SubOriginCategory98(state,id) ==
CASE state.provenance[id].kind="Printed" -> 3 [] state.provenance[id].kind="Copy" -> 0
[] OTHER -> GrantCategory98(state.applications[state.provenance[id].effect].definition,state.barrierCard)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: GrantCategory98
SubRowsFromEffect98 · operator
reference-profile · input revision 2 · CC0 1.0
SubRowsFromEffect98(state,application) == SelectSeq(state.order,LAMBDA id : state.provenance[id].kind="Grant" /\ state.provenance[id].effect=application)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
SubtypePresent912 · operator
reference-profile · input revision 2 · CC0 1.0
SubtypePresent912(printed,contributions,subtype) ==
(IF subtype \in printed THEN 1 ELSE 0)
+SumSimultaneous912({[id |-> c.id,amount |-> c.amount] : c \in {c \in contributions : c.subtype=subtype}})>0Exact module download · Source bundle and reproduction instructions
Resolved project definitions: SumSimultaneous912
SumSimultaneous912 · operator
reference-profile · input revision 2 · CC0 1.0
SumSimultaneous912(rows) ==
IF rows={} THEN 0 ELSE LET r == CHOOSE r \in rows : TRUE
IN r.amount+SumSimultaneous912(rows \ {r})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: r, SumSimultaneous912
SuppressInstructionEncounterCurrent98 · operator
reference-profile · input revision 2 · CC0 1.0
SuppressInstructionEncounterCurrent98(e,control) == EncounterTimingLive95(e,control) /\ control.encounter=e.idExact module download · Source bundle and reproduction instructions
Resolved project definitions: EncounterTimingLive95
SuppressInstructionEncounterEnded98 · operator
reference-profile · input revision 2 · CC0 1.0
SuppressInstructionEncounterEnded98(e,control) ==
e.stage="Complete" \/ e.aborted \/ e.id \in control.phaseEndedIds \/
(e.traversalId # 0 /\ (e.traversalId # control.traversal.id \/ ~TraversalTimingPresent6(control.traversal)))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TraversalTimingPresent6
SuppressInstructionIntentMatches98 · operator
reference-profile · input revision 2 · CC0 1.0
SuppressInstructionIntentMatches98(intent,p) ==
/\ intent.tag="SuppressInstructionActivation" /\ intent.definition=p.definition /\ intent.abilityInstance=p.id /\ intent.ability=p.definition.syntax.id
/\ intent.source=p.ability.source /\ intent.source=p.definition.syntax.source /\ intent.source.kind="Object"
/\ intent.windowId=p.windowId /\ intent.transactionId=p.transaction
/\ intent.classification.ability=intent.ability /\ intent.classification.source=intent.sourceExact module download · Source bundle and reproduction instructions
SuppressInstructionOrdinaryCandidates98 · operator
reference-profile · input revision 2 · CC0 1.0
SuppressInstructionOrdinaryCandidates98(e,classification) ==
CurrentUnsuppressedBarrierInstructions98(e) \cap (IF classification.selector="Last" THEN IF Len(e.order)=0 THEN {} ELSE {e.order[Len(e.order)]} ELSE SubIds6(e.order))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentUnsuppressedBarrierInstructions98, SubIds6
SuppressInstructionSelectionMatches98 · operator
reference-profile · input revision 2 · CC0 1.0
SuppressInstructionSelectionMatches98(intent,selection,plan) ==
/\ selection.tag="SuppressInstructionTargets" /\ selection.NeutralValue00003=intent
/\ InstructionProfileMatches93(selection.instruction,plan)
/\ selection.instruction.revision<=plan.revision /\ selection.targets=plan.targetsExact module download · Source bundle and reproduction instructions
Resolved project definitions: InstructionProfileMatches93
SuppressInstructionTargetsValid98 · operator
reference-profile · input revision 2 · CC0 1.0
SuppressInstructionTargetsValid98(intent,e,control,targets) ==
/\ EncounterSuppressInstructionRef98(e)=intent.encounter
/\ IF SuppressInstructionEncounterEnded98(e,control) THEN targets={}
ELSE /\ SuppressInstructionEncounterCurrent98(e,control)
/\ CASE intent.classification.mode="All" -> targets={}
[] intent.classification.mode="Hook" -> targets \subseteq SubIds6(e.order) /\ Cardinality(targets)=IF Len(e.order)=0 THEN 0 ELSE 1
[] OTHER -> LET available == SuppressInstructionOrdinaryCandidates98(e,intent.classification)
minimum == IF Cardinality(available)<intent.classification.minimumTargets THEN Cardinality(available) ELSE intent.classification.minimumTargets
IN targets \subseteq available /\ Cardinality(targets)>=minimum /\ Cardinality(targets)<=intent.classification.maximumTargetsExact module download · Source bundle and reproduction instructions
Resolved project definitions: available, minimum, EncounterSuppressInstructionRef98, SuppressInstructionEncounterCurrent98, SuppressInstructionEncounterEnded98, SubIds6
SyncConditionalActivity96 · operator
reference-profile · input revision 2 · CC0 1.0
SyncConditionalActivity96(before,after,beforeStack,afterStack,definitions,snapshot) ==
/\ ConditionalSnapshotBound96(snapshot,before) /\ definitions=snapshot.definitions
/\ after=ConditionalActivityLedger96(before,definitions,snapshot)
/\ SyncConditionalWindows96(beforeStack,afterStack,before,after)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActivityLedger96, ConditionalSnapshotBound96, SyncConditionalWindows96
SyncConditionalWindows96 · operator
reference-profile · input revision 2 · CC0 1.0
SyncConditionalWindows96(before,after,beforeLedger,afterLedger) ==
after=[i \in 1..Len(before) |->
LET lost == {id \in before[i].pending \cap DOMAIN beforeLedger.instances : afterLedger.instances[id].status # "Pending"}
IN [before[i] EXCEPT !.pending=@ \ lost,!.lostPending=@ \cup lost]]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: lost
TechniqueEdges911 · operator
reference-profile · input revision 2 · CC0 1.0
TechniqueEdges911(node) ==
(IF node.next=0 THEN {} ELSE {node.next}) \cup {node.options[option] : option \in {option \in DOMAIN node.options : node.options[option]#0}}Exact module download · Source bundle and reproduction instructions
TextClasses93 · operator
reference-profile · input revision 2 · CC0 1.0
TextClasses93 == {"SchemaAtom043","Restriction","Instruction","Declaration","AbilityFlag"}Exact module download · Source bundle and reproduction instructions
TextUnit93 · operator
reference-profile · input revision 2 · CC0 1.0
TextUnit93(id,category,subtype,primary,value) ==
[id |-> id,category |-> category,subtype |-> subtype,primary |-> primary,value |-> value]Exact module download · Source bundle and reproduction instructions
TextUnitIds93 · operator
reference-profile · input revision 2 · CC0 1.0
TextUnitIds93(units,category) == {units[i].id : i \in {j \in 1..Len(units) : units[j].category=category}}Exact module download · Source bundle and reproduction instructions
TextUnitsValid93 · operator
reference-profile · input revision 2 · CC0 1.0
TextUnitsValid93(units) ==
/\ Cardinality({units[i].id : i \in 1..Len(units)})=Len(units)
/\ \A i \in 1..Len(units) :
/\ units[i].id \in Nat \ {0} /\ units[i].category \in TextClasses93 /\ units[i].primary \in BOOLEAN
/\ CASE units[i].category="SchemaAtom043" -> units[i].subtype \in ConditionKinds93
[] units[i].category="Restriction" -> units[i].subtype \in RestrictionKinds93
[] units[i].category="AbilityFlag" -> units[i].subtype \in AbilityFlagKinds93
[] OTHER -> units[i].subtype="NoValue"
/\ TextUnitIds93(units,"Instruction")={} \/ TextUnitIds93(units,"Declaration")={}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: AbilityFlagKinds93, ConditionKinds93, RestrictionKinds93, TextClasses93, TextUnitIds93
ThreatFlagGate93 · operator
reference-profile · input revision 2 · CC0 1.0
ThreatFlagGate93(units,points) ==
\A i \in {j \in 1..Len(units) : units[j].category="AbilityFlag" /\ units[j].subtype="Threat"} :
MaxOf(points["SideA"],points["SideB"]) >= units[i].valueExact module download · Source bundle and reproduction instructions
Resolved project definitions: MaxOf
TimingRef9 · operator
reference-profile · input revision 2 · CC0 1.0
TimingRef9(kind,id) == [kind |-> kind,id |-> id]Exact module download · Source bundle and reproduction instructions
TimingRefValid9 · operator
reference-profile · input revision 2 · CC0 1.0
TimingRefValid9(ref) == ref.kind \in TimingStructureKinds9 /\ ref.id \in Nat \ {0}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingStructureKinds9
TimingStepInvocation911 · operator
reference-profile · input revision 2 · CC0 1.0
TimingStepInvocation911(entry,world) ==
/\ entry.kind="Rule" /\ entry.ruleInvocation \in DOMAIN world.ruleInvocations
/\ LET invocation == world.ruleInvocations[entry.ruleInvocation]
IN /\ invocation.tag="ActualRuleInvocation" /\ ~invocation.returned
/\ TimingRefValid9(invocation.structure) /\ invocation.structure.kind \in TimingStructureKinds9
/\ invocation.step=entry.ruleStep /\ entry.sourceProcedure=invocation.structureExact module download · Source bundle and reproduction instructions
Resolved project definitions: invocation, TimingRefValid9, TimingStructureKinds9
TimingStructureKinds9 · operator
reference-profile · input revision 2 · CC0 1.0
TimingStructureKinds9 == {"Turn","TurnPhase","SchemaAtom138","TraversalPhase","Inspection","ItemInspection"}Exact module download · Source bundle and reproduction instructions
TraversalEndCleanupClass9 · operator
reference-profile · input revision 2 · CC0 1.0
TraversalEndCleanupClass9(w) ==
IF w.kind="Paid" THEN "Close"
ELSE IF w.kind="Reaction" /\ w.beginning.kind="TraversalPhase" THEN "CloseBegin"
ELSE "CompleteNormally"Exact module download · Source bundle and reproduction instructions
TraversalEndCleanupFrame9 · operator
reference-profile · input revision 2 · CC0 1.0
TraversalEndCleanupFrame9(w) ==
LET marked == [w EXCEPT !.site.traversalEnding=TRUE]
IN IF TraversalEndCleanupClass9(w) \in {"Close","CloseBegin"} THEN ClosePriorityWindow9(marked) ELSE markedExact module download · Source bundle and reproduction instructions
Resolved project definitions: marked, ClosePriorityWindow9, TraversalEndCleanupClass9
TraversalEndCleanupReceiptMatches9 · operator
reference-profile · input revision 2 · CC0 1.0
TraversalEndCleanupReceiptMatches9(stack,cleanupId,actualCleanup) ==
/\ cleanupId \in Nat \ {0} /\ actualCleanup.tag="TraversalEndWindowCleanup" /\ actualCleanup.id=cleanupId
/\ actualCleanup.traversalId \in Nat /\ actualCleanup.encounterId \in Nat
/\ actualCleanup.traversalId # 0 \/ actualCleanup.encounterId # 0
/\ actualCleanup.endInstructionId \in Nat \ {0}
/\ actualCleanup.windowIds \subseteq {stack[i].id : i \in 1..Len(stack)}
/\ DOMAIN actualCleanup.windows = actualCleanup.windowIds
/\ \A i \in 1..Len(stack) : stack[i].id \in actualCleanup.windowIds =>
actualCleanup.windows[stack[i].id]=stack[i] /\ stack[i].openExact module download · Source bundle and reproduction instructions
TraversalPrioritySite9 · operator
reference-profile · input revision 2 · CC0 1.0
TraversalPrioritySite9(turn,r,approach,layout,actualProcedure) ==
PrioritySite9("SchemaAtom138",r.step,r.phase,TimingRef9("TraversalPhase",r.phaseId),ActivePlayer9(turn),turn.id,r.id,0,0,
IF r.phase = "Approach" /\ approach.id = r.phaseId /\ approach.traversalId = r.id /\ approach.begun
THEN ApproachedBarrier6(approach,layout) ELSE 0,FALSE,
TurnFrameValid5(turn) /\ TraversalFrameValid6(r) /\ r.id \in Nat \ {0} /\ TraversalStepInfo6(r.step).phase = r.phase /\
actualProcedure.traversal=r /\ ~actualProcedure.returned,TraversalTimingPresent6(r) /\ ~r.ending)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ActivePlayer9, PrioritySite9, TimingRef9, ApproachedBarrier6, TraversalFrameValid6, TraversalStepInfo6, TraversalTimingPresent6, TurnFrameValid5
TriggerPattern96 · operator
reference-profile · input revision 2 · CC0 1.0
TriggerPattern96(d,event) ==
/\ event.kind \in ConditionalEventKinds96(d)
/\ event.scopeKind="Global" \/ (event.scopeKind="Ability" /\ event.scopeDefinition=ConditionalKey96(d))
/\ d.trigger.subject="SchemaAtom016" \/ (d.trigger.subject="SchemaAtom149" /\ event.object=d.syntax.source.object)
/\ ConditionalActorMatches96(d,event.actor)
/\ d.trigger.side="SchemaAtom016" \/ event.side=d.trigger.sideExact module download · Source bundle and reproduction instructions
Resolved project definitions: ConditionalActorMatches96, ConditionalEventKinds96, ConditionalKey96
TriggerStipulations96 · operator
reference-profile · input revision 2 · CC0 1.0
TriggerStipulations96(d,event,actualCondition) ==
/\ actualCondition.tag="ConditionalTriggerStipulations" /\ actualCondition.ability=d.syntax.id /\ actualCondition.source=d.syntax.source
/\ actualCondition.occurrence=event.id /\ actualCondition.snapshotId=event.snapshot.id
/\ DOMAIN actualCondition.results=d.triggerRequirements
/\ \A id \in DOMAIN actualCondition.results : actualCondition.results[id]Exact module download · Source bundle and reproduction instructions
TurnPrioritySite9 · operator
reference-profile · input revision 2 · CC0 1.0
TurnPrioritySite9(turn,step,phaseId,actionPoints,actualProcedure) ==
LET info == IF turn.owner = "SideA" THEN SideAStepInfo5(step) ELSE SideBStepInfo5(step)
steps == IF turn.owner = "SideA" THEN SetupRange(SideASteps5) ELSE SetupRange(SideBSteps5)
IN PrioritySite9("Turn",step,turn.phase,TimingRef9("TurnPhase",phaseId),ActivePlayer9(turn),turn.id,0,0,actionPoints,0,FALSE,
TurnFrameValid5(turn) /\ step \in steps /\ info.phase = turn.phase /\ actualProcedure.turn=turn /\ actualProcedure.step=step,
~turn.formalEnded)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: info, steps, ActivePlayer9, PrioritySite9, TimingRef9, TurnFrameValid5
UnitShape911 · operator
reference-profile · input revision 2 · CC0 1.0
UnitShape911(unit) == IRField911(unit,"shape","Single")Exact module download · Source bundle and reproduction instructions
Resolved project definitions: IRField911
VariableXValue912 · operator
reference-profile · input revision 2 · CC0 1.0
VariableXValue912(d,world,cardFacts,evaluation) ==
IF ~CurrentXDefinitionActive912(d,world,cardFacts) \/ ~evaluation.available THEN 0 ELSE evaluation.valueExact module download · Source bundle and reproduction instructions
Resolved project definitions: CurrentXDefinitionActive912
VisibleSubOrder98 · operator
reference-profile · input revision 2 · CC0 1.0
VisibleSubOrder98(spine,present) == SelectSeq(spine,LAMBDA id : id \in present)Exact module download · Source bundle and reproduction instructions
Resolved project definitions: LAMBDA
WholeAbilityRestrictionGate93 · operator
reference-profile · input revision 2 · CC0 1.0
WholeAbilityRestrictionGate93(a,actualRestrictions) ==
/\ actualRestrictions.tag="AbilityRestrictions" /\ actualRestrictions.ability=a.id /\ actualRestrictions.source=a.source
/\ DOMAIN actualRestrictions.results=TextUnitIds93(a.units,"Restriction")
/\ \A id \in DOMAIN actualRestrictions.results : actualRestrictions.results[id]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TextUnitIds93
WindowSiteAllowed9 · operator
reference-profile · input revision 2 · CC0 1.0
WindowSiteAllowed9(kind,site) ==
/\ kind \in PriorityWindowKinds9 /\ site.live /\ TimingRefValid9(site.structure)
/\ site.active \in SetupPlayers /\ site.turnId \in Nat \ {0}
/\ CASE kind = "NeutralValue00001" ->
/\ site.route = "Turn" /\ site.phase = "NeutralValue00001" /\ site.actionPoints \in Nat \ {0}
/\ site.step = IF site.active = "SideA" THEN "ProcedureCode0e20572a4bab" ELSE "ProcedureCode989abc27e0c6"
[] kind = "Paid" -> PaidWindowOptions9(site).paid /\ ~site.traversalEnding
[] kind = "MidItemInspection" -> site.route = "ItemInspection" /\ site.step = "ProcedureCode1dd0e8f05be2" /\ ~site.traversalEnding
[] OTHER -> TRUE
/\ kind \in {"Reaction","Interrupt"} \/ site.timingLiveExact module download · Source bundle and reproduction instructions
Resolved project definitions: PaidWindowOptions9, PriorityWindowKinds9, TimingRefValid9, SetupPlayers
WindowTop9 · operator
reference-profile · input revision 2 · CC0 1.0
WindowTop9(stack) == stack[Len(stack)]Exact module download · Source bundle and reproduction instructions
WouldContextKey99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldContextKey99(ref) == [field \in DOMAIN ref \ {"revision"} |-> ref[field]]Exact module download · Source bundle and reproduction instructions
WouldContextValid99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldContextValid99(ref) ==
/\ ref.origin \in {"Ability","Rule","BarrierInstruction"} /\ ref.id \in Nat \ {0} /\ ref.revision \in Nat
/\ ref.source.kind \in {"Object","Rule"}
/\ IF ref.origin="Rule" THEN ref.abilityInstance=0 /\ ref.index=0 /\ ref.source=RuleAbilitySource9(ref.ruleStep) /\ ref.ruleStep # "NoValue"
ELSE ref.abilityInstance \in Nat \ {0} /\ (IF ref.origin="BarrierInstruction" THEN ref.index=0 ELSE ref.index \in Nat \ {0})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: RuleAbilitySource9
WouldCriterionMatches99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldCriterionMatches99(effect,criterion) ==
/\ effect.kind=criterion.kind /\ effect.subtype=criterion.subtype /\ effect.actor=criterion.actor
/\ ~criterion.minimumPresent \/ effect.amount>=criterion.minimum
/\ ~criterion.targetSitePresent \/ effect.targetSite=criterion.targetSiteExact module download · Source bundle and reproduction instructions
WouldDescriptor99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldDescriptor99(effect) ==
[kind |-> effect.kind,subtype |-> IF effect.kind="Damage" THEN effect.damageType ELSE "NoValue",
actor |-> IF "actor" \in DOMAIN effect THEN effect.actor ELSE effect.baseController,
amount |-> IF "value" \in DOMAIN effect THEN effect.value ELSE 0,
targetSite |-> IF "targetSite" \in DOMAIN effect THEN effect.targetSite ELSE "NoValue"]Exact module download · Source bundle and reproduction instructions
WouldMatchingGroups99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldMatchingGroups99(history,period,criterion) ==
{key \in DOMAIN history.groups : \E i \in 1..Len(history.evidence) : history.evidence[i].group=key /\
period \in history.evidence[i].periods /\ ExpectedWouldCriterionMatches99(history.evidence[i].descriptor,criterion)}Exact module download · Source bundle and reproduction instructions
Resolved project definitions: ExpectedWouldCriterionMatches99
WouldOrdinalAt99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldOrdinalAt99(history,id,period,criterion) ==
Cardinality({other \in DOMAIN history.occurrences : history.occurrences[other].serial<=history.occurrences[id].serial /\
period \in history.occurrences[other].periods /\ WouldCriterionMatches99(history.occurrences[other].effect,criterion)})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldCriterionMatches99
WouldOrdinalAtCurrent99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldOrdinalAtCurrent99(history,key,period,criterion) ==
IF key \notin WouldMatchingGroups99(history,period,criterion) THEN 0
ELSE Cardinality({other \in WouldMatchingGroups99(history,period,criterion) :
FirstWouldMatchSerial99(history,other,period,criterion)<=FirstWouldMatchSerial99(history,key,period,criterion)})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: FirstWouldMatchSerial99, WouldMatchingGroups99
WouldOrdinalCount99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldOrdinalCount99(history,period,criterion) ==
Cardinality({id \in DOMAIN history.occurrences : period \in history.occurrences[id].periods /\ WouldCriterionMatches99(history.occurrences[id].effect,criterion)})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldCriterionMatches99
WouldOrdinalCountCurrent99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldOrdinalCountCurrent99(history,period,criterion) == Cardinality(WouldMatchingGroups99(history,period,criterion))Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldMatchingGroups99
WouldPeriodMembership99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldPeriodMembership99(opening,period,membership) ==
/\ WouldPeriodValid99(period) /\ membership.tag="WouldPeriodMembership"
/\ membership.openingId=opening.id /\ membership.context=WouldContextKey99(opening.context)
/\ membership.period=period /\ membership.procedureId \in Nat \ {0}
/\ CASE period.kind="Turn" -> TurnFrameValid5(membership.frame) /\ membership.frame.id=period.id
[] period.kind="SchemaAtom138" -> TraversalFrameValid6(membership.frame) /\ membership.frame.id=period.id
[] OTHER -> membership.frame.tag="TimingPeriodInstance" /\ membership.frame.period=period /\ membership.frame.procedureId=membership.procedureIdExact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldContextKey99, WouldPeriodValid99, TraversalFrameValid6, TurnFrameValid5
WouldPeriodValid99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldPeriodValid99(ref) == TimingRefValid9(ref) \/ (ref.kind \in {"Game","StatedPeriod"} /\ ref.id \in Nat \ {0})Exact module download · Source bundle and reproduction instructions
Resolved project definitions: TimingRefValid9
WouldRootKey99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldRootKey99(context,root) == [context |-> WouldContextKey99(context),root |-> root]Exact module download · Source bundle and reproduction instructions
Resolved project definitions: WouldContextKey99
WouldViewCurrent99 · operator
reference-profile · input revision 2 · CC0 1.0
WouldViewCurrent99(history,context,world) ==
/\ context.id \in DOMAIN history.latest
/\ history.latest[context.id].imminenceId=context.imminenceId /\ history.latest[context.id].reference=context.currentRef
/\ history.latest[context.id].snapshotId=world.id /\ history.latest[context.id].effects=context.state.effects
/\ history.latest[context.id].groups=[id \in DOMAIN context.state.effects |-> context.wouldGroups[id]]Exact module download · Source bundle and reproduction instructions