interplane.Get Omega
Read in your language

aien-architecture-mv

Canonical architecture for the AIEN ecosystem: flows, boundaries, ADRs, and the map from design to implementation repositories.

Brought by drakestapleton

branch main Branches Tags History

aien-architecture-mv / docs / plans / atemporal / AT1_CASE_V1.md

172 lines · 13202 bytes Raw Blame History Source

AT1_CASE_V1: AT-1 case interchange contract

Contract: AT1_CASE_V1. Domain tags: omega.at1.case.v1 (case identity), omega.at1.acceptance.v1 (acceptance identity). Status: FROZEN on merge of the pull request that adds this file. After that, any change to this file is a contract change and requires AT1_CASE_V2 (AT1 charter section 8). Typos are not exempt. Owner: Agent 0. Program status: NOT_RUN. Predecessor: AT0_CASE_V1 (frozen, unchanged, still the AT-0 contract).

0. Changes from AT0_CASE_V1

1. File shape

ASCII text, LF line endings, every line terminated by exactly one LF, including the last. Allowed bytes: 0x20 to 0x7E and 0x0A. No CR, no tab, no blank line, no leading or trailing space, exactly one space between tokens. Lines appear in exactly the order below; a line marked "repeated" appears once per item, in ascending index order. Unknown keys, missing keys, duplicate keys and out-of-order keys are errors (CASE_PARSE_ERROR), never warnings. A fixed literal that does not match (for example model_family or constraint), an enumeration token outside its set, a repeated block whose line count does not match its count line, or a repeated line whose index token is not its zero-based position, is a shape error (CASE_PARSE_ERROR), per the AT-0 reading "shape before range". clock_dim is the count line for both the clock_energies entries and the interaction_pauli lines; clock_label_count is the count line for the clock_label lines. One exception, so that version mismatches are reported as such: the three version-bearing lines (OMEGA-AT1-CASE v1, domain ..., contract ...) are checked for key and placement in step 1 and for their value in step 2 of section 4 (CASE_UNSUPPORTED_VERSION).

OMEGA-AT1-CASE v1
domain omega.at1.case.v1
contract AT1_CASE_V1
case_name <name>
begin semantic
model_family PAGE_WOOTTERS_FINITE_CLOCKDIAG
energy_unit DIMENSIONLESS_HBAR_1
clock_dim <N>
clock_energies <rational>,<rational>,...            (N entries, strictly increasing)
system_dim 2
system_hamiltonian_pauli <h0>,<hx>,<hy>,<hz>         (rationals)
interaction CLOCK_DIAGONAL_PAULI
interaction_pauli <j> <vx>,<vy>,<vz>                 (repeated, j = 0 .. N-1, rationals)
constraint SUM_HC_HS_V
physical_state NULLSPACE_PROJECTION
reference_clock_label <label>
reference_system_state <complex>,<complex>
clock_povm COVARIANT_DISCRETE
povm_tau_turns <rational>
povm_weight <rational>
clock_label_count <M>
clock_label <k> <label>                              (repeated, k = 0 .. M-1)
observables PAULI_X,PAULI_Y,PAULI_Z
end semantic
begin acceptance
control_kind <POSITIVE|NEGATIVE>
prediction_target <IDEAL|INTERACTING>
expected_outcome <PASS|FAIL>
expected_failure_codes <code>,<code>,... | none
min_bound_kind <RIGOROUS|ESTIMATED|NONE>
tol_constraint_residual <scaled>
tol_povm_residual <scaled>
tol_probability <scaled>
tol_zero_probability <scaled>
tol_schrodinger <scaled>
end acceptance
case_id <64 lowercase hex>
acceptance_id <64 lowercase hex>
end

2. Canonical encodings (shared by AT1_CASE_V1 and AT1_RESULT_V1)

Identical to AT0_CASE_V1 section 2, restated so this file stands alone:

3. Field meaning (the physics, fixed for V1)

Units: hbar = 1, dimensionless energies, times in the reciprocal unit. Pauli matrices in the computational basis with Z|0> = +|0>.

No field of a case may hold a wall-clock time, a host name, a run number or anything else about a physical execution.

4. Validity rules (exact, before any numerics)

