Morphisms of HasQuery Monads #
This module contains the heavier HasQuery naturality layer.
It imports ProbComp and monad homomorphisms, so files that only need the
basic query capability should import VCVio.OracleComp.HasQuery.Basic
instead.
Use this module for proofs that a monad morphism preserves oracle queries, or that it commutes with the canonical lift of public randomness.
A QueryHom spec m n is a monad morphism m →ᵐ n that also preserves the distinguished
oracle-query capability for spec. This is the right notion of morphism for proving that a
construction generic over HasQuery spec is natural in the chosen oracle semantics.
Instances For
A monad morphism preserves public randomness when it commutes with the distinguished lifting of plain probabilistic computations into the ambient monad.