{"item":"nulls","batch":"e01-b-register","track":"B identifiability map: registration only","approach":"Preregistration of one model family for Z32: up to three of the 29 glyph types are nulls (all their occurrences vanish), the rest map consistently to A-Z in printed order, and the plaintext must be one of the 840 expansions (G) of the ten radians-and-inches templates of report section 6. Everything a tester needs is frozen here: transcription, vocabulary generator and digests, the 4,090 masks, fit and equivalence definitions, statistics, 199 seeded shuffle controls and the program that runs them. The program was executed only in its self-test mode, which builds the vocabulary, hashes the control draws and runs synthetic known-answer and contradiction arrays. The Z32 arrangement and its 199 shuffles were not searched. No plaintext is proposed.","protocol":{"id":"z32-e01-b-register-nulls-v1","family":"null glyph types, printed order, no edits, frozen vocabulary G","ciphertext":{"aliases":"C9J|#Ok[AMf8?ORTGX6FDVj%HCELzPW9","rows":["C9J|#Ok[AMf8?ORTG","X6FDVj%HCELzPW9"],"order":"upper row left to right, then lower row; positions 1-32; no route, reversal or transposition","glyphs":32,"types":29,"singletonTypes":26,"doubledTypes":{"C":[1,26],"9":[2,32],"O":[6,14]},"typeIdentity":"case-sensitive alias equality exactly as in report section 2; no merging or splitting of look-alike glyphs"},"plaintextAlphabet":"ABCDEFGHIJKLMNOPQRSTUVWXYZ","vocabularyG":{"words":"ZERO ONE TWO THREE FOUR FIVE SIX SEVEN EIGHT NINE TEN ELEVEN TWELVE","angleValues":"0..6 inclusive (ZERO..SIX)","distanceValues":"1..12 inclusive (ONE..TWELVE)","angleUnit":"RADIAN when the angle is ONE, otherwise RADIANS (including ZERO)","distanceUnit":"INCH when the distance is ONE, otherwise INCHES","templates":["{A} {D}","{D} {A}","{A} AND {D}","{D} AND {A}","{D} ALONG {A}","{D} ALONG THE {A}","{A} AND {D} ALONG","{A} AND {D} ALONG THE RAY","{A} FROM MAGNETIC NORTH AND {D}","{D} AT {A} FROM MAGNETIC NORTH"],"expansion":"A = angle word + space + unit; D = distance word + space + unit; all 7*12*10 = 840 (angle, distance, template) triples","normalization":"remove every space; text is already upper-case A-Z; no other change (no spelling, abbreviation, digit or punctuation variants)","lengthsRetained":"all (16..44); a text is used by a mask only when its length equals the surviving slot count","sortedUniqueSha256":{"convention":"sorted distinct texts, UTF-8, joined by LF, no final LF; the empty list hashes the empty string","all840":"888b3af7732993aadde76cf6e7e36f1fd3abee393407c9110936550df11dfb75","perLength":{"26":"59faaa61d39789b9bc557fb4e6d9e61ac8937ea8f592b47f47e795410e2f4892","27":"b67e564c5dae3c83b515916ef86981615addcae5a8d8b40a256e79d0afecb9f0","28":"98eaa309cd44f3fa8b7941e2a885e509240aeee74be6afb4028c8ee5c7f6d4ce","29":"0479f81a25132aca9f9fbc4b0be44d9ca659f63c260a63451341ba47ece9e09c","30":"107b336a390f734fcb08eeda51966a7452bd76a751b4e3e592ff9887022537e2","31":"a664b8b4ae93d29381d13e597c3b951963a11c2fcda5eaa7da1483954b156506","32":"f64b62d0764290fe042b908e34ed11d48f9bdd8274c2426d59d4510442f7b8b3"}}},"nullModel":{"unit":"glyph TYPE: a mask is a set of 0, 1, 2 or 3 of the 29 types; every occurrence of a chosen type is deleted; no single occurrence of a type can be null while another survives","masks":{"eq0":1,"eq1":29,"eq2":406,"eq3":3654,"le3":4090},"enumeration":"every subset, no pruning by shape, position or appearance","survivors":"remaining glyphs keep printed order; surviving length = 32 minus deleted occurrences, between 26 and 32","key":"a function from the surviving types to A-Z; equal glyphs must carry equal letters; different glyphs may share a letter (homophonic, as in report section 6); no further constraint","injectiveVariant":"not registered: at least 26 types survive every mask and no text in G has more than 18 distinct letters, so a one-to-one key cannot fit any text","fit":"pair (mask, text) with len(text) == surviving length and the key well defined; zero conflicts only, near-fits are not counted","lengthFilter":"text length must equal surviving length exactly; no padding, truncation, continuation or partial reading"},"equivalence":{"reading":"the normalized text string; two fits with the same string are one reading whatever the mask, key, template or values","key":"the 29-character string over A-Z and - (null) giving each type its letter in first-occurrence order; two keys are equal iff these strings are equal; a fit (mask, text) determines exactly one key and a key determines its mask and text, so keys = distinct (mask, text) pairs","parameterFit":"tuple (mask, template index, angle, distance); equals keys here because the 840 normalized texts are pairwise distinct","valuePair":"distinct (angle, distance) among the fitted readings","retained":"for every observed reading: number of masks (= keys) per exact null budget, number of constrained masks, its value pairs; plus the full sorted key list"},"budgets":{"exact":"eq0, eq1, eq2, eq3: masks with exactly k null types","cumulative":"le0, le1, le2, le3: masks with at most k null types","note":"eq0 = le0 is the printed-order test already settled in episode 1 (0 of 10); it is recomputed only as a consistency value inside the full family"},"strata":{"all":"every fit","constrained":"fits whose surviving sequence still contains at least one repeated type, i.e. at least one equality is actually tested","reason":"frozen before any fit: the single mask {C,9,O} leaves 26 singletons, so each of the 50 length-26 texts fits it for every arrangement of these glyphs; that floor is identical in the observed array and in every control"},"statistics":{"cells":"8 budgets x 2 strata = 16 cells","perCell":["readings","keys","paramFits","valuePairs"],"primary":"le3.constrained.readings; secondary (all reported, none selected afterwards): the other 63 values","report":"observed value; control frequencies of zero, exactly one, more than one; control min, median, max; inclusive tail tailGE = number of controls with value >= observed; p = (1 + tailGE)/200"},"controls":{"n":199,"rng":"Python random.Random(320102), CPython Mersenne Twister, list.shuffle semantics of random.shuffle","procedure":"for each of 199 draws in order: s = list(the 32 aliases in printed order); rng.shuffle(s); one generator advancing through all draws, never reseeded; search the identical full family (all 4090 masks, all of G) on s","drawsSha256":"d8283c2ed1066742fab0a8a52b1be89cb7ae2010738a8a21df37f67ce2838197","drawsSha256Convention":"the 199 shuffled 32-character strings in draw order, UTF-8, joined by LF, no final LF","distinctDraws":199,"excludedDraws":"none; a draw equal to the printed order is kept and counted (run output field controlsEqualToObserved)"},"decisionRules":{"modelRelativeSingleton":"only if readings == 1 in the cell being reported; it is uniqueness inside this family and vocabulary, not a decipherment","notDistinguishing":"two-sided on the primary statistic, with tailLE = number of controls with value <= observed, computed from the per-control values: if both (1 + tailGE)/200 and (1 + tailLE)/200 exceed 10/200, the family does not separate Z32 from a shuffle of its own glyphs","forbidden":"no corrected phrase, no candidate plaintext selection, no geographical selection, no change of vocabulary, budget, key rule or statistic after the run; an empty vocabulary length or an empty fit set stays empty"},"program":{"language":"Python 3 standard library","codeSha256":"2d467aa0a3c43adb465cf5472e6b76a1ac4f5e34843605457096bca4740d4b32","testCommand":"python3 nulls.py run","selftestCommand":"python3 nulls.py","selftestStdoutSha256":"849f40531edaaeb07290f1e03a9c1fd8a1a70bdb1a3d6d63135a2e52b86805e6"}},"protocolSha256":"45ce312a56a9b980391b8efd8076a0d0a146cc177000a2f18ed44cec5300ece5","protocolHashConvention":"sha256(json.dumps(protocol, sort_keys=True, separators=(',', ':'), ensure_ascii=True).encode('ascii'))","gates":{"ready":"pass","reasons":["every family parameter, definition, statistic and control draw is fixed above and in the program; the tester makes no model choice","self-test is deterministic: two executions gave byte-identical stdout (sha256 in protocol.program)","length-32 vocabulary digest equals the report value f64b62d0764290fe042b908e34ed11d48f9bdd8274c2426d59d4510442f7b8b3","transcription counts recomputed from the section 2 aliases: 32 glyphs, 29 types, 26 singletons, 3 doubled"],"section9Certificate":"not rerun here: the brief states it passed in episode 1 and forbids rerunning settled searches; only its transcription counts and vocabulary digest were recomputed","runModeExecuted":false,"runModeCaveat":"the run() wrapper itself (per-reading table, key list) was never executed, to keep the barrier; search, stats and experiment, which it calls, were exercised on synthetic arrays"},"vocabularyCounts":{"expansions":840,"distinctAfterNormalization":840,"textsSharedByTwoParameterTuples":0,"lengthRange":[16,44],"expansionsAfterLengthFilter26to32":240,"distinctAfterLengthFilter26to32":240,"perLength":{"26":{"expansions":50,"distinct":50,"sha256":"59faaa61d39789b9bc557fb4e6d9e61ac8937ea8f592b47f47e795410e2f4892"},"27":{"expansions":40,"distinct":40,"sha256":"b67e564c5dae3c83b515916ef86981615addcae5a8d8b40a256e79d0afecb9f0"},"28":{"expansions":45,"distinct":45,"sha256":"98eaa309cd44f3fa8b7941e2a885e509240aeee74be6afb4028c8ee5c7f6d4ce"},"29":{"expansions":42,"distinct":42,"sha256":"0479f81a25132aca9f9fbc4b0be44d9ca659f63c260a63451341ba47ece9e09c"},"30":{"expansions":33,"distinct":33,"sha256":"107b336a390f734fcb08eeda51966a7452bd76a751b4e3e592ff9887022537e2"},"31":{"expansions":20,"distinct":20,"sha256":"a664b8b4ae93d29381d13e597c3b951963a11c2fcda5eaa7da1483954b156506"},"32":{"expansions":10,"distinct":10,"sha256":"f64b62d0764290fe042b908e34ed11d48f9bdd8274c2426d59d4510442f7b8b3"}},"letterInventory":"ACDEFGHILMNORSTUVWXYZ","maxDistinctLettersInOneText":18},"parameterCounts":{"masks":{"eq0":1,"eq1":29,"eq2":406,"eq3":3654,"le3":4090},"maskStrata":[{"masks":1,"nullTypes":0,"survivingLength":32,"survivingRepeatedTypes":3},{"masks":3,"nullTypes":1,"survivingLength":30,"survivingRepeatedTypes":2},{"masks":26,"nullTypes":1,"survivingLength":31,"survivingRepeatedTypes":3},{"masks":3,"nullTypes":2,"survivingLength":28,"survivingRepeatedTypes":1},{"masks":78,"nullTypes":2,"survivingLength":29,"survivingRepeatedTypes":2},{"masks":325,"nullTypes":2,"survivingLength":30,"survivingRepeatedTypes":3},{"masks":1,"nullTypes":3,"survivingLength":26,"survivingRepeatedTypes":0},{"masks":78,"nullTypes":3,"survivingLength":27,"survivingRepeatedTypes":1},{"masks":975,"nullTypes":3,"survivingLength":28,"survivingRepeatedTypes":2},{"masks":2600,"nullTypes":3,"survivingLength":29,"survivingRepeatedTypes":3}],"maskTextPairsTested":171010,"maskTextPairsByBudget":{"eq0":10,"eq1":619,"eq2":14136,"eq3":156245},"unconstrainedPairs":50,"routes":1,"edits":0},"structuralFacts":{"scope":"follow from the glyph multiplicities and G alone; they hold for every arrangement of the 32 glyphs, so they are not a fit test of Z32","floor":"In eq3.all and le3.all every array has at least 50 readings and 50 keys (mask {C,9,O}, the 50 length-26 texts). A unique reading is therefore impossible in those two cells before any test.","whereUniquenessIsPossibleAtAll":"only in eq0, eq1, eq2, le0, le1, le2 and in the constrained stratum of eq3 and le3; whether it occurs is for the testing item","constraintStrength":"no mask ever tests more than three letter equalities; 2,600 of the 3,654 three-null masks test three, 975 test two, 78 test one, 1 tests none"},"controlPlan":{"shuffles":"see protocol.controls","statistics":"see protocol.statistics","synthetic":{"note":"run now, on arrays that are neither Z32 nor its frozen shuffles; values are regression targets for the tester","knownAnswer3Singles":{"le3.all":{"keys":1180,"paramFits":1180,"readings":73,"valuePairs":49},"le3.constrained":{"keys":1130,"paramFits":1130,"readings":23,"valuePairs":20},"plantedRecovered":true,"relabelInvariant":true,"statsSha256":"5f4266443c7713ad9b288cc8ee253ec3be3a23c65cdf7ac29e0a33e1b8da9335","design":"first sorted length-29 text, one fresh glyph per letter, three glyph pairs on equal letters, three singleton null types inserted before letter indices 5, 14, 23: 32 glyphs, 29 types; the planted mask and text must be among the fits"},"knownAnswer1Double":{"le3.all":{"keys":699,"paramFits":699,"readings":81,"valuePairs":58},"le3.constrained":{"keys":649,"paramFits":649,"readings":31,"valuePairs":26},"plantedRecovered":true,"relabelInvariant":true,"statsSha256":"e4669ed8450e86d8cb18c547f6f51802f6c385b82d93eaac348d79a9ab1358c2","design":"first sorted length-30 text, two glyph pairs, one null type inserted twice (before letter indices 7 and 19); planted fit must be found at eq1"},"allSingletons":{"keys":225338,"readings":105,"design":"32 distinct glyphs: keys must equal N32 + 32*N31 + C(32,2)*N30 + C(32,3)*N29 and readings N32+N31+N30+N29; asserted"},"contradictionPeriodic":{"fits":0,"design":"'abcd' repeated 8 times: asserted zero fits"},"contradictionRuns":{"fits":0,"design":"known-answer array overwritten with four runs of one repeated glyph each (lengths 4,4,3,3), more than three nulls can remove; value recorded, not asserted in code"},"relabelInvariance":"renaming the glyph types leaves all 64 statistics unchanged; asserted on both known-answer arrays","rehearsal":{"le3.all.readings":{"controlMany":199,"controlMax":132,"controlMedian":75,"controlMin":51,"controlOne":0,"controlZero":0,"observed":73,"p":"111/200","tailGE":110},"le3.constrained.readings":{"controlMany":198,"controlMax":82,"controlMedian":25,"controlMin":1,"controlOne":1,"controlZero":0,"observed":23,"p":"111/200","tailGE":110},"seed":9001,"summarySha256":"9f35257ff44cb781da8ff8d09536de63989828dd55aa18b4bcbb05051aebf41e","design":"whole pipeline on knownAnswer3Singles as observed with 199 shuffles from the separate seed 9001"}},"powerWarning":"In the rehearsal the array with a planted true answer had 23 constrained readings against a control median of 25 (inclusive tail 110 of 199, p = 111/200). On this one synthetic example the registered statistics did not separate a true planted message from shuffles of its own glyphs."},"observedFits":"not_run","sources":[{"url":"https://api.imd.fun/artifacts/e254764c1c80b74fc17aca82f660f81d84da8e959073169b0995bddc7d4f6304","use":"transcription and aliases (section 2), vocabulary G and its length-32 digest, key rule, shuffle procedure (section 6), open families (section 8)","sha256":"e254764c1c80b74fc17aca82f660f81d84da8e959073169b0995bddc7d4f6304"},{"url":"https://api.imd.fun/jobs/1a42670d-81e5-4560-9bd3-e2e9d9f5ae65/result","use":"listing of the earlier accepted item files; fetched, no value taken from it"}],"codeAndData":{"file":"nulls.py (embedded below; write the string to a file as UTF-8 without changes)","codeSha256":"2d467aa0a3c43adb465cf5472e6b76a1ac4f5e34843605457096bca4740d4b32","codeBytes":11602,"dataSha256":{"ciphertextAliasesUtf8":"e52c79651fa03be1f28c6a776cdbfa1e9cfe7e18cc0206d19afecf99fe9f620d","vocabularyAll840":"888b3af7732993aadde76cf6e7e36f1fd3abee393407c9110936550df11dfb75","controlDraws":"d8283c2ed1066742fab0a8a52b1be89cb7ae2010738a8a21df37f67ce2838197","selftestStdout":"849f40531edaaeb07290f1e03a9c1fd8a1a70bdb1a3d6d63135a2e52b86805e6"},"literalData":"the aliases, the 13 number words, the unit rules and the 10 templates in protocol.vocabularyG are the complete ingredients; the program regenerates everything else","code":"#!/usr/bin/env python3\n# Z32 identifiability family \"nulls\" (null glyph TYPES): frozen protocol program.\n# Standard library only; reads no files, no network; prints JSON to stdout.\n#   python3 nulls.py            -> selftest: vocabulary, control-draw digest, synthetic controls.\n#                                  Never evaluates the Z32 arrangement or its frozen shuffles.\n#   python3 nulls.py run        -> the registered test (observed + 199 shuffle controls).\nimport sys, json, random\nfrom hashlib import sha256\nfrom itertools import product, combinations\nfrom math import comb\n\nCT = 'C9J|#Ok[AMf8?ORTG' + 'X6FDVj%HCELzPW9'\nWORDS = 'ZERO ONE TWO THREE FOUR FIVE SIX SEVEN EIGHT NINE TEN ELEVEN TWELVE'.split()\nTEMPLATES = [\n    '{A} {D}', '{D} {A}', '{A} AND {D}', '{D} AND {A}',\n    '{D} ALONG {A}', '{D} ALONG THE {A}', '{A} AND {D} ALONG',\n    '{A} AND {D} ALONG THE RAY', '{A} FROM MAGNETIC NORTH AND {D}',\n    '{D} AT {A} FROM MAGNETIC NORTH',\n]\nMAXNULL, SEED, NCTRL = 3, 320102, 199\nBUDGETS = ['eq0', 'eq1', 'eq2', 'eq3', 'le0', 'le1', 'le2', 'le3']\nSTRATA = ['all', 'constrained']\nSTATS = ['readings', 'keys', 'paramFits', 'valuePairs']\n\ndef digest(lines):\n    return sha256('\\n'.join(lines).encode('utf-8')).hexdigest()\n\ndef expansions():\n    rows = []\n    for a, d, ti in product(range(7), range(1, 13), range(len(TEMPLATES))):\n        A = WORDS[a] + (' RADIAN' if a == 1 else ' RADIANS')\n        D = WORDS[d] + (' INCH' if d == 1 else ' INCHES')\n        rows.append((TEMPLATES[ti].format(A=A, D=D).replace(' ', ''), ti, a, d))\n    return rows\n\nROWS = expansions()\nPARAMS = {}                       # normalized text -> list of (template, angle, distance)\nfor _t, _ti, _a, _d in ROWS:\n    PARAMS.setdefault(_t, []).append((_ti, _a, _d))\nBYLEN = {}                        # length -> sorted distinct texts\nfor _t in sorted(PARAMS):\n    BYLEN.setdefault(len(_t), []).append(_t)\nEQ = {}                           # (length, i, j) -> frozenset of text indices with t[i] == t[j]\n\ndef eqset(L, i, j):\n    k = (L, i, j)\n    if k not in EQ:\n        EQ[k] = frozenset(n for n, t in enumerate(BYLEN.get(L, ())) if t[i] == t[j])\n    return EQ[k]\n\ndef search(seq):\n    \"\"\"All fits of one glyph array. A fit is (k, c, mask, text): mask = sorted tuple of\n    indices (first-occurrence type order) of the k null types; every occurrence of a null\n    type is deleted; text has exactly the surviving length and equal surviving glyphs carry\n    equal letters (a function type -> A-Z, not required injective); c = number of surviving\n    types that still occur more than once (c == 0: no equality is tested at all).\"\"\"\n    types = list(dict.fromkeys(seq))\n    fits = []\n    for k in range(MAXNULL + 1):\n        for mask in combinations(range(len(types)), k):\n            null = {types[i] for i in mask}\n            surv = [g for g in seq if g not in null]\n            L = len(surv)\n            texts = BYLEN.get(L, ())\n            if not texts:\n                continue\n            last, pairs, rep = {}, [], set()\n            for i, g in enumerate(surv):\n                if g in last:\n                    pairs.append((last[g], i)); rep.add(g)\n                last[g] = i\n            ok = None\n            for i, j in pairs:\n                s = eqset(L, i, j)\n                ok = s if ok is None else ok & s\n                if not ok:\n                    break\n            idx = range(len(texts)) if ok is None else sorted(ok)\n            fits.extend((k, len(rep), mask, texts[n]) for n in idx)\n    return fits\n\ndef key_of(seq, mask, text):\n    \"\"\"Key on the observed glyph types, first-occurrence order, '-' = null type.\"\"\"\n    types = list(dict.fromkeys(seq))\n    null = {types[i] for i in mask}\n    m = dict(zip([g for g in seq if g not in null], text))\n    return ''.join(m.get(g, '-') for g in types)\n\ndef stats(fits):\n    out = {}\n    for b, s in product(BUDGETS, STRATA):\n        lim = int(b[2])\n        sel = [f for f in fits if (f[0] == lim if b[:2] == 'eq' else f[0] <= lim)\n               and (s == 'all' or f[1] >= 1)]\n        texts = {f[3] for f in sel}\n        out[b + '.' + s] = {\n            'readings': len(texts),\n            'keys': len({(f[2], f[3]) for f in sel}),\n            'paramFits': sum(len(PARAMS[f[3]]) for f in sel),\n            'valuePairs': len({(a, d) for t in texts for _, a, d in PARAMS[t]}),\n        }\n    return out\n\ndef draws(seq, seed, n):\n    rng, out = random.Random(seed), []\n    for _ in range(n):\n        s = list(seq)             # fresh copy of the 32 glyphs\n        rng.shuffle(s)            # one advancing generator\n        out.append(s)\n    return out\n\ndef experiment(observed, seed, n):\n    obs = stats(search(observed))\n    ctrl = [stats(search(s)) for s in draws(observed, seed, n)]\n    summary = {}\n    for cell in obs:\n        summary[cell] = {}\n        for st in STATS:\n            v = sorted(c[cell][st] for c in ctrl)\n            o = obs[cell][st]\n            tail = sum(x >= o for x in v)\n            summary[cell][st] = {\n                'observed': o, 'controlZero': sum(x == 0 for x in v),\n                'controlOne': sum(x == 1 for x in v), 'controlMany': sum(x > 1 for x in v),\n                'controlMin': v[0], 'controlMedian': v[len(v) // 2], 'controlMax': v[-1],\n                'tailGE': tail, 'p': '%d/%d' % (1 + tail, n + 1)}\n    return summary\n\ndef vocabulary_report():\n    lens = sorted(BYLEN)\n    need = list(range(len(CT) - 2 * MAXNULL, len(CT) + 1))\n    return {\n        'expansions': len(ROWS), 'distinctNormalized': len(PARAMS),\n        'collidingTexts': sum(len(v) > 1 for v in PARAMS.values()),\n        'lengthMin': lens[0], 'lengthMax': lens[-1],\n        'allDistinctSha256': digest(sorted(PARAMS)),\n        'expansionsInLengthFilter': sum(len(t) in need for t, _, _, _ in ROWS),\n        'distinctInLengthFilter': sum(len(BYLEN.get(L, ())) for L in need),\n        'perLength': {str(L): {'expansions': sum(len(t) == L for t, _, _, _ in ROWS),\n                               'distinct': len(BYLEN.get(L, ())),\n                               'sha256': digest(BYLEN.get(L, []))} for L in need},\n        'maxDistinctLetters': max(len(set(t)) for t in PARAMS),\n        'letterInventory': ''.join(sorted(set(''.join(PARAMS)))),\n    }\n\ndef synth(text, repeats, nulls):\n    \"\"\"Known-answer array: one fresh glyph per letter, except the listed position pairs\n    (equal letters) share a glyph; nulls = {insert-before-index: null glyph id}.\"\"\"\n    g = list(range(len(text)))\n    for i, j in repeats:\n        assert text[i] == text[j]\n        g[j] = g[i]\n    out = []\n    for i in range(len(text) + 1):\n        out.extend(nulls.get(i, ()))\n        if i < len(text):\n            out.append(g[i])\n    return out\n\ndef repeat_pairs(text, n):\n    seen, out, used = {}, [], set()\n    for i, ch in enumerate(text):\n        if ch in seen and seen[ch] not in used and len(out) < n:\n            out.append((seen[ch], i)); used.update((seen[ch], i))\n        elif ch not in seen:\n            seen[ch] = i\n    return out\n\ndef selftest():\n    rep = {'vocabulary': vocabulary_report()}\n    assert rep['vocabulary']['expansions'] == 840\n    assert rep['vocabulary']['perLength']['32']['sha256'] == \\\n        'f64b62d0764290fe042b908e34ed11d48f9bdd8274c2426d59d4510442f7b8b3'\n    types = list(dict.fromkeys(CT))\n    mult = sorted(CT.count(g) for g in types)\n    assert len(CT) == 32 and len(types) == 29 and mult == [1] * 26 + [2] * 3\n    rep['masks'] = {'eq%d' % k: comb(29, k) for k in range(4)}\n    rep['masks']['le3'] = sum(comb(29, k) for k in range(4))\n    by = {}\n    for k in range(4):\n        for m in combinations(range(29), k):\n            L = 32 - sum(CT.count(types[i]) for i in m)\n            c = 3 - sum(CT.count(types[i]) == 2 for i in m)\n            by[(k, L, c)] = by.get((k, L, c), 0) + 1\n    rep['maskStrata'] = [{'nullTypes': k, 'survivingLength': L, 'survivingRepeatedTypes': c,\n                          'masks': n} for (k, L, c), n in sorted(by.items())]\n    d = draws(CT, SEED, NCTRL)\n    rep['controlDraws'] = {'n': len(d), 'sha256': digest([''.join(s) for s in d]),\n                           'distinct': len({''.join(s) for s in d})}\n    # --- synthetic controls (none uses the Z32 arrangement or its frozen shuffles) ---\n    syn = {}\n    t29, t30 = BYLEN[29][0], BYLEN[30][0]\n    ka1 = synth(t29, repeat_pairs(t29, 3), {5: ['n1'], 14: ['n2'], 23: ['n3']})\n    ka2 = synth(t30, repeat_pairs(t30, 2), {7: ['n1'], 19: ['n1']})\n    for name, arr, text, k in (('knownAnswer3Singles', ka1, t29, 3), ('knownAnswer1Double', ka2, t30, 1)):\n        ty = list(dict.fromkeys(arr))\n        assert len(arr) == 32 and len(ty) == 29\n        planted = tuple(i for i, g in enumerate(ty) if isinstance(g, str))\n        f = search(arr)\n        assert any(x[0] == k and x[2] == planted and x[3] == text for x in f)\n        key = key_of(arr, planted, text)\n        assert ''.join(dict(zip(ty, key))[g] for g in arr).replace('-', '') == text\n        relabel = {g: n for n, g in enumerate(reversed(ty))}\n        assert stats(search([relabel[g] for g in arr])) == stats(f)\n        syn[name] = {'plantedRecovered': True, 'relabelInvariant': True,\n                     'statsSha256': sha256(json.dumps(stats(f), sort_keys=True).encode()).hexdigest(),\n                     'le3.all': stats(f)['le3.all'], 'le3.constrained': stats(f)['le3.constrained']}\n    n = {L: len(BYLEN.get(L, ())) for L in range(26, 33)}\n    s = stats(search(list(range(32))))          # 32 singletons: pure counting identity\n    assert s['le3.all']['keys'] == n[32] + 32 * n[31] + comb(32, 2) * n[30] + comb(32, 3) * n[29]\n    assert s['le3.all']['readings'] == n[32] + n[31] + n[30] + n[29]\n    assert s['le3.constrained']['keys'] == 0\n    syn['allSingletons'] = {'keys': s['le3.all']['keys'], 'readings': s['le3.all']['readings']}\n    f = search(list('abcd' * 8))                # contradiction: period-4 array, no text fits\n    assert f == []\n    bad = list(ka1); bad[0], bad[1], bad[2], bad[3] = 'x', 'x', 'x', 'x'\n    bad[8], bad[9], bad[10], bad[11] = 'y', 'y', 'y', 'y'\n    bad[16], bad[17], bad[18] = 'z', 'z', 'z'; bad[20], bad[21], bad[22] = 'w', 'w', 'w'\n    f = search(bad)                             # contradiction: four runs, only three nulls\n    syn['contradictionRuns'] = {'fits': len(f)}\n    syn['contradictionPeriodic'] = {'fits': 0}\n    r = experiment(ka1, 9001, NCTRL)            # pipeline rehearsal on synthetic data only\n    syn['rehearsal'] = {'seed': 9001, 'le3.constrained.readings': r['le3.constrained']['readings'],\n                        'le3.all.readings': r['le3.all']['readings'],\n                        'summarySha256': sha256(json.dumps(r, sort_keys=True).encode()).hexdigest()}\n    rep['synthetic'] = syn\n    return rep\n\ndef run():\n    d = draws(CT, SEED, NCTRL)\n    fits = search(list(CT))\n    per = {}\n    for k, c, mask, text in fits:\n        e = per.setdefault(text, {'masksByNullTypes': [0] * (MAXNULL + 1), 'constrainedMasks': 0,\n                                  'valuePairs': sorted({(a, x) for _, a, x in PARAMS[text]})})\n        e['masksByNullTypes'][k] += 1\n        e['constrainedMasks'] += c >= 1\n    return {'controlDrawsSha256': digest([''.join(s) for s in d]),\n            'controlsEqualToObserved': sum(''.join(s) == CT for s in d),\n            'summary': experiment(list(CT), SEED, NCTRL),\n            'observedReadings': {t: per[t] for t in sorted(per)},\n            'observedKeys': sorted(key_of(CT, m, t) + ' ' + t for _, _, m, t in fits)}\n\nif __name__ == '__main__':\n    mode = sys.argv[1] if len(sys.argv) > 1 else 'selftest'\n    print(json.dumps(run() if mode == 'run' else selftest(), sort_keys=True, indent=1))\n"},"limitations":["Registration only. No fit of the Z32 arrangement or of its 199 frozen shuffles was computed, so this item says nothing about how many readings Z32 has in this family.","The family is narrow by construction: nulls are whole types, at most three, with one vocabulary of 840 strings. Position-dependent nulls, null single occurrences, more than three null types, nulls combined with routes, abbreviations or misspellings are other families and are not covered.","G, its bounds and its templates are experimental choices of the earlier goal; the 1970 letters do not specify them. Counts are relative to G.","Only three types repeat, so a mask tests at most three letter equalities. The family is weakly constrained, and the synthetic rehearsal showed no power to tell a planted answer from shuffles on that example. That is one example, not a power study.","The floor of 50 unconstrained readings makes eq3.all and le3.all uninformative about uniqueness; the constrained stratum was frozen to keep those budgets interpretable.","Shuffle controls keep the glyph multiset and calibrate only this frozen search. They do not account for the earlier choice of grammar and say nothing about whether any wording was intended.","The transcription is the report section 2 reading (29 types). The FBI worksheet count of 26 symbols is an unresolved discrepancy in that report; merged-type variants are not registered here.","The section 9 certificate was not rerun in this item. The Z13 report and the individual earlier item files were not read.","The program prints tailGE but not tailLE; the two-sided rule needs the tester to count tailLE from the control values, a mechanical step with no choice in it.","Synthetic control values came from one CPython 3 interpreter on this machine; the tester should confirm drawsSha256 and the self-test digest on their interpreter before anything else."],"changeConclusion":["The gate would fail if a tester cannot reproduce protocolSha256, codeSha256, drawsSha256, the vocabulary digests or the self-test output digest, or finds a parameter this registration leaves open.","A different transcription (merged or split glyph types) changes the masks, lengths and floor, and needs its own registration.","For the later test: a singleton in a cell where uniqueness is possible, with controls rarely giving one or more, would be model-relative uniqueness worth a hashed, independently checked prediction; many readings, or an observed value inside the control distribution, means nulls do not distinguish a decipherment.","An authenticated key, worksheet or second message in the same system (report section 8) would supersede this family entirely.","Nothing here changes the standing result: Z32 stays unsolved."]}