A validator refuses the case with the AT1_RESULT_V1 refusal code shown, on the first failure, in this order:

  1. Shape and encodings (sections 1, 2): CASE_PARSE_ERROR (shape) or CASE_NONCANONICAL (parsed, non-canonical token).
  2. The values of the three version-bearing lines (OMEGA-AT1-CASE v1, domain omega.at1.case.v1, contract AT1_CASE_V1): CASE_UNSUPPORTED_VERSION.
  3. Ranges and fixed values of section 3; reference_system_state nonzero; povm_weight > 0; povm_tau_turns > 0: CASE_INVALID_PARAMETER. (Counts and index order are shape, step 1.)
  4. Rational spectrum per level: for every j, (hx + vx_j)^2 + (hy + vy_j)^2 + (hz + vz_j)^2 is the square of a rational: CASE_IRRATIONAL_SPECTRUM.
  5. case_id and acceptance_id equal the recomputed values (section 5): CASE_ID_MISMATCH.
  6. Acceptance: expected_failure_codes is none when expected_outcome PASS, nonempty, sorted bytewise ascending, no duplicates when FAIL, every code an AT1_RESULT_V1 failure code: CASE_INVALID_PARAMETER.

5. Identity

Every hashed byte is exact text. Equal digests are evidence of equal exact content, not the definition of equality.

6. Worked example (known-answer test for codecs)

Normative for byte layout and digests. The physics table is hand-derived and informational; AT1_SPEC.md and the oracle are the authority on values.

OMEGA-AT1-CASE v1
domain omega.at1.case.v1
contract AT1_CASE_V1
case_name at1-kat-rotated-level-n4
begin semantic
model_family PAGE_WOOTTERS_FINITE_CLOCKDIAG
energy_unit DIMENSIONLESS_HBAR_1
clock_dim 4
clock_energies -3/2,-1/2,1/2,3/2
system_dim 2
system_hamiltonian_pauli 0/1,0/1,0/1,1/2
interaction CLOCK_DIAGONAL_PAULI
interaction_pauli 0 0/1,0/1,0/1
interaction_pauli 1 0/1,0/1,0/1
interaction_pauli 2 3/10,0/1,-1/10
interaction_pauli 3 0/1,0/1,0/1
constraint SUM_HC_HS_V
physical_state NULLSPACE_PROJECTION
reference_clock_label t0
reference_system_state (1/1;0/1),(1/1;0/1)
clock_povm COVARIANT_DISCRETE
povm_tau_turns 1/4
povm_weight 1/1
clock_label_count 4
clock_label 0 t0
clock_label 1 t1
clock_label 2 t2
clock_label 3 t3
observables PAULI_X,PAULI_Y,PAULI_Z
end semantic
begin acceptance
control_kind POSITIVE
prediction_target INTERACTING
expected_outcome PASS
expected_failure_codes none
min_bound_kind ESTIMATED
tol_constraint_residual 1@12
tol_povm_residual 1@12
tol_probability 1@12
tol_zero_probability 1@9
tol_schrodinger 1@12
end acceptance
case_id 890980a43bd189494c2c922d2bf0049cbffb07f1090f578e04e1142aee7525f1
acceptance_id d63246c391296c6cd381f1b654cc625be9f453c77c27c68d9eac240efd5b4d8f
end

case_file_sha256 of the 45 lines above, each LF-terminated: 76e282fecf21025c9dd675378244e90ff192822a4c49d6cb812c9fe84b3f9ba4.

Hand derivation (informational). Levels 0, 1, 3 are uncoupled: e = +-1/2 with eigenvectors |0>, |1>. Level 2 has h + v_2 = (3/10, 0, 4/10), |h + v_2| = 1/2, so its eigenvalues are also +-1/2 but along the axis n = (3/5, 0, 4/5): |e_{2,-}> = (-1/sqrt(10)) |0> + (3/sqrt(10)) |1>. Kernel: (j = 1, e = +1/2) via |0> and (j = 2, e = -1/2) via |e_{2,-}>; dimension 2; both system components survive. The file's psi_0 = (1, 1) is proportional to |+x>; the values below use the normalized |+x> (p(k) does not depend on the scale; with the unnormalized vector ||Psi||^2 is 7/20 instead of 7/40). With psi_0 = |+x>: <0|psi_0> = 1/sqrt(2), <e_{2,-}|psi_0> = 1/sqrt(5), ||Psi||^2 = (1/4)(1/2 + 1/5) = 7/40, and the cross term <0|e_{2,-}> = -1/sqrt(10) makes the clock marginal label-dependent: ||phi_k||^2 = (1/16)(7/10 - (1/5) cos(pi k / 2)), so

labelp(clock)ideal model would say
t05/281/4
t11/41/4
t29/281/4
t31/41/4

The four values sum to 1 (the POVM is complete for this clock), the clock probabilities alone already refute the ideal prediction (AT1_RESULT_V1 check 10 compares them with w/N under prediction_target IDEAL), and the same case with prediction_target IDEAL is the negative class N1 (expected SCHRODINGER_DEVIATION_EXCEEDED). The relative phase between the two kernel levels is real here (cos), so this table does not depend on the phase sign of section 3; the Y outcomes do. Conditional Pauli values are left to AT1_SPEC.md.