The typed oracularized sampler #
Piece O3 of planning/oracularization.md (issue #189): the sampler of the paper's typed
oracularized verifier (sec:orac-def) as a CL.TypedSampler over the three roles, whose typed CL
functions are roleFamily of the input sampler's (the identity for the oracle, the input's for the
isolated players) — the half of lem:oracle-effective-interface about the sampler.
The program is the fixed core OracleSampler.core, run on the input sampler's program through
the s-m-n construction hardcode, as the repeated sampler is. The core routes a typed query with
at most one call to the input sampler, through the universal machine:
- the dimension query is forwarded unchanged;
- a query at an isolated role is forwarded as the query of the corresponding original player;
- a query at the oracle role is answered from the query itself, with no call at all: the identity's marginals are the seed, its first stage map is the identity and its later ones zero, its first factor space is everything and its later ones nothing. The zero vectors are written over the supplied vector rather than over the dimension, so the core never allocates by a dimension it has not been given.
The identity's queries #
A query with its player replaced; the dimension query has none.
Equations
- MIPRE.CL.Sampler.Query.withPlayer w MIPRE.CL.Sampler.Query.dimension = MIPRE.CL.Sampler.Query.dimension
- MIPRE.CL.Sampler.Query.withPlayer w (MIPRE.CL.Sampler.Query.marginal w_1 j z) = MIPRE.CL.Sampler.Query.marginal w j z
- MIPRE.CL.Sampler.Query.withPlayer w (MIPRE.CL.Sampler.Query.linear w_1 j u y) = MIPRE.CL.Sampler.Query.linear w j u y
- MIPRE.CL.Sampler.Query.withPlayer w (MIPRE.CL.Sampler.Query.factor w_1 j u) = MIPRE.CL.Sampler.Query.factor w j u
Instances For
Roles as data #
The roles as numbers: the oracle 0, the isolated Alice 1, the isolated Bob 2.
Equations
Instances For
Reading a role back.
Equations
Instances For
Equations
- One or more equations did not get rendered due to their size.
The core #
The input sampler's program, hardcoded first.
Instances For
The index.
Equations
Instances For
The typed query, nil for the dimension query.
Equations
Instances For
The type of a typed query.
Instances For
The untyped query of a typed query.
Instances For
A call to the input sampler, through the universal machine, on the query q.
Equations
- One or more equations did not get rendered due to their size.
Instances For
An isolated role's query, as the query of the corresponding original player.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The untyped query, parsed: (n, kind, w, j, u, y).
Equations
Instances For
The oracle's answers, read off the query alone: the marginal of the identity is the seed; its first stage map is the identity and its later ones zero; its first factor space is everything and its later ones nothing.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The router: the dimension query and the isolated roles' queries go to the input sampler, the oracle's are answered directly.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The answer of the call is the answer.
Instances For
The core of the typed oracularized sampler.
Equations
Instances For
The router on well-formed queries #
The oracle's answer to an untyped query, as the core computes it.
Equations
- MIPRE.OracleSampler.oracleAnswer MIPRE.CL.Sampler.Query.dimension = []
- MIPRE.OracleSampler.oracleAnswer (MIPRE.CL.Sampler.Query.marginal w j z) = z
- MIPRE.OracleSampler.oracleAnswer (MIPRE.CL.Sampler.Query.linear w j u y) = if j = 1 then y else List.map (fun (x : Bool) => false) y
- MIPRE.OracleSampler.oracleAnswer (MIPRE.CL.Sampler.Query.factor w j u) = if j = 1 then List.map (fun (x : Bool) => true) u else List.map (fun (x : Bool) => false) u
Instances For
The typed sampler #
The program of the typed oracularized sampler on the input sampler's program sp.
Equations
Instances For
A forwarded query is answered by the input sampler, through the universal machine.
An oracle query is answered directly.
The typed oracularized sampler (the sampler of sec:orac-def): the typed CL functions
are the identity for the oracle and the input sampler's own for the isolated players, the same
for both players; the program answers an isolated role's query as the input sampler answers the
corresponding original player's, and an oracle query directly. It depends on the input sampler
alone.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The running time #
A forwarded query is at most twice the typed query, plus a constant: it is the dimension query, or the typed query's own fields with the player replaced.
The explicit cost of the core on an input of size xs, at the input sampler's coefficient
B and degree k, with X one more than the size of the typed query.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The core halts within coreCost on every input of the typed sampler, well formed or
not: the router, at most one call to the input sampler through the universal machine, and the
postprocessing.
The running time of the typed oracularized sampler: constants c, m, e uniform in
everything such that, whenever W dominates the input sampler's coefficient, its description
length and the index, and the input sampler runs within B (|d| + 1)^k at n, the typed
sampler runs within c (W + 1)^m (|d| + 1)^{e (k + 1)}. A forwarded query is at most a constant
factor larger than the typed query, and since |d| + 1 ≥ 2 that factor is absorbed into the
degree, so no term exponential in k enters the coefficient.
The program is a polynomial-time function of the input sampler's program: the s-m-n map at the fixed core.