Documentation

MIPRE.Foundations.CL.DetypingProgRoute

Executable routing of detyped queries #

The fixed finite graph is compiled into a table. The variable content is processed by list operations and at most one call to the original typed sampler. Padding follows the supplied content vector, so malformed queries never cause an unbounded dimension allocation.

noncomputable def MIPRE.CL.Detyping.Program.graphResult {T : Type u_1} [Fintype T] [DecidableEq T] [Cost.SizedEncoding T] (E : T → T → Prop) [DecidableRel E] (a : GraphArgs T) :
Equations
  • One or more equations did not get rendered due to their size.
Instances For
    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        Equations
        • One or more equations did not get rendered due to their size.
        Instances For
          Equations
          Instances For
            Equations
            • One or more equations did not get rendered due to their size.
            Instances For
              Equations
              • One or more equations did not get rendered due to their size.
              Instances For
                Equations
                • One or more equations did not get rendered due to their size.
                Instances For
                  Equations
                  • One or more equations did not get rendered due to their size.
                  Instances For
                    theorem MIPRE.CL.Detyping.Program.post_prefix (g : ℕ) (preBits result : Cost.BitStr) :
                    (post g).toFun (withPrefix preBits, Cost.encode result) = Cost.encode (preBits ++ result)
                    theorem MIPRE.CL.Detyping.Program.routeResult_preserves (g : ℕ) (p : Parsed) (a : GraphResult) (payload : Cost.Data) (h : routeResult g p a = (true, payload)) :
                    ∃ (d : Cost.Data) (ctx : Cost.Data), payload = (p.1.cons d).cons ctx
                    theorem MIPRE.CL.Detyping.Program.route_preserves {T : Type u_1} [Fintype T] [DecidableEq T] [Cost.SizedEncoding T] (E : T → T → Prop) [DecidableRel E] (n : ℕ) (q payload : Cost.Data) (h : (route E).toFun ((Cost.encode n).cons q) = (true, payload)) :
                    ∃ (d : Cost.Data) (ctx : Cost.Data), payload = ((Cost.encode n).cons d).cons ctx